run a nextcloud instance on mydomain.com. This domain is also used as my matrix-domain. The matrix server itself runs on matrix.mydomain.com
For the federation to work, I have to place a file, that tells clients where to find the right matrix server address for the domain:
/var/www/html/.well-known/matrix/server
Can someone give me a hint, how to modify the apache config, so that this file will always be publicly availabe?
You should ask Matrix themselves about this since it isn’t specific to Nextcloud.
Try their main chat, or search their room listings for other support channels: #matrix:matrix.org
Also, try internet searching for your federation /var/www/html/.well-known/matrix/server issue. Seems it is covered in setup documentation online. Says you must add a srv record to index.html
Try following the documentation directions and confirm you’ve gotten SSL working on your matrix subdomain, then adding the serv record to index.html and then checking whether federation works.
I don’t know matrix, but i would try to create a virtual host pointing with matrix.mydomain.com on port 80 to the file needed. It’s like the vHost you should have created for your nextcloud in /etc/apache2/sites/available.
@JanMrlth
Perhaps you can set a rewrite rule at the beginning to exclude rewrite for your special file.
Please test its with a simple file like “test.html”.