Set up three-tier synchronization: Syncthing (real-time), GitHub (version control), rsync (disaster recovery). Includes complete documentation for future Claude sessions. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
47 lines
1.6 KiB
YAML
47 lines
1.6 KiB
YAML
version: '3.8'
|
||
|
||
services:
|
||
watchtower:
|
||
image: containrrr/watchtower:latest
|
||
container_name: watchtower
|
||
restart: unless-stopped
|
||
volumes:
|
||
- /var/run/docker.sock:/var/run/docker.sock
|
||
environment:
|
||
# Проверка обновлений каждые 6 часов (в 00:00, 06:00, 12:00, 18:00)
|
||
- WATCHTOWER_SCHEDULE=0 0 0,6,12,18 * * *
|
||
|
||
# Удалять старые образы после обновления
|
||
- WATCHTOWER_CLEANUP=true
|
||
|
||
# Включить debug логи
|
||
- WATCHTOWER_DEBUG=false
|
||
|
||
# Таймаут перед остановкой контейнера (10 секунд)
|
||
- WATCHTOWER_TIMEOUT=10s
|
||
|
||
# Включить уведомления в логи
|
||
- WATCHTOWER_NOTIFICATIONS=shoutrrr
|
||
- WATCHTOWER_NOTIFICATION_URL=logger://
|
||
|
||
# Мониторить только контейнеры с label com.centurylinklabs.watchtower.enable=true
|
||
- WATCHTOWER_LABEL_ENABLE=false
|
||
|
||
# Исключить критичные контейнеры БД и системные
|
||
- WATCHTOWER_EXCLUDE_CONTAINERS=postgres-main,authentik-postgres,postiz-postgres,supabase-db,redis-main,authentik-redis,postiz-redis,rabbitmq,traefik,vault
|
||
|
||
# Включить мониторинг локального реестра
|
||
- WATCHTOWER_INCLUDE_STOPPED=false
|
||
|
||
# Rolling restart (один за раз)
|
||
- WATCHTOWER_ROLLING_RESTART=true
|
||
|
||
networks:
|
||
- watchtower
|
||
labels:
|
||
- "com.centurylinklabs.watchtower.enable=false"
|
||
|
||
networks:
|
||
watchtower:
|
||
name: watchtower
|
||
driver: bridge
|