resource pools: add resource pool cli commands

Add commands for creating, modifying, listing, and deleting resource
pools.

Signed-off-by: Dylan Whyte <d.whyte@proxmox.com>
This commit is contained in:
Dylan Whyte 2021-01-29 08:54:39 +01:00 committed by Thomas Lamprecht
parent b89cd20528
commit 42ade84744

View File

@ -10,6 +10,7 @@ use PVE::API2::Group;
use PVE::API2::Role; use PVE::API2::Role;
use PVE::API2::ACL; use PVE::API2::ACL;
use PVE::API2::AccessControl; use PVE::API2::AccessControl;
use PVE::API2::Pool;
use PVE::API2::Domains; use PVE::API2::Domains;
use PVE::CLIFormatter; use PVE::CLIFormatter;
use PVE::CLIHandler; use PVE::CLIHandler;
@ -145,7 +146,12 @@ our $cmddef = {
delete => [ 'PVE::API2::ACL', 'update_acl', ['path'], { delete => 1 }], delete => [ 'PVE::API2::ACL', 'update_acl', ['path'], { delete => 1 }],
list => [ 'PVE::API2::ACL', 'read_acl', [], {}, $print_api_result, $PVE::RESTHandler::standard_output_options], list => [ 'PVE::API2::ACL', 'read_acl', [], {}, $print_api_result, $PVE::RESTHandler::standard_output_options],
}, },
pool => {
add => [ 'PVE::API2::Pool', 'create_pool', ['poolid'] ],
modify => [ 'PVE::API2::Pool', 'update_pool', ['poolid'] ],
delete => [ 'PVE::API2::Pool', 'delete_pool', ['poolid'] ],
list => [ 'PVE::API2::Pool', 'index', [], {}, $print_api_result, $PVE::RESTHandler::standard_output_options],
},
realm => { realm => {
add => [ 'PVE::API2::Domains', 'create', ['realm'] ], add => [ 'PVE::API2::Domains', 'create', ['realm'] ],
modify => [ 'PVE::API2::Domains', 'update', ['realm'] ], modify => [ 'PVE::API2::Domains', 'update', ['realm'] ],