1
votes

Ive created a webapp and have added an ip restriction so that it can only be accessed via the azure application gateway.

In the Application Gateway I navigated to BackEnd Pools, clicked ADD and copied the web app URL eg https://mywebapp.azurewebsites.net, it complained it only wanted FQDN so i removed the https:// and entered in mywebapp.azurewebsites.net

I then navigated to my Application Gateway and copied the public IP address of the gateway and entered it in my browser to test the app but it wont see the web app , I get the error"This site can’t be reached"

Have I missed a step , is the FQDN incorrect? Do I need to use a custom Domain?

1
Do you have enabled health probe or can you display any screenshots?Nancy Xiong
I havent enabled any heath probes as havent got to that bit yet? Can you advise?itye1970
Where have you added the ip restriction in web app ?Avanish
i went to the webapp , then clicked networking and then ip restrictions Clicked configure IP Restrictions Clicked Add Rule Entered a name eg- appgateway-allow Entered the Subnet Address of the APP Gateway IP Address left on V4 Clicked Allow Priority - wasnt sure on this so put in 100itye1970

1 Answers

0
votes

One of the things I would look for is if a listener and a rule has been created. This is required to enable the application gateway to route traffic appropriately to the backend pool.

More info here - https://docs.microsoft.com/en-us/azure/application-gateway/application-gateway-web-app-powershell

I tried adding an existing app service web app to the backend pool like you mentioned and realized that it was not adding the listener/rule for it. When i used the powershell script as mentioned in the link above which creates a listener and a rule , i was able to successfully hit backend pool website when i browsed using the Application Gateway public ip/dns.

https://docs.microsoft.com/en-us/azure/application-gateway/application-gateway-create-gateway-arm