Redirecting nextcloud URL
-
old nextcloud runs without HAproxy behind a portforwarding (443, SSL/TLS on the box itself) and is reached via:
https://mail.my.tld/nextcloud
new nextcloud is inside a docker container and behind HAproxy (SSL/TLS offloading)
https://cloud.my.tld
The old links should stay valid ... for example calendar links like:
https://mail.my.tld/nextcloud/remote.php/dav/calendars/stefan@my.tld/pers%c3%b6nlich/
should be kept working while also this should work:
https://cloud.my.tld/remote.php/dav/calendars/stefan@my.tld/pers%c3%b6nlich/
Should/could that be solved on the level of HAproxy or should I better write some Rewrite-statements in the target apache?
I assume there are multiple ways to solve that, and I wonder if someone could help me to find the most elegant and reliable solution.