This Python SDK provides modularized management of AWS infrastructure resources using boto3. It simplifies tasks such as creating Virtual Private Clouds (VPCs), launching EC2 instances, managing security groups, and more.
The SDK is structured into individual modules for different AWS resources:
- VPC Module: Handles VPC creation and management.
- EC2 Instance Module: Manages EC2 instance launching and configuration.
- Security Group Module: Facilitates security group creation and rules management.
- Subnet Module: Supports subnet creation and configuration.
- Internet Gateway Module: Provides functionality for managing internet gateways.
- Route Table Module: Manages route tables and associations with subnets for network traffic routing.
- Auto Scaling Group Module: Facilitates creation and management of auto-scaling groups and launch configurations for dynamic instance scaling.
-
Code Organization: Each module encapsulates logic specific to its AWS resource, enhancing code organization and readability.
-
Reusability: Modules can be reused across projects or within the same project for different infrastructure components, promoting code reusability.
-
Scalability: Easily add new modules for additional AWS resources or modify existing ones without impacting other parts of the SDK.
Before installing the SDK, ensure:
- Python 3.9+ is installed on your system.
- AWS credentials are configured:
- Either through environment variables (
AWS_ACCESS_KEY_IDandAWS_SECRET_ACCESS_KEY). - Or using AWS CLI configuration (
aws configure).
- Either through environment variables (
python3 -m venv path/to/venv
source path/to/venv/bin/activate
python3 -m pip install -r requirements.txt python3 modules/main.pypython3 pip install pytest
pytest test/
docker build -t myimage . docker run -p 4000:80 myimagedocker build -t mytestimage .
docker run mytestimage
curl -sSL https://install.python-poetry.org | python3 -poetry initpoetry install poetry run python modules/main.pypoetry add --dev pytest
poetry run pytest