Skip to content

Commit

Permalink
Move EKS examples off of old awsx Network (pulumi#516)
Browse files Browse the repository at this point in the history
  • Loading branch information
CyrusNajmabadi committed Jan 16, 2020
1 parent 610f175 commit ddf668c
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 6 deletions.
7 changes: 4 additions & 3 deletions aws-ts-eks-hello-world/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,11 @@ import * as pulumi from "@pulumi/pulumi";
const name = "helloworld";

// Create an EKS cluster with non-default configuration
const vpc = new awsx.Network("vpc", { usePrivateSubnets: false });
const vpc = new awsx.ec2.Vpc("vpc", { numberOfAvailabilityZones: 2 });

const cluster = new eks.Cluster(name, {
vpcId: vpc.vpcId,
subnetIds: vpc.subnetIds,
vpcId: vpc.id,
subnetIds: vpc.publicSubnetIds,
desiredCapacity: 2,
minSize: 1,
maxSize: 2,
Expand Down
6 changes: 3 additions & 3 deletions aws-ts-eks/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,12 @@ import * as awsx from "@pulumi/awsx";
import * as eks from "@pulumi/eks";

// Create a VPC for our cluster.
const vpc = new awsx.Network("vpc");
const vpc = new awsx.ec2.Vpc("vpc", { numberOfAvailabilityZones: 2 });

// Create the EKS cluster itself, including a "gp2"-backed StorageClass and a deployment of the Kubernetes dashboard.
const cluster = new eks.Cluster("cluster", {
vpcId: vpc.vpcId,
subnetIds: vpc.subnetIds,
vpcId: vpc.id,
subnetIds: vpc.publicSubnetIds,
instanceType: "t2.medium",
desiredCapacity: 2,
minSize: 1,
Expand Down

0 comments on commit ddf668c

Please sign in to comment.