Since create_vm already calls update_pct_config, which in turn calls
vmconfig_apply_pending we do not need to explicitly create the IPAM
entries when creating a container from scratch.

Signed-off-by: Stefan Hanreich <s.hanre...@proxmox.com>
---
 src/PVE/API2/LXC.pm | 1 -
 1 file changed, 1 deletion(-)

diff --git a/src/PVE/API2/LXC.pm b/src/PVE/API2/LXC.pm
index ee4fdca..dabcc14 100644
--- a/src/PVE/API2/LXC.pm
+++ b/src/PVE/API2/LXC.pm
@@ -479,7 +479,6 @@ __PACKAGE__->register_method({
                        my $lxc_setup = PVE::LXC::Setup->new($conf, $rootdir);
                        $lxc_setup->template_fixup($conf);
                    } else {
-                       PVE::LXC::create_ifaces_ipams_ips($conf, $vmid);
                        my $lxc_setup = PVE::LXC::Setup->new($conf, $rootdir); 
# detect OS
                        PVE::LXC::Config->write_config($vmid, $conf); # safe 
config (after OS detection)
                        $lxc_setup->post_create_hook($password, $ssh_keys);
-- 
2.39.2


_______________________________________________
pve-devel mailing list
pve-devel@lists.proxmox.com
https://lists.proxmox.com/cgi-bin/mailman/listinfo/pve-devel

Reply via email to