-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yaml
115 lines (107 loc) · 3.03 KB
/
docker-compose.yaml
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
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
version: "3"
volumes:
db_data:
driver: local
grafana_data:
driver: local
services:
zabbix-server:
hostname: zabbix-server
restart: unless-stopped
image: zabbix/zabbix-server-pgsql:alpine-latest
environment:
- DB_SERVER_PORT=5432
- DB_SERVER_HOST=postgresql
- POSTGRES_DB=zabbix
- POSTGRES_USER=zabbix
- POSTGRES_PASSWORD=zabbix
- ENABLE_TIMESCALEDB=true
- ZBX_STARTREPORTWRITERS=2
- ZBX_WEBSERVICEURL=http://zabbix-reports:10053/report
volumes:
- ./zabbix/usr/lib/zabbix/externalscripts:/usr/lib/zabbix/externalscripts:ro
depends_on:
- postgresql
zabbix-frontend:
hostname: zabbix-frontend
restart: unless-stopped
image: zabbix/zabbix-web-apache-pgsql:alpine-latest
environment:
- DB_SERVER_PORT=5432
- DB_SERVER_HOST=postgresql
- POSTGRES_DB=zabbix
- POSTGRES_USER=zabbix
- POSTGRES_PASSWORD=zabbix
- PHP_TZ=America/Sao_Paulo
- ZBX_SERVER_NAME=zabbix-server
- ZBX_SERVER_HOST=zabbix-server
volumes:
- /etc/timezone:/etc/timezone:ro
- /etc/localtime:/etc/localtime:ro
- ./zabbix/etc/ssl/apache2:/etc/ssl/apache2:ro
depends_on:
- postgresql
- zabbix-server
postgresql:
hostname: postgresql
restart: unless-stopped
image: timescale/timescaledb:latest-pg13
environment:
- POSTGRES_DB=zabbix
- POSTGRES_USER=zabbix
- POSTGRES_PASSWORD=zabbix
- TS_TUNE_MEMORY=4GB
- TS_TUNE_NUM_CPUS=4
volumes:
- db_data:/var/lib/postgresql/data
command: ["postgres", "-c", "max_connections=1000"]
zabbix-agent:
hostname: zabbix-agent
restart: unless-stopped
image: zabbix/zabbix-agent:alpine-latest
environment:
- ZBX_HOSTNAME=zabbix-agent
- ZBX_ENABLEREMOTECOMMANDS=1
- ZBX_SERVER_HOST=zabbix-server
volumes:
- /etc/timezone:/etc/timezone:ro
- /etc/localtime:/etc/localtime:ro
- ./zabbix/etc/zabbix/zabbix_agentd.d:/etc/zabbix/zabbix_agentd.d:ro
- ./zabbix/frontend_hacks:/usr/share/zabbix/local/
depends_on:
- zabbix-server
zabbix-reports:
hostname: zabbix-reports
restart: unless-stopped
image: zabbix/zabbix-web-service:alpine-latest
environment:
- ZBX_ALLOWEDIP=zabbix-server,zabbix-frontend
- ZBX_DEBUGLEVEL=4
cap_add:
- SYS_ADMIN
depends_on:
- zabbix-server
- zabbix-frontend
grafana:
hostname: grafana
restart: unless-stopped
image: grafana/grafana:latest
environment:
- GF_INSTALL_PLUGINS=alexanderzobnin-zabbix-app
- GF_PLUGINS_ALLOW_LOADING_UNSIGNED_PLUGINS=alexanderzobnin-zabbix-datasource
- GF_LOG_LEVEL=info
volumes:
- grafana_data:/var/lib/grafana
- ./grafana/provisioning:/etc/grafana/provisioning
depends_on:
- zabbix-frontend
npm:
image: 'jc21/nginx-proxy-manager:latest'
restart: unless-stopped
ports:
- '80:80'
- '81:81'
- '443:443'
volumes:
- ./data:/data
- ./letsencrypt:/etc/letsencrypt