-
Notifications
You must be signed in to change notification settings - Fork 3.4k
workflows: add RUN_AS_ROOT to build-go-caches workflow #39763
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
Conversation
/test |
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.
🙏
c8e1f8d
to
44fe0d7
Compare
44fe0d7
to
814fec0
Compare
Pull request was converted to draft
6c99347
to
50bd8b1
Compare
Since we reverse the default for running builder as root we should have also set the correct value of the env variable in the build-go-caches workflow as otherwise the builder does not create the golang cache in the right directory. Fixes: 9324f9a ("contrib: Reverse default for running builder as root") Signed-off-by: André Martins <andre@cilium.io>
50bd8b1
to
18efa4d
Compare
/test |
|
@joestringer I'm not sure I follow, the tests workflows were not changed. This workflow is only used to generate the golang caches which there's a step further down in the workflow to revert the owner from root. |
Now I'm confused 😅 The GitHub workflow before this PR:
which then invokes
...
...
...
So even if the script runs as non-root, I would expect it to respect the specified environment variables and place the relevant files under |
One slightly fishy thing above is that the EDIT: Well, there's an answer:
(Note that my username on my host is not |
I guess the question I have is, why do we need to run this build as root? I don't see a reason, other than maybe it aligns some directory paths in a better way. But then which directory path is supposed to be different? Maybe we can just fix the directory path or something? |
Here's my counter-proposal:
|
@joestringer I also tried that before but it doesn't work 😅 . It doesn't work because |
Since we reverse the default for running builder as root we should have
also set the correct value of the env variable in the build-go-caches
workflow as otherwise the builder does not create the golang cache in
the right directory.
Fixes: 9324f9a ("contrib: Reverse default for running builder as root")