In my opinion, Availability Zones in cdk.context.json should not include the account number. Availability Zones are region specific, not account specific.
Kind of related to #6929.
Example cdk.context.json after deploying a stack that uses/creates VPCs.
{
"availability-zones:account=<AccountId>:region=us-east-1": [
"us-east-1a",
"us-east-1b",
"us-east-1c",
"us-east-1d",
"us-east-1e",
"us-east-1f"
]
}
N/A
This is :bug: Bug Report
Availability Zone Names are account specific, surprisingly.
Pre...2018~ish (maybe earlier), they were shuffled where if you had a datacenter in iad , it could be mapped to us-east-1b in one account and us-east-1a in another account. When making cross-account VPC Peering that align with the datacenter (gotta get that low latency!) this is very important to map correctly on an account level, which may require sorting these based on the shuffled values.
Availability Zone Ids are not account specific, but Cloudformation does not yet support referencing by those.
@iph Interesting and makes sense.
I did some searching and found the explanation in the docs as well.
Thanks @iph for that jam! Im sure this issue, although closed will develop a life of it's own in the internet :)
Most helpful comment
Thanks @iph for that jam! Im sure this issue, although closed will develop a life of it's own in the internet :)