Is it possible to run docker CLI plugins from the docker snap?

Is it possible to run docker CLI plugins from the docker snap?

I am following these instructions to try to install the buildx plugin for docker, and I have tried to put the binary in different folders without luck for the moment.

AFAIK, the docker snap uses the home directory for the snap, so have you tried putting the binary in /home/<user>/snap/docker/current/.docker/...?

I tried that one, but no luck :confused:

The docker snap is too old to support cli plugins. You need docker to be at least version 19.03, which isn’t available in the snap. I’ve pushed many times to get the docker snap brought up to date but it seems to fall by the wayside…

@tianon do you have an ETA updating the docker snap to 19.03+?

In the meantime, you can run the buildx plugin directly:

chmod +x /path/to/docker-buildx
/path/to/docker-buildx version
/path/to/docker-buildx build .
1 Like

Good point, thanks for this!

I’ve been playing with this (I wasn’t aware I could run it directly, either :smile:) but I’m struggling to get it to build alternative architectures :frowning:

@tianon any chance we can get some guidance, please?

19.03.8 is now in the beta channel and could use some testing :smile:

3 Likes