How to Update Docker Container Synology?

Photo of author

Upgrading or implementing the most recent software updates to Docker containers running on a Synology NAS (Network-Attached Storage) device is called “Update Docker Container Synology.” This ensures that the Docker containers’ containerized programs are running the most recent versions of their software, which may include security updates, bug patches, and new features, to maintain the most significant levels of speed, security, and functionality.

In this article, we will cover how to update a docker image in Synology using manual and automatic methods, updating Docker Containers Using Docker Compose on a Synology NAS, and updating docker container Synology using the docker application and various frequently asked questions.

Updating Docker containers on Synology enables fixing vulnerabilities, ensuring stability with bug fixes, accessing new features, and maintaining compatibility with other system parts. Missing updates endangers your system and lowers performance. Let’s analyze the process.

Read also: How To Start Docker Daemon Linux ?

Synology Docker Update Image

Synology updates the Docker image in the following two ways:

Manual Updation

You must complete the procedures listed below to upgrade an existing Docker container manually:

Manual Updation

  1. Visit the Registry and download a fresh image—usually the “latest” one.
  2. Choose the Container you need to modify under Container, then stop it.
  3. Choose “Clear” from the Actions menu.
  4. The “Clear” option has been changed to “Reset” in DSM7.
  5. Restarting the Container

With the newly downloaded Docker image as the starting point, this will completely clean the Container. Also, the data for the applications won’t be deleted since the data folders are mounted inside the Container. Additionally, this does not affect configurations.

Automatic Updation

For a few images, manually updating a Docker image could be acceptable. However, a more complex method uses Watchtower, another Docker container.

This one has automatic Docker container updates. Its filename is containrrr/watchtower. You can use the steps listed below to execute a straightforward setup:

  1. Download the Docker registry’s containrrr/watchtower image.
  2. SSH root login with root privileges
  3. Run this command in the shell:

 docker run -d –network host –name watchtower-once -v /var/run/docker.sock:/var/run/docker.sock containrrr/watchtower:latest –cleanup –include-stopped –run-once

automatic updation

4. The Watchtower image will launch, and every Container will receive an update immediately. Once it has finished running, the Container generated for this may be located in the list of containers with its power turned off. As needed, you may restart it manually or use Synology Task Scheduler to schedule it to run at specific periods.

The task scheduler’s command is as follows in that case:

docker start watchtower-once -a

As an alternative, you can utilize Watchtower’s scheduling. Enter this command in the shell to start it at 4 a.m. on Mondays:

Docker run -e “TZ=Europe/Berlin” -d –restart unless-stopped –network host –name watchtower -v /var/run/docker.sock:/var/run/docker.sock containrrr/watchtower –cleanup –include-stopped –schedule “0 0 4 ? * MON”

You must set the time zone to your location to avoid having an offset from UTC. Additionally, the Container is always restarted rather than being killed. Even whether the NAS was rebooted or it crashed. The final option schedules the task using the cron syntax.

See also: PHP Apache Docker: Setting Up A Robust Development Environment

How to update Docker Container Synology?

Below, we’ll examine two approaches to updating Docker containers on a Synology NAS.

Updating Docker Containers using the Docker Application for Synology NAS

  1. To get the most recent version, open the Registry, look for the Container you want to update, and double-click it. Your current version will be replaced by the most recent one. Make sure you allow the download time to complete.
  2. The previous Container should stop, be edited, and given a new name. Typically, I leave it alone and prefix the word with -Backup.
  3. Select the Container, then choose Settings, and then Clone Settings when the Container has been given a new name. The Container will be set up when you give it a name. You will utilize the most recent version when you start the new Container!
  4. Now the Container is prepared! You may completely roll back to the previous version of the Docker container if you delete the new Container and rename the old one (by removing the -Backup) once you encounter any problems.

Update Docker Containers Using Docker Compose on a Synology NAS

Running Synology’s GUI differs differently from upgrading a container using Docker Compose. We are technically establishing a new container and maintaining our old one when we utilize Synology’s GUI and clone the parameters.

Moreover, it’s challenging to accomplish that since Docker Compose needs our configuration file to generate the Container.

Due to this, updating the Container and fixing it (updating the Docker Compose file to utilize an older version) rather than creating a plan in advance is nearly always quicker.

If you’d instead make a backup of the Container, rename the folder on your Synology NAS, copy the file to a new place, and then make a new container.

  1. Obtain a list of the active containers.
  2. Run the command below, replacing the incorrect container ID, to stop the Container you want to update.
  3. Navigate to the directory containing the Docker Compose file.
  4. In contrast to the second command, which installs the package, the first downloads the most recent picture.
  5. Now that it has been updated, the Container is functional!


What does NAS stand for?

NAS stands for network-attached storage for data security. In addition, a Synology NAS enables you to build a private cloud where you can store the data securely, access, back up, and distribute it.

What characteristics does NAS Synology have?

1. Create storage that is unique to your requirements. 2. Simple file access and file sharing. 3. Your Mac and PC backups are done automatically. 4. Organise and safeguard your media. 5. Private video surveillance can help you protect your house.

Will my settings be lost when I upgrade my Container (s)?

No, a container is meant to be thrown away. If you followed the above instructions or those in the Container's manual, all your configuration files should be on your local disc.


In conclusion, we examined two distinct approaches to update Docker containers Synology. This post demonstrated how to upgrade Synology NAS with Docker containers. As we indicated at the outset, this is merely a preferred method and doesn’t imply that there aren’t other options.

We appreciate you reading our article about updating Docker Containers on Synology NAS.

Leave a Comment