-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yaml
79 lines (74 loc) · 1.37 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
67
68
69
70
71
72
73
74
75
76
77
78
79
version: "3.9"
services:
db:
container_name: db
image: mongo
ports:
- 27017:27017
networks:
- rinha
deploy:
resources:
limits:
cpus: "0.60"
memory: "330MB"
app1: &app
container_name: gotcha_one
image: omurilo/gotcha
build:
context: .
ports:
- 80
depends_on:
- db
networks:
- rinha
develop:
watch:
- action: rebuild
path: ./internal
- action: rebuild
path: ./cmd/main.go
- action: rebuild
path: ./infra/database/main.go
- action: sync+restart
path: ./nginx.conf
target: /nginx.conf
deploy:
resources:
limits:
cpus: "0.35"
memory: "100MB"
app2:
<<: *app
container_name: gotcha_two
ports:
- 80
nginx:
container_name: nginx
image: nginx:latest
build:
context: .
dockerfile: Dockerfile.nginx
# volumes:
# - ./nginx.conf:/etc/nginx/nginx.conf:ro
depends_on:
- app1
- app2
ports:
- 9999:9999
networks:
- rinha
develop:
watch:
- action: sync+restart
path: ./nginx.conf
target: /etc/nginx/nginx.conf
deploy:
resources:
limits:
cpus: "0.20"
memory: "20MB"
networks:
rinha:
driver: bridge