Is it possible to change the owner of a block storage?

I’m running a small application with Apache and I need block storage mounted in /external/data.

The issue is that I need to run Apache with the root user in order to access the mounted folder (instead of the habitual www-data user).

Is it possible to change the user / owner of a block storage?


Going to take a look at it today.
Coming back soon with something :slight_smile:

Hi back @Kmaschta,

We made a release this afternoon and now every file written to the volume will belong to/owned by the group id 1000.
(this one is the default when you create a new user outside of root on debian/ubuntu).

So you can go ahead and re-deploy your app without root, if you create a user in the container like so useradd -u 1000 -U app it will own the files in the volume.

Let me know if I am not clear enough, and you need more explanation.


Thanks, it works fine!

I changed the line a bit because the user was already: usermod -a -G 1000 www-data

1 Like