4

Are there any best practices on continuous deployment to an Azure Container Instance so that it keeps the public IP? Or mapping an Azure Reserved IP to a dynamic IP that the ACI gets bound to at deployment?

1 Answers1

6

Currently, your best bet is to create a DNS A record for the app and remap it to the new IP when you create a new container. However, we are working on enabling you to simply update the container and keep the IP.

Update: You can now request a DNS entry for your ACI container in the Microsoft-managed azurecontainer.io domain using the dns-name-label switch in the az cli. You can keep this DNS stable across updates.

az container create -n helloworld --image microsoft/aci-helloworld /
    -g myResourceGroup --dns-name-label mycontainer
4c74356b41
  • 69,186
  • 6
  • 100
  • 141
Sean McKenna
  • 3,706
  • 19
  • 19
  • Could you post here once that is available on ACI? – Juha Ristolainen Jan 09 '18 at 08:51
  • Sure, will do. The first thing we're going to enable is the ability to create a DNS record in our domain (azurecontainer.io) that can be stable across updates. That should be available in the API in the next month or so. – Sean McKenna Jan 23 '18 at 16:57
  • 2
    This is now available and I have updated my answer above. – Sean McKenna Feb 14 '18 at 05:28
  • 2
    But can I assign a reserved IP to my container? this is a requirements in my case. Can I do this with Azure Function? AKS? – AlexB May 28 '18 at 14:29
  • This is only for dns. Our use case also require direct communication with a static reserved IP address. Is this at all possible with container instances? – jemag Dec 19 '18 at 14:02