How to deploy multiple applications in a single ECS task?

Bhanu Reddy
2 min readAug 16, 2022
Ecs task containing different types of containers(applications)

OBJECTIVE: In this blog, I am going to explain how to deploy different types of containers in a single ECS task to have ease of communication between the applications. The above diagram is the architecture of the ECS service which is having ECS task with different types of applications(containers) in it.

Create a task definition with multiple applications inside the container definitions

Task Definition with multiple applications
Task with multiple containers

USE CASES:
— we can avoid using docker-compose which does not support on AWS ECS. — we can create CI CD pipelines to deploy the applications automatically.
— we can deploy complex applications like airflow and druid seamlessly.
— scaling becomes very easy, we just need to set the desired count on ECS.
— multiple container applications can communicate with each other without any extra effort as they all are inside one ECS task.

CONCLUSION:
AWS ECS (Elastic Container Service) is a container orchestration platform that allows clients to run and manage Docker containers in the AWS cloud.

Containers are a standardized package of software that runs reliably in different computing environments. They hold everything you need to run an application, including the code, runtime environment, system tools, libraries, and settings. You can use containers to run anything you want, from microservices to applications.

With AWS ECS, Amazon orchestrates the containers and provides developers the ability to automate and scale container deployment and upkeep. Unlike AWS EKS(Elastic Kubernetes Service), there is no cost for running an orchestration cluster. With AWS ECS pricing, you only pay for the underlying resources your containers use.

--

--