X-Git-Url: https://git.proxmox.com/?a=blobdiff_plain;f=PVE%2FAccessControl.pm;h=44fc0aa924849f11780f427c8d891f26ea975dab;hb=ab7b19b58ce8b73ed67c6fa9e4de2d1413697e75;hp=0fb46b5594848fe81e957d315a87a07fa65f084e;hpb=b7ba86d426abe886de2766bb6d3a5012d38fb36b;p=pve-access-control.git diff --git a/PVE/AccessControl.pm b/PVE/AccessControl.pm index 0fb46b5..44fc0aa 100644 --- a/PVE/AccessControl.pm +++ b/PVE/AccessControl.pm @@ -14,7 +14,7 @@ use PVE::OTP; use PVE::Ticket; use PVE::Tools qw(run_command lock_file file_get_contents split_list safe_print); use PVE::Cluster qw(cfs_register_file cfs_read_file cfs_write_file cfs_lock_file); -use PVE::JSONSchema; +use PVE::JSONSchema qw(register_standard_option get_standard_option); use PVE::Auth::Plugin; use PVE::Auth::AD; @@ -1078,6 +1078,10 @@ sub remove_vm_from_pool { # bash completion helpers +register_standard_option('userid-completed', + get_standard_option('userid', { completion => \&complete_username}), +); + sub complete_username { my $user_cfg = cfs_read_file('user.cfg');