After upgrading to Next CloudHub version 8 (29.0.1), I get an error:
The data directory and files may be accessible from the Internet. The “.htaccess” file does not work. It is strongly recommended to configure the web server so that the data directory is not accessible from the external network, or to move the data directory outside the root directory of the web server
My data is here: /var/www/nextcloud-data
When transferring them to the /var/nextcloud-data directory and updating the path in the file config.php I’m getting an error:
The data directory is set incorrectly. Make sure that there is a file in the root of the data directory. “ocdata”. The data catalog is not writable.
Although I have assigned recording rights: chown www-data:www-data -R /var/nextcloud-data
I have read these recommendations, but they are about configuring based on the Apache web server. I use the Nginx web server, and these recommendations do not suit me.
v29 runs these tests from the server-side rather than the client. If you weren’t getting this warning before, there’s a high probability the underlying cause is related to a somewhat different config matter in your environment that wasn’t visible before. Specifically:
The check runs tests against each of your configured trusted_domains and your overwrite.cli.url. It’s important that each of these domains:
is valid
are resolvable in DNS on your server (or from inside your container, if using Docker)
go to the same place on your server as they do externally
I’m coming to the conclusion that this is a bug of the 29th version. It was not fixed in 29.0.1 either. Moreover, in a clean installation, it does not play, and when updating an existing instance of NextCloud, it plays. Comparing configs did not add understanding.
As I said, your original warning was likely due to a change in the setup checks in v28+. You did not fill out the original support template so it’s challenging to provide further help.
If you’re using containers, confirm DNS resolution for your trusted_domains in the container are the same as when outside the container. That’s >50% of the cause across the environments I’ve seen.