Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange
Join us in building a kind, collaborative learning community via our updated Code of Conduct.

Questions tagged [amazon-ecs]

Amazon EC2 Container Service (ECS) is a highly scalable, high performance container management service that supports Docker containers and allows you to easily run applications on a managed cluster of Amazon EC2 instances.

0
votes
0answers
13 views

None of these Availability Zones contains a healthy target. Requests are being routed to all targets [on hold]

I want to deploy a docker container using Fargate. I created an ECS instance but when I put the DNS name in the browser I get 503 Service Temporarily Unavailable. How can I get health target ? ...
0
votes
0answers
13 views

Redirect ephemeral port to 80

I am starting in AWS and server management in general and just set up a deployment pipeline with ECS and some containers. My container : My host port is 0 and redirected to container port 4200 (...
0
votes
0answers
16 views

java.sql.SQLException: Driver:org.postgresql.Driver@******** returned null for URL:jdbc:postgresql://… --port=5432

I want to deploy a docker image with AWS. I use 2 services:RDS database(POSTGRESQL) and ECS as a container for the deployment. I can connect to the database using https://docs.aws.amazon.com/...
0
votes
0answers
29 views

503 Service Temporarily Unavailable AWS

I followed this tutorial https://medium.com/@remy.dewolf/aws-fargate-first-hands-on-experience-and-review-1b52fca2148e but in the end when I copy-paste the DNS name I get that the service is ...
0
votes
1answer
14 views

Gerrit ssh users on EC2/ECS

I'm trying to deploy gerrit code review to AWS and am running into problems with trying to ssh in once it's deployed. When I've created a new user, what does work is SSH tunneling in like ssh -fNL ...
0
votes
2answers
18 views

ecs instances generated via Auto Scaling group not registering to ecs cluster

I have created an ECS cluster linked to an Autoscaling group with an Application load balancer attached. The Autoscaling deploys the instances, the AMI is correctly choosen (ECS optimized). for ...
0
votes
0answers
16 views

How to secure AWS RDS MySql password for Docker Wordpress

I am relatively new to Wordpress and need help on how to secure AWS RDS mysql password. Currently I am providing the password in Task Definition as environment variables. These are picked up and wp-...
0
votes
0answers
68 views

ALB Connection Draining is always reaching the “Deregistration Delay”

I'm using ECS along with ALB to expose my containers to the internet. When I'm updating a container image (I'm using CloudFormation to update the tasks and services), the target group set the ...
0
votes
0answers
71 views

Nuxt SSR reverse proxy through Nginx on AWS ELB

I'm trying to set up a frontend application using Nuxt on AWS ECS. Architecture EC2: Within each EC2 instance: Nuxt is being served on port 3000 Nginx reverse proxies from port 80 to Nuxt's port ...
0
votes
1answer
75 views

How do you tag EC2 instances spawned by ECS in Terraform?

I have an ECS service that spawns some containers: resource "aws_ecs_service" "rocketchat" { name = "rocketchat-ecs-service" cluster = "${aws_ecs_cluster.rocketchat.id}" ...
0
votes
1answer
51 views

How do I find out the reason a task instance gets deregistered?

We have a bunch of services running in ECS. All of them are set to run at least two instances. With some of the services I notice that at irregular intervals one of the instances gets de-registered. ...
0
votes
0answers
18 views

The idiomatic approach to mounting “configuration” volumes on ECS?

I have a docker container that I would like to "port" to ECS. My Dockerfile contains a VOLUME instruction: VOLUME /app/configuration So using docker on a linux machine, you just point to the ...
1
vote
0answers
25 views

In ECS, how to mount container's user home and host's user home?

In ECS, how can I mount volumes the container's userhome and host's user home? "containerDefinitions": [ { "name": "web", "image": "nginx", "cpu": 99, "memory": 100, "portMappings": [ { "...
1
vote
1answer
69 views

Why does creating a service in AWS ECS require the ecs:CreateService permission on all resources?

I'm trying to create a service on AWS ECS, using CloudFormation. The user trying to create service has a role granting it the ecs:CreateService permission on the cluster that will host the service. ...
2
votes
1answer
306 views

HEALTHCHECK in ECS Container

I'm struggling setting up the correct HEALTHCHECK for a Container inside Task Definition in Amazon ECS. I've tried multiple solutions and can't get the simplest "always true" healthcheck to actually ...
0
votes
1answer
87 views

Why do I get an “empty reply from server” from AWS ECS?

I have a web service in a Docker image to which I am trying to upload two files: a 6MB file and an 18MB file. When running in my local Docker service, both files upload fine. With the same image in ...
0
votes
0answers
53 views

AWS - ECS with ELB not working, instance IP works though

I've set up an ECS cluster with a single container, with an ELB to serve the traffic to it. The ELB listener is HTTPS/443, and the host listener is HTTP/8080. I.e. when you hit the URL it's HTTPS but ...
3
votes
1answer
100 views

Assigning a domain name to an AWS Fargate task

I have an AWS Fargate task running a web app in a public subnet so it has a public address. My question is how to I connect a domain (through Route 53) to that task, so that nothing breaks when I ...
0
votes
0answers
73 views

Configure CloudWatch stream name using ECS Container Name

I'm using awslogs for Docker containers within ECS, and I would like to use the image name as the stream name in CloudWatch. However, I'm not sure where this logic should be placed. /etc/docker/...
0
votes
1answer
154 views

Routing HTTP traffic to user specific Docker containers dynamically

I am attempting to architect a service which would run user specific java processes within Docker containers in AWS (ECS most likely). One java process per container per user. The only exception to ...
0
votes
1answer
21 views

How do AWS ECS Task Definition updates work?

I have an ECS Service running a task definition. Whenever I push a new task definition out, I know there is some blue-green logic to drain the previous task before rerouting to the new task. What ...
2
votes
3answers
1k views

HealthCheck on ECS task without an ELB

We have a Docker container(Spring Boot) that runs in an ECS cluster. We run it without Elastic Load Balancing. We want to update the service without downtime, so when the new task is up and healthy,...
0
votes
1answer
110 views

AWS ECS: Service + autoscaling vs User Data launching Task

Trying to wrap my head around ECS using EC2 launch (not Fargate, at least for now). Assume a single long-running task that I want to launch with every container instance. The intended mechanism for ...
3
votes
1answer
242 views

AWS ECS: Unable to place task

I am trying to set up an AWS service with autoscaling. I have created a cluster with an application loadbalancer and created a task using a docker image that should be open on port 8080 for use. I ...
0
votes
0answers
64 views

How to configure routing between docker containers running on single EC2 instance using AWS Network Load Balancer?

I have a setup where I have ECS Cluster with a single EC2 instance with multiple Docker containers registering to a Network Load Balancer target group with random ports. Target group reports targets ...
0
votes
0answers
139 views

How to configure ipv6 for docker which is hosted in Amazon EC2?

I have been facing issue in configuring ipv6 in docker which is on AWS EC2. If i run ping6 google.com is working from the EC2 host. But the same not working inside the container but ipv4 is working on ...
1
vote
1answer
359 views

ECR cross-account pull permissions

We have two AWS accounts. Account A has ECR repositories and Account B is meant to be able to pull from them. I have tried setting the repository permission statements in Account A to allow pulling ...
0
votes
1answer
213 views

AWS ECS Cannot start task

I am trying run a task definition I have in AWS ECS. I have a default cluster, and I've got a Container Instance launched on it, and I'm trying to run a task definition I've got on the instance. The ...
0
votes
1answer
202 views

Fixed IP address, hosting via Docker in AWS ECS

We want to host our software on AWS via Docker using ECS. However, our software must connect to an external service, and they limit our access based on IP address. Is it possible to have fixed IP ...
0
votes
0answers
174 views

Autoscaling AWS ECS services with soft limits

As per the service utilization documentation it is possible to have a Memory utilizations over 100% when using soft limits in the ECS tasks (because you don't want to kill your app with hard limits). ...
1
vote
1answer
714 views

how to pull docker image on ECR using cloudformation template

I want to use docker image hosted on ECR and i want to automate the pull operation using cloudformation template. I attached IAM role with ECR full access to ec2 instance and it doesn't work. i am ...
0
votes
1answer
22 views

Low req/s ratio on EC2 machine on PHP Hello World

I’m having a problem with AWS. Im using Elastic Container Service that is created as on link https://docs.aws.amazon.com/AmazonECS/latest/developerguide/launch_container_instance.html Instance type ...
0
votes
0answers
102 views

No network connection on Multiple docker container in Elastic Beanstalk

I'm trying to deploy a multiple docker container to Elastic Beanstalk. There is two containers, one for the supervisor+uwsgi+django application and one for the JavaScript frontend. Using docker-...
0
votes
0answers
296 views

ECS Container instance without public ip

I have an ECS Cluster in my private subnet and a NAT instance for external outbound connectivity. Everything works great, but AWS always attaches an public ip (which is not needed) on any new EC2 ...
0
votes
0answers
87 views

Error message: The Auto Scaling group can't be updated in the CloudFormation stack

One of my ec2 instance in my cluster 'prod' seems to have lost connection with the cluster. The 'agent connected' status is false and no task is running on the instance. I therefore have drained the ...
0
votes
0answers
43 views

aws ecs does not spawn new ec2 instance after an instance is drained and deregistered

One of my ec2 instance in my cluster 'prod' seems to have lost connection with the cluster. The 'agent connected' status is false and no task is running on the instance. I therefore have drained the ...
0
votes
1answer
79 views

Is it possible to use IAM roles for ECS tasks in an Elastic Beanstalk application?

I maintain a project running on Elastic Beanstalk on the Multicontainer Docker platform. To securely access the SSM Parameter Store I would like to give specific containers access to specific IAM ...
0
votes
0answers
218 views

service xxx is is unhealthy in target-group yyy due to (reason Request timed out)

This message seems to appear regularly every few days 99fd3f00-8fff-4016-9c7b-6e5a22632352 2017-11-13 10:48:03 +1100 service GoogleDrivePolling (instance i-069d7d12d17bb57ec) (port 32814) is ...
1
vote
0answers
73 views

Cloudformation ECS keep all taskdefinition revisions

In CloudFormation ECS when I update TaskDefinition tag Image:app:2 and make update-stack, I get only the one last new revision a myapp:2. How I can keep all previous revisions in which case manually ...
1
vote
0answers
287 views

How to automate OS/ECS-agent updating on a EC2 instance in ECS Auto Scaling environment?

First off: I feel like I still don't understand some of the fundamental concepts of AWS, so please bear with me, if this question is noobish. I have the following set-up in AWS: 1 ECS-Cluster with 1 ...
0
votes
0answers
30 views

ELB with ECS has huge occasional delay

We have a website (Django + Angular 4) running on ECS. It worked well, before we added ELB, to manage HTTPS. After that, we get sporadic delay of > 75s. If it doesn't load and you refresh it will load ...
0
votes
0answers
206 views

How to patch ECS cluster instances

I want to automate patching of the EC2 instances backing my ECS cluster. I looked at using systems manager but it isn't clear if the process outlined at http://docs.aws.amazon.com/systems-manager/...
0
votes
1answer
281 views

How to set different destination ('region') of an aws cloudwatch logging agent inside a docker image?

Here is my dockerfile. FROM 796678920264.dkr.ecr.us-west-1.amazonaws.com/myproject/base:latest COPY /* / RUN python awslogs-agent-setup.py --non-interactive -c /aws-log.myservice.cfg --region us-...
1
vote
1answer
51 views

How to turn off access log for only a certain url in this nginx configuration?

This is a nginx configuration server { listen $PORT; location ~ ^/documents/(.*)$ { proxy_pass http://127.0.0.1:5000/$1; proxy_set_header Host $host; ...
0
votes
0answers
141 views

AWS Batch CLIENT_ERROR Invalid IamInstaceProfile

Hopefully I'm posting in the correct community! I'm trying to set up a container to run on AWS Batch. I'm not doing anything fancy, more or less just following the default set-up with everything. I'm ...
0
votes
1answer
356 views

Memory utilisation and OOM exception in AWS ECS

Here is a chart of MemoryUtilization from one of my service in an ECS cluster. As you can see the memory shot up to 25% briefly. In this cluster I have 3 t2.medium machines. The specification says ...
0
votes
1answer
129 views

Shutdown old EC2 instances only after creating new one in when changing ECS host ami in autoscaling group

Here is my LaunchConfiguration of my AutoScalingGroup in my ECS-Cluster - using cloudformation. UpdatePolicy: AutoScalingRollingUpdate: MinInstancesInService: 1 MaxBatchSize: 1 ...
0
votes
0answers
38 views

Unable to change LaunchConfiguration to a one which uses the ecs-optimized ami, but why?

There's a production cluster in the company I work for and it's member instances are not ECS optimized. I would like to change these instances to an ECS optimized ami. Before doing that on ...
2
votes
1answer
216 views

How to replace ECS cluster instance ami to a different kind of ami while avoiding downtime?

The company I work for uses Amazon ECS. There are 5 or more production clusters configured there and there was some problem last week and AWS support team recommended us to change the ECS instance ...
0
votes
0answers
184 views

Why ecs cluster does not restart a task with the latest version of task definition?

I have originally defined a task called GoogleDriveAPI-prod:1. It has a memory hard limit of 2048. The cluster has only 1 instance of t2.medium machine. Even though i set the desirable number of task ...