refactor: remove explicit availability zone constraint from public subnet configuration

This commit is contained in:
vickytechkey 2026-08-07 10:05:38 +05:30
parent db147d6d66
commit 7522ce69b2

View file

@ -51,7 +51,7 @@ export class AwsCdkStack extends cdk.Stack {
// 3. Define the EC2 Instance (t4g.medium)
const instance = new ec2.Instance(this, 'internalsInstance', {
vpc,
vpcSubnets: { subnetType: ec2.SubnetType.PUBLIC, availabilityZones: ['ap-south-1b', 'ap-south-1c'] },
vpcSubnets: { subnetType: ec2.SubnetType.PUBLIC },
instanceType: ec2.InstanceType.of(ec2.InstanceClass.T4G, ec2.InstanceSize.MEDIUM),
machineImage: ec2.MachineImage.fromSsmParameter(
'/aws/service/canonical/ubuntu/server/24.04/stable/current/arm64/hvm/ebs-gp3/ami-id'