Forum Discussion
kidka
Feb 24, 2023Copper Contributor
Container instances
Hi, what I can do to prevent changing private IP for Container instance? Currently I have it connected to Function app and when Ip change, there is disconnection. Or am I able to monitor it with alerts and afterwards I will change it manually in the Func. App?
1 Reply
You may use a Static Private IP via Virtual Network (VNet)
To prevent IP changes, deploy your container instance into a VNet with a delegated subnet:
1. Create a VNet and a subnet delegated to Microsoft.ContainerInstance/containerGroups. .
2. Deploy your container with the --subnet parameter (via CLI or ARM/Bicep).
3. Assign a static private IP within that subnet.