Using NFS as backend to nextcloud

zis8snbt4p

Dabbler
Joined
Nov 15, 2020
Messages
35
Hi,

I am running nextcloud on a container and I want to persist 3 folders (/var/www/html/data`, `/var/www/html/config` and `/var/www/html/custom_apps`) into my TrueNAS backend. I have decided to use the NFS protocol to share the folders.
Now nextcloud seems to be using a user `www-data:root` to access its data.
What is a good/the best way to configure the user permissions in the NFS share and in the folders.

Is it enough to:
1. Create a user with the same uid as `www-data`. (Find it from /etc/passwd)
2. `www-data` user chown's the 3 folders that will be exported to (`/var/www/html/data`, `/var/www/html/config` and `/var/www/html/custom_apps`
3. mapall users to `www-data`.
4. Only authorize the container to access the folder by assigning a static IP to the nextcloud container.
 
Top