How to migrate to a new AWS Account
This guide will cover the steps I took to migrate from one AWSAccount to another specifically for Project Reclass Infrastructure.
Last updated
Was this helpful?
This guide will cover the steps I took to migrate from one AWSAccount to another specifically for Project Reclass Infrastructure.
Last updated
Was this helpful?
Beginning April 2021 AWS no longer allows domain transfer between AWS accounts via GUI. Thereby, the aws CLI must be utilized. .
. Ensure the permissions allow you to make changes to Route53
Initiate the domain transfer:
First you'll need to run aws configure
again in order to switch to the accepting account
Next you must accept the transfer
It is important to note that transferring a domain does not break any existing DNS records, this is due to the nameservers still being owned and operated by the original hosted zone, and by extension Route53. AWS explicitly tells us that the domain adn the DNS records do not need to be owned by the same account for routing to occur. While importing the hosted zone is likely the easiest way to migrate the domain, you may want to migrate and create records at your own pace. If this is the case remember you'll need to create a new hosted zone for the domain, remember to update the NS for the domain under Route53 -> Domains -> ${DOMAIN-NAME}
in the graphical environment.
In order to migrate the website in it's current state, create an AMI of the EC2 instance in which it is hosted, make this AMI private.
To create the AMI go to the EC2 list select the server you'd like to make an image from and go to Actions -> images and templates -> create image
Fill out the AMI image name and descritpion, enable no reboot if uptime is a must and then click "create image":
You'll be able to find a list of all AMI images on the sidebar under Images -> AMI
Finally select your AMI go to the permissions, and allow access to the new AWS Account by entering the new Account ID. Then you'll be able to access and launch the image. It'll be under the same sidebar Images -> AMI
and under the "Private" filter
Once the domain and image have been properly trasnferred add an A record pointing the domain projectreclass.org -> ${ip.ip.ip.ip}
to the new IP address of the newly launched server
Assuming everything has gone well thus far, migrating toynet should be simple. Toynet is deployed automatically utilizing Terraform code.
After the domain transfer has been accepted, you'll need to create a new hosted zone or .
It is recommended to first attach an Elastic IP with the ability to reassociate and attach it to the server and point it the domain at that. This will allow you to quickly reassociate the IP without having to change records in the event you want to change the endpoint of projectreclass.org.
And uploading the plan.json to the