-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yml
95 lines (87 loc) · 2.27 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
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
version: '3'
services:
redis:
image: redis:6.2
ports:
- 6379:6379
postgres:
image: postgres:13.4
volumes:
- ./postgres/gas_volume_2021_09.sql:/docker-entrypoint-initdb.d/gas_volume_2021_09.sql
environment:
POSTGRES_USER: catapult
POSTGRES_PASSWORD: secret
POSTGRES_DB: iot
ports:
- 5432:5432
mosquitto:
image: eclipse-mosquitto:2.0
volumes:
- mosquitto-data:/mosquitto/data
- mosquitto-logs:/mosquitto/logs
- mosquitto-conf:/mosquitto/config
- ./mosquitto/mosquitto.conf:/mosquitto/config/mosquitto.conf
- ./mosquitto/passwd:/mosquitto/config/passwd
ports:
- 1883:1883
sensor-receptor:
depends_on:
- mosquitto
- postgres
- redis
build:
context: ./sensor-receptor
dockerfile: ./Dockerfile
volumes:
- sensor-receptor:/sensor-receptor/app
tty: true
environment:
MQTT_HOST: mqtt://mosquitto:1883
MQTT_USER: catapult
MQTT_PASSWORD: secret
REDIS_HOST: redis
REDIS_PORT: 6379
PGUSER: catapult
PGHOST: postgres
PGPASSWORD: secret
PGDATABASE: iot
PGPORT: 5432
api:
depends_on:
- postgres
build:
context: ./api
dockerfile: ./Dockerfile
volumes:
- api:/api/app
environment:
API_PORT: 4000
PGUSER: catapult
PGHOST: postgres
PGPASSWORD: secret
PGDATABASE: iot
PGPORT: 5432
ports:
- 4000:4000
dashboard:
depends_on:
- api
build:
context: ./dashboard
dockerfile: ./Dockerfile
volumes:
- dashboard:/dashboard/app
- /dashboard/app/node_modules
stdin_open: true
environment:
- CHOKIDAR_USEPOLLING=true
- CI=true
ports:
- 3000:3000
volumes:
mosquitto-data:
mosquitto-logs:
mosquitto-conf:
sensor-receptor:
api:
dashboard: