Giter Site home page Giter Site logo

multiarch / alpine Goto Github PK

View Code? Open in Web Editor NEW
88.0 88.0 22.0 57 KB

:earth_africa: `alpine` Docker image for multiple architectures

Home Page: https://hub.docker.com/r/multiarch/alpine/

License: MIT License

Shell 100.00%
alpine cross-compiler cross-platform docker multiarch

alpine's People

Contributors

aosadchyy avatar cybe avatar lafin avatar moul avatar nlm avatar squat avatar tcely avatar tmaczukin avatar uspike avatar wborn avatar wilmardo avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

alpine's Issues

Problems with qemu 5.2

Hi, we use multiarch/alpine to build some images for armv7 target on gitlab, and since the last update to qemu 5.2 we.re getting this error:

 qemu-arm-static: Unable to reserve 0xffff0000 bytes of virtual address space at 0x1000 (Success) for use as guest address space (check yourvirtual memory ulimit setting, min_mmap_addr or reserve less using -R option)

Any idea of why it could be or how to workaround it?

apk add on multiarch/alpine:armhf-v3.10 does not respect proxy settings that alpine:3.10 accepts

I have been trying to build a Docker image based on multiarch/alpine:armhf-v3.10 behind a proxy.
With alpine:3.10, this is quite straightforward: just provide a --build-arg telling it the proxy settings. Then apk add works fine.
multiarch/alpine:armhf-v3.10, however, seems to ignore any such settings, so apk add fails to get through the proxy.

I tried adding various additional --build-args that folklore suggested might help. I tried different capitalization, I tried adding HTTP_PROXY_AUTH with a username and password (even though the proxy did not require such) because folklore suggested apk add might not realize it needed to set anything up unless HTTP_PROXY_AUTH was provided (even if HTTP_PROXY_AUTH would then go unused), I tried adding --network=host.
In every case, alpine:3.10 worked fine but the same apk add on multiarch/alpine:armhf-v3.10 kicked back a "Permission denied".

$ sudo docker system prune --all --volumes
Total reclaimed space: 4.147GB

sudo docker build -t gitlab/gitlab-runner-helper:x86_64-57d7c5fc --build-arg HTTP_PROXY=proxyaddress:proxyport --build-arg HTTPS_PROXY=proxyaddress:proxyport --build-arg http_proxy=proxyaddress:proxyport --build-arg https_proxy=proxyaddress:proxyport --build-arg HTTP_PROXY_AUTH=basic:*:proxyuser:proxypass --network=host -f dockerfiles/build/Dockerfile.x86_64 dockerfiles/build
Sending build context to Docker daemon  33.93MB
Step 1/8 : FROM alpine:3.10
3.10: Pulling from library/alpine
21c83c524219: Pull complete
Digest: sha256:f0e9534a598e501320957059cb2a23774b4d4072e37c7b2cf7e95b241f019e35
Status: Downloaded newer image for alpine:3.10
 ---> be4e4bea2c2e
Step 2/8 : ENV PATH="${PATH:-/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin}"
 ---> Running in dc395d397df0
Removing intermediate container dc395d397df0
 ---> 21c1c5f99dbc
Step 3/8 : RUN apk add --no-cache bash ca-certificates git git-lfs miniperl     && ln -s miniperl /usr/bin/perl
 ---> Running in 123152b84744
fetch http://dl-cdn.alpinelinux.org/alpine/v3.10/main/x86_64/APKINDEX.tar.gz
fetch http://dl-cdn.alpinelinux.org/alpine/v3.10/community/x86_64/APKINDEX.tar.gz
(1/12) Installing ncurses-terminfo-base (6.1_p20190518-r2)
(2/12) Installing ncurses-libs (6.1_p20190518-r2)
(3/12) Installing readline (8.0.0-r0)
(4/12) Installing bash (5.0.0-r0)
Executing bash-5.0.0-r0.post-install
(5/12) Installing ca-certificates (20191127-r0)
(6/12) Installing nghttp2-libs (1.39.2-r0)
(7/12) Installing libcurl (7.66.0-r0)
(8/12) Installing expat (2.2.8-r0)
(9/12) Installing pcre2 (10.33-r0)
(10/12) Installing git (2.22.4-r0)
(11/12) Installing git-lfs (2.7.2-r0)
Executing git-lfs-2.7.2-r0.post-install
Git LFS initialized.
(12/12) Installing miniperl (5.28.2-r1)
Executing busybox-1.30.1-r3.trigger
Executing ca-certificates-20191127-r0.trigger
OK: 39 MiB in 26 packages
Removing intermediate container 123152b84744
 ---> 34b34a41e11d
