Nextcloud – NAS storage 0770 error

Common Nextcloud first run error. Usually appears after changing the /data location.

In my case, it was when I setup Nextcloud to use my Windows NAS.

The easiest solution is to edit the config.php file on your install server (change the path to reflect your install location).

A) For regular installation:

sudo nano /var/www/nextcloud/config/config.php


B) For Docker

sudo docker exec -it nextcloud /bin/bash
nano /config/www/nextcloud/config/config.php


In here we can add the line

'check_data_directory_permissions' => false,

[ctrl] + [x], then [y] to save, then [enter] to write and close.

This will skip the permission check and allow use of the mounted storage.
Much easier way than dealing with permissions and messing with fstab.

😀