This project provides scripts and instructions for migrating a server to a cloud server on AWS. The project includes scripts for configuring the new cloud server instance, transferring data from the current server to the new server, and verifying that the new server is running as expected.
To get started, you'll need to have an AWS account and a running instance of a server that you want to migrate to AWS. You'll also need to have a basic understanding of the command line and basic server administration.
Before you begin, you'll need to install the AWS command line interface (CLI) on your current server:
bash
sudo apt-get update
sudo apt-get install awscli
You'll also need to configure the AWS CLI with your AWS access key and secret access key:
bash
aws configure
The configure_cloud_server.sh script can be used to configure a new cloud server instance on AWS. To use the script, you'll need to have an AWS key pair and security group set up in your AWS account.
bash
./configure_cloud_server.sh your_key.pem security_group_name
The transfer_data.sh script can be used to transfer data from the current server to the new cloud server instance using rsync and mysqldump. To use the script, you'll need to replace the placeholders with your own information:
bash
./transfer_data.sh /path/to/local/directory username@your.cloud.server /path/to/remote/directory username password database_name
The verify_cloud_server.sh script can be used to verify that the new cloud server instance is running as expected. The script checks the web server status and MySQL status.
bash
./verify_cloud_server.sh http://your.cloud.server username password
Contributions to this project are welcome. To contribute, please fork the repository and submit a pull request.