-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathdocker-compose-construction.yml
62 lines (60 loc) · 1.41 KB
/
docker-compose-construction.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
version: '3.9'
services:
# Uncomment to run the emergency generators example
# generators:
# image: emergency-generator:latest
# depends_on:
# mosquitto:
# condition: service_healthy
# environment:
# - GENERATORS=3
# - BROKER=mosquitto
# networks:
# - mqtt
# Uncomment to run the construction example
construction:
image: construction-site:latest
depends_on:
mosquitto:
condition: service_healthy
environment:
- VEHICLE=1
- BROKER=mosquitto
networks:
- mqtt
telegraf:
image: telegraf:latest
volumes:
- ./telegraf/telegraf.conf:/etc/telegraf/telegraf.conf:ro
depends_on:
mosquitto:
condition: service_healthy
networks:
- mqtt
mosquitto:
image: eclipse-mosquitto:latest
ports:
- 1883:1883
healthcheck:
test: ["CMD", "mosquitto_pub", "-h", "localhost", "-t", "test", "-m", "hello"]
interval: 10s
retries: 5
start_period: 30s
timeout: 5s
networks:
- mqtt
volumes:
- ./mosquitto/mosquitto.conf:/mosquitto/config/mosquitto.conf
# Option to use InfluxDB v2 OSS
# influxdb:
# image: influxdb:latest
# volumes:
# # Mount for influxdb data directory and configuration
# - ./influxdb/data:/var/lib/influxdb2:rw
# ports:
# - 8086:8086
# networks:
# - mqtt
networks:
mqtt:
name: mqtt