Server call failed for getting current user

I get some weird login issues in the backoffice, on my iis site when its hosted, but not locally.
After refreshing the backoffice i get two pink errors with this message:
Server error: Contact administrator, see log for full details.
Server call failed for getting current user
background is white

Cant log back out either, have to remove cookies. After I remove cookies I can try log in again, but then it says login failed (even with the correct credentials).

If I log in with the wrong password, then re-try with the correct password, I get logged in. Some times I get an error after logging in, sometimes not, but I can see the interface, and it works. If I refresh i get the errors I mentioned.
No errors in log, even though it says to look in the log.

Version used is 11.2.0. I have Vendr installed, other than that its just standard Umbraco.

Im thinking it could be permissions or something on the iis site that causes it, since it works perfectly on localhost. We have looked at this, and made these changes: File And Folder Permissions | Umbraco CMS but that did not help.

This is our first umbraco site so any pointers are welcome

edit: the site is pushed by an azure pipeline, it might be some of the commands that are wrong, or the way its built. will look further into this

edit2: Created a fresh project, still gives us problems.
The first user created for this project now has a successful login every time, but the other manually added user does not work.
If this user gets a successful login, which is does when it has the UMB-XSRF-V-cookie, GetCurrentUser gives a 502 bad gateway (nginx).
This cookie somehow gets removed, or it seems like that, and then it will log user out. Repeated logins will now not work, unless we do a failed login attempt with wrong password, which in turn gives us this cookie, and now we can login successfull again. But alas, backoffice will not work since we somehow lose this cookie, or gets logged out for some reason

edit3:
using localhost on the server works every time, might be something with nginx then, the search continues


This is a companion discussion topic for the original entry at https://our.umbraco.com/forum/111570-server-call-failed-for-getting-current-user