aws2oci is a comprehensive, open-source toolkit designed to help organizations migrate from AWS/GCP to Oracle Cloud Infrastructure (OCI) while providing ongoing cost monitoring and optimization capabilities.
Cloud costs can spiral out of control quickly. This tool was born from a real need after experiencing ~$7k in unexpected learning costs on AWS. aws2oci helps you:
- Discover your existing cloud infrastructure automatically
- Analyze costs and identify OCI equivalents for all your services
- Estimate potential savings (typically 30-70% cost reduction)
- Export migration plans as Terraform/Ansible code
- Monitor ongoing cloud spending to prevent surprise bills
- Optimize your cloud architecture for cost and performance
- Automatic discovery of AWS resources (EC2, RDS, S3, Lambda, and more)
- GCP resource discovery support
- Multi-account and multi-region scanning
- Comprehensive resource tagging and metadata capture
- Intelligent mapping from AWS/GCP services to OCI equivalents
- Confidence scoring for each mapping
- Alternative recommendations when direct mappings aren't available
- Customizable mapping rules via YAML
- Real-time pricing data from AWS, GCP, and OCI
- Historical pricing tracking and drift detection
- Detailed cost breakdowns by service, region, and resource
- Projected savings calculations
- ROI estimation for migration projects
- Generate production-ready Terraform configurations
- Export Ansible playbooks for configuration management
- Combined Terraform + Ansible workflows
- Modular, best-practice code structure
billingmonitorddaemon for 24/7 cost monitoring- Configurable alert thresholds
- Multiple notification channels (email, Slack)
- Anomaly detection for unexpected spending
- Primary: Oracle Cloud (OCI) and Cloudflare
- Source: AWS and GCP
- Extensible plugin system for additional providers
# Install from PyPI (when published)
pip install aws2oci
# Or install from source
git clone https://github.com/yourusername/aws2oci.git
cd aws2oci
pip install -e .# Initialize configuration
aws2oci config init
# Add AWS credentials (uses AWS CLI credentials by default)
aws2oci credentials add aws
# Add OCI credentials
aws2oci credentials add oci \
--tenancy-ocid ocid1.tenancy.oc1..xxx \
--user-ocid ocid1.user.oc1..xxx \
--fingerprint xx:xx:xx:xx:xx:xx \
--key-file ~/.oci/oci_api_key.pem# Discover your AWS infrastructure
aws2oci discover aws --all-regions
# Analyze costs and generate recommendations
aws2oci analyze cost --provider aws
# Export migration plan to Terraform
aws2oci export terraform --analysis-id 1 --output-dir ./terraform-migration
# Review the generated Terraform
cd terraform-migration
terraform init
terraform plan# Start the billing monitor daemon
aws2oci monitor start
# Set up an alert rule
aws2oci monitor alerts add \
--name "Monthly Budget" \
--type cost_threshold \
--threshold 5000 \
--channel email- Getting Started Guide
- CLI Reference
- Architecture Documentation
- Service Mappings
- API Reference
- Contributing Guide
┌─────────────────────────────────────────────────────────────────┐
│ User Interface Layer │
│ ┌──────────────┐ ┌──────────────┐ ┌──────────────────────┐ │
│ │ CLI Tool │ │ REST API │ │ Admin Dashboard │ │
│ └──────────────┘ └──────────────┘ └──────────────────────┘ │
└─────────────────────────────────────────────────────────────────┘
│
┌─────────────────────────────────────────────────────────────────┐
│ Application Layer │
│ ┌──────────────┐ ┌──────────────┐ ┌──────────────────────┐ │
│ │ Discovery │ │ Analysis │ │ Export │ │
│ │ Engine │ │ Engine │ │ Engine │ │
│ └──────────────┘ └──────────────┘ └──────────────────────┘ │
└─────────────────────────────────────────────────────────────────┘
│
┌─────────────────────────────────────────────────────────────────┐
│ Data Layer │
│ ┌──────────────┐ ┌──────────────┐ ┌──────────────────────┐ │
│ │ SQLite │ │ Config Files │ │ Encrypted Creds │ │
│ │ Database │ │ (JSON) │ │ (Keyring) │ │
│ └──────────────┘ └──────────────┘ └──────────────────────┘ │
└─────────────────────────────────────────────────────────────────┘
See ARCHITECTURE.md for detailed architecture documentation.
Analyze your current AWS spending and see how much you could save by migrating to OCI:
aws2oci discover aws
aws2oci analyze savings --show-recommendationsGenerate a complete migration plan with Infrastructure as Code:
aws2oci discover aws --services ec2,rds,s3
aws2oci analyze cost --provider aws
aws2oci export combined --output-dir ./migration-planMonitor your cloud spending and get alerted before costs spiral:
# Start daemon
aws2oci monitor start
# Configure alerts
aws2oci monitor alerts add --type percentage_increase --threshold 20Compare costs across multiple cloud providers:
aws2oci discover aws
aws2oci discover gcp
aws2oci analyze compare --providers aws,gcp,ociAWS to OCI Cost Comparison
==========================
Total Monthly Cost (AWS): $12,450.00
Total Monthly Cost (OCI): $4,235.00
Total Monthly Savings: $8,215.00 (66%)
Breakdown by Service:
┌─────────────────┬──────────────┬──────────────┬──────────────┬────────────┐
│ Service │ AWS Cost │ OCI Cost │ Savings │ Savings % │
├─────────────────┼──────────────┼──────────────┼──────────────┼────────────┤
│ Compute (EC2) │ $6,200.00 │ $2,100.00 │ $4,100.00 │ 66% │
│ Database (RDS) │ $3,800.00 │ $1,450.00 │ $2,350.00 │ 62% │
│ Storage (S3) │ $1,200.00 │ $485.00 │ $715.00 │ 60% │
│ Network │ $1,250.00 │ $200.00 │ $1,050.00 │ 84% │
└─────────────────┴──────────────┴──────────────┴──────────────┴────────────┘
Top Recommendations:
1. [HIGH] Migrate m5.2xlarge instances to VM.Standard.E4.Flex - Save $450/mo
2. [HIGH] Move to OCI for network egress (10TB free) - Save $890/mo
3. [MEDIUM] Use OCI Autonomous Database for RDS instances - Save $1,200/mo
Configuration is managed through JSON files with the following precedence:
~/.aws2oci/config.json(user configuration)$PWD/config.json(project configuration)$HOME/config.json(legacy location)
Example configuration:
{
"version": "1.0",
"providers": {
"oci": {
"enabled": true,
"default_region": "us-ashburn-1"
},
"aws": {
"enabled": true,
"default_region": "us-east-1"
}
},
"monitoring": {
"billingmonitord": {
"enabled": true,
"interval_minutes": 60
}
}
}See .env.example for all available configuration options.
Security is a top priority for aws2oci:
- Credential Storage: Uses system keyring (macOS Keychain, Windows Credential Manager, Linux Secret Service)
- Encryption: All sensitive data encrypted with Fernet (symmetric encryption)
- Least Privilege: Supports read-only IAM roles
- Audit Logging: All operations logged with timestamps
- No Plain Text: Credentials never stored in plain text
See Security Documentation for details.
Run aws2oci in a container:
# Build image
docker build -t aws2oci:latest .
# Run CLI
docker run -it --rm \
-v ~/.aws2oci:/root/.aws2oci \
-v ~/.aws:/root/.aws:ro \
aws2oci:latest aws2oci discover aws
# Run with docker-compose
docker-compose --profile daemon up -d # Start billing monitor
docker-compose --profile dashboard up -d # Start web dashboard# Clone repository
git clone https://github.com/yourusername/aws2oci.git
cd aws2oci
# Create virtual environment
python3 -m venv venv
source venv/bin/activate # On Windows: venv\Scripts\activate
# Install development dependencies
make install-dev
# Run tests
make test
# Run linters
make lint
# Format code
make format# Run all tests
make test
# Run specific test file
pytest tests/unit/test_discovery.py
# Run with coverage
make test
# Run integration tests
pytest tests/integration/We welcome contributions! Please see CONTRIBUTING.md for details.
See IMPLEMENTATION_ROADMAP.md for the detailed development plan.
Current status: Design Phase (Week 0)
- Architecture design
- Database schema
- AWS discovery engine
- Service mapping system
- Cost analysis engine
- Terraform/Ansible export
- Billing monitoring daemon
- CLI interface
- Web-based admin dashboard (React)
- Automated migration execution
- Azure and Alibaba Cloud support
- AI-powered cost optimization
- What-if scenario modeling
- Compliance checking
- Carbon footprint analysis
Q: Is aws2oci free? A: Yes, aws2oci is completely free and open source under the MIT license.
Q: Does aws2oci actually perform the migration? A: No, aws2oci generates the Infrastructure as Code (Terraform/Ansible) for you to review and execute. You maintain full control over the migration process.
Q: How accurate are the cost estimates? A: Cost estimates are based on current official pricing from cloud providers and are typically within ±5%. Always verify with your specific configuration.
Q: Will aws2oci work with my AWS organization? A: Yes, aws2oci supports multi-account AWS Organizations. Configure credentials for each account you want to analyze.
Q: Does it support private cloud deployments? A: Currently, aws2oci focuses on public cloud providers. Private cloud support may be added in future versions.
Q: How is this different from cloud provider migration tools? A: aws2oci is provider-agnostic, open source, and focused on cost transparency. It gives you full control and doesn't lock you into any vendor's migration service.
- Issues: GitHub Issues
- Discussions: GitHub Discussions
- Email: your.email@example.com
This project is licensed under the MIT License - see the LICENSE file for details.
Built with:
- Click - CLI framework
- SQLAlchemy - Database ORM
- FastAPI - API framework
- Boto3 - AWS SDK
- OCI Python SDK - Oracle Cloud SDK
- Your Name - Initial work
If you use aws2oci in your research or business, please cite:
@software{aws2oci2025,
author = {Your Name},
title = {aws2oci: Cloud Migration and Cost Management Toolkit},
year = {2025},
url = {https://github.com/yourusername/aws2oci}
}Made with by developers who care about cloud costs
Star this repository if you find it useful!