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

DO NOT MERGE (yet) - Fix gnupg/rpm/deb containers #427

Closed
wants to merge 8 commits into from

Conversation

chevdor
Copy link
Contributor

@chevdor chevdor commented Jun 2, 2022

  • rename nonroot as user
  • fix acl: some of the files were not owned by the nonroot user
  • add gpg2 symlink (required)

From the readme:

Used as base for tooling that requires gnupg. GPG usually requires working with the gpg-agent.
Using the gpg-agent in a rootless context can be challenging as you will need to align the UID
in the container with the UIDs of your local system.

While we could make an image with UID that could be passed as ARG, this will likely always endup
being the wrong UID. For this reason, this image is creating the users at runtime.
By default, the UID is 1000 but you may customize it using the LOCAL_USER_ID environment variable.
This will allow downstream images such as paritytech/rpm and paritytech/deb to be ran with the "right"
UID and allows mapping the gpg-agent socket for the right UID.

This PR fixes the rootless rpm container calls as long as called like:

podman run  --rm -it \
   -v "/run/user/$(id -u)/gnupg/S.gpg-agent:/home/user/.gnupg/S.gpg-agent" \
   -v "$PWD/polkadot-0.9.23-1.x86_64.rpm:/home/user/polkadot-0.9.23-1.x86_64.rpm" \
   -v "$HOME/.gnupg/pubring.kbx:/home/user/.gnupg/pubring.kbx" \
    chevdor/rpm  \
   "rpm --addsign polkadot-0.9.23-1.x86_64.rpm"

@chevdor chevdor changed the title Fix rpm container Fix gnupg/rpm containers Jun 2, 2022
@chevdor chevdor marked this pull request as ready for review June 2, 2022 19:37
@chevdor chevdor changed the title Fix gnupg/rpm containers DO NOT MERGE (yet) - Fix gnupg/rpm containers Jun 3, 2022
@chevdor
Copy link
Contributor Author

chevdor commented Jan 20, 2023

The RPM part can be dropped once paritytech/polkadot#6595 is merged

@rcny rcny marked this pull request as draft May 18, 2023 20:12
@chevdor chevdor changed the title DO NOT MERGE (yet) - Fix gnupg/rpm containers DO NOT MERGE (yet) - Fix gnupg/rpm/deb containers Jul 28, 2023
@chevdor
Copy link
Contributor Author

chevdor commented Jul 28, 2023

We no longer support RPM so those changes and the rpm container could be dropped but the other chanegs may still be relevant.

@rcny rcny closed this Apr 8, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants