I'm using Azure App Services Authentication/Authorization to restrict access to my web app, using Azure Active Directory as sign in method.
I've set the "Action to take when request is not authenticated" to "Log in with Azure Active Directory".
In order to find details about the logged in user, I make a request to the /.auth/me endpoint (as instructions from Microsoft docs says). This works fine, until the app is restarted in Azure. After restart, the /.auth/me/ endpoint returns an empty array, instead of the user information.
I can only reproduce the problem if the App service plan is running Linux. If I create a Windows App Service Plan, the /.auth/me endpoint is populated even after restart.
I've tried creating a new app on Azure, without uploading any code, and the problem is still there.
Do I need to set some extra settings in order for this to work on a Linux based ASP? I've tested with both docker based ASPs and code based (on dotnet core 2.2).