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

Add the ability to specify peertube UID and GID via environment variables #6809

Merged
merged 1 commit into from
Jan 14, 2025

Conversation

zbirkenbuel
Copy link
Contributor

@zbirkenbuel zbirkenbuel commented Jan 4, 2025

Description

This adds support for specifying the peertube user and group IDs using the standard environment variable pattern similar to linuxserver.io images. This allows for better external permission management, specifically this makes it easier to support mapping volumes to NFS shares using nfs4 id mapping.

This changes elects not to use the linuxserver.io variable names of PUID and PGID since the peertube container ends up having both a "node" and "peertube" user created and it would not be obvious which of those PUID/PGID should apply to.

New variables are PEERTUBE_UID and PEERTUBE_GID respectively.

Related issues

Existing feature request that was closed due to inactivity

Has this been tested?

  • 👍 yes, I added tests to the test suite
  • 💭 no, because this PR is a draft and still needs work
  • 🙅 no, because this PR does not update server code
  • 🙋 no, because I need help

…bles

This adds support for specifying the peertube user and group IDs using the standard environment variable pattern similar to linuxserver.io images.  This allows for better external permission management, specifically this makes it easier to support mapping volumes to NFS shares using nfs4 id mapping.

This changes elects *not* to use the linuxserver.io variable names of PUID and PGID since the peertube container ends up having both a "node" and "peertube" user created and it would not be obvious which of those PUID/PGID should apply to.
@zbirkenbuel
Copy link
Contributor Author

Just commenting that the suggestion to use the --user argument mentioned in #2424 doesn't solve the NFS permission issue since it only changes the user that the container "root" user runs as. Since the container image manually creates a peertube user account that argument is effectively ignored.

@Chocobozzz
Copy link
Owner

Thanks @zbirkenbuel 🙏

Where do you think we should document this feature? docker-compose.yml? Or https://docs.joinpeertube.org/install/docker?

@Chocobozzz Chocobozzz merged commit c31084c into Chocobozzz:develop Jan 14, 2025
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants