canonical / terraform-provider-maas

Terraform MAAS provider
Mozilla Public License 2.0
60 stars 43 forks source link

cannot define the fabric for network interface in `maas_instance` #64

Open pescobar opened 1 year ago

pescobar commented 1 year ago

When configuring network interfaces for maas_instance you can define name, subnet_cidr and ip_address

When configuring network interfaces for vm_host_machine you can define name, fabric, vlan, subnet_cidr and ip_address

Would it be possible to also define fabric for network interfaces in a maas_instance ?

Right now when we deploy a new maas_instance new fabrics with random names are added to MAAS and we need to manually reconfigure the interfaces to attach them to the right fabric and then delete the random fabric. It would be really convenient to be able to define the right fabric during the deployment as you can do for vm_host_machine

pescobar commented 1 year ago

By now we can workaround the issue by using subnet_cidr so the interface is attached to the right fabric and enabling hw_sync for the maas_instance. This way when we reconfigure the network interface the new network settings should be populated to MAAS by the hardware sync functionality (I still have to test this)

JFYI, our use case is that we want to attach a 100Gbps card to a fabric where all the ports are in trunk mode. After we deploy the machine we plan configure multiple vlan interfaces over this 100Gbps card. We want to configure the vlans outside of MAAS so reconfiguring the network doesn't require redeploying the machine. In MAAS we only want to define to which fabric the 100Gbps card is attached. As workaround we use a dummy subnet_cidr which we won't use in production but allows us to attach the network card to the right fabric.

seb54000 commented 3 months ago

Would be nice to also have the availability to provide space (maybe I should raise a new issue/feature request for that ?)