Skip to content
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

[Buildx] Che-dashboard && che-workspace-loader build is failing in some cases #16983

Closed
skabashnyuk opened this issue May 21, 2020 · 11 comments
Closed
Labels
area/dashboard kind/bug Outline of a bug - must adhere to the bug report template. severity/P1 Has a major impact to usage or development of the system.

Comments

@skabashnyuk
Copy link
Contributor

Describe the bug

For unknown to me reasons Buildx build is failing some times.

several times like this
https://github.com/eclipse/che-dashboard/runs/695674547?check_suite_focus=true

#7 ERROR: failed to copy: httpReaderSeeker: failed open: server message: invalid_token: authorization failed
------
 > [stage-1 2/4] RUN sed -i 's|    AllowOverride None|    AllowOverride All|' /usr/local/apache2/conf/httpd.conf &&     sed -i 's|Listen 80|Listen 8080|' /usr/local/apache2/conf/httpd.conf &&     mkdir -p /var/www && ln -s /usr/local/apache2/htdocs /var/www/html &&     chmod -R g+rwX /usr/local/apache2 &&     echo "ServerName localhost" >> /usr/local/apache2/conf/httpd.conf:
------
failed to solve: rpc error: code = Unknown desc = failed to load cache: failed to copy: httpReaderSeeker: failed open: server message: invalid_token: authorization failed
##[error]Process completed with exit code 1.

several times like this
https://github.com/eclipse/che-workspace-loader/runs/695731886?check_suite_focus=true
#29 exporting manifest

sha256:9eb16121ec8338a95f42e79bfe80630ecf3a36f1b981238145a470f77f48caa8 done
#29 exporting config sha256:c9a275485c8d93b80104c669d2425a640bdd965159f03f9312984419ffb39b58 done
#29 exporting manifest sha256:cf42d3821b55aa33b3c6ee2f9d0e867ac65aacacca5e2027bff8f6bc9e820855 done
#29 exporting config sha256:e55e574af113d99980c90b39e5ab05f0c54b2fe968539ab956e978847c66e8ae
#29 exporting config sha256:e55e574af113d99980c90b39e5ab05f0c54b2fe968539ab956e978847c66e8ae done
#29 exporting manifest list sha256:81fd17e4f315439dd71107ae21eb2127c63465d48db5f3d56649d0eba509b372 done
#29 pushing layers
#29 pushing layers 0.1s done
#29 pushing manifest for quay.io/eclipse/che-workspace-loader:next
#29 pushing manifest for quay.io/eclipse/che-workspace-loader:next 0.2s done
#29 ERROR: failed commit on ref "manifest-sha256:cf42d3821b55aa33b3c6ee2f9d0e867ac65aacacca5e2027bff8f6bc9e820855": unexpected status: 401 UNAUTHORIZED
------
 > exporting to image:
------
failed to solve: rpc error: code = Unknown desc = failed commit on ref "manifest-sha256:cf42d3821b55aa33b3c6ee2f9d0e867ac65aacacca5e2027bff8f6bc9e820855": unexpected status: 401 UNAUTHORIZED
##[error]Process completed with exit code 1.
@skabashnyuk skabashnyuk added kind/bug Outline of a bug - must adhere to the bug report template. area/dashboard area/workspace-loader labels May 21, 2020
@che-bot che-bot added the status/need-triage An issue that needs to be prioritized by the curator responsible for the triage. See https://github. label May 21, 2020
@skabashnyuk skabashnyuk added severity/P1 Has a major impact to usage or development of the system. and removed status/need-triage An issue that needs to be prioritized by the curator responsible for the triage. See https://github. labels May 21, 2020
@skabashnyuk
Copy link
Contributor Author

At this moment I think it might be related to:

  • the way how we do cache layers. We use docker hub to push cache and quay.io to push real images
  • quay.io/docker hub might not support the necessary API used by buildx
  • multi-platform build

@skabashnyuk
Copy link
Contributor Author

CC @shahidhs-ibm @benoitf @nickboldt

@skabashnyuk
Copy link
Contributor Author

at this moment I want to make several experiments with/without cache and using the matrix for multi-platform build

@skabashnyuk
Copy link
Contributor Author

build with matrix

      matrix:
        platform: [linux/amd64, linux/s390x]
        layerscaching: [true, false]

Знімок екрана 2020-05-21 о 11 40 47

fails only linux/s390x+ without layerscaching

@skabashnyuk
Copy link
Contributor Author

che-workspce-loader

