docker

Can I install Docker on Synology DS418?


Is there a way to install Docker on Synology DS418 ?

I had try this with this aarch64/docker-20.10.6.tgz.

Here are the step I did:

  1. Download static docker binary at https://download.docker.com/linux/static/stable/aarch64/ . I choose the aarch64/docker-20.10.6.tgz, but I am maybe mistaking here.

  2. tar xzvf /path/to/.tar.gz

  3. sudo cp docker/* /usr/bin/

  4. create the /etc/docker/daemon.json configuration file with the following configuration:

{
  "storage-driver": "vfs",
  "iptables": false,
  "bridge": "none"
}
  1. sudo dockerd &

I received this error when I do the step 5.

xxx@NAS:~$ sudo dockerd &
[1] 806
xxx@NAS:~$ INFO[2021-05-04T14:35:55.752149353-05:00] Starting up
WARN[2021-05-04T14:35:55.753236211-05:00] could not change group /var/run/docker.sock to docker: group docker not found
INFO[2021-05-04T14:35:55.753833733-05:00] libcontainerd: containerd is still running pid=28644
INFO[2021-05-04T14:35:55.753946586-05:00] parsed scheme: "unix" module=grpc
INFO[2021-05-04T14:35:55.754184624-05:00] scheme "unix" not registered, fallback to default scheme module=grpc
INFO[2021-05-04T14:35:55.754265514-05:00] ccResolverWrapper: sending update to cc: {[{unix:///var/run/docker/containerd/containerd.sock <nil> 0 <nil>}] <nil> <nil>} module=grpc
INFO[2021-05-04T14:35:55.754313995-05:00] ClientConn switching balancer to "pick_first" module=grpc
WARN[2021-05-04T14:35:56.754892127-05:00] grpc: addrConn.createTransport failed to connect to {unix:///var/run/docker/containerd/containerd.sock <nil> 0 <nil>}. Err :connection error: desc = "transport: error while dialing: dial unix:///var/run/docker/containerd/containerd.sock: timeout". Reconnecting... module=grpc
WARN[2021-05-04T14:35:59.191460361-05:00] grpc: addrConn.createTransport failed to connect to {unix:///var/run/docker/containerd/containerd.sock <nil> 0 <nil>}. Err :connection error: desc = "transport: error while dialing: dial unix:///var/run/docker/containerd/containerd.sock: timeout". Reconnecting... module=grpc
WARN[2021-05-04T14:36:03.215171500-05:00] grpc: addrConn.createTransport failed to connect to {unix:///var/run/docker/containerd/containerd.sock <nil> 0 <nil>}. Err :connection error: desc = "transport: error while dialing: dial unix:///var/run/docker/containerd/containerd.sock: timeout". Reconnecting... module=grpc
WARN[2021-05-04T14:36:08.582014438-05:00] grpc: addrConn.createTransport failed to connect to {unix:///var/run/docker/containerd/containerd.sock <nil> 0 <nil>}. Err :connection error: desc = "transport: error while dialing: dial unix:///var/run/docker/containerd/containerd.sock: timeout". Reconnecting... module=grpc
failed to start containerd: timeout waiting for containerd to start

Thank you very much


Solution

  • All you're missing is:

    sudo synogroup --add docker $USER
    

    If you run this command as a non-root user, that user will be able to execute docker commands without sudo.

    If you don't want this, try running the command as root or

    sudo synogroup --add docker 
    

    may work. But I haven't tested either these latter two approaches.