Questions tagged [aws-ecs]

Use this tag for questions related to Amazon Elastic Container Services (ECS), which is a highly scalable, high-performance container orchestration service that supports Docker containers and allows you to run and scale containerized applications on AWS.

Amazon Elastic Container Service (Amazon ECS) is a highly scalable, high-performance container orchestration service that supports Docker containers and allows you to easily run and scale containerized applications on AWS.

Amazon ECS eliminates the need for you to install and operate your own container orchestration software, manage and scale a cluster of virtual machines, or schedule containers on those virtual machines.

Infrastructure Integration Amazon ECS makes it easy to build performant, modern applications on AWS and features AWS Fargate so you can deploy and manage containers without having to provision or manage any servers.  Amazon ECS is deeply integrated with key AWS services including Elastic Load Balancing, Amazon VPC, AWS IAM, Amazon ECR, AWS Batch, Amazon CloudWatch, AWS CloudFormation, AWS CodeBuild, AWS CodePipeline, AWS CloudTrail, and Route 53 AutoNaming for Service Discovery.

Benefits Cluster Management Made Easy Flexible Scheduling Performance at Scale Security Extensible

90 questions
74
votes
5 answers

ECS unable to assume role

From the console, I am invoking a lambda which submits a batch job. The batch job fails, indicating that ECS is unable to assume the role that is provided to execute the job definition. For the role, I've added the lambda and ECS services. The error…
Nate Reed
  • 6,761
  • 12
  • 53
  • 67
35
votes
9 answers

Why are AWS Batch Jobs stuck in RUNNABLE?

I use a computing environment of 0-256 m3.medium on demand instances. My Job definition requires 1 CPU and 3 GB of Ram, which m3.medium has. What are possible reasons why AWS Batch Jobs are stuck in state RUNNABLE? AWS says: A job that resides in…
arm
  • 605
  • 1
  • 7
  • 16
34
votes
2 answers

What vCPUs in Fargate really mean?

I was trying to get answers on my question here and here, but I understood that I need to know specifically Fargate implementation of vCPUs. So my question is: If I allocate 4 vCPUs to my task does that mean that my single-threaded app running on a…
Ruslan Plastun
  • 1,985
  • 3
  • 21
  • 48
32
votes
6 answers

How to get Task ID from within ECS container?

Hello I am interested in retrieving the Task ID from within inside a running container which lives inside of a EC2 host machine. AWS ECS documentation states there is an environment variable ECS_CONTAINER_METADATA_FILE with the location of this data…
code
  • 5,294
  • 16
  • 62
  • 113
25
votes
4 answers

How can I run commands in a running container in AWS ECS using Fargate

If I am running container in AWS ECS using EC2, then I can access running container and execute any command. ie. docker exec -it How can I run commands in the running container or access container in AWS ECS using Fargate?
Nitin
  • 2,701
  • 2
  • 30
  • 60
21
votes
1 answer

how to get list of registered targets in AWS target group via CLI

We are trying to get the state of a registered target (instance) in a target group. This can be done with the command aws elbv2 describe-target-health --target-group-arn ${TG} --targets Id=${ID},Port=${PORT}, reference. We are able to get the PORT…
Jose Martinez
  • 11,452
  • 7
  • 53
  • 68
19
votes
4 answers

How fast can ECS fargate boot a container?

What the the minimum/average time for AWS ECS Fargate to boot and run a docker image? For arguments sake, the 45MB anapsix/alpine-java image. I would like to investigate using ECS Fargate to speed up the process of building software locally on a…
Magnus
  • 7,952
  • 2
  • 26
  • 52
15
votes
4 answers

Mount S3 bucket as filesystem on AWS ECS container

I am trying to mount S3 as a volume on AWS ECS docker container using rexray/s3fs driver. I am able to do this on my local machine, where I installed plugin $docker plugin install rexray/s3fs and mounted S3 bucket on docker container. $docker…
Pratik Mungekar
  • 161
  • 1
  • 1
  • 5
14
votes
3 answers

AWS ECS: Run Tasks Failed Reasons : ["ATTRIBUTE"]

While trying to run a task in EC2 instances, I get this terrible error message. Run tasks failed Reasons : ["ATTRIBUTE"] Like many others, I was referred to check out the "requiresAttributes" section of my task where I found this list: …
Chad Van De Hey
  • 2,716
  • 3
  • 29
  • 46
11
votes
1 answer

What is the impact if my service exceeds 100% "Service CPU utilization"

AS per AWS docs: Service CPU utilization = (Total CPU units used by tasks in service) x 100 ------------------------------------------------------ (Total CPU units specified in task definition) x (number of tasks in service) ...so is there any…
vr00n
  • 550
  • 1
  • 4
  • 12
10
votes
7 answers

Set one lifecycle policy for all repositories in ECR

I curious if there is a way to set one common lifecycle policy, that will be applied to all repositories in ECR? Currently, as I understand there is no way to do it. One approach that I'm thinking about is to use JSON definition of lifecycle…
Alex
  • 115
  • 1
  • 5
9
votes
3 answers

AWS Fargate - pulling from a private repo

When searching for this it yields how to do this using ECS. This requires either putting a config file in a particular directory or setting env variables, neither of which are possible when using Fargate as it's serverless. I feel as if I'm missing…
Alex Jones
  • 360
  • 3
  • 14
8
votes
2 answers

How can I use docker compose on AWS Batch?

I have a multi-container (docker compose) application. I would like to scale it offline on AWS Batch for processing large volumes of data on S3. My .yml file for docker compose looks something like this: version: '2' services: container1: …
7
votes
1 answer

How to accurately report running task count in AWS Cloudwatch from AWS ECS

I have a simple Cloudwatch dashboard to monitor the running task count in a simple ECS cluster. AWS provides this documentation which is exactly what I want. The problem is it doesn't accurately reflect on my dashboard. Often my desired service…
bluescores
  • 4,437
  • 1
  • 20
  • 34
7
votes
4 answers

AWS Fargate Task Debugging, what does "CannotPullContainerError ... invalid reference format" mean?

I have docker container stored on AWS ECR, using this container I have created Task . When I run Task over Fargate , the service moves from PROVISIONING > PENDING (red color) > STOPPED states . There is no log either in Service Event , or CloudWatch…
1
2 3 4 5 6