# *****************************
# * *
# * W A T C H T O W E R *
# * *
# *****************************
# https://containrrr.dev/watchtower/
services:
watchtower:
image: containrrr/watchtower:latest
container_name: watchtower
restart: unless-stopped
environment:
- TZ=Europe/Paris
- WATCHTOWER_SCHEDULE=0 0 21 * * *
- WATCHTOWER_LABEL_ENABLE=true
- WATCHTOWER_CLEANUP=true
- WATCHTOWER_ROLLING_RESTART=true
- WATCHTOWER_TIMEOUT=30
- WATCHTOWER_REMOVE_VOLUMES=true
- WATCHTOWER_DEBUG=false
- WATCHTOWER_LOG_LEVEL=warn
# notifications par e-mail
- WATCHTOWER_NOTIFICATIONS=email
- WATCHTOWER_NOTIFICATION_EMAIL_FROM=Watchtower@ndd.fr
- WATCHTOWER_NOTIFICATION_EMAIL_TO=***********
- WATCHTOWER_NOTIFICATION_EMAIL_SERVER=smtp.free.fr
- WATCHTOWER_NOTIFICATION_EMAIL_SERVER_USER=******
- WATCHTOWER_NOTIFICATION_EMAIL_SERVER_PASSWORD=******
- WATCHTOWER_NOTIFICATION_EMAIL_SERVER_PORT=***
- WATCHTOWER_NOTIFICATION_EMAIL_SUBJECTTAG=[Watchtower]
networks:
- watchtower
labels:
- com.centurylinklabs.watchtower.enable=true
volumes:
- /var/run/docker.sock:/var/run/docker.sock:ro
networks:
watchtower:
driver: bridge
name: watchtower
ipam:
config:
- subnet: 172.25.0.0/16
gateway: 172.25.0.1
WATCHTOWER_LOG_LEVEL=debug
time="2025-02-27T11:23:00+01:00" level=debug msg="Sleeping for a second to ensure the docker api client has been properly initialized."
time="2025-02-27T11:23:01+01:00" level=debug msg="Making sure everything is sane before starting"
time="2025-02-27T11:23:01+01:00" level=debug msg="Retrieving running containers"
time="2025-02-27T11:23:03+01:00" level=debug msg="Retrieving running containers"
time="2025-02-27T11:23:05+01:00" level=debug msg="There are no additional watchtower containers"
time="2025-02-27T11:23:05+01:00" level=debug msg="Watchtower HTTP API skipped."
time="2025-02-27T11:23:05+01:00" level=info msg="Watchtower 1.7.1"
time="2025-02-27T11:23:05+01:00" level=info msg="Using notifications: smtp"
time="2025-02-27T11:23:05+01:00" level=info msg="Only checking containers using enable label"
time="2025-02-27T11:23:05+01:00" level=info msg="Scheduling first run: 2025-02-27 21:00:00 +0100 CET"
time="2025-02-27T11:23:05+01:00" level=info msg="Note that the first check will be performed in 9 hours, 36 minutes, 54 seconds"
Watchtower updates on 4e6ede590f0e
# *****************************
# * *
# * W A T C H T O W E R *
# * *
# *****************************
# https://containrrr.dev/watchtower/
services:
watchtower:
image: containrrr/watchtower:latest
container_name: watchtower
hostname: Citrouille
restart: unless-stopped
environment:
- TZ=Europe/Paris
- WATCHTOWER_SCHEDULE=0 0 21 * * *
- WATCHTOWER_LABEL_ENABLE=true
- WATCHTOWER_CLEANUP=true
- WATCHTOWER_ROLLING_RESTART=true
- WATCHTOWER_TIMEOUT=30
- WATCHTOWER_REMOVE_VOLUMES=true
- WATCHTOWER_DEBUG=false
- WATCHTOWER_LOG_LEVEL=warn
# notifications par e-mail
- WATCHTOWER_NOTIFICATIONS=email
- WATCHTOWER_NOTIFICATION_EMAIL_FROM=Watchtower@ndd.fr
- WATCHTOWER_NOTIFICATION_EMAIL_TO=***********
- WATCHTOWER_NOTIFICATION_EMAIL_SERVER=smtp.free.fr
- WATCHTOWER_NOTIFICATION_EMAIL_SERVER_USER=******
- WATCHTOWER_NOTIFICATION_EMAIL_SERVER_PASSWORD=******
- WATCHTOWER_NOTIFICATION_EMAIL_SERVER_PORT=***
- WATCHTOWER_NOTIFICATION_EMAIL_SUBJECTTAG=[Watchtower]
networks:
- watchtower
labels:
- com.centurylinklabs.watchtower.enable=true
volumes:
- /var/run/docker.sock:/var/run/docker.sock:ro
networks:
watchtower:
driver: bridge
name: watchtower
ipam:
config:
- subnet: 172.25.0.0/16
gateway: 172.25.0.1
Le titre de l'e-mail est désormaisPour cela, il suffit de déclarer un hostname dans le compose pour le conteneur watchtower, exemple pour avoir Citrouille :