@@ -40,16 +40,18 @@ type CreateMachinepoolUserOptions struct {
4040}
4141
4242const (
43- use = "machinepool"
44- short = "Add machine pool to cluster"
45- long = "Add a machine pool to the cluster."
46- example = ` # Interactively add a machine pool to a cluster named "mycluster"
43+ // DefaultInstanceType is the default AWS instance type for new machine pools.
44+ DefaultInstanceType = "m7i.xlarge"
45+ use = "machinepool"
46+ short = "Add machine pool to cluster"
47+ long = "Add a machine pool to the cluster."
48+ example = ` # Interactively add a machine pool to a cluster named "mycluster"
4749 rosa create machinepool --cluster=mycluster --interactive
48- # Add a machine pool mp-1 with 3 replicas of m5 .xlarge to a cluster
49- rosa create machinepool --cluster=mycluster --name=mp-1 --replicas=3 --instance-type=m5 .xlarge
50- # Add a machine pool mp-1 with autoscaling enabled and 3 to 6 replicas of m5 .xlarge to a cluster
50+ # Add a machine pool mp-1 with 3 replicas of m7i .xlarge to a cluster
51+ rosa create machinepool --cluster=mycluster --name=mp-1 --replicas=3 --instance-type=m7i .xlarge
52+ # Add a machine pool mp-1 with autoscaling enabled and 3 to 6 replicas of m7i .xlarge to a cluster
5153 rosa create machinepool --cluster=mycluster --name=mp-1 --enable-autoscaling \
52- --min-replicas=3 --max-replicas=6 --instance-type=m5 .xlarge
54+ --min-replicas=3 --max-replicas=6 --instance-type=m7i .xlarge
5355 # Add a machine pool with labels to a cluster
5456 rosa create machinepool -c mycluster --name=mp-1 --replicas=2 --instance-type=r5.2xlarge --labels=foo=bar,bar=baz,
5557 # Add a machine pool with spot instances to a cluster
@@ -64,7 +66,9 @@ type CreateMachinepoolOptions struct {
6466}
6567
6668func NewCreateMachinepoolUserOptions () * CreateMachinepoolUserOptions {
67- return & CreateMachinepoolUserOptions {}
69+ return & CreateMachinepoolUserOptions {
70+ InstanceType : DefaultInstanceType ,
71+ }
6872}
6973
7074func (m * CreateMachinepoolOptions ) Machinepool () * CreateMachinepoolUserOptions {
@@ -130,7 +134,7 @@ func BuildMachinePoolCreateCommandWithOptions() (*cobra.Command, *CreateMachinep
130134 flags .StringVar (
131135 & options .InstanceType ,
132136 "instance-type" ,
133- "m5.xlarge" ,
137+ DefaultInstanceType ,
134138 "Instance type that should be used." ,
135139 )
136140
0 commit comments