diff --git a/lb2.py b/lb2.py index e8b6feb..2c5d14f 100644 --- a/lb2.py +++ b/lb2.py @@ -36,11 +36,12 @@ def create_vpc(ec2_client): return vpc_id -def create_subnet(ec2_client, vpc_id): +def create_subnet(ec2_client, vpc_id, availability_zone): # Create subnet response = ec2_client.create_subnet( VpcId=vpc_id, CidrBlock='10.0.1.0/24', + AvailabilityZone=availability_zone, TagSpecifications=[ { 'ResourceType': 'subnet',