Portainer is a lightweight management UI which allows you to easily manage your Docker host or Swarm cluster. Portainer is meant to be as simple to deploy as it is to use. It consists of a single container that can run on any Docker engine (Docker for Linux, Docker for Synology DSM and Docker for Windows are all supported). Portainer allows you to manage your Docker stacks, containers, images, volumes, networks and more! It is compatible with the standalone Docker engine and with Docker Swarm. In this step by step guide I will show you how to install Portainer on your Synology NAS using Docker. This guide works perfectly for the latest Portainer CE 2.21.4 release.
STEP 1
Please Support My work by Making a Donation.
STEP 2
Install Container Manager via Synology āPackage Centerā. If you run an older DSM version (under 7.2), search for Docker instead of Container Manager.
STEP 3
Go toĀ File StationĀ and open the docker folder. Inside the docker folder, create a new folder and name itĀ portainer. Follow the instructions in the images below.
Note: Be careful enter to only lowercase, not uppercase letters.
STEP 4
Go toĀ Control Panel / Terminal & SNMP / Terminal tab. Check Enable SSH service on port 22 then click Apply. Follow the instructions in the images below.
STEP 5
Now open Windows Command Prompt Client. Search for command prompt on your Windows PC. Follow the instructions in the image below. You can also use the PuTTY Client or Mac Z Shell (Client) if you are a Mac user. Refer to this guide if you are a beginner: How to SSH into a Synology NAS
STEP 6
On Windows 10, open Command Prompt or use PuTTY or Mac Z Shell and type ssh yourNASusername@yourNASip -p22 then enter. Follow the instructions in the image below.
STEP 7
In Command Prompt, this message “Are you sure you want to continue connecting (yes/no)?” can sometimes appear, so type yes then enter. Follow the instructions in the image below.
STEP 8
After you press enter, you will be prompted to type in your NAS password. Type it in and press enter. Your command prompt will look like this:
STEP 9
Now type:
sudo su -
Then press enter. Follow the instructions in the image below.
The su command switches to root user with high privileges.
STEP 10
After you press enter, you will be prompted to type in your NAS password then press enter. Now you have full root access to your NAS. Follow the instructions in the image below.
STEP 11
Copy/Paste the code below in your client then press enter.
docker run -d -p 8000:8000 -p 9000:9000 --name=portainer --restart=always -v /var/run/docker.sock:/var/run/docker.sock -v /volume1/docker/portainer:/data portainer/portainer-ce
Follow the instructions in the image below.
STEP 12
After you press enter, the installation of the docker portainer image will start and should be done in a few seconds or minutes, depending on your Internet speed connection. Follow the instructions in the image below. At this step, you can also install Watchtower or Ouroboros to automatically update containers on your Docker.
STEP 13
Open your browser and type inĀ http://Synology-ip-address:9000/ Follow the instructions in the image below. Choose an Username and a strong Password, confirm the password then press Create user.
STEP 14
Click Get Started (Proceed using the local environment which Portainer is running it). Follow the instructions in the image below.
STEP 15
Go back toĀ STEP 1Ā or you will deal with karma š
STEP 16
On the right Environments, click on the little pencil. Follow the instructions in the image below.
STEP 17
After you click on the little pencil a new page will open. On the Public IP area type in your own NAS Local IP which, in my case, is 192.168.1.18 then click UpdateĀ environment. Follow the instructions in the image below.
STEP 18
If everything goes right, you will see this message at the top right of your screen: “Environment updated“.
Enjoy Portainer!
Note: If you want to run the Portainer container over HTTPS check How to Run Docker Containers Over HTTPS.
Note: Find outĀ how to update Portainer container with the latest image.
Note: I recommend you use Reverse Proxy to allow Portainer to work over an HTTPS connection.
Note: Can I run Docker on my Synology NAS?Ā See the supported models.
Note: CE stands for Community Edition.
Note: Now you can start adding more containers on your Synology Docker and have much more control over them using Portainer.
Note: If you receive the message: “Failure Cannot connect to the Docker daemon at unix:///var/run/docker.sock. Is the docker daemon running?” This happens when you try to install Portainer using the Docker Package through registry on your NAS without following the step by step guide in this article, especially STEP 11.
This post was updated on Friday / October 25th, 2024 at 9:10 AM