This is a collection of notes found useful when debugging cloud applications.
Deployment Failed?
Template deployment failed - you got the error like below.
New-AzureRmResourceGroupDeployment : 1:48:59 PM - Error: Code=InvalidTemplateDeployment; Message=The template
deployment 'xxx' is not valid according to the validation procedure. The tracking id is 'xxxx-6e033d9c100c'
Yet "Deployments" blade in resource groups does not show any failed deployments.
Go to Monitor - Activity log in Azure portal and check for "Validate Deployment" activities
At the bottom of JSON you should see the actual error that caused the template validation to fail.
Asked HTTP got HTTPS?
If you testing HTTP access to site and see HTTP with 307 redirect and HTTPs response, check if HSTS can be an issue. To remove site for example in Google Chrome for to chrome://net-internals/#hsts ad remove the site. E.g.
Trace Redirects
wget http://your-url 2>&1 | grep Location:
curl -v -L http://your-url
Debug Azure Function Proxies
If youir proxy returns error (e.g. 50x HTTP response) then turn on debug and examine the logs the cause and solution can become clear. Microsoft documentation
For example:
we go to App Service Kudu - D:\home\LogFiles\Application\Proxies\DetailedTrace
and check the logfile
Download and review the logfile. The error cause becomes immediately clear - untrusted certificated is used in development environment
Comments