1

I have an existing ACI. Can I add it to a VNET and Subnet via Azure CLI/Azure cloud shell.

Radix
  • 2,527
  • 1
  • 19
  • 43
Jay chuks
  • 389
  • 1
  • 5
  • 18

1 Answers1

0

Unfortunately, this isn't possible right now from the CLI, the az container commands don't support patching / upgrading an existing container instance or container group for the network profile property

https://learn.microsoft.com/en-us/azure/container-instances/container-instances-update#properties-that-require-container-delete

If you are interested in not loosing the traffic going to your existing ACI, you should deploy a new ACI to a private VNET/Subnet and front both your containers using an applicationGW or Load Balancer on your new VNET/Subnet.

Once ready to make the move you should be direct all traffic to your ACI running in the VNET.

djsly
  • 1,522
  • 11
  • 13