How to Update Docker Compose on a Synology NAS

  • Post author:WunderTech
  • Post published:January 21, 2021
  • Post last modified:November 2, 2022
  • Post category:Synology
  • Reading time:6 mins read

Today we are going to take a look at how you can update Docker Compose on a Synology NAS.

First off, if you aren’t sure how to use Docker Compose on a Synology NAS, I created a tutorial on how you can do it. The tutorial will walk you through Docker entirely and help you decide if Docker Compose is the right choice for you. This tutorial will focus on how you can update Docker Compose since the Docker Compose version shipped with a Synology NAS is fairly old.


1. Ensure that you have Docker installed. Docker Compose is automatically installed on a Synology NAS, but the device must have Docker installed.

2. Ensure you can SSH into your Synology NAS. Open Control Panel, select Terminal & SNMP, and Enable SSH service. If you are using Synology’s Firewall, ensure that you allow port 22 traffic. I created a video on how to SSH into your Synology NAS if you have any problems.

3. After you SSH into the device, run the command below to determine the version of Docker Compose you’re currently running.

docker-compose --version
update docker compose synology - current docker-compose version

4. Navigate to where the Docker Compose directory exists.

cd /var/packages/Docker/target/usr/bin
update docker compose synology - navigate to the docker user folder

5. Back up the current directory by renaming it. This will keep the folder on your Synology NAS, but will not be overwritten by the update.

sudo mv docker-compose docker-compose-backup
update docker compose synology - take a backup of the docker-compose folder

6. Now that the directory has been renamed, we can run the script below which will automatically update Docker Compose. Please note that as of the writing of this tutorial, version 1.27.4 is the latest release. I would heir on the side of caution and not install anything other than the Latest Release, but you must update the version below (written in red) with the latest version. You can find the latest version at this link.

sudo curl -L`uname -s`-`uname -m` -o docker-compose

NOTE: If you update to a version that doesn’t appear to work, delete the folder by running the command below, then rerun the command above with the prior version.

sudo rm docker-compose
remove docker-compose file that currently eixsts

7. Update the permissions so that the folder can be executed. This command gives execute permission to the folder on top of the permissions that it currently has.

sudo chmod +x docker-compose
change the permissions of the docker-compose folder

8. Docker Compose is now updated! You can run the command below again to confirm that you’re on version 1.27.4. If you’re interested in learning why you might want to use Docker Compose as opposed to Synology’s Docker GUI, I explain it in greater detail in the video instructions!

docker-compose --version
confirm the new version of docker-compose is installed

Conclusion – Synology NAS Update Docker Compose

If you’ve made it this far, you can learn how to create Docker Compose containers on a Synology NAS in this tutorial. I also have a guide that will show you how to update Docker Compose containers. Some people find it easier to use Synology’s GUI, but Docker Compose opens a lot of possibilities for extremely easy container management!

As always, thank you for reading the tutorial. If you have any questions, please leave them in the comments!


Frank is an IT professional with 13+ years experience and the creator of WunderTech. He focuses on sharing his experience with others on computer hardware, servers, software, networking, and self-hosted apps. He has a BS in Computer Information Systems and an MBA. Learn more about Frank in his bio.

This Post Has 10 Comments

  1. xbmcnut

    Thanks, very helpful. FYI, I’m getting a python error when trying 1.28.0 but the version in your post (1.27.4) works just fine.

    1. WunderTech

      Thanks for letting me know! I just tried 1.28.0 and received the same error as well. Ironically, I recorded this a few days before 1.28.0 was released so my suggestion to “always update to the newest version” doesn’t seem to be accurate. I will update the instructions to reflect that.

      Thanks again!

  2. Jackald1918

    Big ask, could you do a follow up for docker compose and explain the directory structure for the synology, ie..
    cd /var/packages/Docker/target/usr/bin. Maybe, tips to understand directory layout to find specific directory under Docker or the NAS as a whole. Limitation of synology nas using linux, a reference to command line, etc…. I am sure many with a clearer understanding of structure, many would navigate much easier using docker compose, as well as myself. Not to influence, but you are really are talented at your trade and excellent teacher. Keep up the good work!!

    1. WunderTech

      Thanks so much for the kind words! I will certainly look into this and familiarize myself a little more to hopefully explain it a little easier than it’s probably explained online. The Synology Docker implementation is…confusing in a lot of ways, especially when you get into SSH and the directory structure. I will do my best to try and create a tutorial for it at some point.

      With that said, rather than waiting, if you have any specific questions, I am happy to try and answer them!

    1. WunderTech

      Awesome! Thank you for letting me know!!

  3. louis

    Thank you very much. I updated my docker-compose without any issues. Just struggling with mounting volumes. I would be grateful if you can explain to me how can I mount the following in the gui docker or command line: mount a volume (shared directory) like this:
    -v $HOME/MyMusic:/home/streamripper
    Is this suppose to be the folder I am creating in volume1 as : volume1/MyMusic?
    The github link is:
    Thank you in advance.

    1. WunderTech

      The key to reading the documentation is to look for the “:” (semi-colon). The left side of the semi-colon ($HOME/MyMusic) is the location on your local device (so yes, volume1/mymusic). The location to the right of the semi-colon is the container’s location and should NOT be changed. So that will be left as “/home/streamripper”.

      Hope this helps!

    1. WunderTech

      Great feedback! Thank you for sharing!

Comments are closed.