-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yml
49 lines (45 loc) · 988 Bytes
/
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
version: '3.5'
networks:
default:
services:
broker:
# -m set the HTTP PORT for monitoring
# -D enable debugging output
# -V trace the raw protocol
# -sc streaming server config file
command: ["-m", "8222", "-D", "-V", "-sc", "/run/secrets/nats-config"]
image: nats-streaming
networks:
default:
ports:
- "4222:4222"
- "8222:8222"
- "6222:6222"
secrets:
- nats-config
database:
build: .
command: [
"postgres",
"-c", "log_destination=stderr",
"-c", "client_min_messages=error",
"-c", "log_min_messages=error",
"-c", "log_min_error_statement=error"
]
depends_on:
- broker
environment:
- POSTGRES_DB=postgres
- POSTGRES_USER=postgres
- POSTGRES_PASSWORD=postgres
networks:
default:
ports:
- "5432:5432"
volumes:
- pg-data:/var/lib/postgresql/data
volumes:
pg-data:
secrets:
nats-config:
file: nats-config