fix: register details in pve ipam db for add_next_freeip

Signed-off-by: lou lecrivain <lou.lecrivain@wdz.de>
Tested-by: Stefan Hanreich <s.hanreich@proxmox.com>
Reviewed-by: Stefan Hanreich <s.hanreich@proxmox.com>
Tested-by: Hannes Duerr <h.duerr@proxmox.com>
Link: https://lore.proxmox.com/mailman.187.1734119229.332.pve-devel@lists.proxmox.com
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
This commit is contained in:
Lou Lecrivain 2024-12-13 20:45:39 +01:00 committed by Thomas Lamprecht
parent 8794d57125
commit 5a050f4d4c

View file

@ -201,7 +201,11 @@ sub add_next_freeip {
die "can't find free ip in subnet '$cidr'\n" if !$freeip; die "can't find free ip in subnet '$cidr'\n" if !$freeip;
$dbsubnet->{ips}->{$freeip} = {}; $dbsubnet->{ips}->{$freeip} = {
mac => $mac,
hostname => $hostname,
vmid => $vmid
};
write_db($db); write_db($db);
}); });