Skip to content

Instantly share code, notes, and snippets.

@patrickacioli
Created March 23, 2021 20:50
Show Gist options
  • Save patrickacioli/c6a4ce4c5f1b1448122f6d0296095f3d to your computer and use it in GitHub Desktop.
Save patrickacioli/c6a4ce4c5f1b1448122f6d0296095f3d to your computer and use it in GitHub Desktop.
Task with multiple containers in ECS Task Definition
version: "3"
services:
redis:
image: redis
command: redis-server --requirepass REDIS_PASSWORD
ports:
- "6379:6379"
database:
image: postgres:latest
ports:
- "5432:5432"
environment:
POSTGRES_PASSWORD: POSTGRES_PASSWORD
POSTGRES_DB : POSTGRES_DB
logging:
driver: none
app:
image: IMAGE
command: COMMAND
links:
- database
- redis
env_file:
.env.dev
ports:
- PORT_APP:PORT_APP
logging:
driver: awslogs
options:
awslogs-group: GROUPS_LOGS
awslogs-region: GROUPS_REGION
awslogs-stream-prefix: GROUPS_LOGS_PREFIX
version: 1
task_definition:
task_execution_role: ARN_EXECTION_ROLE
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment