This project demonstrates a Multi-Region Disaster Recovery (DR) System for cloud applications, ensuring high availability, automated failover, and minimal data loss in case of regional outages.
- Multi-region deployment with AWS
- Automated failover using Route53 health checks
- Stateless Dockerized application
- Replicated database instances
- Infrastructure as Code (Terraform)
- Health monitoring and failover scripts
- Primary Region: Handles live traffic under normal conditions
- Secondary Region: Standby for failover, maintains replicated data
- Route53 DNS: Monitors health and switches traffic automatically
- Application: Stateless Flask app in Docker
- Database: PostgreSQL instances replicated across regions
multi-region-dr/
├── README.md
├── infrastructure/
│ ├── provider.tf
│ ├── vpc.tf
│ ├── rds.tf
│ └── route53.tf
├── app/
│ ├── app.py
│ ├── requirements.txt
│ └── Dockerfile
└── scripts/
└── failover.py
- Provision Infrastructure
terraform init terraform plan terraform apply
- Build Docker App
docker build -t multi-region-app ./app
- Run App
docker run -p 80:80 multi-region-app
- Test Failover
python scripts/failover.py
- AWS Account with IAM permissions
- Terraform >= 1.5
- Docker
- Python 3.11+
- Boto3 library for AWS SDK in Python
- Route53 health checks
- Flask
/healthendpoint - Manual or automated failover testing
- Active-Active multi-region deployment
- Zero-downtime failover
- Chaos testing for disaster simulation
- Integration with Prometheus / CloudWatch for alerting
✨ I’m Sufyan bin Uzayr, an open-source developer passionate about building and sharing meaningful projects. You can learn more about me and my work at sufyanism.com or connect with me on Linkedin
🚀 Explore courses and resources in coding, tech, and development at zeba.academy and code.zeba.academy. Empower yourself with practical skills through curated tutorials, real-world projects, and hands-on experience. Level up your tech game today! 💻✨
Zeba Academy is a learning platform dedicated to coding, technology, and development.
➡ Visit our main site: zeba.academy
➡ Explore hands-on courses and resources at: code.zeba.academy
➡ Check out our YouTube for more tutorials: zeba.academy
➡ Follow us on Instagram: zeba.academy
Thank you for visiting!