Transfer a Docker Image from Mac to Pi

TLDR

It didn’t work out. Don’t bother repeating it. It seems that with this way, the image is not of the correct architecture!

Aim

I’d like to transfer Docker images without depending on an external repository like Docker Hub.

Protocol

Check the images:

docker images

Save the image to a tar file:

docker save -o myImage.tar rolfsuter/testmultiarch:latest

Copy the tar file to the Pi:

scp myImage.tar pi@[IP]:myImage.tar

Connect to the Pi:

ssh pi@[IP]

List the current Docker images on the Pi:

sudo docker images

Load the image from the tar file:

sudo docker load -i myImage.tar

Check the image. Run:

sudo docker run --rm rolfsuter/testmultiarch:latest uname

Response:

standard_init_linux.go:211: exec user process caused "exec format error"

References

Leave a Reply

Your email address will not be published. Required fields are marked *