]> git.proxmox.com Git - pve-network.git/commitdiff
controllers: evpn : correctly limit the number of controllers to max 1
authorAlexandre Derumier <aderumier@odiso.com>
Tue, 27 Dec 2022 07:17:19 +0000 (08:17 +0100)
committerThomas Lamprecht <t.lamprecht@proxmox.com>
Fri, 30 Dec 2022 14:36:57 +0000 (15:36 +0100)
Signed-off-by: Alexandre Derumier <aderumier@odiso.com>
PVE/Network/SDN/Controllers/EvpnPlugin.pm

index 74ec0187ee310ca24acc092b9b690c0f6e1dbfbd..d09f2a9e6c3179f6c9c7e1fe655cec340d76ec50 100644 (file)
@@ -271,7 +271,7 @@ sub on_update_hook {
        my $controller = $controller_cfg->{ids}->{$id};
        next if $controller->{type} ne "evpn";
        $controllernb++;
-       die "only 1 global evpn controller can be defined" if $controllernb > 1;
+       die "only 1 global evpn controller can be defined" if $controllernb >= 1;
     }
 }