Watchtower Docker Setup
Posted: 31 May 2024, 18:01
I have seen a few posts asking how to set up watchtower on TOS, so I hope this helps someone.
Firstly I have not managed to successfully run Watchtower using the gui. I had to use putty to ssh on to my TNAS, you will need to enable ssh in the control panel as it is disabled by default, also download, using docker manager, the Watchtower image.
Putty to your NAS, Login with your admin account, if you are using TOS 4 then access root by running sudo -i, TNAS 5 you don't need to do this.
Paste in this command to putty
docker run -d --name watchtower -v /var/run/docker.sock:/var/run/docker.sock \containrrr/watchtower
Using Docker Manager GUI stop the Watchtower container, edit the container, check that the network is set to bridge otherwise Watchtower can't access other containers, set your Environment Variables, TZ Europe/London (or wherever), WATCHTOWER_DEBUG true WATCHTOWER_TRACE true, WATCHTOWER_SCHEDULE 0 0 3 * * * (3am every morning, WATCHTOWER_POLL_INETRVAL 86400 (every day), WATCHTOWER_INCLUDE_STOPPED true (updates all container even ones not running), WATCHTOWER_TRACE true.
Restart your container.
Firstly I have not managed to successfully run Watchtower using the gui. I had to use putty to ssh on to my TNAS, you will need to enable ssh in the control panel as it is disabled by default, also download, using docker manager, the Watchtower image.
Putty to your NAS, Login with your admin account, if you are using TOS 4 then access root by running sudo -i, TNAS 5 you don't need to do this.
Paste in this command to putty
docker run -d --name watchtower -v /var/run/docker.sock:/var/run/docker.sock \containrrr/watchtower
Using Docker Manager GUI stop the Watchtower container, edit the container, check that the network is set to bridge otherwise Watchtower can't access other containers, set your Environment Variables, TZ Europe/London (or wherever), WATCHTOWER_DEBUG true WATCHTOWER_TRACE true, WATCHTOWER_SCHEDULE 0 0 3 * * * (3am every morning, WATCHTOWER_POLL_INETRVAL 86400 (every day), WATCHTOWER_INCLUDE_STOPPED true (updates all container even ones not running), WATCHTOWER_TRACE true.
Restart your container.