Skip to content

ECS - Elastic Container Service

What is Amazon Elastic Container Service?#

  • Highly scalable and fast container management service
  • run, stop, and manage containers on a cluster.
  • containers are defined in a task definition - to run an individual task or task within a service
  • a service is a configuration that lets you run a number of tasks simultaneosly
  • You can run your tasks and services on a serverless infrastructure that’s managed by AWS Fargate or on a a cluster of Amazon EC2 instances
  • Integrated with Amazon Elastic Container Registry and Docker
  • CI/CD: monitors changes to source dir, Builds new Docker image, pushes to container registry (ecr) and updates your ecs service to use the new image
  • Supports service discovery
  • Sending logs and metrics to Amazon Cloudwatch

Launch Types#

  • Fargate - pay-as-you-go - run containers without having to manage your infrastructure
  • EC2 - configure and deploy ec2 instances in your cluster

Fargate better for large workloads requiring minimal overhead, small workloads with occasional bursts, tiny workloads and batch workloads EC2 better for workloads needing constantly high cpu and memeory, large workloads to optimise for price, access to persistent storage and you must self manage.

Managment#

Source#