]> git.proxmox.com Git - pve-ha-manager.git/commitdiff
cli: assert that node exist when changing CRS request state
authorThomas Lamprecht <t.lamprecht@proxmox.com>
Thu, 6 Apr 2023 12:09:01 +0000 (14:09 +0200)
committerThomas Lamprecht <t.lamprecht@proxmox.com>
Thu, 6 Apr 2023 12:09:01 +0000 (14:09 +0200)
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
src/PVE/CLI/ha_manager.pm

index a0ebe5716467532b1d5895111e8490eafde0acaa..54fbe20eb4ad817147836fbdbae32cb6ef957d4c 100644 (file)
@@ -132,6 +132,8 @@ __PACKAGE__->register_method ({
     code => sub {
        my ($param) = @_;
 
+       PVE::Cluster::check_node_exists($param->{node});
+
        my $cmd = $param->{disable} ? 'disable-node-maintenance' : 'enable-node-maintenance';
        PVE::HA::Config::queue_crm_commands("$cmd $param->{node}");