-
Notifications
You must be signed in to change notification settings - Fork 923
/
Copy pathdocker-compose.yml
62 lines (57 loc) · 1.15 KB
/
docker-compose.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
version: '3.5'
services:
api-01: &api
image: henriqueholtz/rinha-de-backend-2024-q1-dotnet:0.1
container_name: api-01
environment:
- HTTP_PORTS=5000
ports:
- 5001:5000
depends_on:
- db
deploy:
resources:
limits:
cpus: '0.25'
memory: '110MB'
api-02:
# Copy from 'api-01'.
<<: *api
container_name: api-02
ports:
- 5002:5000
nginx:
image: nginx:1.24
volumes:
- ./nginx.conf:/etc/nginx/nginx.conf:ro
depends_on:
- api-01
- api-02
ports:
- '9999:9999'
deploy:
resources:
limits:
cpus: '0.12'
memory: '50MB'
db:
image: postgres:12.18
hostname: db
environment:
- POSTGRES_PASSWORD=Rinh@2024q1
- POSTGRES_USER=rinha
- POSTGRES_DB=RinhaDb
ports:
- '5432:5432'
volumes:
- ./script.sql:/docker-entrypoint-initdb.d/script.sql
- ./postgres.conf:/docker-entrypoint-initdb.d/postgres.conf
deploy:
resources:
limits:
cpus: '0.88'
memory: '280MB'
networks:
default:
driver: bridge
name: rinha-nginx-2024q1