acs-engine-terraform
acs-engine-terraform copied to clipboard
Error Private IP Address Is Allocated
All goes well until:
"error": { "code": "PrivateIPAddressIsAllocated", "message": "IP configuration /subscriptions/aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee/resourceGroups/k8sexample/providers/Microsoft.Network/networkInterfaces/k8s-master-12345678-nic-0/ipConfigurations/ipconfig1 is using the private IP address 172.20.10.10 which is already allocated to resource /subscriptions/aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee/resourceGroups/k8sexample/providers/Microsoft.Network/networkInterfaces/k8s-agentpool1-12345678-nic-0.",
I seemed to get pass that by:
- Using a /22 or larger subnet
- Setting the parameter for "firstConsecutiveStaticIP" somewhere in the middle of the subnet range
first_master_ip = "${cidrhost(var.cluster_subnet, 250)}" // Take the subnet and replace the 4th octet with a 250.
- Using the "vnetCidr" parameter within MasterProfile
"masterProfile": { "count": ${master_node_count}, "dnsPrefix": "${cluster_name}", "vmSize": "${vm_type}", "vnetCidr": "${vnet_cidr}", "firstConsecutiveStaticIP": "${first_master_ip}", "storageProfile": "ManagedDisks" },