Skip to content

Commit

Permalink
Merge pull request #454 from jjuan97/fix/aws-region-duplicate
Browse files Browse the repository at this point in the history
Fix error value (us-east-1us-east-1a) for parameter availabilityZone is invalid
  • Loading branch information
ericzbeard authored Oct 24, 2024
2 parents 2d4712f + a35074b commit 96e82a2
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 60 deletions.
52 changes: 12 additions & 40 deletions VPC/VPC_With_Managed_NAT_And_Private_Subnet.json
Original file line number Diff line number Diff line change
Expand Up @@ -67,17 +67,10 @@
"Ref": "VPC"
},
"AvailabilityZone": {
"Fn::Sub": [
"${AWS::Region}${AZ}",
"Fn::Select": [
0,
{
"AZ": {
"Fn::Select": [
0,
{
"Fn::GetAZs": null
}
]
}
"Fn::GetAZs": null
}
]
},
Expand Down Expand Up @@ -132,17 +125,10 @@
"Ref": "VPC"
},
"AvailabilityZone": {
"Fn::Sub": [
"${AWS::Region}${AZ}",
"Fn::Select": [
1,
{
"AZ": {
"Fn::Select": [
1,
{
"Fn::GetAZs": null
}
]
}
"Fn::GetAZs": null
}
]
},
Expand Down Expand Up @@ -197,17 +183,10 @@
"Ref": "VPC"
},
"AvailabilityZone": {
"Fn::Sub": [
"${AWS::Region}${AZ}",
"Fn::Select": [
0,
{
"AZ": {
"Fn::Select": [
0,
{
"Fn::GetAZs": null
}
]
}
"Fn::GetAZs": null
}
]
},
Expand Down Expand Up @@ -261,17 +240,10 @@
"Ref": "VPC"
},
"AvailabilityZone": {
"Fn::Sub": [
"${AWS::Region}${AZ}",
"Fn::Select": [
1,
{
"AZ": {
"Fn::Select": [
1,
{
"Fn::GetAZs": null
}
]
}
"Fn::GetAZs": null
}
]
},
Expand Down
32 changes: 12 additions & 20 deletions VPC/VPC_With_Managed_NAT_And_Private_Subnet.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -43,11 +43,9 @@ Resources:
Type: AWS::EC2::Subnet
Properties:
VpcId: !Ref VPC
AvailabilityZone: !Sub
- ${AWS::Region}${AZ}
- AZ: !Select
- 0
- !GetAZs
AvailabilityZone: !Select
- 0
- !GetAZs
CidrBlock: !FindInMap
- SubnetConfig
- Public0
Expand All @@ -71,11 +69,9 @@ Resources:
Type: AWS::EC2::Subnet
Properties:
VpcId: !Ref VPC
AvailabilityZone: !Sub
- ${AWS::Region}${AZ}
- AZ: !Select
- 1
- !GetAZs
AvailabilityZone: !Select
- 1
- !GetAZs
CidrBlock: !FindInMap
- SubnetConfig
- Public1
Expand All @@ -99,11 +95,9 @@ Resources:
Type: AWS::EC2::Subnet
Properties:
VpcId: !Ref VPC
AvailabilityZone: !Sub
- ${AWS::Region}${AZ}
- AZ: !Select
- 0
- !GetAZs
AvailabilityZone: !Select
- 0
- !GetAZs
CidrBlock: !FindInMap
- SubnetConfig
- Private0
Expand All @@ -126,11 +120,9 @@ Resources:
Type: AWS::EC2::Subnet
Properties:
VpcId: !Ref VPC
AvailabilityZone: !Sub
- ${AWS::Region}${AZ}
- AZ: !Select
- 1
- !GetAZs
AvailabilityZone: !Select
- 1
- !GetAZs
CidrBlock: !FindInMap
- SubnetConfig
- Private1
Expand Down

0 comments on commit 96e82a2

Please sign in to comment.