1. Container Station: If this is not already on your device then install it from the QNAP App Store. Setup with all default options.
  2. Portainer Container: If this is not already up and running see my “Three Tips” post for ideas how to create the container. Also, create the admin user if you have not already done so.

Main Setup

When you log into Portainer for the first time it will prompt you to connect to a Docker endpoint. For our purposes that endpoint will be Container Station. If Portainer is running on the same machine as Container Station choose the Local option. Otherwise, choose Remote.

Endpoint Setup Endpoint Setup

Local Endpoint

This option is super easy …if… you started Portainer with the correct Docker flag:

-v /var/run/docker.sock:/var/run/docker.sock

If you did, then click the Connect button and you are all set. Yay!
If you did NOT, then your options are either to restart the container using that flag or to follow the remote connection process outlined below.

Remote Endpoint #1 - Modify Container Station to accept Portainer as a connection

A few adjustments need to be made to Container Station before it will allow Portainer to connect. Big Picture: this process communicates via TLS through a specified port on your NAS’s IP address.

  1. Open Container Station and go to: Preferences > Docker Certificate
  2. Click the Download button to save a zipped certificate to your PC
  3. Unzip the certificate file to a temp folder (we’ll return to this in step 5 in the next section)
  4. Upload the zipped certificate file to /share/Container/ on your NAS (via local share, File Station, etc.)
  5. Login to your NAS via SSH with a user that has admin privileges
  6. Create a hidden directory by executing mkdir -pv ~/.docker
  7. Unzip and copy the cert file contents to the hidden directory:
    unzip /share/Container/ -d ~/.docker
  8. Now execute:
    • Update the above with your NAS’s IP address

Remote Endpoint #2 - Portainer: add Container Station as an endpoint

While logged in as the admin user:

  1. Choose Remote
  2. Enter an environment or device name
  3. Enter endpoint URL: use the same one listed in #1 above (include the port number). Example:
  4. Turn on TLS
  5. Use the certificate files you unzipped in the section above to make the following selections/matchings:
    • TLS CA certificate == ca.pem
    • TLS certificate == cert.pem
    • TLS key == key.pem
  6. Click Connect

Was this post helpful? Buy Me A Coffee or drop me a note in the comments. Thanks.