no suitable node - unable to deploy image using docker service no suitable node - unable to deploy image using docker service docker docker

no suitable node - unable to deploy image using docker service


when you build your in PC, the build environment is x86.if you build the image on the Pi, the build environment and architecture is armhf.

Those images are not cross-platform and this is known problem nowadays.https://developer.ibm.com/linuxonpower/2017/07/27/create-multi-architecture-docker-image/

you might be right that in some scenarios, docker run versus docker service might work strangely (docker service results in error state, docker run works)


There is some issue with resolving images by docker.
When I type

docker info

In one of lines I see:

Architecture: armv7l

But when I build image on the same machine. And then inspect image,

docker image inspect 7c2f63598729

In one of lines what do I see:

"io.resin.architecture": "armhf",

How is this even possible ?The issue was resolved, by adding to stack command additional argument

--resolve-image never

So now, my stack deploy looks like this

docker stack deploy --compose-file docker-compose.yml --resolve-image never home


If you can run the image directly on the pi, you have definitely compiled it for the right architecture. If it cannot run using docker swarm, try to recreate the stack.

I accidentally pulled an x86 image to the pi, and even after downloading a new arm-compatible image from the registry, I was still getting:

no suitable node (unsupported platform on 3 nodes)

Doing docker inspect on the stack I could see this:

"Architecture": "amd64","OS": "linux"

After recreating the stack it started up correctly. Docker inspect on the stack no longer has any indication of architecture.