问题
I have two web apps (webapp1 and webapp2). I would like to use Application Gateway features where can route using path based redirect. http://mywebsite/login1 redirect to webapp1 http://mywebsite/login2 redirect to webapp2
Is this possible it possible to do this with Application gateway if so can you please give link or direction on how to do this for web apps prespective
回答1:
Yes, it is. You can use path-based routing in the Application Gateway to do the job. Here is the link:
Application Gateway URL Routing
The main idea is that you can use the routing rules to point to a specific backend pool. That backend pool will point to whatever servers you want handling that request.
回答2:
Is this possible it possible to do this with Application gateway
Sure. If you want to do that with Azure WebApp service. But there are two things that we need to do:
1.Make sure that the application root path is the same as you mapped in the Application Gateway. For instance:
if you want route http://mywebsite/login1 -> webapp1 Your webapp1 application root path(home page) should be :http:///login1 You can do quick config at your app service - > Application settings -> Virtual applications and directories:
2.Two custom health prob is needed for Azure web apps , we could use PS script to create them since it seems there is no way to create them on Azure portal.
For more detail information, please refer to this blog.
来源:https://stackoverflow.com/questions/51136636/configuring-azure-application-gateway-to-azure-web-app-to-route-requests-by-path