Comment 1 for bug 1846457

Revision history for this message
Vern Hart (vern) wrote : Re: [2.6] Composing a VM with an IP address on its interface is in Auto Assign state after commissioning

I tried this on maas 2.6.2 and verified that the node commissions with the given static ip, the mode is auto and the ip goes away after it finishes commissioning.

ubuntu@OrangeBox100:~$ maas admin pod compose 13 hostname=vern1 cores=1 memory=1024 storage=5 interfaces="eth0:space=undefined,ip=172.27.100.100,mode=static"
Success.
Machine-readable output follows:
{
    "system_id": "73a8gy",
    "resource_uri": "/MAAS/api/2.0/machines/73a8gy/"
}
ubuntu@OrangeBox100:~$ systemid=73a8gy
ubuntu@OrangeBox100:~$ maas admin machine read $systemid | jq '{"status": .status_name, "boot_interface": .boot_interface.links[0] | {"mode": .mode, "ip_address": .ip_address}}'
{
  "status": "Commissioning",
  "boot_interface": {
    "mode": "auto",
    "ip_address": "172.27.100.100"
  }
}
ubuntu@OrangeBox100:~$ maas admin machine read $systemid | jq '{"status": .status_name, "boot_interface": .boot_interface.links[0] | {"mode": .mode, "ip_address": .ip_address}}'
{
  "status": "Ready",
  "boot_interface": {
    "mode": "auto",
    "ip_address": null
  }
}
ubuntu@OrangeBox100:~$ maas admin version read
Success.
Machine-readable output follows:
{"capabilities": ["networks-management", "static-ipaddresses", "ipv6-deployment-ubuntu", "devices-management", "storage-deployment-ubuntu", "network-deployment-ubuntu", "bridging-interface-ubuntu", "bridging-automatic-ubuntu", "authenticate-api"], "version": "2.6.2", "subversion": "7841-ga10625be3-0ubuntu1~19.10.1"}