solidnerd/docker-bookstack

Missing permissions when running with rootless podman

stebit opened this issue · 1 comments

When running the container in a rootless podman environment, uploading photos and documents is not possible, as the permissions on /var/www aren't set properly. Bookstack gives the output File path /uploads/images/gallery/2023-02/pic.png could not be uploaded to. Ensure it is writable to the server.'

Other projects solve this by chowning the directories (i.e. Syncthing).

I just tried to add a similar chown command to the docker-entypoint.sh (chown -R www-data:www-data /var/www/bookstack), but this just ends in chown: changing ownership of '/var/www/bookstack/public/uploads': Operation not permitted and the container stopping.

Has anyone figured out how to modify the image to make it work? I have hardly any experience with Dockerfiles and would appreciate any kind of hints.

stfeb commented

Ah, a simple podman unshare chown will do too. Changing anything about the image seems to be unnecessary.