Search code examples
azureazure-web-app-serviceazure-application-gateway

Azure Application gateway with web apps


I have setup an Azure Application Gateway in front of an Azure Web Application. I have added IP restriction on Web app to allow access only from the Application gateway's public IP address. This works fine but when I type the public IP address in the browser, it re-directs to the web app's URL. How can I stop the application gateway redirecting to the web app URL but to return the response against the public IP?


Solution

  • It turns out that you first need to configure the custom domain to the webapp and once the propagation happens the CNAME record of the custom domain should be changed to map the FQDN of the Application gateway.