2

I have an Azure Web App (WebAppLinux) running an Angular application. The deployment is based on the Azure WebApp@1 task in an Azure pipeline.

Everything was fine until today. Without anyone having done a deployment, the website only shows an index page with the files stored in the home directory.

A re-deployment through the CI/CD pipeline is still successful. However, the error remains.

Was there any change to the Azure App Service that made my application incompatible?

User21033
  • 33
  • 2
barracuda317
  • 608
  • 7
  • 24

2 Answers2

4

The answer of LuisDev99 in https://stackoverflow.com/a/61707805/3809334 has solved the problem.

We had to add

pm2 serve /home/site/wwwroot --no-daemon --spa

to the Startup Command under Configuration, select the tab -> General Settings

In the past we had a startup script that called npx serve -s within our Angular application.

It seems that this way did not work anymore over the weekend. Maybe because there was a configuration change in the WebApp by Microsoft

barracuda317
  • 608
  • 7
  • 24
  • We had the same problem. We switched to an azure storage account to serve the static files. – Mischa Aug 31 '20 at 18:21
  • This also worked for us, but this cannot be a long term solution imho, since web.config is now also being ignored, and we configured all our CSP headers inside web.config – EimerReis Sep 03 '20 at 08:01
  • this works, but same as @EimerReis we also put our custom headers in `web.config`. do you have any suggestions how can Linux App Service read the `web.config` specially the customer headers? – klaydze Sep 06 '21 at 12:47
0

Not an answer, but if you file an issue in https://github.com/Azure-App-Service/Linux/issues, that will help proceed with the next steps for investigation.