-
Notifications
You must be signed in to change notification settings - Fork 786
/
docker-compose-staging.yml
168 lines (155 loc) · 4.55 KB
/
docker-compose-staging.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
version: '3'
services:
memcached:
image: memcached:1.6.15
ports:
- "11211:11211"
django:
image: ${AWS_ACCOUNT_ID}.dkr.ecr.us-east-1.amazonaws.com/evalai-staging-backend:${COMMIT_ID}
env_file:
- docker/prod/docker_staging.env
build:
context: ./
dockerfile: docker/prod/django/Dockerfile
ports:
- '8000:8000'
logging:
driver: awslogs
options:
awslogs-region: us-east-1
awslogs-group: django_staging
awslogs-create-group: 'true'
celery:
image: ${AWS_ACCOUNT_ID}.dkr.ecr.us-east-1.amazonaws.com/evalai-staging-celery:${COMMIT_ID}
env_file:
- docker/prod/docker_staging.env
build:
context: ./
dockerfile: docker/prod/celery/Dockerfile
depends_on:
- django
logging:
driver: awslogs
options:
awslogs-region: us-east-1
awslogs-group: celery_staging
awslogs-create-group: 'true'
worker:
image: ${AWS_ACCOUNT_ID}.dkr.ecr.us-east-1.amazonaws.com/evalai-staging-worker:${COMMIT_ID}
build:
context: ./
dockerfile: docker/prod/worker/Dockerfile
env_file:
- docker/prod/docker_staging.env
worker_py3.8:
image: ${AWS_ACCOUNT_ID}.dkr.ecr.us-east-1.amazonaws.com/evalai-staging-worker-py3.8:${COMMIT_ID}
build:
context: ./
dockerfile: docker/prod/worker_py3.8/Dockerfile
env_file:
- docker/prod/docker_staging.env
nodejs:
image: ${AWS_ACCOUNT_ID}.dkr.ecr.us-east-1.amazonaws.com/evalai-staging-frontend:${COMMIT_ID}
build:
context: ./
dockerfile: docker/prod/nodejs/Dockerfile
args:
NODE_ENV: staging
ports:
- '80:80'
- "443:443"
volumes:
- /code/node_modules
- /code/bower_components
logging:
driver: awslogs
options:
awslogs-region: us-east-1
awslogs-group: nodejs_staging
awslogs-create-group: 'true'
remote-worker:
image: ${AWS_ACCOUNT_ID}.dkr.ecr.us-east-1.amazonaws.com/evalai-staging-remote-worker:${COMMIT_ID}
build:
context: ./
dockerfile: docker/prod/worker/Dockerfile
command: ['python', '-m', 'scripts.workers.remote_submission_worker']
env_file:
- docker/prod/docker_remote_worker.env
code-upload-worker:
image: ${AWS_ACCOUNT_ID}.dkr.ecr.us-east-1.amazonaws.com/evalai-staging-code-upload-worker:${COMMIT_ID}
env_file:
- docker/prod/docker_code_upload_worker.env
build:
context: ./
dockerfile: docker/prod/code-upload-worker/Dockerfile
prometheus:
hostname: prometheus
image: prom/prometheus:latest
user: "1000"
volumes:
- ./monitoring/prometheus/prometheus_staging.yml:/etc/prometheus/prometheus.yml
- ./monitoring/prometheus/rules.yml:/etc/rules/rules.yml
- ./monitoring/prometheus/prometheus_db:/var/lib/prometheus
- ./monitoring/prometheus/prometheus_db:/prometheus
- ./monitoring/prometheus/prometheus_db:/etc/prometheus
command:
- '--config.file=/etc/prometheus/prometheus.yml'
- '--web.external-url=http://localhost:9090/prometheus'
ports:
- '9090:9090'
grafana:
hostname: grafana
image: grafana/grafana:latest
user: "1000"
env_file:
- docker/prod/docker_staging.env
volumes:
- ./monitoring/grafana/grafana_db:/var/lib/grafana
depends_on:
- prometheus
ports:
- '3000:3000'
statsd-exporter:
hostname: statsd
image: prom/statsd-exporter:latest
command:
- '--log.level=info'
- '--web.telemetry-path=/statsd/metrics'
ports:
- '9125:9125/udp'
- '9125:9125/tcp'
- '9102:9102'
node_exporter:
hostname: node_exporter
image: prom/node-exporter
ports:
- '9100:9100'
nginx-ingress:
image: ${AWS_ACCOUNT_ID}.dkr.ecr.us-east-1.amazonaws.com/evalai-staging-nginx-ingress:${COMMIT_ID}
build:
context: ./
dockerfile: docker/prod/nginx-ingress/Dockerfile
args:
MONITORING_ENV: staging
depends_on:
- prometheus
- grafana
- statsd-exporter
- alert-manager
ports:
- '80:80'
- '443:443'
alert-manager:
hostname: alert_manager
image: prom/alertmanager:v0.24.0
user: "1000"
volumes:
- ./monitoring/prometheus:/prometheus
- ./monitoring/alertmanager/data:/data
- ./monitoring/alertmanager/templates:/etc/alertmanager/templates
command:
- '--config.file=/prometheus/alert_manager.yml'
- '--storage.path=/data'
- '--web.external-url=http://localhost:9093/alert_manager'
ports:
- '9093:9093'