build-image
build-image copied to clipboard
Container-structure-tests fail for arm64
When building the new Dockerfile on Apple Silicon for arm64 (with the changes from @lukasholzer), the container-structure-tests are failing now:
=== RUN: Command Test: hugo
--- FAIL
duration: 289.941792ms
Error: Error creating container: API error (400): failed to create shim task: OCI runtime create failed: runc create failed: unable to start container process: exec: "hugo": executable file not found in $PATH: unknown
=== RUN: Command Test: Golang
--- FAIL
duration: 19.521397542s
stderr: /opt/build-bin/run-build-functions.sh: line 912: /opt/buildhome/.gimme/env/go1.18.linux.amd64.env: No such file or directory
bash: line 2: go: command not found
Error: Expected string 'go version go1.18 linux/amd64' not found in output ''
Error: Test 'Golang' exited with incorrect error code. Expected: 0, Actual: 127
--- FAIL
duration: 0s
Error: /opt/build-bin/run-build-functions.sh has incorrect permissions. Expected: -rwxrwxr-x, Actual: -rwxr-xr-x
=== RUN: Metadata Test
--- FAIL
duration: 0s
Error: env var TARGETARCH value arm64 does not match expected value: amd64
=== RUN: Command Test: Homebrew
--- FAIL
duration: 295.3165ms
Error: Error creating container: API error (400): failed to create shim task: OCI runtime create failed: runc create failed: unable to start container process: exec: "brew": executable file not found in $PATH: unknown
they are only failing if you build the image locally with arm and then run the tests against them. When the image is built with amd64 they are passing.
in general we need to think about maybe having 2 separate yaml files for each architecture one as some expectations like the TARGETARCH can never pass otherwise.
For now I'm totally ok with they can just run on the CI (or against a pulled image)
This should be fixed in #828