Skip to content

Fix buildx installation#2952

Merged
TingluoHuang merged 1 commit into
actions:mainfrom
ajschmidt8:fix-buildx
Oct 25, 2023
Merged

Fix buildx installation#2952
TingluoHuang merged 1 commit into
actions:mainfrom
ajschmidt8:fix-buildx

Conversation

@ajschmidt8

Copy link
Copy Markdown
Contributor

This PR is a continuation of #2901.

I hadn't tested that change locally and didn't realize the Dockerfile did a multi-stage build.

This PR fixes the buildx installation to ensure that the binary is copied to the final stage.

I tested these changes locally to confirm that it works as expected.

@ajschmidt8 ajschmidt8 requested a review from a team as a code owner October 25, 2023 17:00
@ajschmidt8

Copy link
Copy Markdown
Contributor Author

cc: @TingluoHuang.

If we could get a patch release for 2.311.0 with this change that would be awesome.

Comment thread images/Dockerfile
@TingluoHuang TingluoHuang merged commit ce4e62c into actions:main Oct 25, 2023
@Wielewout Wielewout mentioned this pull request Oct 26, 2023
@chrisdleech-pol

Copy link
Copy Markdown

This seems to be causing an issue for some container actions. Example when using hadolint-action in a workflow.

Build container for action use: '/home/runner/_work/_actions/hadolint/hadolint-action/v3.1.0/Dockerfile'.
  ERROR: mkdir /home/runner/.docker/buildx: read-only file system
@ajschmidt8 ajschmidt8 deleted the fix-buildx branch October 26, 2023 20:33
@ajschmidt8

Copy link
Copy Markdown
Contributor Author

This seems to be causing an issue for some container actions. Example when using hadolint-action in a workflow.

Build container for action use: '/home/runner/_work/_actions/hadolint/hadolint-action/v3.1.0/Dockerfile'.
  ERROR: mkdir /home/runner/.docker/buildx: read-only file system

As far I as know, this hasn't been released yet. So I'm not sure if this is what's causing your problem.

@chrisdleech-pol

Copy link
Copy Markdown

Fair enough. The latest image for 2.311.0 was updated 1 day ago, and I assumed this part of that update

@jlehnGIT

jlehnGIT commented Oct 27, 2023

Copy link
Copy Markdown

@ajschmidt8 was curious if this was related...We tried to run runner version 2.310.2 from current 2.209.0 and something has changed to where what was working fine now is failing and seems to be related possibly to Docker. Was wondering if this error indicates related to this issue or not please?

image

@ajschmidt8

Copy link
Copy Markdown
Contributor Author

This PR hasn't been included in any runner release yet. I would recommend reviewing the release changelogs to identify any changes that may have affected your workflows.

Disclaimer, I don't work for GitHub and therefore don't provide any support for these changes.

@jlehnGIT

Copy link
Copy Markdown

Thank you and yes understand. Was seeing if you may have an idea of what may be happening. Thank you.

@omer2500

omer2500 commented Feb 20, 2024

Copy link
Copy Markdown

This seems to be causing an issue for some container actions. Example when using hadolint-action in a workflow.

Build container for action use: '/home/runner/_work/_actions/hadolint/hadolint-action/v3.1.0/Dockerfile'.
  ERROR: mkdir /home/runner/.docker/buildx: read-only file system

As far I as know, this hasn't been released yet. So I'm not sure if this is what's causing your problem.

For anyone facing this issue
add this to your runner env:

  - name: BUILDX_CONFIG
    value: /tmp/buildx

This will tell it to go to a different folder
works on 2.313
should work on earlier versions with the build

@ajschmidt8 maybe we should set it in a folder that we know is not read-only by default?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

5 participants