]> git.proxmox.com Git - pve-network.git/commitdiff
vnet: rename read_local_vm_config to read_cluster_vm_config
authorAlexandre Derumier <aderumier@odiso.com>
Fri, 3 May 2019 09:00:16 +0000 (11:00 +0200)
committerDietmar Maurer <dietmar@proxmox.com>
Mon, 6 May 2019 05:56:12 +0000 (07:56 +0200)
and remove "next if !$d->{node}"

Signed-off-by: Alexandre Derumier <aderumier@odiso.com>
PVE/Network/Network/VnetPlugin.pm

index a6515af1e5222be3b4afb88e16ef3fbedb02c959..b2080e11222f4a7a52b98bd88bcc972588f11b67 100644 (file)
@@ -84,7 +84,7 @@ sub on_delete_hook {
     my ($class, $networkid, $scfg) = @_;
 
     # verify than no vm or ct have interfaces in this bridge
-    my $vmdata = read_local_vm_config();
+    my $vmdata = read_cluster_vm_config();
 
     foreach my $vmid (sort keys %{$vmdata->{qemu}}) {
        my $conf = $vmdata->{qemu}->{$vmid};
@@ -113,7 +113,7 @@ sub on_update_hook {
 
 }
 
-sub read_local_vm_config {
+sub read_cluster_vm_config {
 
     my $qemu = {};
     my $lxc = {};
@@ -127,7 +127,6 @@ sub read_local_vm_config {
     foreach my $vmid (keys %$ids) {
        next if !$vmid;
        my $d = $ids->{$vmid};
-       next if !$d->{node};
        next if !$d->{type};
        if ($d->{type} eq 'qemu' && $have_qemu_server) {
            my $cfspath = PVE::QemuConfig->cfs_config_path($vmid);