Loading repository data…
Loading repository data…
22MH1A42G1 / repository
Python Script for AWS Automation with Boto3. (Create a Python script using the AWS SDK (Boto3) to automate common AWS tasks, such as provisioning EC2 instances, uploading files to S3, and managing RDS databases.)
This project is a fully functional AWS Automation Dashboard, built using Streamlit and Boto3, designed to automate infrastructure tasks like launching EC2 instances, uploading files to S3, and managing RDS databases.
✅ Web-based interface for AWS tasks
✅ Secure .env file for credentials
✅ Modular structure with clean Python code
✅ Deployed and tested on Amazon EC2
AWS_MINI_PROJECT/
├── app.py # Streamlit Web Interface
├── .env # AWS keys and configuration
├── EC2/
│ └── create_ec2_instance_file.py
├── RDS/
│ ├── create_rds_instance.py
│ ├── delete_rds_instance.py
│ ├── create_snapshot.py
│ ├── modify_rds_instance.py
│ └── restore_from_snapshot.py
├── S3/
│ └── upload_to_s3.py
├── screenshots/
│ ├── ec2.png
│ ├── s3.png
│ └── rds.png
├── architecture_diagram.png
├── requirements.txt
└── README.md
git clone https://github.com/22MH1A42G1/Aws-Automation-With-Boto3.git
cd Aws-Automation-With-Boto3
.env file in the root directory and add the following content:AWS_ACCESS_KEY_ID=your_access_key
AWS_SECRET_ACCESS_KEY=your_secret_key
AWS_DEFAULT_REGION=ap-south-1
AMI_ID=ami-0ded8326293d3201b
KEY_PAIR_NAME=PemKey
EC2_INSTANCE_NAME=MyEC2Instance
RDS_USERNAME=admin
RDS_PASSWORD=Automation123
RDS_DB_INSTANCE=mydbinstance
RDS_SNAPSHOT_NAME=mysnapshot
RDS_RESTORE_INSTANCE=mynewdbinstance
.env to your .gitignore.pip install -r requirements.txt
pip install streamlit boto3 python-dotenv
python -m streamlit run app.py
# Visit the following URL in your browser:
http://localhost:8501
# Run this from your local machine:
ssh -i "PemKey.pem" ec2-user@<EC2-Public-IP>
# For Amazon Linux:
sudo yum update -y
sudo yum install python3 git -y
# For Ubuntu:
sudo apt update && sudo apt install python3-pip git -y
# Option 1: Clone from GitHub (requires your repo to be public or provide access):
git clone https://github.com/yourusername/aws-automation-dashboard.git
# Option 2: Use SCP to upload files:
scp -i PemKey.pem -r ./aws-automation-dashboard ec2-user@<EC2-Public-IP>:~/project
cd aws-automation-dashboard
# Paste your .env content again on EC2 manually or upload it via SCP.
#### g. Install Project Requirements on EC2
pip3 install -r requirements.txt
# Or manually:
pip3 install streamlit boto3 python-dotenv
streamlit run app.py --server.port 8501 --server.enableCORS false
# Open a browser on your local machine and visit:
http://<EC2-Public-IP>:8501
🎉 Done! You have successfully set up the AWS Automation Dashboard.























