When I create Spaces, VLANs within Spaces, and Subnets within VLANs, using MaaS Web UI, it works!
However, when I try to do the same using MaaS CLI, I can’t achieve the same result.
The problem is that, the subnets that I’m creating, aren’t appearing within the requested VLANs!
So, after running MaaS CLI, I have to go to the MaaS UI and manually add the subnets on their respective VLANS…
So, what I’m doing wrong here:
Creating Spaces (okay):
maas admin spaces create name="mgmt" maas admin spaces create name="infra"
Creating VLANs (also looks ok):
maas admin vlans create 0 space="infra" name="ipmi-1" vid=1000 maas admin vlans create 0 space="infra" name="srvs-1" vid=1001
However, apparently, the next command is accepted but, looks wrong somehow, because when I check the MaaS UI, the subnets aren’t on theirs VLANs:
maas admin subnets create name="IPMI" cidr=172.16.32.0/24 gateway_ip=172.16.32.254 vid=1000 fabric=0 maas admin subnets create name="Servers" cidr=172.16.33.0/24 gateway_ip=172.16.33.254 vid=1001 fabric=0
My playbook to run those commands is here:
BTW, I’m working on my SVAuto thing, to deploy MaaS on top of LXD Containers using Ansible, it’s quite cool! lol
So, every time that I run my Ansible to deploy MaaS, I have to go to its UI to manually fix all the subnets…