I recently installed nextcloud on my ubuntu 18.04 server. Now I’m dealing with proper configuration - also http-access to prevent remote access to the /data directory.
The problem occurs when I enable the htaccess-files by chaning the directory rule in the apache.conf file to
<Directory /var/www/>
..
AllowOverride all
..
</Directory>
The apache will send the http-errorcode 500 “internal server error”.
I consider the problem to be part of the trusted domains (cloud.mydomain.tld) and the domain rewrite rule (config.php). The domain cloud.mydomain.tld won’t let me access the folder /var/www/html/nextcloud/data/username
, but git.mydomain.ttl does.
My question: How to setup the cloud that none can access the /var/www/html/nextcloud/data/username
folders?