Skip to content

fix: rootless support for Alpine container image#123

Open
slauger wants to merge 2 commits intoOpenVoxProject:mainfrom
slauger:fix/alpine-rootless-chown
Open

fix: rootless support for Alpine container image#123
slauger wants to merge 2 commits intoOpenVoxProject:mainfrom
slauger:fix/alpine-rootless-chown

Conversation

@slauger
Copy link
Copy Markdown
Member

@slauger slauger commented Apr 2, 2026

Summary

  • Patches out FileUtils.chown calls in openvoxserver-ca gem — these fail in rootless containers because the process lacks CAP_CHOWN. The directory ownership is already handled correctly by the g=u / SGID permission pattern.
  • Patches the foreground script to use touch + chmod instead of install --owner --group for the restartcounter file, which also requires CAP_CHOWN.

Both patches are the same approach used in the openvox-operator.

Tested on Linux with podman and bind-mounted CA directory — container starts successfully.

Note: When bind-mounting the CA directory with podman rootless, users need to ensure the directory is writable by the container user, e.g. using the :U volume flag.

Ref: #121

The FileUtils.chown calls in openvoxserver-ca fail in rootless containers
because the process lacks CAP_CHOWN. The directory ownership is already
handled correctly by the g=u / SGID permission pattern.

This is the same approach used in the openvox-operator project.

Ref: OpenVoxProject#121
@slauger slauger requested a review from a team as a code owner April 2, 2026 21:40
The foreground script uses 'install --owner --group' to create the
restartcounter file, which requires CAP_CHOWN. Replace with touch + chmod
which works without elevated capabilities.
@slauger slauger changed the title fix: patch out FileUtils.chown for rootless Alpine containers fix: rootless support for Alpine and Ubuntu container images Apr 2, 2026
@slauger slauger force-pushed the fix/alpine-rootless-chown branch from 2d68854 to 8af527d Compare April 2, 2026 22:28
@slauger slauger changed the title fix: rootless support for Alpine and Ubuntu container images fix: rootless support for Alpine container image Apr 2, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: No status

Development

Successfully merging this pull request may close these issues.

1 participant