Added goaccess to monitor traefik
This commit is contained in:
parent
29fea56bbf
commit
82087a46c0
@ -13,6 +13,39 @@ services:
|
||||
- ${PWD}/acme.json:/etc/traefik/acme.json
|
||||
- ${PWD}/access.log:/etc/traefik/access.log
|
||||
|
||||
goaccess:
|
||||
image: allinurl/goaccess
|
||||
command:
|
||||
- --no-global-config
|
||||
- --config-file=/srv/data/goaccess.conf
|
||||
- --num-tests=0
|
||||
volumes:
|
||||
- ${PWD}/access.log:/srv/logs/access.log:ro
|
||||
- ${PWD}/goaccess.conf:/srv/data/goaccess.conf
|
||||
- goaccess_data:/srv/data
|
||||
- goaccess_report:/srv/report
|
||||
labels:
|
||||
traefik.enable: true
|
||||
traefik.http.routers.goaccess.rule: Host(`gruppe1.testsites.info`) && PathPrefix(`/goaccess/ws`)
|
||||
traefik.http.routers.goaccess.priority: 55
|
||||
traefik.http.routers.goaccess.middlewares: strip_goaccess,secHeaders@file
|
||||
traefik.http.routers.goaccess.tls: true
|
||||
traefik.http.routers.goaccess.tls.certresolver: myresolver
|
||||
|
||||
nginx:
|
||||
image: nginx
|
||||
volumes:
|
||||
- goaccess_report:/usr/share/nginx/html
|
||||
labels:
|
||||
traefik.enable: true
|
||||
traefik.http.routers.goaccess_web.rule: Host(`gruppe1.testsites.info`) && PathPrefix(`/goaccess`)
|
||||
traefik.http.routers.goaccess_web.priority: 50
|
||||
traefik.http.routers.goaccess_web.middlewares: strip_goaccess,secHeaders@file
|
||||
traefik.http.routers.goaccess_web.tls: true
|
||||
traefik.http.routers.goaccess_web.tls.certresolver: myresolver
|
||||
|
||||
traefik.http.middlewares.strip_goaccess.stripprefix.prefixes: /goaccess
|
||||
|
||||
portainer:
|
||||
image: portainer/portainer-ce
|
||||
labels:
|
||||
@ -36,3 +69,5 @@ networks:
|
||||
|
||||
volumes:
|
||||
portainer_data:
|
||||
goaccess_report:
|
||||
goaccess_data:
|
5
deploy/base/goaccess.conf
Normal file
5
deploy/base/goaccess.conf
Normal file
@ -0,0 +1,5 @@
|
||||
log-format COMMON
|
||||
log-file /srv/logs/access.log
|
||||
output /srv/report/index.html
|
||||
real-time-html true
|
||||
ws-url wss://gruppe1.testsites.info:443/goaccess/ws
|
Loading…
Reference in New Issue
Block a user