-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathdocker-compose.yml
60 lines (56 loc) · 1.22 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
version: '3.8'
services:
low-latency-service:
build: .
ports:
- "8080"
deploy:
replicas: 3
restart_policy:
condition: on-failure
environment:
- GOMAXPROCS=10
ulimits:
nofile:
soft: 65536
hard: 65536
postgres:
container_name: low-postgres
image: 'postgres:16.3-alpine'
ports:
- "5432:5432"
restart: always
deploy:
mode: replicated
replicas: 1
environment:
POSTGRES_USER: postgres
POSTGRES_PASSWORD: password
POSTGRES_DB: lowserver
PGTZ: "Asia/Tokyo"
volumes:
- ./db-data/postgres/:/var/lib/postgresql/data/
healthcheck:
test: [ "CMD-SHELL", "pg_isready -U postgres" ]
interval: 10s
timeout: 5s
retries: 5
nginx:
image: nginx:latest
ports:
- "80:80"
volumes:
- ./nginx.conf:/etc/nginx/nginx.conf
depends_on:
- low-latency-service
rabbitmq:
image: 'rabbitmq:3.13-management-alpine'
ports:
- "5672:5672"
- "15672:15672"
deploy:
mode: replicated
replicas: 1
volumes:
- ./db-data/rabbitmq/:/var/lib/rabbitmq
# hey -n 100000 -c 200 -m POST -d "test payload" http://localhost/process