1
0
Fork 0
mirror of https://github.com/librenms/docker.git synced 2026-01-23 02:14:48 +00:00

Upgrade to LibreNMS 1.42

Add syslog-ng support
This commit is contained in:
CrazyMax 2018-08-02 23:25:26 +02:00
parent 86683612c5
commit 4ae20d66a0
7 changed files with 190 additions and 78 deletions

View file

@ -1,86 +1,84 @@
version: '3.2'
version: "3.2"
services:
traefik:
image: traefik:1.6-alpine
command:
- --logLevel=INFO
- --defaultentrypoints=http,https
- --entryPoints=Name:http Address::80 Redirect.EntryPoint:https
- --entryPoints=Name:https Address::443 TLS
- --docker
- --docker.exposedbydefault=false
- --docker.domain=example.com
- --acme=true
- --acme.acmelogging=true
- --acme.email=webmaster@example.com
- --acme.storage=acme.json
- --acme.entryPoint=https
- --acme.onhostrule=true
- --acme.httpchallenge=true
- --acme.httpchallenge.entrypoint=http
- "--logLevel=INFO"
- "--defaultentrypoints=http,https"
- "--entryPoints=Name:http Address::80 Redirect.EntryPoint:https"
- "--entryPoints=Name:https Address::443 TLS"
- "--docker"
- "--docker.exposedbydefault=false"
- "--docker.domain=example.com"
- "--acme=true"
- "--acme.acmelogging=true"
- "--acme.email=webmaster@example.com"
- "--acme.storage=acme.json"
- "--acme.entryPoint=https"
- "--acme.onhostrule=true"
- "--acme.httpchallenge=true"
- "--acme.httpchallenge.entrypoint=http"
ports:
- target: 80
published: 80
protocol: tcp
mode: host
- target: 443
published: 443
protocol: tcp
mode: host
volumes:
- ./acme.json:/acme.json
- /var/run/docker.sock:/var/run/docker.sock
- "./acme.json:/acme.json"
- "/var/run/docker.sock:/var/run/docker.sock"
restart: always
db:
image: mariadb:10.2
command:
- mysqld
- --sql-mode=
- --innodb-file-per-table=1
- --lower-case-table-names=0
- "mysqld"
- "--sql-mode="
- "--innodb-file-per-table=1"
- "--lower-case-table-names=0"
volumes:
- ./db:/var/lib/mysql
- "./db:/var/lib/mysql"
environment:
- TZ=Europe/Paris
- MYSQL_ALLOW_EMPTY_PASSWORD=yes
- MYSQL_DATABASE=librenms
- MYSQL_USER=librenms
- MYSQL_PASSWORD=asupersecretpassword
- "TZ=Europe/Paris"
- "MYSQL_ALLOW_EMPTY_PASSWORD=yes"
- "MYSQL_DATABASE=librenms"
- "MYSQL_USER=librenms"
- "MYSQL_PASSWORD=asupersecretpassword"
restart: always
memcached:
image: memcached:alpine
environment:
- TZ=Europe/Paris
- "TZ=Europe/Paris"
restart: always
rrdcached:
image: crazymax/rrdcached
volumes:
- ./librenms/rrd:/data/db
- ./rrd-journal:/data/journal
- "./librenms/rrd:/data/db"
- "./rrd-journal:/data/journal"
environment:
- TZ=Europe/Paris
- PUID=1000
- GID=1000
- LOG_LEVEL=LOG_INFO
- WRITE_TIMEOUT=1800
- WRITE_JITTER=1800
- WRITE_THREADS=4
- FLUSH_DEAD_DATA_INTERVAL=3600
- "TZ=Europe/Paris"
- "PUID=1000"
- "PGID=1000"
- "LOG_LEVEL=LOG_INFO"
- "WRITE_TIMEOUT=1800"
- "WRITE_JITTER=1800"
- "WRITE_THREADS=4"
- "FLUSH_DEAD_DATA_INTERVAL=3600"
restart: always
smtp:
image: juanluisbaptiste/postfix
volumes:
- /etc/localtime:/etc/localtime:ro
- "/etc/localtime:/etc/localtime:ro"
environment:
- SERVER_HOSTNAME=librenms.example.com
- SMTP_SERVER=smtp.example.com
- SMTP_USERNAME=smtp@example.com
- SMTP_PASSWORD=
- "SERVER_HOSTNAME=librenms.example.com"
- "SMTP_SERVER=smtp.example.com"
- "SMTP_USERNAME=smtp@example.com"
- "SMTP_PASSWORD="
restart: always
app:
@ -93,23 +91,45 @@ services:
- rrdcached
- smtp
volumes:
- ./librenms:/data
- "./librenms:/data"
labels:
- traefik.enable=true
- traefik.backend=librenms
- traefik.port=80
- traefik.frontend.rule=Host:librenms.example.com
- "traefik.enable=true"
- "traefik.backend=librenms"
- "traefik.port=80"
- "traefik.frontend.rule=Host:librenms.example.com"
env_file:
- ./librenms.env
restart: always
cron:
image: crazymax/librenms:latest
command:
- "/usr/local/bin/cron"
depends_on:
- app
volumes:
- ./librenms:/data
command: /usr/local/bin/cron
- "./librenms:/data"
env_file:
- ./librenms.env
restart: always
syslog-ng:
image: crazymax/librenms:latest
command:
- "/usr/sbin/syslog-ng"
- "-F"
depends_on:
- app
ports:
- target: 514
published: 514
protocol: tcp
- target: 514
published: 514
protocol: udp
volumes:
- "./librenms:/data"
env_file:
- ./librenms.env
restart: always