Today we pushed a .net 7 web app to Azure and suddenly everything crashed:
HTTP Error 500.31 - ANCM Failed to Find Native Dependencies
Common solutions to this issue:
The specified version of Microsoft.NetCore.App or Microsoft.AspNetCore.App was not found.
Troubleshooting steps:
Check the system event log for error messages
Enable logging the application process' stdout messages
Attach a debugger to the application process and inspect
We had to republish as self contained (+ had to change the publish settings from 32bit to 64bit (also in the App service general configuration)).
Now, with self contained, it seems to work.
No idea why it never happened before. Yesterday we published and everything was working. Today just a css update, and the resulting HTTP 500.31 error.
After searching I found a SO thread where an update in the Extensions (App Service > Development Tools) was causing the 500.31 error, but in our case it didn't solve it.
When we did dotnet --info
via the Azure console of the app service we saw that Microsoft.NetCore.Appcore / Microsoft.AspNetCore.App 7.0.2 was installed and .net sdk 7.0.102.
However when viewing our projectname.runtimeconfig.json
via App Service Editor it was set to "version": "7.0.5"
What does this mean regarding the installed .net (sdk) versions?
Does Microsoft update/deploy only specific versions of .net / .net sdk's to Azure App Services? (If so, is there a list of the updates/supported versions and when they update?)
Or do we manually need to install new .net / .net sdk for an App Service in Azure using the version specific dotnet-install scripts ?