问题
I have multiple App Services inside my App Service Environment. Lets call them A, B and C.
I also have a Azure Api Management inside the same VNet where the App Service Environment is located.
What I need is to let Api Management reach A, B and C. I also need to have communication between App Service A and B.
Can this be done without using own DNS server? If so, how?
回答1:
You should be able to use the FQDN of each app, a.asebaseurl, b.asebaseurl, etc. If you are going through another device like an app gateway you will need to ensure you pass the host header.
Services such as Azure App service web apps and Azure API management that are multi-tenant in nature and rely on a specific host header or SNI extension to resolve to the correct endpoint. Usually, the DNS name of the application, which in turn is the DNS name associated with the application gateway, is different from the domain name of the backend service. Therefore, the host header in the original request received by the application gateway is not the same as the host name of the backend service. Because of this, unless the host header in the request from the application gateway to the backend is changed to the host name of the backend service, the multi-tenant backends are not able to resolve the request to the correct endpoint.
https://docs.microsoft.com/en-us/azure/application-gateway/application-gateway-web-app-overview
来源:https://stackoverflow.com/questions/55723883/when-using-app-service-environment-do-i-need-own-dns-server-to-communicate-from