#16 [linux/s390x builder 7/7] RUN yarn build && yarn test
#16 12.51 Error: Unexpected token ] in JSON at position 356 in /workspace-loader/tslint.json
#16 12.51     at readConfigurationFile (/workspace-loader/node_modules/tslint/lib/configuration.js:187:19)
#16 12.51     at Object.loadConfigurationFromPath (/workspace-loader/node_modules/tslint/lib/configuration.js:160:29)
#16 12.51     at /workspace-loader/node_modules/typescript-formatter/lib/provider/tslintjson.js:134:43
#16 12.51     at step (/workspace-loader/node_modules/typescript-formatter/lib/provider/tslintjson.js:32:23)
#16 12.51     at Object.next (/workspace-loader/node_modules/typescript-formatter/lib/provider/tslintjson.js:13:53)
#16 12.51     at fulfilled (/workspace-loader/node_modules/typescript-formatter/lib/provider/tslintjson.js:4:58)
#16 12.51     at <anonymous>
#16 12.65 error Command failed with exit code 1.
#16 12.66 info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
#16 12.82 error Command failed with exit code 1.
#16 12.82 info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
#16 ERROR: executor failed running [/bin/sh -c yarn build && yarn test]: buildkit-runc did not terminate successfully

@ericwill
Copy link
Contributor

I was running into this for sidecar container builds as well, but ended up just disabling caching for now. Not sure if it helps but @benoitf managed to get it working here.

@skabashnyuk
Copy link
Contributor Author

che loader

#29 pushing layers
#29 pushing layers 0.1s done
#29 pushing manifest for quay.io/eclipse/che-workspace-loader:next
#29 pushing manifest for quay.io/eclipse/che-workspace-loader:next 0.2s done
#29 ERROR: failed commit on ref "manifest-sha256:c6e2b61b24d6e9cce631a20165a8bc391330bbc6db4173f67e723ffc8aa86d0b": unexpected status: 401 UNAUTHORIZED
------
 > exporting to image:
------
failed to solve: rpc error: code = Unknown desc = failed commit on ref "manifest-sha256:c6e2b61b24d6e9cce631a20165a8bc391330bbc6db4173f67e723ffc8aa86d0b": unexpected status: 401 UNAUTHORIZED
child_process.js:669
    throw err;
    ^

Error: Command failed: docker buildx build --platform linux/amd64,linux/s390x --cache-from="type=registry,ref=${CACHE_IMAGE_FULL}" --cache-to="type=registry,ref=${CACHE_IMAGE_FULL},mode=max" -t ${IMAGE_FULL}  -f apache.Dockerfile --push .

https://github.com/eclipse/che-workspace-loader/runs/698909038

@shahidhs-ibm
Copy link

@skabashnyuk We have checked the github action logs of your work and the phantomjs failures in s390x will need a fix. We will work on this and will keep you posted. Most likely will need a new PR.

@skabashnyuk
Copy link
Contributor Author

@shahidhs-ibm thx.

@skabashnyuk
Copy link
Contributor Author

workspace loader new failure

9 pushing manifest for quay.io/eclipse/che-workspace-loader:next
#29 pushing manifest for quay.io/eclipse/che-workspace-loader:next 0.2s done
#29 ERROR: failed commit on ref "manifest-sha256:c6e2b61b24d6e9cce631a20165a8bc391330bbc6db4173f67e723ffc8aa86d0b": unexpected status: 401 UNAUTHORIZED
------
 > exporting to image:
------
failed to solve: rpc error: code = Unknown desc = failed commit on ref "manifest-sha256:c6e2b61b24d6e9cce631a20165a8bc391330bbc6db4173f67e723ffc8aa86d0b": unexpected status: 401 UNAUTHORIZED
child_process.js:669
    throw err;
    ^

Error: Command failed: docker buildx build --platform linux/amd64,linux/s390x --cache-from="type=registry,ref=${CACHE_IMAGE_FULL}" --cache-to="type=registry,ref=${CACHE_IMAGE_FULL},mode=max" -t ${IMAGE_FULL}  -f apache.Dockerfile --push .
    at checkExecSyncError (child_process.js:630:11)
    at execSync (child_process.js:666:15)
    at run (/home/runner/work/_actions/nick-invision/retry/v1/dist/exec.js:5:3)
    at Object.<anonymous> (/home/runner/work/_actions/nick-invision/retry/v1/dist/exec.js:8:1)
    at Module._compile (internal/modules/cjs/loader.js:1133:30)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:1153:10)
    at Module.load (internal/modules/cjs/loader.js:977:32)

@sleshchenko
Copy link
Member

that's a quite general. Currently, we have a pretty stable build of workspace and che-dashboard.
If we'll face any failure - we'll register a new issue.

alpeb added a commit to linkerd/linkerd2 that referenced this issue Oct 23, 2020
gcr.io has an issue that it's not possible to update multi-arch images
(see eclipse-che/che#16983 and open-policy-agent/gatekeeper#665).

We're now relying on ghcr.io instead, which I verified doesn't have this
bug, so we can stop skipping these pushes.
alpeb added a commit to linkerd/linkerd2 that referenced this issue Oct 23, 2020
gcr.io has an issue that it's not possible to update multi-arch images
(see eclipse-che/che#16983 and open-policy-agent/gatekeeper#665).

We're now relying on ghcr.io instead, which I verified doesn't have this
bug, so we can stop skipping these pushes.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/dashboard kind/bug Outline of a bug - must adhere to the bug report template. severity/P1 Has a major impact to usage or development of the system.
Projects
None yet
Development

No branches or pull requests

5 participants