-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathdocker-compose.yml
45 lines (44 loc) · 1 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
services:
emqx:
image: emqx:5.8.0
container_name: emqx
environment:
- "EMQX_NODE_NAME=emqx@node1.emqx.io"
- "EMQX_DASHBOARD__DEFAULT_PASSWORD=admin"
- "EMQX_API_KEY__BOOTSTRAP_FILE=/opt/emqx/data/bootstrap_api_keys.txt"
networks:
emqx-bridge:
aliases:
- node1.emqx.io
healthcheck:
test: ["CMD", "/opt/emqx/bin/emqx", "ctl", "status"]
interval: 5s
timeout: 25s
retries: 5
ports:
- 1883:1883
- 8083:8083
- 18083:18083
volumes:
- ./data:/opt/emqx/data
postgres:
image: postgres:13
container_name: postgres
environment:
- POSTGRES_USER=mqttmud
- POSTGRES_PASSWORD=mqttmud
- POSTGRES_DB=mqttmud
networks:
emqx-bridge:
healthcheck:
test: ["CMD", "pg_isready", "-U", "mqttmud"]
interval: 5s
timeout: 25s
retries: 5
ports:
- 5432:5432
volumes:
- ./pgdata:/var/lib/postgresql/data
networks:
emqx-bridge:
driver: bridge