Search code examples
azurevnetazure-hybrid-connections

How to access on-prem resource from an App Service through Express Route?


I have an app service in Azure (not in ASE App Service Env). It is integrated with a vnet.

And I have an API on-premises that this app must access by its internal on-prem DNS name.

And there is an Express Route between Azure and on-prem location.

How to access the on-prem API by its DNS name through an Express Route?

How to configure network connectivity?

How to resolve on-premises names in Azure?


Solution

  • There are different ways of achieving that, depending on your set-up.

    You might need to use:

    App Service

    For App Services you must use Regional VNet integration.

    If you need all traffic from the App Service to be routed via the Vnet, you must specify in the app service the setting WEBSITE_VNET_ROUTE_ALL = 1

    https://learn.microsoft.com/en-us/azure/app-service/web-sites-integrate-with-vnet#regional-vnet-integration

    DNS

    https://learn.microsoft.com/en-us/azure/virtual-network/virtual-networks-name-resolution-for-vms-and-role-instances

    Troubleshoot DNS in App Service

    https://learn.microsoft.com/en-us/azure/app-service/web-sites-integrate-with-vnet#troubleshooting

    Configure Peering

    https://learn.microsoft.com/en-us/azure/expressroute/expressroute-howto-routing-portal-resource-manager

    Route tables for VNets (not always necesary)

    https://learn.microsoft.com/en-us/azure/virtual-network/manage-route-table