| Key | Value |
|---|---|
| Services | ECS, ECR |
| Integrations | AWS CLI, CloudFormation, Docker |
| Categories | Containers; Serverless |
A demo application illustrating ECS container applications running locally using LocalStack. The application image is built using Docker, pushed to a local ECR registry, and deployed via CloudFormation to an ECS cluster.
- A valid LocalStack for AWS license. Your license provides a
LOCALSTACK_AUTH_TOKENto activate LocalStack. - Docker
localstackCLIawslocalCLI
make checkmake installexport LOCALSTACK_AUTH_TOKEN=<your-auth-token>
make startmake deployThe script:
- Creates a new ECR registry locally.
- Builds the application Docker image from the
nginxbase image. - Pushes the image to the ECR registry.
- Creates an ECS cluster and supporting infrastructure via CloudFormation.
- Deploys and starts the ECS application container in your local Docker environment.
Please refer to the templates/ folder for details about the CloudFormation templates for the ECS service.
You should see a success output in the terminal:
...
Sample app (nginx) successfully deployed.The nginx test app is accessible at http://localhost:45139/ after deployment.
This code is available under the Apache 2.0 license.