]> git.giorgioravera.it Git - docker.git/commitdiff
Updated watchtower to check stopped containers
authorGiorgio Ravera <giorgio.ravera@gmail.com>
Tue, 16 Jul 2024 08:13:24 +0000 (10:13 +0200)
committerGiorgio Ravera <giorgio.ravera@gmail.com>
Tue, 16 Jul 2024 08:13:24 +0000 (10:13 +0200)
watchtower/docker-compose.yaml
watchtower/force.sh

index 38e6b88032737a7db698547c4c488d3e60b91e42..072d5c691ec9754014459fa01ab9f2a3ad899120 100644 (file)
@@ -1,5 +1,3 @@
-version: '3'
-
 services:
   watchtower:
     container_name: watchtower
@@ -8,9 +6,10 @@ services:
     environment:
       - TZ=${DOCKER_TZ}
       - WATCHTOWER_CLEANUP=true
+      - WATCHTOWER_INCLUDE_STOPPED=true
       - WATCHTOWER_POLL_INTERVAL=21600
-      - WATCHTOWER_LABEL_ENABLE=false
-      - WATCHTOWER_MONITOR_ONLY=false
+      #- WATCHTOWER_LABEL_ENABLE=false
+      #- WATCHTOWER_MONITOR_ONLY=false
       - WATCHTOWER_NO_STARTUP_MESSAGE=true
       - WATCHTOWER_NOTIFICATIONS_LEVEL=info
       - WATCHTOWER_NOTIFICATIONS=email
@@ -19,7 +18,6 @@ services:
       - WATCHTOWER_NOTIFICATION_EMAIL_SERVER=mail.giorgioravera.it
       #- WATCHTOWER_NOTIFICATION_EMAIL_SERVER_PORT=25
       #- WATCHTOWER_NOTIFICATION_EMAIL_SUBJECTTAG=Docker WatchTower
-    #privileged: true
     volumes:
       - /var/run/docker.sock:/var/run/docker.sock
     networks:
index b35d1b2b145162fe083aadfd84a2c2cd25e3b4bd..c8a41cc2bbadc1274ad95aab76f248187aa2e278 100755 (executable)
@@ -54,6 +54,7 @@ run_without_notifications()
                        -v /var/run/docker.sock:/var/run/docker.sock \
                        containrrr/watchtower \
                                --cleanup \
+                               --revive-stopped \
                                --run-once \
                                --no-startup-message
 }
@@ -64,6 +65,7 @@ run_with_notifications()
                        -v /var/run/docker.sock:/var/run/docker.sock \
                        containrrr/watchtower \
                                --cleanup \
+                               --revive-stopped \
                                --run-once \
                                --no-startup-message \
                                --notifications=email \