-
Notifications
You must be signed in to change notification settings - Fork 923
/
Copy pathdocker-compose.yaml
66 lines (61 loc) · 1.12 KB
/
docker-compose.yaml
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
version: '3'
services:
proxy:
image: nginx:latest
ports:
- "9999:80"
depends_on:
- api1
- api2
- bancoRinha
networks:
- rinhaBe
volumes:
- ./nginx.conf:/etc/nginx/nginx.conf:ro
deploy:
resources:
limits:
cpus: "0.2"
memory: "20MB"
api1:
image: bbeluco/rinhabe-image:latest
ports:
- "20001:8080"
networks:
- rinhaBe
deploy:
resources:
limits:
cpus: "0.5"
memory: "155MB"
api2:
image: bbeluco/rinhabe-image:latest
ports:
- "20002:8080"
networks:
- rinhaBe
deploy:
resources:
limits:
cpus: "0.5"
memory: "155MB"
bancoRinha:
image: postgres
environment:
POSTGRES_PASSWORD: pass
ports:
- "5432:5432"
networks:
- rinhaBe
volumes:
- ./population.sql:/docker-entrypoint-initdb.d/init.sql
command: postgres -c fsync=0
deploy:
resources:
limits:
cpus: "0.3"
memory: "150MB"
networks:
rinhaBe:
name: rinhaBe_network
driver: bridge