Step 4/8 : RUN git lfs install --skip-repo
 ---> Running in 9e50736c3ebc
Git LFS initialized.
Removing intermediate container 9e50736c3ebc
 ---> 5c657eb8e8ec
Step 5/8 : COPY ./scripts/ /usr/bin
 ---> 98a67ff0b6c5
Step 6/8 : COPY ./binaries/gitlab-runner-helper.x86_64 /usr/bin/gitlab-runner-helper
 ---> 2cd18e7b6f2b
Step 7/8 : RUN echo 'hosts: files dns' >> /etc/nsswitch.conf
 ---> Running in 1a851c7b2f3e
Removing intermediate container 1a851c7b2f3e
 ---> c47a7482305c
Step 8/8 : CMD ["sh"]
 ---> Running in 6d3c0a0bebf8
Removing intermediate container 6d3c0a0bebf8
 ---> 50727ff983e6
[Warning] One or more build-args [HTTP_PROXY_AUTH] were not consumed
Successfully built 50727ff983e6
Successfully tagged gitlab/gitlab-runner-helper:x86_64-57d7c5fc
sudo docker build -t gitlab/gitlab-runner-helper:arm-57d7c5fc --build-arg HTTP_PROXY=proxyaddress:proxyport --build-arg HTTPS_PROXY=proxyaddress:proxyport --build-arg http_proxy=proxyaddress:proxyport --build-arg https_proxy=proxyaddress:proxyport --build-arg HTTP_PROXY_AUTH=basic:*:proxyuser:proxypass --network=host -f dockerfiles/build/Dockerfile.arm dockerfiles/build
Sending build context to Docker daemon  33.93MB
Step 1/8 : FROM multiarch/alpine:armhf-v3.10
armhf-v3.10: Pulling from multiarch/alpine
2924843505f3: Pull complete
c62ec2f1a9fc: Pull complete
Digest: sha256:0aaddc38f3dc7f1f4e9f762e2efca656805e2fb1cd2a1d835467dcbb346cc1ba
Status: Downloaded newer image for multiarch/alpine:armhf-v3.10
 ---> b98b3655db00
Step 2/8 : ENV PATH="${PATH:-/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin}"
 ---> Running in c672faeb2175
Removing intermediate container c672faeb2175
 ---> ae0398c1cb2a
Step 3/8 : RUN apk add --no-cache bash ca-certificates git git-lfs miniperl     && ln -s miniperl /usr/bin/perl
 ---> Running in b90f8b5cf03a
fetch https://uk.alpinelinux.org/alpine/v3.10/main/armhf/APKINDEX.tar.gz
fetch https://uk.alpinelinux.org/alpine/v3.10/community/armhf/APKINDEX.tar.gz
WARNING: Ignoring https://uk.alpinelinux.org/alpine/v3.10/main/armhf/APKINDEX.tar.gz: Permission denied
WARNING: Ignoring https://uk.alpinelinux.org/alpine/v3.10/community/armhf/APKINDEX.tar.gz: Permission denied
ERROR: unsatisfiable constraints:
  bash (missing):
    required by: world[bash]
  ca-certificates (missing):
    required by: world[ca-certificates]
  git (missing):
    required by: world[git]
  git-lfs (missing):
    required by: world[git-lfs]
  miniperl (missing):
    required by: world[miniperl]
The command '/bin/sh -c apk add --no-cache bash ca-certificates git git-lfs miniperl    && ln -s miniperl /usr/bin/perl' returned a non-zero code: 5
Makefile.runner_helper.mk:58: recipe for target 'out/helper-images/prebuilt-arm.tar' failed
make: *** [out/helper-images/prebuilt-arm.tar] Error 5

Missing v3.11 version for armhf and armv7 architectures

The latest CI jobs for armhf and armv7 architectures have failed, which makes the v3.11 images for these unavailable.

All other jobs for all other version/architecture pairs are passing, which suggests that the problem was temporary.

Could the jobs be restarted and the missing version tags published?

