-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yml
98 lines (90 loc) · 2.35 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
96
97
98
version: "3"
services:
influxdb:
image: influxdb:alpine
container_name: influxdb
restart: always
ports:
- ${INFLUXDB_PORT}:8086
volumes:
- ./${INFLUXDB_DATA_STORE}:/var/lib/influxdb2
- ./${INFLUXDB_DATA_STORE}:/etc/influxdb2
environment:
DOCKER_INFLUXDB_INIT_MODE: ${INFLUXDB_INIT_MODE}
DOCKER_INFLUXDB_INIT_USERNAME: ${INFLUXDB_INIT_USER}
DOCKER_INFLUXDB_INIT_PASSWORD: ${INFLUXDB_INIT_PASSWORD}
DOCKER_INFLUXDB_INIT_ORG: ${INFLUXDB_INIT_ORG}
DOCKER_INFLUXDB_INIT_BUCKET: ${INFLUXDB_INIT_BUCKET}
DOCKER_INFLUXDB_INIT_ADMIN_TOKEN: ${INFLUXDB_INIT_ADMIN_TOKEN}
networks:
- printing_lab
data_collect:
image: read_data2:v1
container_name: read_data2
privileged: true
restart: always
volumes:
- ./influxdb/config:/influxdb/config
- ./util_config:/util_config
depends_on:
- influxdb
- mosquitto
networks:
- printing_lab
grafana_emon:
image: grafana/grafana
links:
- influxdb
ports:
- "3000:3000"
container_name: grafana
restart: always
volumes:
- grafana:/var/lib/grafana
environment:
- GF_AUTH_DISABLE_LOGIN_FORM=true
- GF_AUTH_ANONYMOUS_ENABLED=true
- GF_AUTH_ANONYMOUS_ORG_ROLE=Admin
- GF_SECURITY_ALLOW_EMBEDDING=true
depends_on:
- influxdb
networks:
- printing_lab
mosquitto:
image: eclipse-mosquitto
container_name: mosquitto
restart: always
ports:
- 1883:1883
volumes:
- ./mosquitto:/mosquitto/
- ./mosquitto/config/mosquitto.conf:/mosquitto/config/mosquitto.conf
- ./mosquitto/data:/mosquitto/data
- ./mosquitto/log:/mosquitto/log
networks:
- printing_lab
telegraf:
image: telegraf:alpine
depends_on:
- influxdb
- mosquitto
container_name: telegraf
restart: always
environment:
- DOCKER_INFLUXDB_ORG=${INFLUXDB_INIT_ORG}
- DOCKER_INFLUXDB_BUCKET=${INFLUXDB_INIT_BUCKET}
- DOCKER_CURRENT_INFLUXDB_TOKEN=${INFLUXDB_INIT_ADMIN_TOKEN}
volumes:
- /var/run/docker.sock:/var/run/docker.sock
- ./telegraf/telegraf.conf:/etc/telegraf/telegraf.conf
networks:
- printing_lab
networks:
printing_lab:
volumes:
grafana:
driver: local
influxdb:
driver: local
telegraf:
driver: local