Fixed and Reserved Outbound IP for App Service

714 Views Asked by At

I have an azure web app that has 2 slots (one for production and one for staging). My web app calls an external web service that is protected via IP filtering. When I'm in production, I call the external web service for production and when I'm in staging I call the external web service for staging.

Because I switch from staging to production my 2 outbound IP adresses change regularly. So the external web service cannot protect independently staging and production.

Can the App Service Environnement can help me? Or another Azure service?

Thanks.

1

There are 1 best solutions below

0
On

It seems, you're out of luck here. According to Microsoft Azure documentation:

Can I use a reserved IP for all Azure services?

Reserved IPs can only be used for VMs and cloud service instance roles exposed through a VIP.

So, no reserved IPs for Azure App Services, but only for VMs and Cloud Services.

But there might be some solutions possible:

  • replace IP filtering with Azure subdomain filtering, such as my-app-prod.azurewebsites.net, my-app-staging.azurewebsites.net (or buy a domain name and set its subdomain records to point to Azure App Service slot subdomains and use them instead of Azure's)
  • migrate your environment to Azure Cloud Services or VMs and then set up Azure Virtual Network with reserved IP addresses.