简体   繁体   中英

Pulling arm32v7 Docker container images on Raspberry Pi 3 B +

I have a Raspberry Pi 3 B+ with Docker installed on it. I'm trying to pull the latest ARMv7 edition of the golang container image, linked below.

When I run the docker pull command on the image, I get the generic error below.

pi@trevorpi:~ $ docker pull arm32v7/golang:latest
Pulling repository docker.io/arm32v7/golang
Tag latest not found in repository docker.io/arm32v7/golang

Here's the version of Docker I'm running:

pi@trevorpi:~ $ docker version
Client:
 Version:      1.8.3
 API version:  1.20
 Go version:   go1.4.3
 Git commit:   f4bf5c7
 Built:
 OS/Arch:      linux/arm

Server:
 Version:      1.8.3
 API version:  1.20
 Go version:   go1.4.3
 Git commit:   f4bf5c7
 Built:
 OS/Arch:      linux/arm

Here's the output from uname -a , which indicates it's ARMv7:

Linux trevorpi 4.14.71-v7+ #1145 SMP Fri Sep 21 15:38:35 BST 2018 armv7l GNU/Linux

Obviously, the x86 Docker image for golang doesn't work, because it's not ARM-compatible. I can pull the image, but it won't run due to processor architecture:

pi@trevorpi:~ $ docker pull golang:latest
latest: Pulling from library/golang

836de16dcbe9: Already exists
490028bf21ec: Already exists
b9aece5a7acf: Already exists
e5bf67252042: Already exists
a221240e1da3: Already exists
efcf11bc5c78: Already exists
32d2d4bbdbd3: Already exists
599e9bccee8b: Already exists
b77bfa353366: Already exists
dc799d5ef217: Already exists
cb12e793d3e1: Already exists
c984412a4f12: Already exists
Digest: sha256:ce05c9f8151cc4ff3ce508509720597d103b630aa024bcfb012107149abfa361
Status: Image is up to date for golang:latest
pi@trevorpi:~ $ docker run --rm -it golang
WARNING: Your kernel does not support memory swappiness capabilities, memory swappiness discarded.
exec format error
Error response from daemon: Cannot start container 0c04cb7f7192f2059b029637bd6306c0a4ff83299e3a20df920b3ea56339ab7a: [8] System error: exec format error

Question : I manually verified that the latest tag is valid. What do I need to do to pull this image?

Maybe you are trying to download an image not available for your system (OS or Architecture).

$ docker manifest inspect -v arm32v7/golang:latest
[
    {
        "Ref": "docker.io/arm32v7/golang:latest@sha256:faf19ab885f9d0779bbbd615eee610c5aedfdd203ac5fceefbd5fc8afd73a2ac",
        "Descriptor": {
            "mediaType": "application/vnd.docker.distribution.manifest.v2+json",
            "digest": "sha256:faf19ab885f9d0779bbbd615eee610c5aedfdd203ac5fceefbd5fc8afd73a2ac",
            "size": 1795,
            "platform": {
                "architecture": "arm",
                "os": "linux",
                "variant": "v7"
            }

Are you sure your raspberry uses arm v7 architecture? Unfortunately, I don't have raspberry ow my own, so I can't reproduce this problem. Have you tried do pull with other tags than latest? Also, You could try to build this image yourself. Golang repo

Maybe try with an official repository for golang:

docker pull golang:latest

they also support your architecture:

Supported architectures: md64, arm32v6, arm32v7, arm64v8, i386, ppc64le, s390x, windows-amd6

Maybe this is a connection/firewall issue. Can you pull from other repositories?

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM