Raghu Reddy
Raghu Reddy

Reputation: 682

Runtime whitelist APIM IP on function App using ARM

We are provisioning APIM service first(apim.json), Post which we provision multiple function App. All the ARM templates are separate with their respective parameter file. We are using Azure Pipelines for CI/CD.

We have an requirement of applying Access restriction on Function Apps. We want to add Access Restriction using ARM templates.

How can we get VIP of APIM on run time so that we can white list VIP of APIM in access restriction section of Function app. All the pipeline are separate for each function app and APIM

Using API and get the value on runtime(Powershell) is one of the option. But we want to handle it using ARM templates.

Any inputs would be highly appreciated.

Upvotes: 1

Views: 512

Answers (2)

Raghu Reddy
Raghu Reddy

Reputation: 682

Used the following to whitelist at runtime. "ipAddress": "[concat(reference(resourceId('Microsoft.ApiManagement/service', parameters('apimName')),'2019-01-01').publicIPAddresses[0], '/32')]"

Upvotes: 1

Related Questions