If you wish to delete or return an AS number that is no longer required, please email the APNIC hostmaster with your account name in the subject line.
While it’s not straightforward, it’s possible to get the account ID using the Amazon Resource Names (ARNs).
Since we now have the VPC id of the accepter VPC, we can use it’s ARN to extract the account-id. I am using the aws_vpc data source, and using the arn to extract the account-id.
Tagging is a good practice, especially if you have multiple peering connections and it’ll help during any maintenance or network troubleshooting.
We have a complete blogpost dedicated to tagging practices, and I highly recommend you check it out.
When querying an IP address or range, any associated route object will be returned with the inetnum object.
Use this form to perform regular updates on inetnum objects in the APNIC Whois Database, including updating additional routing attributes: To view or modify an exiting aut-num object, enter the aut-num of interest (for example, AS4777) below.When you do a cross-account peering connection request, you need the 12 digit account ID of the AWS account where the accepter VPC resides.If you’ve noticed, I have not defined this as a variable.I also touched upon some concepts of Terraform like data sources, split local values, and loops.You can find the complete terraform code for the above at our github repository.I have created a loop using count to cycle through all the route tables and create the route entry to the other VPC via the peering connection ID.