Hello! I’m getting an error when trying to upload a profile picture in the latest build of Vikunja.
vikunja-1 | 2025-02-05T23:23:01Z: ERROR ▶ 10f open /app/vikunja/files/1: permission denied
I’ve tried changing around the volumes and the permissions (from using named volumes to using local volumes and everything else I can think of), but I get the same error every single time. At this point, I’m starting to think there’s something broken with file permissions outside of the volume, as I get a similar failed mkdir error when I don’t use a volume and try to upload a PFP. Any ideas on how I can fix this?
Did you change the permissions on the volume?
As explained here: Installing
I have tried that, yes. Right now I’m using a named volume instead of mounting a file path on the host machine, so it’s stored inaccessible to the host machine, but I have tried mounting a file path and changing the permissions. It hasn’t worked. Additionally, the docker image doesn’t seem to have a shell bundled with it, so I can’t enter the instance and change the file path from inside.
However, I really think there’s something wrong with the image itself, as I get a “mkdir” error when I just set it up without mounting anything (named volume or local volume), meaning that permissions are screwed up in some way that’s preventing the instance from accessing anything for write in that directory.
Which permissions did you try?
I’ll look into making this work without host folder mounted.
Apparently, that’s a common issue of the scratch
base image. Since we don’t have linux tools to chown
these directories, we can’t create them beforehand. If we set them as default docker volumes, they will be owned by root
, so if we run Vikunja as 1000
it won’t be able to access the folders.
An obvious solution would be to run the container as root, but then it would not be possible to run it with rootless docker-like daemons like podman.
Happy to take ideas if anyone has a solution here.
Hi, I’ve recently started running a Vikunja instance with podman and have run into this problem too. I don’t use a volume, I just mount a path on the host (with :Z
suffix since I’m on Rocky Linux with SELinux). I run podman as a non-root user created only for this task.
Is it possible to run Vikunja with a specific UID (other than 1000
)? I noticed PUID/PGID environment variables in use in older posts here but don’t see the options in the current docs.
As this is my first post, @kolaente thank you very much for all your work. Vikunja is an excellent tool.
It’s not possible anymore with env variables. The reason here was that it required starting the container as root and then changing the id based on the environment variable, which meant it’s not fully rootless.
Docker has an option to change the run user, not sure if podman has something similar?
Thanks for the clarification 
The solution I settled with in the end was to use the U
/Chowning Volume Mounts
option on the bind mount, which sets the UID of the directory on the host (./files
) to match the UID used in the container. The relevant lines in my docker-compose.yml
are:
volumes:
- ./files:/app/vikunja/files:U,Z