I want to have Nextcloud load balanced on two servers, so I tried to run Nextcloud running behind a haproxy via https. Both backends are working individually. But as soon as I enable both with round-robin, I get a lot of error messages especially in the admin menus (e.g. users, apps, log). Additionally, login doesn’t work on the first try and the files app sometimes reloads after 5 seconds.
When I open the developer view of my browser I see a lot of “HTTP 412” Precondition failed errors and on logout I get a CSRF Error. My guess is that there is some problem with the HTTPS encryption, because I switch servers in between.
Is there any solution for this?