Deploy to AWS ECS + Fargate

From Docker Compose to AWS in one command

Stop wrestling with CloudFormation and Terraform. Deploy your entire Docker Compose stack to production-ready AWS infrastructure with a single command.

Trusted by developers — 40,000+ successful deployments

terminal

$ defang compose up --provider=aws

* Uploading build context for web

* Deploying service web

* Tailing logs for deployment ID a1b2c3d4 ;

2026-02-19T10:00:12Z cd Update succeeded ; provisioning...

2026-02-19T10:00:45Z web Listening on port 3000

* Done.

ENDPOINT: https://myapp-web--3000.prod1.defang.dev

Your Docker Compose app works locally. Now deploy it.

You run docker compose up and everything works. Getting that to production AWS shouldn't require a cloud engineering degree.

Without Defang

  • Rewrite your Docker Compose workflow for cloud-native services
  • Learn CloudFormation or Terraform
  • Configure VPCs, subnets, security groups
  • Set up ECS clusters, task definitions, services
  • Manage IAM roles and policies
  • Configure load balancers and SSL certificates
  • Wire up RDS, ElastiCache, secrets...

With Defang

  • Use your exact Docker Compose file — the one that already works locally
  • One command: defang compose up
  • Automatic VPC, ECS, ALB configuration
  • Least-privilege IAM by default
  • SSL certificates handled automatically
  • Add managed services with annotations

Production-ready AWS from your Docker Compose file

Defang reads your Docker Compose file and provisions everything. No rewrites, no new config format.

One Command Deploy

Run defang compose up and your entire Docker Compose application deploys to AWS ECS with Fargate. No Terraform, no CloudFormation, no complexity.

Your AWS Account

Unlike PaaS platforms, Defang deploys directly to your AWS account. You own and control your infrastructure while we handle the complexity.

Managed Services

Automatically provision RDS Postgres, ElastiCache Redis, DocumentDB MongoDB, and AWS Bedrock LLMs with compose annotations like x-defang-postgres and x-defang-llm.

Zero Downtime

Deploy with high_availability mode for rolling updates via AWS ECS. Your users never experience downtime during production deploys.

Cost Optimized

Choose affordable, balanced, or high_availability deployment modes. Pay AWS prices directly, not PaaS markup.

Agentic Apps

Deploy AI agent apps built with CrewAI, LangGraph, AutoGen, Strands, or n8n. Native managed LLMs, databases, and caching for your agents.

Deploy from Your IDE

Use Defang's MCP Server to deploy from Cursor, VS Code, Claude Code, Windsurf, or Kiro. Just run defang mcp setup and deploy without leaving your editor.

Named Stacks

Deploy multiple isolated environments from one compose file. Create dev, staging, and production stacks with defang stack new — each fully independent.

Security & Compliance

SOC 2 certified. CIS AWS Foundations compliant. Least-privilege IAM, encrypted secrets, and private networking by default.

Your Docker Compose file is ready. Deploy it.

If docker compose up works on your machine, you're one command away from production.

terminal

# Works locally?

$ docker compose up

✔ Container web Started

# Deploy the same file to AWS

$ defang compose up --provider=aws

* Done.

SOC 2 Certified · CIS AWS Foundations · AWS Marketplace