Help with Nextcloud docker installation with NFS hosted data directory

Joined
Dec 28, 2023
Messages
2
Having some fun NFS permissions difficulties with connecting it to my Nextcloud docker container:

I have a TrueNAS server running with a storage pool & NFS share. In the AccessControlList of the storage pool, the user is set as www-data & group of www-data (See attached image). This is a user & a group I have manually created in TrueNAS with a UID & GID of 33. This is to match with the inner user within the Nextcloud docker container that accesses this data.
I then have the Nextcloud docker container running on a separate machine with the NFS share mounted as a volume inside the container at /media/carrotmanmatt_nas_files. The data directory for Nextcloud is then set to this path, so that theoretically my Nextcloud files will be streamed over from the NAS while the local config files are stored in a seperate volume stored on the docker host (See `docker-compose.yaml`). I have then run docker exec --user root nextcloudapp chmod -R 755 /media/carrotmanmatt_nas_files & docker exec --user root nextcloudapp chown -R www-data:www-data /media/carrotmanmatt_nas_files to ensure all files are owned by the nextcloud user.

To be clear I run the Nextcloud Docker container on a seperate host from the NAS using Portainer.

When I then run the Nextcloud container, I can successfully create the first admin user, but then when trying to access the main dashboard it just shows this error:
Code:
Internal Server Error

The server encountered an internal error and was unable to complete your request.
Please contact the server administrator if this error reappears multiple times, please include the technical details below in your report.
More details can be found in the server log.


Any help would be greatly appreciated & feel free to ask questions for more information (I have attached the necessary log files)
 

Attachments

  • TrueNAS ACL.png
    TrueNAS ACL.png
    72.9 KB · Views: 89

mrchip

Cadet
Joined
Jan 25, 2024
Messages
6
Did you ever figure this out? I too am running into problems with using nextcloud in docker and trying to store the files in a truenas dataset.
 
Joined
Dec 28, 2023
Messages
2
Did you ever figure this out? I too am running into problems with using nextcloud in docker and trying to store the files in a truenas dataset.
Yh! turns out I just needed to check the `inherit` permissions check box on the ACL page. This was preventing the www-data user from creating new files even though it owned all the data.

Hope this helps!
 
Top