70 lines
1.9 KiB
YAML
70 lines
1.9 KiB
YAML
version: "3"
|
|
|
|
networks:
|
|
traefik:
|
|
external: true
|
|
|
|
configs:
|
|
server:
|
|
file: /srv/alerts/ntfy_server.yml
|
|
|
|
services:
|
|
ntfy:
|
|
image: binwiederhier/ntfy
|
|
networks:
|
|
- traefik
|
|
command:
|
|
- serve
|
|
environment:
|
|
- TZ=Europe/Amsterdam
|
|
volumes:
|
|
- type: bind
|
|
source: /mnt/data/ntfy/cache
|
|
target: /var/cache/ntfy
|
|
- type: bind
|
|
source: /mnt/data/ntfy/data
|
|
target: /var/lib/ntfy
|
|
healthcheck:
|
|
test: ["CMD-SHELL", "wget -q --tries=1 http://localhost:80/v1/health -O - | grep -Eo '\"healthy\"\\s*:\\s*true' || exit 1"]
|
|
interval: 60s
|
|
timeout: 10s
|
|
retries: 3
|
|
start_period: 40s
|
|
deploy:
|
|
placement:
|
|
constraints:
|
|
- node.role == manager
|
|
labels:
|
|
- traefik.enable=true
|
|
- traefik.http.routers.ntfy.entrypoints=websecure
|
|
- traefik.http.routers.ntfy.rule=Host(`ntfy.pim.kunis.nl`)
|
|
- traefik.http.routers.ntfy.tls=true
|
|
- traefik.http.routers.ntfy.tls.certresolver=letsencrypt
|
|
- traefik.http.routers.ntfy.service=ntfy
|
|
- traefik.http.services.ntfy.loadbalancer.server.port=80
|
|
- traefik.docker.network=traefik
|
|
configs:
|
|
- source: server
|
|
target: /etc/ntfy/server.yml
|
|
|
|
apprise:
|
|
image: caronc/apprise:v0.9.0
|
|
networks:
|
|
- traefik
|
|
volumes:
|
|
- type: bind
|
|
source: /mnt/data/apprise
|
|
target: /config
|
|
deploy:
|
|
placement:
|
|
constraints:
|
|
- node.role == manager
|
|
labels:
|
|
- traefik.enable=true
|
|
- traefik.http.routers.apprise.entrypoints=localsecure
|
|
- traefik.http.routers.apprise.rule=Host(`apprise.pim.kunis.nl`)
|
|
- traefik.http.routers.apprise.tls=true
|
|
- traefik.http.routers.apprise.tls.certresolver=letsencrypt
|
|
- traefik.http.routers.apprise.service=apprise
|
|
- traefik.http.services.apprise.loadbalancer.server.port=8000
|
|
- traefik.docker.network=traefik
|