Cannot use `sudo` on aarch64

Hi!

Thank you for this project! It is really helpful!

I've found an issue that prevents me to use Alpine Linux abuild tool on it.
abuild has to be executed by a non-root user with sudo but fails with Cannot lock database error while trying to install the dependencies with apk add.

I was able to minimize the problem to these steps:

  1. docker run -it --rm multiarch/alpine:aarch64-edge sh
  2. apk add sudo
  3. adduser xyz
  4. echo "xyz ALL=(ALL) NOPASSWD: ALL" > /etc/sudoers
  5. su xyz
  6. sudo ls -la
sudo: effective uid is not 0, is /usr/bin/sudo on a file system with the 'nosuid' option set or an NFS file system without root privileges?

If I replace multiarch/alpine:aarch64-edge with alpine:3 at step 1 then everything is OK.

It looks similar to these issues:

  1. moby/moby#36730 (comment)
  2. alpinelinux/docker-abuild#47

Any idea how to work it around ?

https mirror causing fetching failures

Overview

When using the default https mirrors on armhf you get a failure on pulling the packages:

docker run multiarch/alpine:arm64-v3.10 apk add curl
fetch https://uk.alpinelinux.org/alpine/v3.10/main/aarch64/APKINDEX.tar.gz
ERROR: https://uk.alpinelinux.org/alpine/v3.10/main: temporary error (try again later)
fetch https://uk.alpinelinux.org/alpine/v3.10/community/aarch64/APKINDEX.tar.gz
ERROR: https://uk.alpinelinux.org/alpine/v3.10/community: temporary error (try again later)
WARNING: Ignoring APKINDEX.1bc08705.tar.gz: No such file or directory
(1/4) Installing ca-certificates (20191127-r0)
ERROR: ca-certificates-20191127-r0: temporary error (try again later)
(2/4) Installing nghttp2-libs (1.39.2-r0)
(3/4) Installing libcurl (7.66.0-r0)
ERROR: nghttp2-libs-1.39.2-r0: temporary error (try again later)
(4/4) Installing curl (7.66.0-r0)
ERROR: libcurl-7.66.0-r0: temporary error (try again later)
ERROR: curl-7.66.0-r0: temporary error (try again later)
4 errors; 8 MiB in 19 packages

Details

  • This happens for all alpine versions such as 3.10, 3.11, and 3.12.
  • It seems like it's some strange DNS issue because it doesn't happen on every network.

Current Fix

  • Change back to the http mirror such as http://dl-cdn.alpinelinux.org/alpine/v3.10

Reproduce locally

The only way I can reproduce this is through docker in docker, for example, https://gitlab.com/steveazz/playground/-/jobs/578622615 and https://gitlab.com/gitlab-org/gitlab-runner/-/jobs/576880551

docker network create dind
docker run --rm --privileged --network=dind -e DOCKER_TLS_CERTDIR="" --name=docker docker:dind 
# In a new terminal window
docker run --rm -it --network=dind docker:19.03.5 sh # In a new terminal window
docker run --rm -it multiarch/alpine:arm64-v3.10 apk add --no-cache bash ca-certificates git git-lfs miniperl && ln -s miniperl /usr/bin/perl

Reference

https://uk.alpinelinux.org/alpine 404

It seems like the uk.alpinelinux.org mirror isn't available anymore

Step 10/15 : RUN apk update && apk add ca-certificates && rm -rf /var/cache/apk/*
 ---> Running in b4864d46635b
fetch https://uk.alpinelinux.org/alpine/edge/main/armhf/APKINDEX.tar.gz
ERROR: https://uk.alpinelinux.org/alpine/edge/main: No such file or directory
fetch https://uk.alpinelinux.org/alpine/edge/community/armhf/APKINDEX.tar.gz
ERROR: https://uk.alpinelinux.org/alpine/edge/community: No such file or directory
WARNING: Ignoring APKINDEX.514eaa30.tar.gz: No such file or directory
v20190925-3232-g551792af7f [https://uk.alpinelinux.org/alpine/edge/main]
2 errors; 5466 distinct packages available
The command '/bin/sh -c apk update && apk add ca-certificates && rm -rf /var/cache/apk/*' returned a non-zero code: 2

I switched the repositories to http://dl-cdn.alpinelinux.org/alpine/edge/ which seems to be working fine in my case.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.