-
Notifications
You must be signed in to change notification settings - Fork 208
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
ci, make: allow to build release as root user #1242
Conversation
In local environments we usually want to keep the current behavior (i.e. release artifacts owned by the uid/gid of the user invoking `make release`). However in GitHub actions, the command recently started failing with: addgroup: gid '123' in use (see https://github.com/cilium/cilium-cli/actions/runs/3572725726/jobs/6006032172) In GitHub actions, the ownership of the release artifacts shouldn't matter since they're ephemeral anyway. We can now use the following command in the release action: RELEASE_UID=0 RELEASE_GID=0 RELEASER_USER= RELEASER_GROUP= make Signed-off-by: Tobias Klauser <[email protected]>
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.
In the past, we've had problems with the release artifacts owned by root, so they couldn't be deleted anymore without sudo. But maybe that only applies to local-release
which does a rm
on them?
I think this only applies to |
Yes, I just double checked as well, the problem only exists if the user changes between the first and second call to However, I don't fully understand how building as root is not triggering the protection against CVE-2022-24765, which was the whole reason we added the release user in the first place 🤔 |
Ah! I guess because you added |
Yeah, that's the downside to it 😞 I couldn't find another way unfortunately. |
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.
Alternative solution: cilium/hubble#821
Nice, thanks! TIL about |
Addressed in #1244 |
In local environments we usually want to keep the current behavior (i.e. release artifacts owned by the uid/gid of the user invoking
make release
). However in GitHub actions, the command recently started failing with:(see https://github.com/cilium/cilium-cli/actions/runs/3572725726/jobs/6006032172)
In GitHub actions, the ownership of the release artifacts shouldn't matter since they're ephemeral anyway. We can now use the following command in the release action: