Skip to content

Commit

Permalink
Force aws-ecs-agent to use the Host networking
Browse files Browse the repository at this point in the history
According to Amazon's documentation in [step 10](https://docs.aws.amazon.com/AmazonECS/latest/developerguide/ecs-agent-install.html), the ECS-Agent is only supported if running using the Host networking instead of bridge. 

I also enabled Task IAM Role by default, to synchronize with the documentation update in rancher/docs#2015
  • Loading branch information
sodre authored Nov 19, 2019
1 parent c845622 commit 4196043
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions a/amazon-ecs-agent.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,10 @@ ecs-agent:
- /opt/var/lib/ecs/data:/data
- /sys/fs/cgroup:/sys/fs/cgroup:ro
- /var/run/docker/execdriver/native:/var/lib/docker/execdriver/native:ro
ports:
- "127.0.0.1:51678:51678"
- "127.0.0.1:51679:51679"
net: host
environment:
- ECS_ENABLE_TASK_IAM_ROLE=true
- ECS_ENABLE_TASK_IAM_ROLE_NETWORK_HOST=true
- ECS_LOGFILE=/log/ecs-agent.log
- ECS_LOGLEVEL=info
- ECS_DATADIR=/data
Expand Down

0 comments on commit 4196043

Please sign in to comment.