azuressl-certificategatewayazure-application-gateway

Azure application gateway front of azure web app end-to-end SSL gets 404


I am trying to put a WAF in front of an Azure web app (no ASE). The web app is running with HTTPS (SSL *.azurewebsites.net). I have followed the instructions from this MS document:

https://learn.microsoft.com/en-us/azure/application-gateway/application-gateway-end-to-end-ssl-powershell

Everything went pretty well with my powershell. No probs!

The backend pool is pointing to the correct web app domain ( myapp.azurewebsites.net). And I can see the backend health check is shown as HEALTHY!

I also wonder, in portal when I see the probe blade, the hostname is empty. Which might be intentional as I passed -PickHostNameFromBackendHttpSettings switch while creating the probe. Just wanted to give more context.

However, if I try to access the site via App Gateway's Public IP, I receive error 404 - page not found.

Can anybody help me find the problem, please?


Solution

  • I’m not 100% sure, but I kind of guess the issue now. What I’ve done is, manually created only the front end listeners and it started working. Then I guessed, the culprit might be the certificate. The I created the script again with ARM template with the same certificate and it all worked. I guess something went wrong first time with power shell uploading the pfx file. It’s pity that the error code was kind of misleading, took sometime to figure out where to look.

    Thanks for your kind assistance! Cheers.