https://rancher.com/ logo
Title
c

crooked-scooter-58172

08/11/2022, 6:29 PM
Team: We need to assign static IP address to Harvester's VM using API? Is this possible? if yes than can you please share the steps?
w

witty-jelly-95845

08/11/2022, 7:17 PM
Do you mean the VMs running on the nodes within a Harvester cluster or the Harvester nodes themselves?
c

crooked-scooter-58172

08/11/2022, 7:18 PM
VMs running on the nodes within a Harvester cluster
w

witty-jelly-95845

08/11/2022, 7:24 PM
So Harvester expects to hand out IP addresses to VMs using DHCP - you don't specifically configure a VM with a fixed IP (though depending on your DHCP server you can fake that by configuring a fixed MAC address)
It's also possible to configure a static IP via cloud-init Network Data
c

crooked-scooter-58172

08/11/2022, 7:26 PM
Actually I am planning to setup specific VLAN/Subnet for each VM for isolation. Is there anyway I can assign static IP to the VLAN and attach that VLAN to creatVM call?
Using static ipam or something similar
w

witty-jelly-95845

08/12/2022, 8:38 AM
Sorry not tried this so don't know
c

crooked-scooter-58172

09/06/2022, 2:17 PM
I have implemented a solution and it is working fine. Thanks for your consideration