Skip to content

Commit

Permalink
Update default instance type to t3.medium (#1386)
Browse files Browse the repository at this point in the history
The current default, t2.medium, is an instance type from 2014 that is
becoming less common in AWS data centers. This means users will
encounter more errors when deploying clusters with the provider when
using the default instance type.

This mostly affects beginner users, as more experienced users typically
do not rely on the default instance types and instead configure
appropriate types for their workloads.

This change replaces the default t2.medium instances with t3.medium.
These newer instances offer better performance and are marginally
cheaper ($0.0416 vs. $0.0464 per hour).
  • Loading branch information
flostadler authored Sep 25, 2024
1 parent 7fdd859 commit ac7bdfe
Show file tree
Hide file tree
Showing 28 changed files with 61 additions and 61 deletions.
2 changes: 1 addition & 1 deletion nodejs/eks/cluster.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1358,7 +1358,7 @@ export interface ClusterOptions {
useDefaultVpcCni?: boolean;

/**
* The instance type to use for the cluster's nodes. Defaults to "t2.medium".
* The instance type to use for the cluster's nodes. Defaults to "t3.medium".
*/
instanceType?: pulumi.Input<aws.ec2.InstanceType | string>;

Expand Down
6 changes: 3 additions & 3 deletions nodejs/eks/nodegroup.ts
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ export interface NodeGroupBaseOptions {
nodeSubnetIds?: pulumi.Input<pulumi.Input<string>[]>;

/**
* The instance type to use for the cluster's nodes. Defaults to "t2.medium".
* The instance type to use for the cluster's nodes. Defaults to "t3.medium".
*/
instanceType?: pulumi.Input<string | aws.ec2.InstanceType>;

Expand Down Expand Up @@ -952,7 +952,7 @@ function createNodeGroupInternal(
{
associatePublicIpAddress: nodeAssociatePublicIpAddress,
imageId: amiId,
instanceType: args.instanceType || "t2.medium",
instanceType: args.instanceType || "t3.medium",
iamInstanceProfile: instanceProfile,
keyName: keyName,
securityGroups: pulumi
Expand Down Expand Up @@ -1424,7 +1424,7 @@ function createNodeGroupV2Internal(
`${name}-launchTemplate`,
{
imageId: amiId,
instanceType: args.instanceType || "t2.medium",
instanceType: args.instanceType || "t3.medium",
iamInstanceProfile: { arn: instanceProfileArn },
keyName: keyName,
instanceMarketOptions: marketOptions,
Expand Down
4 changes: 2 additions & 2 deletions provider/cmd/pulumi-gen-eks/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -353,7 +353,7 @@ func generateSchema() schema.PackageSpec {
},
"instanceType": {
TypeSpec: schema.TypeSpec{Type: "string"}, // TODO: aws.ec2.InstanceType is a string enum.
Description: "The instance type to use for the cluster's nodes. Defaults to \"t2.medium\".",
Description: "The instance type to use for the cluster's nodes. Defaults to \"t3.medium\".",
},
"instanceRole": {
TypeSpec: schema.TypeSpec{Ref: awsRef("#/resources/aws:iam%2Frole:Role")},
Expand Down Expand Up @@ -2035,7 +2035,7 @@ func nodeGroupProperties(cluster, v2 bool) map[string]schema.PropertySpec {
},
"instanceType": {
TypeSpec: schema.TypeSpec{Type: "string"}, // TODO: aws.ec2.InstanceType is a string enum.
Description: "The instance type to use for the cluster's nodes. Defaults to \"t2.medium\".",
Description: "The instance type to use for the cluster's nodes. Defaults to \"t3.medium\".",
},
"spotPrice": {
TypeSpec: schema.TypeSpec{Type: "string"},
Expand Down
8 changes: 4 additions & 4 deletions provider/cmd/pulumi-resource-eks/schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -302,7 +302,7 @@
},
"instanceType": {
"type": "string",
"description": "The instance type to use for the cluster's nodes. Defaults to \"t2.medium\"."
"description": "The instance type to use for the cluster's nodes. Defaults to \"t3.medium\"."
},
"keyName": {
"type": "string",
Expand Down Expand Up @@ -1253,7 +1253,7 @@
},
"instanceType": {
"type": "string",
"description": "The instance type to use for the cluster's nodes. Defaults to \"t2.medium\"."
"description": "The instance type to use for the cluster's nodes. Defaults to \"t3.medium\"."
},
"ipFamily": {
"type": "string",
Expand Down Expand Up @@ -1732,7 +1732,7 @@
},
"instanceType": {
"type": "string",
"description": "The instance type to use for the cluster's nodes. Defaults to \"t2.medium\"."
"description": "The instance type to use for the cluster's nodes. Defaults to \"t3.medium\"."
},
"keyName": {
"type": "string",
Expand Down Expand Up @@ -2000,7 +2000,7 @@
},
"instanceType": {
"type": "string",
"description": "The instance type to use for the cluster's nodes. Defaults to \"t2.medium\"."
"description": "The instance type to use for the cluster's nodes. Defaults to \"t3.medium\"."
},
"keyName": {
"type": "string",
Expand Down
2 changes: 1 addition & 1 deletion sdk/dotnet/Cluster.cs
Original file line number Diff line number Diff line change
Expand Up @@ -336,7 +336,7 @@ public InputList<Pulumi.Aws.Iam.Role> InstanceRoles
}

/// <summary>
/// The instance type to use for the cluster's nodes. Defaults to "t2.medium".
/// The instance type to use for the cluster's nodes. Defaults to "t3.medium".
/// </summary>
[Input("instanceType")]
public Input<string>? InstanceType { get; set; }
Expand Down
2 changes: 1 addition & 1 deletion sdk/dotnet/Inputs/ClusterNodeGroupOptionsArgs.cs
Original file line number Diff line number Diff line change
Expand Up @@ -168,7 +168,7 @@ public InputList<Pulumi.Aws.Ec2.SecurityGroup> ExtraNodeSecurityGroups
public Pulumi.Aws.Iam.InstanceProfile? InstanceProfile { get; set; }

/// <summary>
/// The instance type to use for the cluster's nodes. Defaults to "t2.medium".
/// The instance type to use for the cluster's nodes. Defaults to "t3.medium".
/// </summary>
[Input("instanceType")]
public Input<string>? InstanceType { get; set; }
Expand Down
2 changes: 1 addition & 1 deletion sdk/dotnet/NodeGroup.cs
Original file line number Diff line number Diff line change
Expand Up @@ -219,7 +219,7 @@ public InputList<Pulumi.Aws.Ec2.SecurityGroup> ExtraNodeSecurityGroups
public Pulumi.Aws.Iam.InstanceProfile? InstanceProfile { get; set; }

/// <summary>
/// The instance type to use for the cluster's nodes. Defaults to "t2.medium".
/// The instance type to use for the cluster's nodes. Defaults to "t3.medium".
/// </summary>
[Input("instanceType")]
public Input<string>? InstanceType { get; set; }
Expand Down
2 changes: 1 addition & 1 deletion sdk/dotnet/NodeGroupV2.cs
Original file line number Diff line number Diff line change
Expand Up @@ -220,7 +220,7 @@ public InputList<Pulumi.Aws.Ec2.SecurityGroup> ExtraNodeSecurityGroups
public Pulumi.Aws.Iam.InstanceProfile? InstanceProfile { get; set; }

/// <summary>
/// The instance type to use for the cluster's nodes. Defaults to "t2.medium".
/// The instance type to use for the cluster's nodes. Defaults to "t3.medium".
/// </summary>
[Input("instanceType")]
public Input<string>? InstanceType { get; set; }
Expand Down
2 changes: 1 addition & 1 deletion sdk/dotnet/Outputs/ClusterNodeGroupOptions.cs
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ public sealed class ClusterNodeGroupOptions
/// </summary>
public readonly Pulumi.Aws.Iam.InstanceProfile? InstanceProfile;
/// <summary>
/// The instance type to use for the cluster's nodes. Defaults to "t2.medium".
/// The instance type to use for the cluster's nodes. Defaults to "t3.medium".
/// </summary>
public readonly string? InstanceType;
/// <summary>
Expand Down
4 changes: 2 additions & 2 deletions sdk/go/eks/cluster.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions sdk/go/eks/nodeGroup.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions sdk/go/eks/nodeGroupV2.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 4 additions & 4 deletions sdk/go/eks/pulumiTypes.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 4 additions & 4 deletions sdk/java/src/main/java/com/pulumi/eks/ClusterArgs.java
Original file line number Diff line number Diff line change
Expand Up @@ -409,14 +409,14 @@ public Optional<Output<List<Role>>> instanceRoles() {
}

/**
* The instance type to use for the cluster&#39;s nodes. Defaults to &#34;t2.medium&#34;.
* The instance type to use for the cluster&#39;s nodes. Defaults to &#34;t3.medium&#34;.
*
*/
@Import(name="instanceType")
private @Nullable Output<String> instanceType;

/**
* @return The instance type to use for the cluster&#39;s nodes. Defaults to &#34;t2.medium&#34;.
* @return The instance type to use for the cluster&#39;s nodes. Defaults to &#34;t3.medium&#34;.
*
*/
public Optional<Output<String>> instanceType() {
Expand Down Expand Up @@ -1636,7 +1636,7 @@ public Builder instanceRoles(Role... instanceRoles) {
}

/**
* @param instanceType The instance type to use for the cluster&#39;s nodes. Defaults to &#34;t2.medium&#34;.
* @param instanceType The instance type to use for the cluster&#39;s nodes. Defaults to &#34;t3.medium&#34;.
*
* @return builder
*
Expand All @@ -1647,7 +1647,7 @@ public Builder instanceType(@Nullable Output<String> instanceType) {
}

/**
* @param instanceType The instance type to use for the cluster&#39;s nodes. Defaults to &#34;t2.medium&#34;.
* @param instanceType The instance type to use for the cluster&#39;s nodes. Defaults to &#34;t3.medium&#34;.
*
* @return builder
*
Expand Down
8 changes: 4 additions & 4 deletions sdk/java/src/main/java/com/pulumi/eks/NodeGroupArgs.java
Original file line number Diff line number Diff line change
Expand Up @@ -324,14 +324,14 @@ public Optional<InstanceProfile> instanceProfile() {
}

/**
* The instance type to use for the cluster&#39;s nodes. Defaults to &#34;t2.medium&#34;.
* The instance type to use for the cluster&#39;s nodes. Defaults to &#34;t3.medium&#34;.
*
*/
@Import(name="instanceType")
private @Nullable Output<String> instanceType;

/**
* @return The instance type to use for the cluster&#39;s nodes. Defaults to &#34;t2.medium&#34;.
* @return The instance type to use for the cluster&#39;s nodes. Defaults to &#34;t3.medium&#34;.
*
*/
public Optional<Output<String>> instanceType() {
Expand Down Expand Up @@ -1171,7 +1171,7 @@ public Builder instanceProfile(@Nullable InstanceProfile instanceProfile) {
}

/**
* @param instanceType The instance type to use for the cluster&#39;s nodes. Defaults to &#34;t2.medium&#34;.
* @param instanceType The instance type to use for the cluster&#39;s nodes. Defaults to &#34;t3.medium&#34;.
*
* @return builder
*
Expand All @@ -1182,7 +1182,7 @@ public Builder instanceType(@Nullable Output<String> instanceType) {
}

/**
* @param instanceType The instance type to use for the cluster&#39;s nodes. Defaults to &#34;t2.medium&#34;.
* @param instanceType The instance type to use for the cluster&#39;s nodes. Defaults to &#34;t3.medium&#34;.
*
* @return builder
*
Expand Down
8 changes: 4 additions & 4 deletions sdk/java/src/main/java/com/pulumi/eks/NodeGroupV2Args.java
Original file line number Diff line number Diff line change
Expand Up @@ -344,14 +344,14 @@ public Optional<InstanceProfile> instanceProfile() {
}

/**
* The instance type to use for the cluster&#39;s nodes. Defaults to &#34;t2.medium&#34;.
* The instance type to use for the cluster&#39;s nodes. Defaults to &#34;t3.medium&#34;.
*
*/
@Import(name="instanceType")
private @Nullable Output<String> instanceType;

/**
* @return The instance type to use for the cluster&#39;s nodes. Defaults to &#34;t2.medium&#34;.
* @return The instance type to use for the cluster&#39;s nodes. Defaults to &#34;t3.medium&#34;.
*
*/
public Optional<Output<String>> instanceType() {
Expand Down Expand Up @@ -1237,7 +1237,7 @@ public Builder instanceProfile(@Nullable InstanceProfile instanceProfile) {
}

/**
* @param instanceType The instance type to use for the cluster&#39;s nodes. Defaults to &#34;t2.medium&#34;.
* @param instanceType The instance type to use for the cluster&#39;s nodes. Defaults to &#34;t3.medium&#34;.
*
* @return builder
*
Expand All @@ -1248,7 +1248,7 @@ public Builder instanceType(@Nullable Output<String> instanceType) {
}

/**
* @param instanceType The instance type to use for the cluster&#39;s nodes. Defaults to &#34;t2.medium&#34;.
* @param instanceType The instance type to use for the cluster&#39;s nodes. Defaults to &#34;t3.medium&#34;.
*
* @return builder
*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -330,14 +330,14 @@ public Optional<InstanceProfile> instanceProfile() {
}

/**
* The instance type to use for the cluster&#39;s nodes. Defaults to &#34;t2.medium&#34;.
* The instance type to use for the cluster&#39;s nodes. Defaults to &#34;t3.medium&#34;.
*
*/
@Import(name="instanceType")
private @Nullable Output<String> instanceType;

/**
* @return The instance type to use for the cluster&#39;s nodes. Defaults to &#34;t2.medium&#34;.
* @return The instance type to use for the cluster&#39;s nodes. Defaults to &#34;t3.medium&#34;.
*
*/
public Optional<Output<String>> instanceType() {
Expand Down Expand Up @@ -1181,7 +1181,7 @@ public Builder instanceProfile(@Nullable InstanceProfile instanceProfile) {
}

/**
* @param instanceType The instance type to use for the cluster&#39;s nodes. Defaults to &#34;t2.medium&#34;.
* @param instanceType The instance type to use for the cluster&#39;s nodes. Defaults to &#34;t3.medium&#34;.
*
* @return builder
*
Expand All @@ -1192,7 +1192,7 @@ public Builder instanceType(@Nullable Output<String> instanceType) {
}

/**
* @param instanceType The instance type to use for the cluster&#39;s nodes. Defaults to &#34;t2.medium&#34;.
* @param instanceType The instance type to use for the cluster&#39;s nodes. Defaults to &#34;t3.medium&#34;.
*
* @return builder
*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,7 @@ public final class ClusterNodeGroupOptions {
*/
private @Nullable InstanceProfile instanceProfile;
/**
* @return The instance type to use for the cluster&#39;s nodes. Defaults to &#34;t2.medium&#34;.
* @return The instance type to use for the cluster&#39;s nodes. Defaults to &#34;t3.medium&#34;.
*
*/
private @Nullable String instanceType;
Expand Down Expand Up @@ -433,7 +433,7 @@ public Optional<InstanceProfile> instanceProfile() {
return Optional.ofNullable(this.instanceProfile);
}
/**
* @return The instance type to use for the cluster&#39;s nodes. Defaults to &#34;t2.medium&#34;.
* @return The instance type to use for the cluster&#39;s nodes. Defaults to &#34;t3.medium&#34;.
*
*/
public Optional<String> instanceType() {
Expand Down
2 changes: 1 addition & 1 deletion sdk/nodejs/cluster.ts
Original file line number Diff line number Diff line change
Expand Up @@ -317,7 +317,7 @@ export interface ClusterArgs {
*/
instanceRoles?: pulumi.Input<pulumi.Input<pulumiAws.iam.Role>[]>;
/**
* The instance type to use for the cluster's nodes. Defaults to "t2.medium".
* The instance type to use for the cluster's nodes. Defaults to "t3.medium".
*/
instanceType?: pulumi.Input<string>;
/**
Expand Down
Loading

0 comments on commit ac7bdfe

Please sign in to comment.