-
Notifications
You must be signed in to change notification settings - Fork 326
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add build support for mips64le #69
Conversation
Add build support for mips64le
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm definitely happy to support this -- any chance you've tested/verified the resulting binary?
Co-Authored-By: Tianon Gravi <[email protected]>
move mips64el up between arm64 and ppc64
Yes, working on this |
Unfortunately test failed... ;( - RUN cut -d: -f1 /etc/group | xargs -n1 addgroup nobody
+ RUN groupadd nobody && cut -d: -f1 /etc/group | xargs -n1 addgroup nobody run
Edit: Edit 2: |
Hmm, that does seem more like an issue with switching the base of the test suite than with the binary -- I'll take a look and see if I can recreate a (passing) test suite on Debian or Ubuntu. 👍 |
Merged in #72! If you rebase on that, you should be able to run something like |
hello, I tested the latest revision both on amd64 and mips64el using
|
Interesting, that seems like either a quirk of how If it turns out to be the latter, I should probably adjust that test to allow for that possibility (or explicitly run it with Edit: this seemed like a sane change regardless, so it's done in 789b12e 😇 👍 |
All tests passed! 👍🎉 That failure before because the base image has tini set as default entrypoint... [root@master3 gosu]# ./test.sh --debian gosu-mips64el ++ mktemp -d -t gosu-test-XXXXXXXXXX + dir=/tmp/gosu-test-RMo6ciNXE2 ++ basename /tmp/gosu-test-RMo6ciNXE2 + base=gosu-test-RMo6ciNXE2 + img=gosu-test:gosu-test-RMo6ciNXE2 + trap 'rm -rf '\''/tmp/gosu-test-RMo6ciNXE2'\''' EXIT + cp -T Dockerfile.test-debian /tmp/gosu-test-RMo6ciNXE2/Dockerfile + cp -T gosu-mips64el /tmp/gosu-test-RMo6ciNXE2/gosu + docker build -t gosu-test:gosu-test-RMo6ciNXE2 /tmp/gosu-test-RMo6ciNXE2 Sending build context to Docker daemon 2.627MB Step 1/43 : FROM registry.icp.com:5000/library/os/inspur-debian-stretch-mips64el:5.0.0 ---> ce7b02d8592c Step 2/43 : RUN cut -d: -f1 /etc/group | xargs -n1 -I'{}' usermod -aG '{}' nobody ---> Using cache ---> e58016aa74c6 Step 3/43 : RUN usermod -aG users games ---> Using cache ---> 26ecdc6708ac Step 4/43 : RUN { echo '#!/bin/sh'; echo 'set -ex'; echo; echo 'spec="$1"; shift'; echo; echo 'expec="$1"; shift'; echo 'real="$(gosu "$spec" id -u):$(gosu "$spec" id -g):$(gosu "$spec" id -G)"'; echo '[ "$expec" = "$real" ]'; echo; echo 'expec="$1"; shift'; echo 'real="$(gosu "$spec" id -un):$(gosu "$spec" id -gn):$(gosu "$spec" id -Gn)" || true'; echo '[ "$expec" = "$real" ]'; } > /usr/local/bin/gosu-t && chmod +x /usr/local/bin/gosu-t ---> Using cache ---> 4a97d132cc30 Step 5/43 : COPY gosu /usr/local/bin/ ---> Using cache ---> f7d7fef16a43 Step 6/43 : RUN chgrp nogroup /usr/local/bin/gosu && chmod +s /usr/local/bin/gosu ---> Using cache ---> bb30dad9c07b Step 7/43 : USER nobody ---> Using cache ---> 986bf03f1c50 Step 8/43 : ENV HOME /omg/really/gosu/nowhere ---> Using cache ---> 7108cf7f1f29 Step 9/43 : RUN id ---> Using cache ---> 6295a18935d4 Step 10/43 : RUN gosu-t 0 "0:0:$(id -G root)" "root:root:$(id -Gn root)" ---> Using cache ---> 5fe7d636ff0c Step 11/43 : RUN gosu-t 0:0 '0:0:0' 'root:root:root' ---> Using cache ---> 5785eb30fe65 Step 12/43 : RUN gosu-t root "0:0:$(id -G root)" "root:root:$(id -Gn root)" ---> Using cache ---> 984f31633d26 Step 13/43 : RUN gosu-t 0:root '0:0:0' 'root:root:root' ---> Using cache ---> a60d1936a2e5 Step 14/43 : RUN gosu-t root:0 '0:0:0' 'root:root:root' ---> Using cache ---> 20ad6a624c22 Step 15/43 : RUN gosu-t root:root '0:0:0' 'root:root:root' ---> Using cache ---> bc234927de38 Step 16/43 : RUN gosu-t 1000 "1000:$(id -g):$(id -g)" "1000:$(id -gn):$(id -gn)" ---> Using cache ---> f5acb94d501e Step 17/43 : RUN gosu-t 0:1000 '0:1000:1000' 'root:1000:1000' ---> Using cache ---> c4ccdca25635 Step 18/43 : RUN gosu-t 1000:1000 '1000:1000:1000' '1000:1000:1000' ---> Using cache ---> e95fc214c561 Step 19/43 : RUN gosu-t root:1000 '0:1000:1000' 'root:1000:1000' ---> Using cache ---> f8c0da0a29ae Step 20/43 : RUN gosu-t 1000:root '1000:0:0' '1000:root:root' ---> Using cache ---> 0e7e19d3e2fd Step 21/43 : RUN gosu-t 1000:daemon "1000:$(id -g daemon):$(id -g daemon)" '1000:daemon:daemon' ---> Using cache ---> 081626e4ad78 Step 22/43 : RUN gosu-t games "$(id -u games):$(id -g games):$(id -G games)" 'games:games:games users' ---> Using cache ---> c6f99f58e2c9 Step 23/43 : RUN gosu-t games:daemon "$(id -u games):$(id -g daemon):$(id -g daemon)" 'games:daemon:daemon' ---> Using cache ---> a0f06aaa2a25 Step 24/43 : RUN gosu-t 0: "0:0:$(id -G root)" "root:root:$(id -Gn root)" ---> Using cache ---> 513afe237395 Step 25/43 : RUN gosu-t '' "$(id -u):$(id -g):$(id -G)" "$(id -un):$(id -gn):$(id -Gn)" ---> Using cache ---> ba60d597a4e0 Step 26/43 : RUN gosu-t ':0' "$(id -u):0:0" "$(id -un):root:root" ---> Using cache ---> e14849a070cf Step 27/43 : RUN [ "$(gosu 0 env | grep '^HOME=')" = 'HOME=/root' ] ---> Using cache ---> 8a90cc9b6cf3 Step 28/43 : RUN [ "$(gosu 0:0 env | grep '^HOME=')" = 'HOME=/root' ] ---> Using cache ---> 122d6e964bb2 Step 29/43 : RUN [ "$(gosu root env | grep '^HOME=')" = 'HOME=/root' ] ---> Using cache ---> 7a9e49b30fbd Step 30/43 : RUN [ "$(gosu 0:root env | grep '^HOME=')" = 'HOME=/root' ] ---> Using cache ---> 52f56a96f6f4 Step 31/43 : RUN [ "$(gosu root:0 env | grep '^HOME=')" = 'HOME=/root' ] ---> Using cache ---> da818f495b2c Step 32/43 : RUN [ "$(gosu root:root env | grep '^HOME=')" = 'HOME=/root' ] ---> Using cache ---> c84b370f7827 Step 33/43 : RUN [ "$(gosu 0:1000 env | grep '^HOME=')" = 'HOME=/root' ] ---> Using cache ---> 090bf39f673a Step 34/43 : RUN [ "$(gosu root:1000 env | grep '^HOME=')" = 'HOME=/root' ] ---> Using cache ---> bb58fa0eaf00 Step 35/43 : RUN [ "$(gosu 1000 env | grep '^HOME=')" = 'HOME=/' ] ---> Using cache ---> 2f1b40255878 Step 36/43 : RUN [ "$(gosu 1000:0 env | grep '^HOME=')" = 'HOME=/' ] ---> Using cache ---> c57a132dea2d Step 37/43 : RUN [ "$(gosu 1000:root env | grep '^HOME=')" = 'HOME=/' ] ---> Using cache ---> 307174ccc60c Step 38/43 : RUN [ "$(gosu games env | grep '^HOME=')" = 'HOME=/usr/games' ] ---> Using cache ---> ba5a4e81e59c Step 39/43 : RUN [ "$(gosu games:daemon env | grep '^HOME=')" = 'HOME=/usr/games' ] ---> Using cache ---> 05044fec163f Step 40/43 : RUN ! gosu bogus true ---> Using cache ---> af91c195b13a Step 41/43 : RUN ! gosu 0day true ---> Using cache ---> ece7fc4a7a46 Step 42/43 : RUN ! gosu 0:bogus true ---> Using cache ---> 44cfc5566a29 Step 43/43 : RUN ! gosu 0:0day true ---> Using cache ---> 7c666ed107e6 Successfully built 7c666ed107e6 Successfully tagged gosu-test:gosu-test-RMo6ciNXE2 + rm -rf /tmp/gosu-test-RMo6ciNXE2 + trap - EXIT + trap 'docker rm -f '\''gosu-test-RMo6ciNXE2'\'' > /dev/null; docker rmi -f '\''gosu-test:gosu-test-RMo6ciNXE2'\'' > /dev/null' EXIT + docker run -d --init=false --entrypoint= --name gosu-test-RMo6ciNXE2 gosu-test:gosu-test-RMo6ciNXE2 gosu root sleep 1000 b791a15b7d6d117ea411cade289d48243cc0b9ecc0a964a07ce8a0c1c0f43b9c + sleep 1 ++ docker top gosu-test-RMo6ciNXE2 ++ wc -l + '[' 2 = 2 ']' + docker rm -f gosu-test-RMo6ciNXE2 + docker rmi -f gosu-test:gosu-test-RMo6ciNXE2 |
The CI build and test all passed. Related logs below: