Skip to main content

Rails-like infrastructure management for AWS, Google Cloud, and DigitalOcean

Project description

InfraDSL - The Rails of Modern Infrastructure

"Infrastructure as simple as business logic"

InfraDSL brings Rails-like simplicity to cloud infrastructure management. Deploy production-ready applications to AWS, Google Cloud, and DigitalOcean with 95% less code than traditional tools. Currently, in active development. Any feedback is welcome!

🚀 Quick Start

Install

pip install infradsl

Deploy in 30 seconds

from infradsl import AWS, GoogleCloud, DigitalOcean

# Deploy a web server in one line
server = AWS.EC2("web-server").t3_micro().ubuntu().service("nginx").create()

# Container app to Google Cloud Run
app = GoogleCloud.CloudRun("my-app").container("webapp", "./src").public().create()

# Complete production stack
database = AWS.RDS("app-db").postgresql().production().create()
storage = AWS.S3("app-assets").website().public().create()
api = AWS.ECS("app-api").fargate().container("api:latest").create()

Result: Production infrastructure with auto-scaling, HTTPS, monitoring, and enterprise security.

🎯 Revolutionary Features

Cross-Cloud Magic

InfraDSL automatically selects optimal cloud providers per service based on cost, performance, and compliance:

from infradsl import InfraDSL

app = InfraDSL.Application("my-app")
    .auto_optimize()
    .database("postgresql")      # → GCP (best price/performance)
    .compute("web-servers")      # → AWS (best global coverage)
    .cdn("static-assets")        # → Cloudflare (best edge network)
    .storage("user-uploads")     # → DigitalOcean (best simplicity)
    .create()

Universal Provider Support

  • AWS: EC2, ECS, RDS, S3, Lambda, CloudFront, Route53
  • Google Cloud: GKE, Cloud Run, Compute Engine, Cloud SQL, Cloud Storage
  • DigitalOcean: Droplets, Kubernetes, Databases, Spaces, Load Balancers
  • Cloudflare: CDN, DNS, Workers, R2 Storage, SSL/TLS

CLI Commands

infradsl init my-project aws          # Initialize new project
infradsl preview main.py              # Preview changes
infradsl apply main.py                # Deploy infrastructure
infradsl destroy main.py              # Clean up resources
infradsl doctor                       # Check setup and diagnose issues

🔧 Setup & Authentication

AWS Credentials

# Via AWS CLI
aws configure

# Or environment variables
export AWS_ACCESS_KEY_ID=your_access_key
export AWS_SECRET_ACCESS_KEY=your_secret_key
export AWS_DEFAULT_REGION=us-east-1

Google Cloud Credentials

# Via gcloud CLI
gcloud auth application-default login

# Or service account key
export GOOGLE_APPLICATION_CREDENTIALS=path/to/service-account.json

DigitalOcean Token

export DIGITALOCEAN_TOKEN=your_do_token

💻 Usage Examples

AWS Infrastructure

from infradsl import AWS

# Simple web server
server = AWS.EC2("web-server").t3_micro().ubuntu().create()

# Production API with load balancer
api = (AWS.ECS("production-api")
    .fargate()
    .container("api:latest")
    .auto_scale(min=2, max=50)
    .load_balancer()
    .create())

# Database with automated backups
db = (AWS.RDS("app-db")
    .postgresql()
    .production()
    .encrypted()
    .create())

Google Cloud

from infradsl import GoogleCloud

# Serverless container
app = (GoogleCloud.CloudRun("my-app")
    .container("webapp", "./src")
    .public()
    .create())

# Kubernetes cluster
cluster = (GoogleCloud.GKE("production")
    .location("us-central1")
    .auto_scale(min_nodes=3, max_nodes=20)
    .create())

DigitalOcean

from infradsl import DigitalOcean

# Simple droplet
droplet = (DigitalOcean.Droplet("web-server")
    .size("s-2vcpu-2gb")
    .region("nyc1")
    .create())

# Kubernetes cluster
cluster = (DigitalOcean.Kubernetes("app-cluster")
    .region("fra1")
    .nodes(3)
    .create())

🏗️ Key Benefits

95% Code Reduction

  • Kubernetes YAML: 500+ lines → 1 line
  • Terraform: 100+ lines → 1 line
  • Docker Configuration: 50+ lines → 0 lines (automatic)

Developer Experience

  • Time to Production: Days → Minutes
  • Learning Curve: Weeks → 5 minutes
  • Rails-like Simplicity: Intuitive, chainable API

Production Ready

  • Security: Automatic best practices
  • Auto-scaling: Built-in by default
  • Monitoring: Enterprise-grade observability

🛣️ What's Next

  • Template Marketplace: Reusable infrastructure patterns
  • Cost Optimization: Automatic resource rightsizing
  • Multi-Cloud Intelligence: Cross-provider optimization
  • IDE Integration: VS Code and JetBrains extensions

📚 Documentation

Visit https://docs.infradsl.dev for complete documentation, tutorials, and examples.

🤝 Contributing

We welcome contributions! Check out our GitHub repository for issues and contribution guidelines.


Built with ❤️ for Engineers who want to ship, not configure infrastructure.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

infradsl-0.1.4.tar.gz (1.3 MB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

infradsl-0.1.4-py3-none-any.whl (1.6 MB view details)

Uploaded Python 3

File details

Details for the file infradsl-0.1.4.tar.gz.

File metadata

  • Download URL: infradsl-0.1.4.tar.gz
  • Upload date:
  • Size: 1.3 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.5

File hashes

Hashes for infradsl-0.1.4.tar.gz
Algorithm Hash digest
SHA256 142b6a95683ed4d7fb6576d516cb46f156b6aa27536c19d91ac6d7976046ed62
MD5 c753eab56bc0cea94bfd7403763b0101
BLAKE2b-256 bd543cbf8fd8f65efe435f37d595ff2cb9cb99e12dde8324b9e8534f312851e7

See more details on using hashes here.

File details

Details for the file infradsl-0.1.4-py3-none-any.whl.

File metadata

  • Download URL: infradsl-0.1.4-py3-none-any.whl
  • Upload date:
  • Size: 1.6 MB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.5

File hashes

Hashes for infradsl-0.1.4-py3-none-any.whl
Algorithm Hash digest
SHA256 a0057c5d2c425667cda5cb21eb6738b587a17c95eb60a9f7122739b9a8c49d3c
MD5 f2fa95cc80a36758564b1c1871dfa488
BLAKE2b-256 66ee2aceae835b2f3f223035957f2665a7b54f7583f464559466c504fd23ff15

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page