From cf3ed34fa106a82b7d9fc1a3681b43606dd1e780 Mon Sep 17 00:00:00 2001 From: "daniele.corsini@corsinvest.it" Date: Mon, 11 Dec 2023 14:59:00 +0100 Subject: [PATCH] Update 8.1 --- composer.json | 2 +- src/PveClient.php | 3758 +++++++++++++++++++++++++++------------------ 2 files changed, 2260 insertions(+), 1500 deletions(-) diff --git a/composer.json b/composer.json index c38deb5..91100cf 100644 --- a/composer.json +++ b/composer.json @@ -1,7 +1,7 @@ { "name": "corsinvest/cv4pve-api-php", "description": "Corsinvest Proxmox VE Client API PHP", - "version": "8.0.1", + "version": "8.1.0", "keywords": [ "Proxmox", "Proxmox VE", diff --git a/src/PveClient.php b/src/PveClient.php index 5c8359c..68ce577 100644 --- a/src/PveClient.php +++ b/src/PveClient.php @@ -130,7 +130,7 @@ public function getVersion() { /** * Class PVECluster - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVECluster { @@ -172,6 +172,19 @@ public function getMetrics() { return $this->metrics ?: ($this->metrics = new PVEClusterMetrics($this->client)); } + /** + * @ignore + */ + private $notifications; + + /** + * Get ClusterNotifications + * @return PVEClusterNotifications + */ + public function getNotifications() { + return $this->notifications ?: ($this->notifications = new PVEClusterNotifications($this->client)); + } + /** * @ignore */ @@ -391,7 +404,7 @@ public function index() { /** * Class PVEClusterReplication - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEClusterReplication { @@ -440,8 +453,7 @@ public function index() { * @return Result */ public function create($id, $target, $type, $comment = null, $disable = null, $rate = null, $remove_job = null, $schedule = null, $source = null) { - $params = [ - 'id' => $id, + $params = ['id' => $id, 'target' => $target, 'type' => $type, 'comment' => $comment, @@ -449,15 +461,14 @@ public function create($id, $target, $type, $comment = null, $disable = null, $r 'rate' => $rate, 'remove_job' => $remove_job, 'schedule' => $schedule, - 'source' => $source - ]; + 'source' => $source]; return $this->client->create("/cluster/replication", $params); } } /** * Class PVEItemReplicationClusterId - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemReplicationClusterId { @@ -486,10 +497,8 @@ function __construct($client, $id) { * @return Result */ public function delete($force = null, $keep = null) { - $params = [ - 'force' => $force, - 'keep' => $keep - ]; + $params = ['force' => $force, + 'keep' => $keep]; return $this->client->delete("/cluster/replication/{$this->id}", $params); } @@ -505,7 +514,7 @@ public function read() { * Update replication job configuration. * @param string $comment Description. * @param string $delete A list of settings you want to delete. - * @param string $digest Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications. + * @param string $digest Prevent changes if current configuration file has a different digest. This can be used to prevent concurrent modifications. * @param bool $disable Flag to disable/deactivate the entry. * @param float $rate Rate limit in mbps (megabytes per second) as floating point number. * @param string $remove_job Mark the replication job for removal. The job will remove all local replication snapshots. When set to 'full', it also tries to remove replicated volumes on the target. The job then removes itself from the configuration file. @@ -515,23 +524,21 @@ public function read() { * @return Result */ public function update($comment = null, $delete = null, $digest = null, $disable = null, $rate = null, $remove_job = null, $schedule = null, $source = null) { - $params = [ - 'comment' => $comment, + $params = ['comment' => $comment, 'delete' => $delete, 'digest' => $digest, 'disable' => $disable, 'rate' => $rate, 'remove_job' => $remove_job, 'schedule' => $schedule, - 'source' => $source - ]; + 'source' => $source]; return $this->client->set("/cluster/replication/{$this->id}", $params); } } /** * Class PVEClusterMetrics - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEClusterMetrics { @@ -571,7 +578,7 @@ public function index() { /** * Class PVEMetricsClusterServer - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEMetricsClusterServer { @@ -607,7 +614,7 @@ public function serverIndex() { /** * Class PVEItemServerMetricsClusterId - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemServerMetricsClusterId { @@ -638,104 +645,855 @@ public function delete() { } /** - * Read metric server configuration. + * Read metric server configuration. + * @return Result + */ + public function read() { + return $this->client->get("/cluster/metrics/server/{$this->id}"); + } + + /** + * Create a new external metric server config + * @param int $port server network port + * @param string $server server dns name or IP address + * @param string $type Plugin type. + * Enum: graphite,influxdb + * @param string $api_path_prefix An API path prefix inserted between '<host>:<port>/' and '/api2/'. Can be useful if the InfluxDB service runs behind a reverse proxy. + * @param string $bucket The InfluxDB bucket/db. Only necessary when using the http v2 api. + * @param bool $disable Flag to disable the plugin. + * @param string $influxdbproto + * Enum: udp,http,https + * @param int $max_body_size InfluxDB max-body-size in bytes. Requests are batched up to this size. + * @param int $mtu MTU for metrics transmission over UDP + * @param string $organization The InfluxDB organization. Only necessary when using the http v2 api. Has no meaning when using v2 compatibility api. + * @param string $path root graphite path (ex: proxmox.mycluster.mykey) + * @param string $proto Protocol to send graphite data. TCP or UDP (default) + * Enum: udp,tcp + * @param int $timeout graphite TCP socket timeout (default=1) + * @param string $token The InfluxDB access token. Only necessary when using the http v2 api. If the v2 compatibility api is used, use 'user:password' instead. + * @param bool $verify_certificate Set to 0 to disable certificate verification for https endpoints. + * @return Result + */ + public function create($port, $server, $type, $api_path_prefix = null, $bucket = null, $disable = null, $influxdbproto = null, $max_body_size = null, $mtu = null, $organization = null, $path = null, $proto = null, $timeout = null, $token = null, $verify_certificate = null) { + $params = ['port' => $port, + 'server' => $server, + 'type' => $type, + 'api-path-prefix' => $api_path_prefix, + 'bucket' => $bucket, + 'disable' => $disable, + 'influxdbproto' => $influxdbproto, + 'max-body-size' => $max_body_size, + 'mtu' => $mtu, + 'organization' => $organization, + 'path' => $path, + 'proto' => $proto, + 'timeout' => $timeout, + 'token' => $token, + 'verify-certificate' => $verify_certificate]; + return $this->client->create("/cluster/metrics/server/{$this->id}", $params); + } + + /** + * Update metric server configuration. + * @param int $port server network port + * @param string $server server dns name or IP address + * @param string $api_path_prefix An API path prefix inserted between '<host>:<port>/' and '/api2/'. Can be useful if the InfluxDB service runs behind a reverse proxy. + * @param string $bucket The InfluxDB bucket/db. Only necessary when using the http v2 api. + * @param string $delete A list of settings you want to delete. + * @param string $digest Prevent changes if current configuration file has a different digest. This can be used to prevent concurrent modifications. + * @param bool $disable Flag to disable the plugin. + * @param string $influxdbproto + * Enum: udp,http,https + * @param int $max_body_size InfluxDB max-body-size in bytes. Requests are batched up to this size. + * @param int $mtu MTU for metrics transmission over UDP + * @param string $organization The InfluxDB organization. Only necessary when using the http v2 api. Has no meaning when using v2 compatibility api. + * @param string $path root graphite path (ex: proxmox.mycluster.mykey) + * @param string $proto Protocol to send graphite data. TCP or UDP (default) + * Enum: udp,tcp + * @param int $timeout graphite TCP socket timeout (default=1) + * @param string $token The InfluxDB access token. Only necessary when using the http v2 api. If the v2 compatibility api is used, use 'user:password' instead. + * @param bool $verify_certificate Set to 0 to disable certificate verification for https endpoints. + * @return Result + */ + public function update($port, $server, $api_path_prefix = null, $bucket = null, $delete = null, $digest = null, $disable = null, $influxdbproto = null, $max_body_size = null, $mtu = null, $organization = null, $path = null, $proto = null, $timeout = null, $token = null, $verify_certificate = null) { + $params = ['port' => $port, + 'server' => $server, + 'api-path-prefix' => $api_path_prefix, + 'bucket' => $bucket, + 'delete' => $delete, + 'digest' => $digest, + 'disable' => $disable, + 'influxdbproto' => $influxdbproto, + 'max-body-size' => $max_body_size, + 'mtu' => $mtu, + 'organization' => $organization, + 'path' => $path, + 'proto' => $proto, + 'timeout' => $timeout, + 'token' => $token, + 'verify-certificate' => $verify_certificate]; + return $this->client->set("/cluster/metrics/server/{$this->id}", $params); + } + } + + /** + * Class PVEClusterNotifications + * @package Corsinvest\VE\ProxmoxVE\Api + */ + class PVEClusterNotifications { + + /** + * @ignore + */ + private $client; + + /** + * @ignore + */ + function __construct($client) { + $this->client = $client; + } + + /** + * @ignore + */ + private $endpoints; + + /** + * Get NotificationsClusterEndpoints + * @return PVENotificationsClusterEndpoints + */ + public function getEndpoints() { + return $this->endpoints ?: ($this->endpoints = new PVENotificationsClusterEndpoints($this->client)); + } + + /** + * @ignore + */ + private $targets; + + /** + * Get NotificationsClusterTargets + * @return PVENotificationsClusterTargets + */ + public function getTargets() { + return $this->targets ?: ($this->targets = new PVENotificationsClusterTargets($this->client)); + } + + /** + * @ignore + */ + private $matchers; + + /** + * Get NotificationsClusterMatchers + * @return PVENotificationsClusterMatchers + */ + public function getMatchers() { + return $this->matchers ?: ($this->matchers = new PVENotificationsClusterMatchers($this->client)); + } + + /** + * Index for notification-related API endpoints. + * @return Result + */ + public function index() { + return $this->client->get("/cluster/notifications"); + } + } + + /** + * Class PVENotificationsClusterEndpoints + * @package Corsinvest\VE\ProxmoxVE\Api + */ + class PVENotificationsClusterEndpoints { + + /** + * @ignore + */ + private $client; + + /** + * @ignore + */ + function __construct($client) { + $this->client = $client; + } + + /** + * @ignore + */ + private $sendmail; + + /** + * Get EndpointsNotificationsClusterSendmail + * @return PVEEndpointsNotificationsClusterSendmail + */ + public function getSendmail() { + return $this->sendmail ?: ($this->sendmail = new PVEEndpointsNotificationsClusterSendmail($this->client)); + } + + /** + * @ignore + */ + private $gotify; + + /** + * Get EndpointsNotificationsClusterGotify + * @return PVEEndpointsNotificationsClusterGotify + */ + public function getGotify() { + return $this->gotify ?: ($this->gotify = new PVEEndpointsNotificationsClusterGotify($this->client)); + } + + /** + * @ignore + */ + private $smtp; + + /** + * Get EndpointsNotificationsClusterSmtp + * @return PVEEndpointsNotificationsClusterSmtp + */ + public function getSmtp() { + return $this->smtp ?: ($this->smtp = new PVEEndpointsNotificationsClusterSmtp($this->client)); + } + + /** + * Index for all available endpoint types. + * @return Result + */ + public function endpointsIndex() { + return $this->client->get("/cluster/notifications/endpoints"); + } + } + + /** + * Class PVEEndpointsNotificationsClusterSendmail + * @package Corsinvest\VE\ProxmoxVE\Api + */ + class PVEEndpointsNotificationsClusterSendmail { + + /** + * @ignore + */ + private $client; + + /** + * @ignore + */ + function __construct($client) { + $this->client = $client; + } + + /** + * Get ItemSendmailEndpointsNotificationsClusterName + * @param name + * @return PVEItemSendmailEndpointsNotificationsClusterName + */ + public function get($name) { + return new PVEItemSendmailEndpointsNotificationsClusterName($this->client, $name); + } + + /** + * Returns a list of all sendmail endpoints + * @return Result + */ + public function getSendmailEndpoints() { + return $this->client->get("/cluster/notifications/endpoints/sendmail"); + } + + /** + * Create a new sendmail endpoint + * @param string $name The name of the endpoint. + * @param string $author Author of the mail + * @param string $comment Comment + * @param bool $disable Disable this target + * @param string $from_address `From` address for the mail + * @param string $mailto List of email recipients + * @param string $mailto_user List of users + * @return Result + */ + public function createSendmailEndpoint($name, $author = null, $comment = null, $disable = null, $from_address = null, $mailto = null, $mailto_user = null) { + $params = ['name' => $name, + 'author' => $author, + 'comment' => $comment, + 'disable' => $disable, + 'from-address' => $from_address, + 'mailto' => $mailto, + 'mailto-user' => $mailto_user]; + return $this->client->create("/cluster/notifications/endpoints/sendmail", $params); + } + } + + /** + * Class PVEItemSendmailEndpointsNotificationsClusterName + * @package Corsinvest\VE\ProxmoxVE\Api + */ + class PVEItemSendmailEndpointsNotificationsClusterName { + + /** + * @ignore + */ + private $name; + + /** + * @ignore + */ + private $client; + + /** + * @ignore + */ + function __construct($client, $name) { + $this->client = $client; + $this->name = $name; + } + + /** + * Remove sendmail endpoint + * @return Result + */ + public function deleteSendmailEndpoint() { + return $this->client->delete("/cluster/notifications/endpoints/sendmail/{$this->name}"); + } + + /** + * Return a specific sendmail endpoint + * @return Result + */ + public function getSendmailEndpoint() { + return $this->client->get("/cluster/notifications/endpoints/sendmail/{$this->name}"); + } + + /** + * Update existing sendmail endpoint + * @param string $author Author of the mail + * @param string $comment Comment + * @param string $delete A list of settings you want to delete. + * @param string $digest Prevent changes if current configuration file has a different digest. This can be used to prevent concurrent modifications. + * @param bool $disable Disable this target + * @param string $from_address `From` address for the mail + * @param string $mailto List of email recipients + * @param string $mailto_user List of users + * @return Result + */ + public function updateSendmailEndpoint($author = null, $comment = null, $delete = null, $digest = null, $disable = null, $from_address = null, $mailto = null, $mailto_user = null) { + $params = ['author' => $author, + 'comment' => $comment, + 'delete' => $delete, + 'digest' => $digest, + 'disable' => $disable, + 'from-address' => $from_address, + 'mailto' => $mailto, + 'mailto-user' => $mailto_user]; + return $this->client->set("/cluster/notifications/endpoints/sendmail/{$this->name}", $params); + } + } + + /** + * Class PVEEndpointsNotificationsClusterGotify + * @package Corsinvest\VE\ProxmoxVE\Api + */ + class PVEEndpointsNotificationsClusterGotify { + + /** + * @ignore + */ + private $client; + + /** + * @ignore + */ + function __construct($client) { + $this->client = $client; + } + + /** + * Get ItemGotifyEndpointsNotificationsClusterName + * @param name + * @return PVEItemGotifyEndpointsNotificationsClusterName + */ + public function get($name) { + return new PVEItemGotifyEndpointsNotificationsClusterName($this->client, $name); + } + + /** + * Returns a list of all gotify endpoints + * @return Result + */ + public function getGotifyEndpoints() { + return $this->client->get("/cluster/notifications/endpoints/gotify"); + } + + /** + * Create a new gotify endpoint + * @param string $name The name of the endpoint. + * @param string $server Server URL + * @param string $token Secret token + * @param string $comment Comment + * @param bool $disable Disable this target + * @return Result + */ + public function createGotifyEndpoint($name, $server, $token, $comment = null, $disable = null) { + $params = ['name' => $name, + 'server' => $server, + 'token' => $token, + 'comment' => $comment, + 'disable' => $disable]; + return $this->client->create("/cluster/notifications/endpoints/gotify", $params); + } + } + + /** + * Class PVEItemGotifyEndpointsNotificationsClusterName + * @package Corsinvest\VE\ProxmoxVE\Api + */ + class PVEItemGotifyEndpointsNotificationsClusterName { + + /** + * @ignore + */ + private $name; + + /** + * @ignore + */ + private $client; + + /** + * @ignore + */ + function __construct($client, $name) { + $this->client = $client; + $this->name = $name; + } + + /** + * Remove gotify endpoint + * @return Result + */ + public function deleteGotifyEndpoint() { + return $this->client->delete("/cluster/notifications/endpoints/gotify/{$this->name}"); + } + + /** + * Return a specific gotify endpoint + * @return Result + */ + public function getGotifyEndpoint() { + return $this->client->get("/cluster/notifications/endpoints/gotify/{$this->name}"); + } + + /** + * Update existing gotify endpoint + * @param string $comment Comment + * @param string $delete A list of settings you want to delete. + * @param string $digest Prevent changes if current configuration file has a different digest. This can be used to prevent concurrent modifications. + * @param bool $disable Disable this target + * @param string $server Server URL + * @param string $token Secret token + * @return Result + */ + public function updateGotifyEndpoint($comment = null, $delete = null, $digest = null, $disable = null, $server = null, $token = null) { + $params = ['comment' => $comment, + 'delete' => $delete, + 'digest' => $digest, + 'disable' => $disable, + 'server' => $server, + 'token' => $token]; + return $this->client->set("/cluster/notifications/endpoints/gotify/{$this->name}", $params); + } + } + + /** + * Class PVEEndpointsNotificationsClusterSmtp + * @package Corsinvest\VE\ProxmoxVE\Api + */ + class PVEEndpointsNotificationsClusterSmtp { + + /** + * @ignore + */ + private $client; + + /** + * @ignore + */ + function __construct($client) { + $this->client = $client; + } + + /** + * Get ItemSmtpEndpointsNotificationsClusterName + * @param name + * @return PVEItemSmtpEndpointsNotificationsClusterName + */ + public function get($name) { + return new PVEItemSmtpEndpointsNotificationsClusterName($this->client, $name); + } + + /** + * Returns a list of all smtp endpoints + * @return Result + */ + public function getSmtpEndpoints() { + return $this->client->get("/cluster/notifications/endpoints/smtp"); + } + + /** + * Create a new smtp endpoint + * @param string $from_address `From` address for the mail + * @param string $name The name of the endpoint. + * @param string $server The address of the SMTP server. + * @param string $author Author of the mail. Defaults to 'Proxmox VE'. + * @param string $comment Comment + * @param bool $disable Disable this target + * @param string $mailto List of email recipients + * @param string $mailto_user List of users + * @param string $mode Determine which encryption method shall be used for the connection. + * Enum: insecure,starttls,tls + * @param string $password Password for SMTP authentication + * @param int $port The port to be used. Defaults to 465 for TLS based connections, 587 for STARTTLS based connections and port 25 for insecure plain-text connections. + * @param string $username Username for SMTP authentication + * @return Result + */ + public function createSmtpEndpoint($from_address, $name, $server, $author = null, $comment = null, $disable = null, $mailto = null, $mailto_user = null, $mode = null, $password = null, $port = null, $username = null) { + $params = ['from-address' => $from_address, + 'name' => $name, + 'server' => $server, + 'author' => $author, + 'comment' => $comment, + 'disable' => $disable, + 'mailto' => $mailto, + 'mailto-user' => $mailto_user, + 'mode' => $mode, + 'password' => $password, + 'port' => $port, + 'username' => $username]; + return $this->client->create("/cluster/notifications/endpoints/smtp", $params); + } + } + + /** + * Class PVEItemSmtpEndpointsNotificationsClusterName + * @package Corsinvest\VE\ProxmoxVE\Api + */ + class PVEItemSmtpEndpointsNotificationsClusterName { + + /** + * @ignore + */ + private $name; + + /** + * @ignore + */ + private $client; + + /** + * @ignore + */ + function __construct($client, $name) { + $this->client = $client; + $this->name = $name; + } + + /** + * Remove smtp endpoint + * @return Result + */ + public function deleteSmtpEndpoint() { + return $this->client->delete("/cluster/notifications/endpoints/smtp/{$this->name}"); + } + + /** + * Return a specific smtp endpoint + * @return Result + */ + public function getSmtpEndpoint() { + return $this->client->get("/cluster/notifications/endpoints/smtp/{$this->name}"); + } + + /** + * Update existing smtp endpoint + * @param string $author Author of the mail. Defaults to 'Proxmox VE'. + * @param string $comment Comment + * @param string $delete A list of settings you want to delete. + * @param string $digest Prevent changes if current configuration file has a different digest. This can be used to prevent concurrent modifications. + * @param bool $disable Disable this target + * @param string $from_address `From` address for the mail + * @param string $mailto List of email recipients + * @param string $mailto_user List of users + * @param string $mode Determine which encryption method shall be used for the connection. + * Enum: insecure,starttls,tls + * @param string $password Password for SMTP authentication + * @param int $port The port to be used. Defaults to 465 for TLS based connections, 587 for STARTTLS based connections and port 25 for insecure plain-text connections. + * @param string $server The address of the SMTP server. + * @param string $username Username for SMTP authentication + * @return Result + */ + public function updateSmtpEndpoint($author = null, $comment = null, $delete = null, $digest = null, $disable = null, $from_address = null, $mailto = null, $mailto_user = null, $mode = null, $password = null, $port = null, $server = null, $username = null) { + $params = ['author' => $author, + 'comment' => $comment, + 'delete' => $delete, + 'digest' => $digest, + 'disable' => $disable, + 'from-address' => $from_address, + 'mailto' => $mailto, + 'mailto-user' => $mailto_user, + 'mode' => $mode, + 'password' => $password, + 'port' => $port, + 'server' => $server, + 'username' => $username]; + return $this->client->set("/cluster/notifications/endpoints/smtp/{$this->name}", $params); + } + } + + /** + * Class PVENotificationsClusterTargets + * @package Corsinvest\VE\ProxmoxVE\Api + */ + class PVENotificationsClusterTargets { + + /** + * @ignore + */ + private $client; + + /** + * @ignore + */ + function __construct($client) { + $this->client = $client; + } + + /** + * Get ItemTargetsNotificationsClusterName + * @param name + * @return PVEItemTargetsNotificationsClusterName + */ + public function get($name) { + return new PVEItemTargetsNotificationsClusterName($this->client, $name); + } + + /** + * Returns a list of all entities that can be used as notification targets. + * @return Result + */ + public function getAllTargets() { + return $this->client->get("/cluster/notifications/targets"); + } + } + + /** + * Class PVEItemTargetsNotificationsClusterName + * @package Corsinvest\VE\ProxmoxVE\Api + */ + class PVEItemTargetsNotificationsClusterName { + + /** + * @ignore + */ + private $name; + + /** + * @ignore + */ + private $client; + + /** + * @ignore + */ + function __construct($client, $name) { + $this->client = $client; + $this->name = $name; + } + + /** + * @ignore + */ + private $test; + + /** + * Get NameTargetsNotificationsClusterTest + * @return PVENameTargetsNotificationsClusterTest + */ + public function getTest() { + return $this->test ?: ($this->test = new PVENameTargetsNotificationsClusterTest($this->client, $this->name)); + } + } + + /** + * Class PVENameTargetsNotificationsClusterTest + * @package Corsinvest\VE\ProxmoxVE\Api + */ + class PVENameTargetsNotificationsClusterTest { + + /** + * @ignore + */ + private $name; + + /** + * @ignore + */ + private $client; + + /** + * @ignore + */ + function __construct($client, $name) { + $this->client = $client; + $this->name = $name; + } + + /** + * Send a test notification to a provided target. + * @return Result + */ + public function testTarget() { + return $this->client->create("/cluster/notifications/targets/{$this->name}/test"); + } + } + + /** + * Class PVENotificationsClusterMatchers + * @package Corsinvest\VE\ProxmoxVE\Api + */ + class PVENotificationsClusterMatchers { + + /** + * @ignore + */ + private $client; + + /** + * @ignore + */ + function __construct($client) { + $this->client = $client; + } + + /** + * Get ItemMatchersNotificationsClusterName + * @param name + * @return PVEItemMatchersNotificationsClusterName + */ + public function get($name) { + return new PVEItemMatchersNotificationsClusterName($this->client, $name); + } + + /** + * Returns a list of all matchers + * @return Result + */ + public function getMatchers() { + return $this->client->get("/cluster/notifications/matchers"); + } + + /** + * Create a new matcher + * @param string $name Name of the matcher. + * @param string $comment Comment + * @param bool $disable Disable this matcher + * @param bool $invert_match Invert match of the whole matcher + * @param string $match_calendar Match notification timestamp + * @param string $match_field Metadata fields to match (regex or exact match). Must be in the form (regex|exact):<field>=<value> + * @param string $match_severity Notification severities to match + * @param string $mode Choose between 'all' and 'any' for when multiple properties are specified + * Enum: all,any + * @param string $target Targets to notify on match + * @return Result + */ + public function createMatcher($name, $comment = null, $disable = null, $invert_match = null, $match_calendar = null, $match_field = null, $match_severity = null, $mode = null, $target = null) { + $params = ['name' => $name, + 'comment' => $comment, + 'disable' => $disable, + 'invert-match' => $invert_match, + 'match-calendar' => $match_calendar, + 'match-field' => $match_field, + 'match-severity' => $match_severity, + 'mode' => $mode, + 'target' => $target]; + return $this->client->create("/cluster/notifications/matchers", $params); + } + } + + /** + * Class PVEItemMatchersNotificationsClusterName + * @package Corsinvest\VE\ProxmoxVE\Api + */ + class PVEItemMatchersNotificationsClusterName { + + /** + * @ignore + */ + private $name; + + /** + * @ignore + */ + private $client; + + /** + * @ignore + */ + function __construct($client, $name) { + $this->client = $client; + $this->name = $name; + } + + /** + * Remove matcher * @return Result */ - public function read() { - return $this->client->get("/cluster/metrics/server/{$this->id}"); + public function deleteMatcher() { + return $this->client->delete("/cluster/notifications/matchers/{$this->name}"); } /** - * Create a new external metric server config - * @param int $port server network port - * @param string $server server dns name or IP address - * @param string $type Plugin type. - * Enum: graphite,influxdb - * @param string $api_path_prefix An API path prefix inserted between '<host>:<port>/' and '/api2/'. Can be useful if the InfluxDB service runs behind a reverse proxy. - * @param string $bucket The InfluxDB bucket/db. Only necessary when using the http v2 api. - * @param bool $disable Flag to disable the plugin. - * @param string $influxdbproto - * Enum: udp,http,https - * @param int $max_body_size InfluxDB max-body-size in bytes. Requests are batched up to this size. - * @param int $mtu MTU for metrics transmission over UDP - * @param string $organization The InfluxDB organization. Only necessary when using the http v2 api. Has no meaning when using v2 compatibility api. - * @param string $path root graphite path (ex: proxmox.mycluster.mykey) - * @param string $proto Protocol to send graphite data. TCP or UDP (default) - * Enum: udp,tcp - * @param int $timeout graphite TCP socket timeout (default=1) - * @param string $token The InfluxDB access token. Only necessary when using the http v2 api. If the v2 compatibility api is used, use 'user:password' instead. - * @param bool $verify_certificate Set to 0 to disable certificate verification for https endpoints. + * Return a specific matcher * @return Result */ - public function create($port, $server, $type, $api_path_prefix = null, $bucket = null, $disable = null, $influxdbproto = null, $max_body_size = null, $mtu = null, $organization = null, $path = null, $proto = null, $timeout = null, $token = null, $verify_certificate = null) { - $params = [ - 'port' => $port, - 'server' => $server, - 'type' => $type, - 'api-path-prefix' => $api_path_prefix, - 'bucket' => $bucket, - 'disable' => $disable, - 'influxdbproto' => $influxdbproto, - 'max-body-size' => $max_body_size, - 'mtu' => $mtu, - 'organization' => $organization, - 'path' => $path, - 'proto' => $proto, - 'timeout' => $timeout, - 'token' => $token, - 'verify-certificate' => $verify_certificate - ]; - return $this->client->create("/cluster/metrics/server/{$this->id}", $params); + public function getMatcher() { + return $this->client->get("/cluster/notifications/matchers/{$this->name}"); } /** - * Update metric server configuration. - * @param int $port server network port - * @param string $server server dns name or IP address - * @param string $api_path_prefix An API path prefix inserted between '<host>:<port>/' and '/api2/'. Can be useful if the InfluxDB service runs behind a reverse proxy. - * @param string $bucket The InfluxDB bucket/db. Only necessary when using the http v2 api. + * Update existing matcher + * @param string $comment Comment * @param string $delete A list of settings you want to delete. - * @param string $digest Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications. - * @param bool $disable Flag to disable the plugin. - * @param string $influxdbproto - * Enum: udp,http,https - * @param int $max_body_size InfluxDB max-body-size in bytes. Requests are batched up to this size. - * @param int $mtu MTU for metrics transmission over UDP - * @param string $organization The InfluxDB organization. Only necessary when using the http v2 api. Has no meaning when using v2 compatibility api. - * @param string $path root graphite path (ex: proxmox.mycluster.mykey) - * @param string $proto Protocol to send graphite data. TCP or UDP (default) - * Enum: udp,tcp - * @param int $timeout graphite TCP socket timeout (default=1) - * @param string $token The InfluxDB access token. Only necessary when using the http v2 api. If the v2 compatibility api is used, use 'user:password' instead. - * @param bool $verify_certificate Set to 0 to disable certificate verification for https endpoints. - * @return Result - */ - public function update($port, $server, $api_path_prefix = null, $bucket = null, $delete = null, $digest = null, $disable = null, $influxdbproto = null, $max_body_size = null, $mtu = null, $organization = null, $path = null, $proto = null, $timeout = null, $token = null, $verify_certificate = null) { - $params = [ - 'port' => $port, - 'server' => $server, - 'api-path-prefix' => $api_path_prefix, - 'bucket' => $bucket, + * @param string $digest Prevent changes if current configuration file has a different digest. This can be used to prevent concurrent modifications. + * @param bool $disable Disable this matcher + * @param bool $invert_match Invert match of the whole matcher + * @param string $match_calendar Match notification timestamp + * @param string $match_field Metadata fields to match (regex or exact match). Must be in the form (regex|exact):<field>=<value> + * @param string $match_severity Notification severities to match + * @param string $mode Choose between 'all' and 'any' for when multiple properties are specified + * Enum: all,any + * @param string $target Targets to notify on match + * @return Result + */ + public function updateMatcher($comment = null, $delete = null, $digest = null, $disable = null, $invert_match = null, $match_calendar = null, $match_field = null, $match_severity = null, $mode = null, $target = null) { + $params = ['comment' => $comment, 'delete' => $delete, 'digest' => $digest, 'disable' => $disable, - 'influxdbproto' => $influxdbproto, - 'max-body-size' => $max_body_size, - 'mtu' => $mtu, - 'organization' => $organization, - 'path' => $path, - 'proto' => $proto, - 'timeout' => $timeout, - 'token' => $token, - 'verify-certificate' => $verify_certificate - ]; - return $this->client->set("/cluster/metrics/server/{$this->id}", $params); + 'invert-match' => $invert_match, + 'match-calendar' => $match_calendar, + 'match-field' => $match_field, + 'match-severity' => $match_severity, + 'mode' => $mode, + 'target' => $target]; + return $this->client->set("/cluster/notifications/matchers/{$this->name}", $params); } } /** * Class PVEClusterConfig - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEClusterConfig { @@ -833,11 +1591,9 @@ public function index() { * @return Result */ public function create($clustername, $linkN = null, $nodeid = null, $votes = null) { - $params = [ - 'clustername' => $clustername, + $params = ['clustername' => $clustername, 'nodeid' => $nodeid, - 'votes' => $votes - ]; + 'votes' => $votes]; $this->client->addIndexedParameter($params, 'link', $linkN); return $this->client->create("/cluster/config", $params); } @@ -845,7 +1601,7 @@ public function create($clustername, $linkN = null, $nodeid = null, $votes = nul /** * Class PVEConfigClusterApiversion - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEConfigClusterApiversion { @@ -872,7 +1628,7 @@ public function joinApiVersion() { /** * Class PVEConfigClusterNodes - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEConfigClusterNodes { @@ -908,7 +1664,7 @@ public function nodes() { /** * Class PVEItemNodesConfigClusterNode - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemNodesConfigClusterNode { @@ -949,13 +1705,11 @@ public function delnode() { * @return Result */ public function addnode($apiversion = null, $force = null, $linkN = null, $new_node_ip = null, $nodeid = null, $votes = null) { - $params = [ - 'apiversion' => $apiversion, + $params = ['apiversion' => $apiversion, 'force' => $force, 'new_node_ip' => $new_node_ip, 'nodeid' => $nodeid, - 'votes' => $votes - ]; + 'votes' => $votes]; $this->client->addIndexedParameter($params, 'link', $linkN); return $this->client->create("/cluster/config/nodes/{$this->node}", $params); } @@ -963,7 +1717,7 @@ public function addnode($apiversion = null, $force = null, $linkN = null, $new_n /** * Class PVEConfigClusterJoin - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEConfigClusterJoin { @@ -981,7 +1735,7 @@ function __construct($client) { /** * Get information needed to join this cluster over the connected node. - * @param string $node The node for which the joinee gets the nodeinfo. + * @param string $node The node for which the joinee gets the nodeinfo. * @return Result */ public function joinInfo($node = null) { @@ -1001,14 +1755,12 @@ public function joinInfo($node = null) { * @return Result */ public function join($fingerprint, $hostname, $password, $force = null, $linkN = null, $nodeid = null, $votes = null) { - $params = [ - 'fingerprint' => $fingerprint, + $params = ['fingerprint' => $fingerprint, 'hostname' => $hostname, 'password' => $password, 'force' => $force, 'nodeid' => $nodeid, - 'votes' => $votes - ]; + 'votes' => $votes]; $this->client->addIndexedParameter($params, 'link', $linkN); return $this->client->create("/cluster/config/join", $params); } @@ -1016,7 +1768,7 @@ public function join($fingerprint, $hostname, $password, $force = null, $linkN = /** * Class PVEConfigClusterTotem - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEConfigClusterTotem { @@ -1043,7 +1795,7 @@ public function totem() { /** * Class PVEConfigClusterQdevice - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEConfigClusterQdevice { @@ -1070,7 +1822,7 @@ public function status() { /** * Class PVEClusterFirewall - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEClusterFirewall { @@ -1188,7 +1940,7 @@ public function index() { /** * Class PVEFirewallClusterGroups - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEFirewallClusterGroups { @@ -1224,25 +1976,23 @@ public function listSecurityGroups() { /** * Create new security group. * @param string $group Security Group name. - * @param string $comment - * @param string $digest Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications. + * @param string $comment + * @param string $digest Prevent changes if current configuration file has a different digest. This can be used to prevent concurrent modifications. * @param string $rename Rename/update an existing security group. You can set 'rename' to the same value as 'name' to update the 'comment' of an existing group. * @return Result */ public function createSecurityGroup($group, $comment = null, $digest = null, $rename = null) { - $params = [ - 'group' => $group, + $params = ['group' => $group, 'comment' => $comment, 'digest' => $digest, - 'rename' => $rename - ]; + 'rename' => $rename]; return $this->client->create("/cluster/firewall/groups", $params); } } /** * Class PVEItemGroupsFirewallClusterGroup - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemGroupsFirewallClusterGroup { @@ -1296,7 +2046,7 @@ public function getRules() { * Enum: in,out,group * @param string $comment Descriptive comment. * @param string $dest Restrict packet destination address. This can refer to a single IP address, an IP set ('+ipsetname') or an IP alias definition. You can also specify an address range like '20.34.101.207-201.3.9.99', or a list of IP addresses and networks (entries are separated by comma). Please do not mix IPv4 and IPv6 addresses inside such lists. - * @param string $digest Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications. + * @param string $digest Prevent changes if current configuration file has a different digest. This can be used to prevent concurrent modifications. * @param string $dport Restrict TCP/UDP destination port. You can use service names or simple numbers (0-65535), as defined in '/etc/services'. Port ranges can be specified with '\d+:\d+', for example '80:85', and you can use comma separated list to match several ports or ranges. * @param int $enable Flag to enable/disable a rule. * @param string $icmp_type Specify icmp-type. Only valid if proto equals 'icmp' or 'icmpv6'/'ipv6-icmp'. @@ -1311,8 +2061,7 @@ public function getRules() { * @return Result */ public function createRule($action, $type, $comment = null, $dest = null, $digest = null, $dport = null, $enable = null, $icmp_type = null, $iface = null, $log = null, $macro = null, $pos = null, $proto = null, $source = null, $sport = null) { - $params = [ - 'action' => $action, + $params = ['action' => $action, 'type' => $type, 'comment' => $comment, 'dest' => $dest, @@ -1326,15 +2075,14 @@ public function createRule($action, $type, $comment = null, $dest = null, $diges 'pos' => $pos, 'proto' => $proto, 'source' => $source, - 'sport' => $sport - ]; + 'sport' => $sport]; return $this->client->create("/cluster/firewall/groups/{$this->group}", $params); } } /** * Class PVEItemGroupGroupsFirewallClusterPos - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemGroupGroupsFirewallClusterPos { @@ -1364,7 +2112,7 @@ function __construct($client, $group, $pos) { /** * Delete rule. - * @param string $digest Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications. + * @param string $digest Prevent changes if current configuration file has a different digest. This can be used to prevent concurrent modifications. * @return Result */ public function deleteRule($digest = null) { @@ -1386,7 +2134,7 @@ public function getRule() { * @param string $comment Descriptive comment. * @param string $delete A list of settings you want to delete. * @param string $dest Restrict packet destination address. This can refer to a single IP address, an IP set ('+ipsetname') or an IP alias definition. You can also specify an address range like '20.34.101.207-201.3.9.99', or a list of IP addresses and networks (entries are separated by comma). Please do not mix IPv4 and IPv6 addresses inside such lists. - * @param string $digest Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications. + * @param string $digest Prevent changes if current configuration file has a different digest. This can be used to prevent concurrent modifications. * @param string $dport Restrict TCP/UDP destination port. You can use service names or simple numbers (0-65535), as defined in '/etc/services'. Port ranges can be specified with '\d+:\d+', for example '80:85', and you can use comma separated list to match several ports or ranges. * @param int $enable Flag to enable/disable a rule. * @param string $icmp_type Specify icmp-type. Only valid if proto equals 'icmp' or 'icmpv6'/'ipv6-icmp'. @@ -1403,8 +2151,7 @@ public function getRule() { * @return Result */ public function updateRule($action = null, $comment = null, $delete = null, $dest = null, $digest = null, $dport = null, $enable = null, $icmp_type = null, $iface = null, $log = null, $macro = null, $moveto = null, $proto = null, $source = null, $sport = null, $type = null) { - $params = [ - 'action' => $action, + $params = ['action' => $action, 'comment' => $comment, 'delete' => $delete, 'dest' => $dest, @@ -1419,15 +2166,14 @@ public function updateRule($action = null, $comment = null, $delete = null, $des 'proto' => $proto, 'source' => $source, 'sport' => $sport, - 'type' => $type - ]; + 'type' => $type]; return $this->client->set("/cluster/firewall/groups/{$this->group}/{$this->pos}", $params); } } /** * Class PVEFirewallClusterRules - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEFirewallClusterRules { @@ -1467,7 +2213,7 @@ public function getRules() { * Enum: in,out,group * @param string $comment Descriptive comment. * @param string $dest Restrict packet destination address. This can refer to a single IP address, an IP set ('+ipsetname') or an IP alias definition. You can also specify an address range like '20.34.101.207-201.3.9.99', or a list of IP addresses and networks (entries are separated by comma). Please do not mix IPv4 and IPv6 addresses inside such lists. - * @param string $digest Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications. + * @param string $digest Prevent changes if current configuration file has a different digest. This can be used to prevent concurrent modifications. * @param string $dport Restrict TCP/UDP destination port. You can use service names or simple numbers (0-65535), as defined in '/etc/services'. Port ranges can be specified with '\d+:\d+', for example '80:85', and you can use comma separated list to match several ports or ranges. * @param int $enable Flag to enable/disable a rule. * @param string $icmp_type Specify icmp-type. Only valid if proto equals 'icmp' or 'icmpv6'/'ipv6-icmp'. @@ -1482,8 +2228,7 @@ public function getRules() { * @return Result */ public function createRule($action, $type, $comment = null, $dest = null, $digest = null, $dport = null, $enable = null, $icmp_type = null, $iface = null, $log = null, $macro = null, $pos = null, $proto = null, $source = null, $sport = null) { - $params = [ - 'action' => $action, + $params = ['action' => $action, 'type' => $type, 'comment' => $comment, 'dest' => $dest, @@ -1497,15 +2242,14 @@ public function createRule($action, $type, $comment = null, $dest = null, $diges 'pos' => $pos, 'proto' => $proto, 'source' => $source, - 'sport' => $sport - ]; + 'sport' => $sport]; return $this->client->create("/cluster/firewall/rules", $params); } } /** * Class PVEItemRulesFirewallClusterPos - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemRulesFirewallClusterPos { @@ -1529,7 +2273,7 @@ function __construct($client, $pos) { /** * Delete rule. - * @param string $digest Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications. + * @param string $digest Prevent changes if current configuration file has a different digest. This can be used to prevent concurrent modifications. * @return Result */ public function deleteRule($digest = null) { @@ -1551,7 +2295,7 @@ public function getRule() { * @param string $comment Descriptive comment. * @param string $delete A list of settings you want to delete. * @param string $dest Restrict packet destination address. This can refer to a single IP address, an IP set ('+ipsetname') or an IP alias definition. You can also specify an address range like '20.34.101.207-201.3.9.99', or a list of IP addresses and networks (entries are separated by comma). Please do not mix IPv4 and IPv6 addresses inside such lists. - * @param string $digest Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications. + * @param string $digest Prevent changes if current configuration file has a different digest. This can be used to prevent concurrent modifications. * @param string $dport Restrict TCP/UDP destination port. You can use service names or simple numbers (0-65535), as defined in '/etc/services'. Port ranges can be specified with '\d+:\d+', for example '80:85', and you can use comma separated list to match several ports or ranges. * @param int $enable Flag to enable/disable a rule. * @param string $icmp_type Specify icmp-type. Only valid if proto equals 'icmp' or 'icmpv6'/'ipv6-icmp'. @@ -1568,8 +2312,7 @@ public function getRule() { * @return Result */ public function updateRule($action = null, $comment = null, $delete = null, $dest = null, $digest = null, $dport = null, $enable = null, $icmp_type = null, $iface = null, $log = null, $macro = null, $moveto = null, $proto = null, $source = null, $sport = null, $type = null) { - $params = [ - 'action' => $action, + $params = ['action' => $action, 'comment' => $comment, 'delete' => $delete, 'dest' => $dest, @@ -1584,15 +2327,14 @@ public function updateRule($action = null, $comment = null, $delete = null, $des 'proto' => $proto, 'source' => $source, 'sport' => $sport, - 'type' => $type - ]; + 'type' => $type]; return $this->client->set("/cluster/firewall/rules/{$this->pos}", $params); } } /** * Class PVEFirewallClusterIpset - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEFirewallClusterIpset { @@ -1628,25 +2370,23 @@ public function ipsetIndex() { /** * Create new IPSet * @param string $name IP set name. - * @param string $comment - * @param string $digest Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications. + * @param string $comment + * @param string $digest Prevent changes if current configuration file has a different digest. This can be used to prevent concurrent modifications. * @param string $rename Rename an existing IPSet. You can set 'rename' to the same value as 'name' to update the 'comment' of an existing IPSet. * @return Result */ public function createIpset($name, $comment = null, $digest = null, $rename = null) { - $params = [ - 'name' => $name, + $params = ['name' => $name, 'comment' => $comment, 'digest' => $digest, - 'rename' => $rename - ]; + 'rename' => $rename]; return $this->client->create("/cluster/firewall/ipset", $params); } } /** * Class PVEItemIpsetFirewallClusterName - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemIpsetFirewallClusterName { @@ -1698,23 +2438,21 @@ public function getIpset() { /** * Add IP or Network to IPSet. * @param string $cidr Network/IP specification in CIDR format. - * @param string $comment - * @param bool $nomatch + * @param string $comment + * @param bool $nomatch * @return Result */ public function createIp($cidr, $comment = null, $nomatch = null) { - $params = [ - 'cidr' => $cidr, + $params = ['cidr' => $cidr, 'comment' => $comment, - 'nomatch' => $nomatch - ]; + 'nomatch' => $nomatch]; return $this->client->create("/cluster/firewall/ipset/{$this->name}", $params); } } /** * Class PVEItemNameIpsetFirewallClusterCidr - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemNameIpsetFirewallClusterCidr { @@ -1744,7 +2482,7 @@ function __construct($client, $name, $cidr) { /** * Remove IP or Network from IPSet. - * @param string $digest Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications. + * @param string $digest Prevent changes if current configuration file has a different digest. This can be used to prevent concurrent modifications. * @return Result */ public function removeIp($digest = null) { @@ -1762,24 +2500,22 @@ public function readIp() { /** * Update IP or Network settings - * @param string $comment - * @param string $digest Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications. - * @param bool $nomatch + * @param string $comment + * @param string $digest Prevent changes if current configuration file has a different digest. This can be used to prevent concurrent modifications. + * @param bool $nomatch * @return Result */ public function updateIp($comment = null, $digest = null, $nomatch = null) { - $params = [ - 'comment' => $comment, + $params = ['comment' => $comment, 'digest' => $digest, - 'nomatch' => $nomatch - ]; + 'nomatch' => $nomatch]; return $this->client->set("/cluster/firewall/ipset/{$this->name}/{$this->cidr}", $params); } } /** * Class PVEFirewallClusterAliases - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEFirewallClusterAliases { @@ -1816,22 +2552,20 @@ public function getAliases() { * Create IP or Network Alias. * @param string $cidr Network/IP specification in CIDR format. * @param string $name Alias name. - * @param string $comment + * @param string $comment * @return Result */ public function createAlias($cidr, $name, $comment = null) { - $params = [ - 'cidr' => $cidr, + $params = ['cidr' => $cidr, 'name' => $name, - 'comment' => $comment - ]; + 'comment' => $comment]; return $this->client->create("/cluster/firewall/aliases", $params); } } /** * Class PVEItemAliasesFirewallClusterName - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemAliasesFirewallClusterName { @@ -1855,7 +2589,7 @@ function __construct($client, $name) { /** * Remove IP or Network alias. - * @param string $digest Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications. + * @param string $digest Prevent changes if current configuration file has a different digest. This can be used to prevent concurrent modifications. * @return Result */ public function removeAlias($digest = null) { @@ -1874,25 +2608,23 @@ public function readAlias() { /** * Update IP or Network alias. * @param string $cidr Network/IP specification in CIDR format. - * @param string $comment - * @param string $digest Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications. + * @param string $comment + * @param string $digest Prevent changes if current configuration file has a different digest. This can be used to prevent concurrent modifications. * @param string $rename Rename an existing alias. * @return Result */ public function updateAlias($cidr, $comment = null, $digest = null, $rename = null) { - $params = [ - 'cidr' => $cidr, + $params = ['cidr' => $cidr, 'comment' => $comment, 'digest' => $digest, - 'rename' => $rename - ]; + 'rename' => $rename]; return $this->client->set("/cluster/firewall/aliases/{$this->name}", $params); } } /** * Class PVEFirewallClusterOptions - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEFirewallClusterOptions { @@ -1919,7 +2651,7 @@ public function getOptions() { /** * Set Firewall options. * @param string $delete A list of settings you want to delete. - * @param string $digest Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications. + * @param string $digest Prevent changes if current configuration file has a different digest. This can be used to prevent concurrent modifications. * @param bool $ebtables Enable ebtables rules cluster wide. * @param int $enable Enable or disable the firewall cluster wide. * @param string $log_ratelimit Log ratelimiting settings @@ -1930,22 +2662,20 @@ public function getOptions() { * @return Result */ public function setOptions($delete = null, $digest = null, $ebtables = null, $enable = null, $log_ratelimit = null, $policy_in = null, $policy_out = null) { - $params = [ - 'delete' => $delete, + $params = ['delete' => $delete, 'digest' => $digest, 'ebtables' => $ebtables, 'enable' => $enable, 'log_ratelimit' => $log_ratelimit, 'policy_in' => $policy_in, - 'policy_out' => $policy_out - ]; + 'policy_out' => $policy_out]; return $this->client->set("/cluster/firewall/options", $params); } } /** * Class PVEFirewallClusterMacros - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEFirewallClusterMacros { @@ -1972,7 +2702,7 @@ public function getMacros() { /** * Class PVEFirewallClusterRefs - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEFirewallClusterRefs { @@ -2002,7 +2732,7 @@ public function refs($type = null) { /** * Class PVEClusterBackup - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEClusterBackup { @@ -2050,14 +2780,17 @@ public function index() { * @param string $id Job ID (will be autogenerated). * @param int $ionice Set IO priority when using the BFQ scheduler. For snapshot and suspend mode backups of VMs, this only affects the compressor. A value of 8 means the idle priority is used, otherwise the best-effort priority is used with the specified value. * @param int $lockwait Maximal time to wait for the global lock (minutes). - * @param string $mailnotification Specify when to send an email + * @param string $mailnotification Deprecated: use 'notification-policy' instead. * Enum: always,failure - * @param string $mailto Comma-separated list of email addresses or users that should receive email notifications. + * @param string $mailto Comma-separated list of email addresses or users that should receive email notifications. Has no effect if the 'notification-target' option is set at the same time. * @param int $maxfiles Deprecated: use 'prune-backups' instead. Maximal number of backup files per guest system. * @param string $mode Backup mode. * Enum: snapshot,suspend,stop * @param string $node Only run if executed on this node. * @param string $notes_template Template string for generating notes for the backup(s). It can contain variables which will be replaced by their values. Currently supported are {{cluster}}, {{guestname}}, {{node}}, and {{vmid}}, but more might be added in the future. Needs to be a single line, newline and backslash need to be escaped as '\n' and '\\' respectively. + * @param string $notification_policy Specify when to send a notification + * Enum: always,failure,never + * @param string $notification_target Determine the target to which notifications should be sent. Can either be a notification endpoint or a notification group. This option takes precedence over 'mailto', meaning that if both are set, the 'mailto' option will be ignored. * @param string $performance Other performance-related settings. * @param int $pigz Use pigz instead of gzip when N>0. N=1 uses half of cores, N>1 uses N as thread count. * @param string $pool Backup all known guest systems included in the specified pool. @@ -2078,9 +2811,8 @@ public function index() { * @param int $zstd Zstd threads. N=0 uses half of the available cores, N>0 uses N as thread count. * @return Result */ - public function createJob($all = null, $bwlimit = null, $comment = null, $compress = null, $dow = null, $dumpdir = null, $enabled = null, $exclude = null, $exclude_path = null, $id = null, $ionice = null, $lockwait = null, $mailnotification = null, $mailto = null, $maxfiles = null, $mode = null, $node = null, $notes_template = null, $performance = null, $pigz = null, $pool = null, $protected = null, $prune_backups = null, $quiet = null, $remove = null, $repeat_missed = null, $schedule = null, $script = null, $starttime = null, $stdexcludes = null, $stop = null, $stopwait = null, $storage = null, $tmpdir = null, $vmid = null, $zstd = null) { - $params = [ - 'all' => $all, + public function createJob($all = null, $bwlimit = null, $comment = null, $compress = null, $dow = null, $dumpdir = null, $enabled = null, $exclude = null, $exclude_path = null, $id = null, $ionice = null, $lockwait = null, $mailnotification = null, $mailto = null, $maxfiles = null, $mode = null, $node = null, $notes_template = null, $notification_policy = null, $notification_target = null, $performance = null, $pigz = null, $pool = null, $protected = null, $prune_backups = null, $quiet = null, $remove = null, $repeat_missed = null, $schedule = null, $script = null, $starttime = null, $stdexcludes = null, $stop = null, $stopwait = null, $storage = null, $tmpdir = null, $vmid = null, $zstd = null) { + $params = ['all' => $all, 'bwlimit' => $bwlimit, 'comment' => $comment, 'compress' => $compress, @@ -2098,6 +2830,8 @@ public function createJob($all = null, $bwlimit = null, $comment = null, $compre 'mode' => $mode, 'node' => $node, 'notes-template' => $notes_template, + 'notification-policy' => $notification_policy, + 'notification-target' => $notification_target, 'performance' => $performance, 'pigz' => $pigz, 'pool' => $pool, @@ -2115,15 +2849,14 @@ public function createJob($all = null, $bwlimit = null, $comment = null, $compre 'storage' => $storage, 'tmpdir' => $tmpdir, 'vmid' => $vmid, - 'zstd' => $zstd - ]; + 'zstd' => $zstd]; return $this->client->create("/cluster/backup", $params); } } /** * Class PVEItemBackupClusterId - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemBackupClusterId { @@ -2189,14 +2922,17 @@ public function readJob() { * @param string $exclude_path Exclude certain files/directories (shell globs). Paths starting with '/' are anchored to the container's root, other paths match relative to each subdirectory. * @param int $ionice Set IO priority when using the BFQ scheduler. For snapshot and suspend mode backups of VMs, this only affects the compressor. A value of 8 means the idle priority is used, otherwise the best-effort priority is used with the specified value. * @param int $lockwait Maximal time to wait for the global lock (minutes). - * @param string $mailnotification Specify when to send an email + * @param string $mailnotification Deprecated: use 'notification-policy' instead. * Enum: always,failure - * @param string $mailto Comma-separated list of email addresses or users that should receive email notifications. + * @param string $mailto Comma-separated list of email addresses or users that should receive email notifications. Has no effect if the 'notification-target' option is set at the same time. * @param int $maxfiles Deprecated: use 'prune-backups' instead. Maximal number of backup files per guest system. * @param string $mode Backup mode. * Enum: snapshot,suspend,stop * @param string $node Only run if executed on this node. * @param string $notes_template Template string for generating notes for the backup(s). It can contain variables which will be replaced by their values. Currently supported are {{cluster}}, {{guestname}}, {{node}}, and {{vmid}}, but more might be added in the future. Needs to be a single line, newline and backslash need to be escaped as '\n' and '\\' respectively. + * @param string $notification_policy Specify when to send a notification + * Enum: always,failure,never + * @param string $notification_target Determine the target to which notifications should be sent. Can either be a notification endpoint or a notification group. This option takes precedence over 'mailto', meaning that if both are set, the 'mailto' option will be ignored. * @param string $performance Other performance-related settings. * @param int $pigz Use pigz instead of gzip when N>0. N=1 uses half of cores, N>1 uses N as thread count. * @param string $pool Backup all known guest systems included in the specified pool. @@ -2217,9 +2953,8 @@ public function readJob() { * @param int $zstd Zstd threads. N=0 uses half of the available cores, N>0 uses N as thread count. * @return Result */ - public function updateJob($all = null, $bwlimit = null, $comment = null, $compress = null, $delete = null, $dow = null, $dumpdir = null, $enabled = null, $exclude = null, $exclude_path = null, $ionice = null, $lockwait = null, $mailnotification = null, $mailto = null, $maxfiles = null, $mode = null, $node = null, $notes_template = null, $performance = null, $pigz = null, $pool = null, $protected = null, $prune_backups = null, $quiet = null, $remove = null, $repeat_missed = null, $schedule = null, $script = null, $starttime = null, $stdexcludes = null, $stop = null, $stopwait = null, $storage = null, $tmpdir = null, $vmid = null, $zstd = null) { - $params = [ - 'all' => $all, + public function updateJob($all = null, $bwlimit = null, $comment = null, $compress = null, $delete = null, $dow = null, $dumpdir = null, $enabled = null, $exclude = null, $exclude_path = null, $ionice = null, $lockwait = null, $mailnotification = null, $mailto = null, $maxfiles = null, $mode = null, $node = null, $notes_template = null, $notification_policy = null, $notification_target = null, $performance = null, $pigz = null, $pool = null, $protected = null, $prune_backups = null, $quiet = null, $remove = null, $repeat_missed = null, $schedule = null, $script = null, $starttime = null, $stdexcludes = null, $stop = null, $stopwait = null, $storage = null, $tmpdir = null, $vmid = null, $zstd = null) { + $params = ['all' => $all, 'bwlimit' => $bwlimit, 'comment' => $comment, 'compress' => $compress, @@ -2237,6 +2972,8 @@ public function updateJob($all = null, $bwlimit = null, $comment = null, $compre 'mode' => $mode, 'node' => $node, 'notes-template' => $notes_template, + 'notification-policy' => $notification_policy, + 'notification-target' => $notification_target, 'performance' => $performance, 'pigz' => $pigz, 'pool' => $pool, @@ -2254,15 +2991,14 @@ public function updateJob($all = null, $bwlimit = null, $comment = null, $compre 'storage' => $storage, 'tmpdir' => $tmpdir, 'vmid' => $vmid, - 'zstd' => $zstd - ]; + 'zstd' => $zstd]; return $this->client->set("/cluster/backup/{$this->id}", $params); } } /** * Class PVEIdBackupClusterIncludedVolumes - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEIdBackupClusterIncludedVolumes { @@ -2295,7 +3031,7 @@ public function getVolumeBackupIncluded() { /** * Class PVEClusterBackupInfo - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEClusterBackupInfo { @@ -2335,7 +3071,7 @@ public function index() { /** * Class PVEBackupInfoClusterNotBackedUp - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEBackupInfoClusterNotBackedUp { @@ -2362,7 +3098,7 @@ public function getGuestsNotInBackup() { /** * Class PVEClusterHa - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEClusterHa { @@ -2428,7 +3164,7 @@ public function index() { /** * Class PVEHaClusterResources - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEHaClusterResources { @@ -2478,22 +3214,20 @@ public function index($type = null) { * @return Result */ public function create($sid, $comment = null, $group = null, $max_relocate = null, $max_restart = null, $state = null, $type = null) { - $params = [ - 'sid' => $sid, + $params = ['sid' => $sid, 'comment' => $comment, 'group' => $group, 'max_relocate' => $max_relocate, 'max_restart' => $max_restart, 'state' => $state, - 'type' => $type - ]; + 'type' => $type]; return $this->client->create("/cluster/ha/resources", $params); } } /** * Class PVEItemResourcesHaClusterSid - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemResourcesHaClusterSid { @@ -2561,7 +3295,7 @@ public function read() { * Update resource configuration. * @param string $comment Description. * @param string $delete A list of settings you want to delete. - * @param string $digest Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications. + * @param string $digest Prevent changes if current configuration file has a different digest. This can be used to prevent concurrent modifications. * @param string $group The HA group identifier. * @param int $max_relocate Maximal number of service relocate tries when a service failes to start. * @param int $max_restart Maximal number of tries to restart the service on a node after its start failed. @@ -2570,22 +3304,20 @@ public function read() { * @return Result */ public function update($comment = null, $delete = null, $digest = null, $group = null, $max_relocate = null, $max_restart = null, $state = null) { - $params = [ - 'comment' => $comment, + $params = ['comment' => $comment, 'delete' => $delete, 'digest' => $digest, 'group' => $group, 'max_relocate' => $max_relocate, 'max_restart' => $max_restart, - 'state' => $state - ]; + 'state' => $state]; return $this->client->set("/cluster/ha/resources/{$this->sid}", $params); } } /** * Class PVESidResourcesHaClusterMigrate - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVESidResourcesHaClusterMigrate { @@ -2620,7 +3352,7 @@ public function migrate($node) { /** * Class PVESidResourcesHaClusterRelocate - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVESidResourcesHaClusterRelocate { @@ -2655,7 +3387,7 @@ public function relocate($node) { /** * Class PVEHaClusterGroups - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEHaClusterGroups { @@ -2700,21 +3432,19 @@ public function index() { * @return Result */ public function create($group, $nodes, $comment = null, $nofailback = null, $restricted = null, $type = null) { - $params = [ - 'group' => $group, + $params = ['group' => $group, 'nodes' => $nodes, 'comment' => $comment, 'nofailback' => $nofailback, 'restricted' => $restricted, - 'type' => $type - ]; + 'type' => $type]; return $this->client->create("/cluster/ha/groups", $params); } } /** * Class PVEItemGroupsHaClusterGroup - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemGroupsHaClusterGroup { @@ -2756,28 +3486,26 @@ public function read() { * Update ha group configuration. * @param string $comment Description. * @param string $delete A list of settings you want to delete. - * @param string $digest Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications. + * @param string $digest Prevent changes if current configuration file has a different digest. This can be used to prevent concurrent modifications. * @param string $nodes List of cluster node names with optional priority. * @param bool $nofailback The CRM tries to run services on the node with the highest priority. If a node with higher priority comes online, the CRM migrates the service to that node. Enabling nofailback prevents that behavior. * @param bool $restricted Resources bound to restricted groups may only run on nodes defined by the group. * @return Result */ public function update($comment = null, $delete = null, $digest = null, $nodes = null, $nofailback = null, $restricted = null) { - $params = [ - 'comment' => $comment, + $params = ['comment' => $comment, 'delete' => $delete, 'digest' => $digest, 'nodes' => $nodes, 'nofailback' => $nofailback, - 'restricted' => $restricted - ]; + 'restricted' => $restricted]; return $this->client->set("/cluster/ha/groups/{$this->group}", $params); } } /** * Class PVEHaClusterStatus - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEHaClusterStatus { @@ -2830,7 +3558,7 @@ public function index() { /** * Class PVEStatusHaClusterCurrent - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEStatusHaClusterCurrent { @@ -2857,7 +3585,7 @@ public function status() { /** * Class PVEStatusHaClusterManagerStatus - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEStatusHaClusterManagerStatus { @@ -2884,7 +3612,7 @@ public function managerStatus() { /** * Class PVEClusterAcme - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEClusterAcme { @@ -2939,6 +3667,19 @@ public function getTos() { return $this->tos ?: ($this->tos = new PVEAcmeClusterTos($this->client)); } + /** + * @ignore + */ + private $meta; + + /** + * Get AcmeClusterMeta + * @return PVEAcmeClusterMeta + */ + public function getMeta() { + return $this->meta ?: ($this->meta = new PVEAcmeClusterMeta($this->client)); + } + /** * @ignore */ @@ -2976,7 +3717,7 @@ public function index() { /** * Class PVEAcmeClusterPlugins - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEAcmeClusterPlugins { @@ -3018,7 +3759,7 @@ public function index($type = null) { * @param string $type ACME challenge type. * Enum: dns,standalone * @param string $api API plugin name - * Enum: 1984hosting,acmedns,acmeproxy,active24,ad,ali,anx,arvan,aurora,autodns,aws,azion,azure,bunny,cf,clouddns,cloudns,cn,conoha,constellix,cpanel,curanet,cyon,da,ddnss,desec,df,dgon,dnshome,dnsimple,dnsservices,do,doapi,domeneshop,dp,dpi,dreamhost,duckdns,durabledns,dyn,dynu,dynv6,easydns,edgedns,euserv,exoscale,fornex,freedns,gandi_livedns,gcloud,gcore,gd,geoscaling,googledomains,he,hetzner,hexonet,hostingde,huaweicloud,infoblox,infomaniak,internetbs,inwx,ionos,ipv64,ispconfig,jd,joker,kappernet,kas,kinghost,knot,la,leaseweb,lexicon,linode,linode_v4,loopia,lua,maradns,me,miab,misaka,myapi,mydevil,mydnsjp,mythic_beasts,namecheap,namecom,namesilo,nanelo,nederhost,neodigit,netcup,netlify,nic,njalla,nm,nsd,nsone,nsupdate,nw,oci,one,online,openprovider,openstack,opnsense,ovh,pdns,pleskxml,pointhq,porkbun,rackcorp,rackspace,rage4,rcode0,regru,scaleway,schlundtech,selectel,selfhost,servercow,simply,tele3,transip,udr,ultra,unoeuro,variomedia,veesp,vercel,vscale,vultr,websupport,world4you,yandex,yc,zilore,zone,zonomi + * Enum: 1984hosting,acmedns,acmeproxy,active24,ad,ali,anx,artfiles,arvan,aurora,autodns,aws,azion,azure,bookmyname,bunny,cf,clouddns,cloudns,cn,conoha,constellix,cpanel,curanet,cyon,da,ddnss,desec,df,dgon,dnsexit,dnshome,dnsimple,dnsservices,do,doapi,domeneshop,dp,dpi,dreamhost,duckdns,durabledns,dyn,dynu,dynv6,easydns,edgedns,euserv,exoscale,fornex,freedns,gandi_livedns,gcloud,gcore,gd,geoscaling,googledomains,he,hetzner,hexonet,hostingde,huaweicloud,infoblox,infomaniak,internetbs,inwx,ionos,ipv64,ispconfig,jd,joker,kappernet,kas,kinghost,knot,la,leaseweb,lexicon,linode,linode_v4,loopia,lua,maradns,me,miab,misaka,myapi,mydevil,mydnsjp,mythic_beasts,namecheap,namecom,namesilo,nanelo,nederhost,neodigit,netcup,netlify,nic,njalla,nm,nsd,nsone,nsupdate,nw,oci,one,online,openprovider,openstack,opnsense,ovh,pdns,pleskxml,pointhq,porkbun,rackcorp,rackspace,rage4,rcode0,regru,scaleway,schlundtech,selectel,selfhost,servercow,simply,tele3,tencent,transip,udr,ultra,unoeuro,variomedia,veesp,vercel,vscale,vultr,websupport,world4you,yandex,yc,zilore,zone,zonomi * @param string $data DNS plugin data. (base64 encoded) * @param bool $disable Flag to disable the config. * @param string $nodes List of cluster node names. @@ -3026,22 +3767,20 @@ public function index($type = null) { * @return Result */ public function addPlugin($id, $type, $api = null, $data = null, $disable = null, $nodes = null, $validation_delay = null) { - $params = [ - 'id' => $id, + $params = ['id' => $id, 'type' => $type, 'api' => $api, 'data' => $data, 'disable' => $disable, 'nodes' => $nodes, - 'validation-delay' => $validation_delay - ]; + 'validation-delay' => $validation_delay]; return $this->client->create("/cluster/acme/plugins", $params); } } /** * Class PVEItemPluginsAcmeClusterId - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemPluginsAcmeClusterId { @@ -3082,32 +3821,30 @@ public function getPluginConfig() { /** * Update ACME plugin configuration. * @param string $api API plugin name - * Enum: 1984hosting,acmedns,acmeproxy,active24,ad,ali,anx,arvan,aurora,autodns,aws,azion,azure,bunny,cf,clouddns,cloudns,cn,conoha,constellix,cpanel,curanet,cyon,da,ddnss,desec,df,dgon,dnshome,dnsimple,dnsservices,do,doapi,domeneshop,dp,dpi,dreamhost,duckdns,durabledns,dyn,dynu,dynv6,easydns,edgedns,euserv,exoscale,fornex,freedns,gandi_livedns,gcloud,gcore,gd,geoscaling,googledomains,he,hetzner,hexonet,hostingde,huaweicloud,infoblox,infomaniak,internetbs,inwx,ionos,ipv64,ispconfig,jd,joker,kappernet,kas,kinghost,knot,la,leaseweb,lexicon,linode,linode_v4,loopia,lua,maradns,me,miab,misaka,myapi,mydevil,mydnsjp,mythic_beasts,namecheap,namecom,namesilo,nanelo,nederhost,neodigit,netcup,netlify,nic,njalla,nm,nsd,nsone,nsupdate,nw,oci,one,online,openprovider,openstack,opnsense,ovh,pdns,pleskxml,pointhq,porkbun,rackcorp,rackspace,rage4,rcode0,regru,scaleway,schlundtech,selectel,selfhost,servercow,simply,tele3,transip,udr,ultra,unoeuro,variomedia,veesp,vercel,vscale,vultr,websupport,world4you,yandex,yc,zilore,zone,zonomi + * Enum: 1984hosting,acmedns,acmeproxy,active24,ad,ali,anx,artfiles,arvan,aurora,autodns,aws,azion,azure,bookmyname,bunny,cf,clouddns,cloudns,cn,conoha,constellix,cpanel,curanet,cyon,da,ddnss,desec,df,dgon,dnsexit,dnshome,dnsimple,dnsservices,do,doapi,domeneshop,dp,dpi,dreamhost,duckdns,durabledns,dyn,dynu,dynv6,easydns,edgedns,euserv,exoscale,fornex,freedns,gandi_livedns,gcloud,gcore,gd,geoscaling,googledomains,he,hetzner,hexonet,hostingde,huaweicloud,infoblox,infomaniak,internetbs,inwx,ionos,ipv64,ispconfig,jd,joker,kappernet,kas,kinghost,knot,la,leaseweb,lexicon,linode,linode_v4,loopia,lua,maradns,me,miab,misaka,myapi,mydevil,mydnsjp,mythic_beasts,namecheap,namecom,namesilo,nanelo,nederhost,neodigit,netcup,netlify,nic,njalla,nm,nsd,nsone,nsupdate,nw,oci,one,online,openprovider,openstack,opnsense,ovh,pdns,pleskxml,pointhq,porkbun,rackcorp,rackspace,rage4,rcode0,regru,scaleway,schlundtech,selectel,selfhost,servercow,simply,tele3,tencent,transip,udr,ultra,unoeuro,variomedia,veesp,vercel,vscale,vultr,websupport,world4you,yandex,yc,zilore,zone,zonomi * @param string $data DNS plugin data. (base64 encoded) * @param string $delete A list of settings you want to delete. - * @param string $digest Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications. + * @param string $digest Prevent changes if current configuration file has a different digest. This can be used to prevent concurrent modifications. * @param bool $disable Flag to disable the config. * @param string $nodes List of cluster node names. * @param int $validation_delay Extra delay in seconds to wait before requesting validation. Allows to cope with a long TTL of DNS records. * @return Result */ public function updatePlugin($api = null, $data = null, $delete = null, $digest = null, $disable = null, $nodes = null, $validation_delay = null) { - $params = [ - 'api' => $api, + $params = ['api' => $api, 'data' => $data, 'delete' => $delete, 'digest' => $digest, 'disable' => $disable, 'nodes' => $nodes, - 'validation-delay' => $validation_delay - ]; + 'validation-delay' => $validation_delay]; return $this->client->set("/cluster/acme/plugins/{$this->id}", $params); } } /** * Class PVEAcmeClusterAccount - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEAcmeClusterAccount { @@ -3144,24 +3881,26 @@ public function accountIndex() { * Register a new ACME account with CA. * @param string $contact Contact email addresses. * @param string $directory URL of ACME CA directory endpoint. + * @param string $eab_hmac_key HMAC key for External Account Binding. + * @param string $eab_kid Key Identifier for External Account Binding. * @param string $name ACME account config file name. * @param string $tos_url URL of CA TermsOfService - setting this indicates agreement. * @return Result */ - public function registerAccount($contact, $directory = null, $name = null, $tos_url = null) { - $params = [ - 'contact' => $contact, + public function registerAccount($contact, $directory = null, $eab_hmac_key = null, $eab_kid = null, $name = null, $tos_url = null) { + $params = ['contact' => $contact, 'directory' => $directory, + 'eab-hmac-key' => $eab_hmac_key, + 'eab-kid' => $eab_kid, 'name' => $name, - 'tos_url' => $tos_url - ]; + 'tos_url' => $tos_url]; return $this->client->create("/cluster/acme/account", $params); } } /** * Class PVEItemAccountAcmeClusterName - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemAccountAcmeClusterName { @@ -3212,7 +3951,7 @@ public function updateAccount($contact = null) { /** * Class PVEAcmeClusterTos - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEAcmeClusterTos { @@ -3229,7 +3968,7 @@ function __construct($client) { } /** - * Retrieve ACME TermsOfService URL from CA. + * Retrieve ACME TermsOfService URL from CA. Deprecated, please use /cluster/acme/meta. * @param string $directory URL of ACME CA directory endpoint. * @return Result */ @@ -3239,9 +3978,38 @@ public function getTos($directory = null) { } } + /** + * Class PVEAcmeClusterMeta + * @package Corsinvest\VE\ProxmoxVE\Api + */ + class PVEAcmeClusterMeta { + + /** + * @ignore + */ + private $client; + + /** + * @ignore + */ + function __construct($client) { + $this->client = $client; + } + + /** + * Retrieve ACME Directory Meta Information + * @param string $directory URL of ACME CA directory endpoint. + * @return Result + */ + public function getMeta($directory = null) { + $params = ['directory' => $directory]; + return $this->client->get("/cluster/acme/meta", $params); + } + } + /** * Class PVEAcmeClusterDirectories - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEAcmeClusterDirectories { @@ -3268,7 +4036,7 @@ public function getDirectories() { /** * Class PVEAcmeClusterChallengeSchema - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEAcmeClusterChallengeSchema { @@ -3295,7 +4063,7 @@ public function challengeschema() { /** * Class PVEClusterCeph - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEClusterCeph { @@ -3361,7 +4129,7 @@ public function cephindex() { /** * Class PVECephClusterMetadata - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVECephClusterMetadata { @@ -3379,7 +4147,7 @@ function __construct($client) { /** * Get ceph metadata. - * @param string $scope + * @param string $scope * Enum: all,versions * @return Result */ @@ -3391,7 +4159,7 @@ public function metadata($scope = null) { /** * Class PVECephClusterStatus - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVECephClusterStatus { @@ -3418,7 +4186,7 @@ public function status() { /** * Class PVECephClusterFlags - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVECephClusterFlags { @@ -3467,8 +4235,7 @@ public function getAllFlags() { * @return Result */ public function setFlags($nobackfill = null, $nodeep_scrub = null, $nodown = null, $noin = null, $noout = null, $norebalance = null, $norecover = null, $noscrub = null, $notieragent = null, $noup = null, $pause = null) { - $params = [ - 'nobackfill' => $nobackfill, + $params = ['nobackfill' => $nobackfill, 'nodeep-scrub' => $nodeep_scrub, 'nodown' => $nodown, 'noin' => $noin, @@ -3478,15 +4245,14 @@ public function setFlags($nobackfill = null, $nodeep_scrub = null, $nodown = nul 'noscrub' => $noscrub, 'notieragent' => $notieragent, 'noup' => $noup, - 'pause' => $pause - ]; + 'pause' => $pause]; return $this->client->set("/cluster/ceph/flags", $params); } } /** * Class PVEItemFlagsCephClusterFlag - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemFlagsCephClusterFlag { @@ -3529,7 +4295,7 @@ public function updateFlag($value) { /** * Class PVEClusterJobs - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEClusterJobs { @@ -3582,7 +4348,7 @@ public function index() { /** * Class PVEJobsClusterRealmSync - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEJobsClusterRealmSync { @@ -3618,7 +4384,7 @@ public function syncjobIndex() { /** * Class PVEItemRealmSyncJobsClusterId - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemRealmSyncJobsClusterId { @@ -3669,15 +4435,13 @@ public function readJob() { * @return Result */ public function createJob($schedule, $comment = null, $enable_new = null, $enabled = null, $realm = null, $remove_vanished = null, $scope = null) { - $params = [ - 'schedule' => $schedule, + $params = ['schedule' => $schedule, 'comment' => $comment, 'enable-new' => $enable_new, 'enabled' => $enabled, 'realm' => $realm, 'remove-vanished' => $remove_vanished, - 'scope' => $scope - ]; + 'scope' => $scope]; return $this->client->create("/cluster/jobs/realm-sync/{$this->id}", $params); } @@ -3694,22 +4458,20 @@ public function createJob($schedule, $comment = null, $enable_new = null, $enabl * @return Result */ public function updateJob($schedule, $comment = null, $delete = null, $enable_new = null, $enabled = null, $remove_vanished = null, $scope = null) { - $params = [ - 'schedule' => $schedule, + $params = ['schedule' => $schedule, 'comment' => $comment, 'delete' => $delete, 'enable-new' => $enable_new, 'enabled' => $enabled, 'remove-vanished' => $remove_vanished, - 'scope' => $scope - ]; + 'scope' => $scope]; return $this->client->set("/cluster/jobs/realm-sync/{$this->id}", $params); } } /** * Class PVEJobsClusterScheduleAnalyze - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEJobsClusterScheduleAnalyze { @@ -3733,18 +4495,16 @@ function __construct($client) { * @return Result */ public function scheduleAnalyze($schedule, $iterations = null, $starttime = null) { - $params = [ - 'schedule' => $schedule, + $params = ['schedule' => $schedule, 'iterations' => $iterations, - 'starttime' => $starttime - ]; + 'starttime' => $starttime]; return $this->client->get("/cluster/jobs/schedule-analyze", $params); } } /** * Class PVEClusterMapping - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEClusterMapping { @@ -3797,7 +4557,7 @@ public function index() { /** * Class PVEMappingClusterPci - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEMappingClusterPci { @@ -3837,23 +4597,21 @@ public function index($check_node = null) { * @param string $id The ID of the logical PCI mapping. * @param string $map A list of maps for the cluster nodes. * @param string $description Description of the logical PCI device. - * @param bool $mdev + * @param bool $mdev * @return Result */ public function create($id, $map, $description = null, $mdev = null) { - $params = [ - 'id' => $id, + $params = ['id' => $id, 'map' => $map, 'description' => $description, - 'mdev' => $mdev - ]; + 'mdev' => $mdev]; return $this->client->create("/cluster/mapping/pci", $params); } } /** * Class PVEItemPciMappingClusterId - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemPciMappingClusterId { @@ -3895,26 +4653,24 @@ public function get() { * Update a hardware mapping. * @param string $delete A list of settings you want to delete. * @param string $description Description of the logical PCI device. - * @param string $digest Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications. + * @param string $digest Prevent changes if current configuration file has a different digest. This can be used to prevent concurrent modifications. * @param string $map A list of maps for the cluster nodes. - * @param bool $mdev + * @param bool $mdev * @return Result */ public function update($delete = null, $description = null, $digest = null, $map = null, $mdev = null) { - $params = [ - 'delete' => $delete, + $params = ['delete' => $delete, 'description' => $description, 'digest' => $digest, 'map' => $map, - 'mdev' => $mdev - ]; + 'mdev' => $mdev]; return $this->client->set("/cluster/mapping/pci/{$this->id}", $params); } } /** * Class PVEMappingClusterUsb - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEMappingClusterUsb { @@ -3951,24 +4707,22 @@ public function index($check_node = null) { /** * Create a new hardware mapping. - * @param string $id The ID of the logical PCI mapping. + * @param string $id The ID of the logical USB mapping. * @param string $map A list of maps for the cluster nodes. - * @param string $description Description of the logical PCI device. + * @param string $description Description of the logical USB device. * @return Result */ public function create($id, $map, $description = null) { - $params = [ - 'id' => $id, + $params = ['id' => $id, 'map' => $map, - 'description' => $description - ]; + 'description' => $description]; return $this->client->create("/cluster/mapping/usb", $params); } } /** * Class PVEItemUsbMappingClusterId - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemUsbMappingClusterId { @@ -4010,24 +4764,22 @@ public function get() { * Update a hardware mapping. * @param string $map A list of maps for the cluster nodes. * @param string $delete A list of settings you want to delete. - * @param string $description Description of the logical PCI device. - * @param string $digest Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications. + * @param string $description Description of the logical USB device. + * @param string $digest Prevent changes if current configuration file has a different digest. This can be used to prevent concurrent modifications. * @return Result */ public function update($map, $delete = null, $description = null, $digest = null) { - $params = [ - 'map' => $map, + $params = ['map' => $map, 'delete' => $delete, 'description' => $description, - 'digest' => $digest - ]; + 'digest' => $digest]; return $this->client->set("/cluster/mapping/usb/{$this->id}", $params); } } /** * Class PVEClusterSdn - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEClusterSdn { @@ -4127,7 +4879,7 @@ public function reload() { /** * Class PVESdnClusterVnets - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVESdnClusterVnets { @@ -4159,10 +4911,8 @@ public function get($vnet) { * @return Result */ public function index($pending = null, $running = null) { - $params = [ - 'pending' => $pending, - 'running' => $running - ]; + $params = ['pending' => $pending, + 'running' => $running]; return $this->client->get("/cluster/sdn/vnets", $params); } @@ -4178,21 +4928,19 @@ public function index($pending = null, $running = null) { * @return Result */ public function create($vnet, $zone, $alias = null, $tag = null, $type = null, $vlanaware = null) { - $params = [ - 'vnet' => $vnet, + $params = ['vnet' => $vnet, 'zone' => $zone, 'alias' => $alias, 'tag' => $tag, 'type' => $type, - 'vlanaware' => $vlanaware - ]; + 'vlanaware' => $vlanaware]; return $this->client->create("/cluster/sdn/vnets", $params); } } /** * Class PVEItemVnetsSdnClusterVnet - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemVnetsSdnClusterVnet { @@ -4227,6 +4975,19 @@ public function getSubnets() { return $this->subnets ?: ($this->subnets = new PVEVnetVnetsSdnClusterSubnets($this->client, $this->vnet)); } + /** + * @ignore + */ + private $ips; + + /** + * Get VnetVnetsSdnClusterIps + * @return PVEVnetVnetsSdnClusterIps + */ + public function getIps() { + return $this->ips ?: ($this->ips = new PVEVnetVnetsSdnClusterIps($this->client, $this->vnet)); + } + /** * Delete sdn vnet object configuration. * @return Result @@ -4242,10 +5003,8 @@ public function delete() { * @return Result */ public function read($pending = null, $running = null) { - $params = [ - 'pending' => $pending, - 'running' => $running - ]; + $params = ['pending' => $pending, + 'running' => $running]; return $this->client->get("/cluster/sdn/vnets/{$this->vnet}", $params); } @@ -4253,28 +5012,26 @@ public function read($pending = null, $running = null) { * Update sdn vnet object configuration. * @param string $alias alias name of the vnet * @param string $delete A list of settings you want to delete. - * @param string $digest Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications. + * @param string $digest Prevent changes if current configuration file has a different digest. This can be used to prevent concurrent modifications. * @param int $tag vlan or vxlan id * @param bool $vlanaware Allow vm VLANs to pass through this vnet. * @param string $zone zone id * @return Result */ public function update($alias = null, $delete = null, $digest = null, $tag = null, $vlanaware = null, $zone = null) { - $params = [ - 'alias' => $alias, + $params = ['alias' => $alias, 'delete' => $delete, 'digest' => $digest, 'tag' => $tag, 'vlanaware' => $vlanaware, - 'zone' => $zone - ]; + 'zone' => $zone]; return $this->client->set("/cluster/sdn/vnets/{$this->vnet}", $params); } } /** * Class PVEVnetVnetsSdnClusterSubnets - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEVnetVnetsSdnClusterSubnets { @@ -4312,38 +5069,38 @@ public function get($subnet) { * @return Result */ public function index($pending = null, $running = null) { - $params = [ - 'pending' => $pending, - 'running' => $running - ]; + $params = ['pending' => $pending, + 'running' => $running]; return $this->client->get("/cluster/sdn/vnets/{$this->vnet}/subnets", $params); } /** * Create a new sdn subnet object. * @param string $subnet The SDN subnet object identifier. - * @param string $type + * @param string $type * Enum: subnet + * @param string $dhcp_dns_server IP address for the DNS server + * @param string $dhcp_range A list of DHCP ranges for this subnet * @param string $dnszoneprefix dns domain zone prefix ex: 'adm' -> <hostname>.adm.mydomain.com * @param string $gateway Subnet Gateway: Will be assign on vnet for layer3 zones * @param bool $snat enable masquerade for this subnet if pve-firewall * @return Result */ - public function create($subnet, $type, $dnszoneprefix = null, $gateway = null, $snat = null) { - $params = [ - 'subnet' => $subnet, + public function create($subnet, $type, $dhcp_dns_server = null, $dhcp_range = null, $dnszoneprefix = null, $gateway = null, $snat = null) { + $params = ['subnet' => $subnet, 'type' => $type, + 'dhcp-dns-server' => $dhcp_dns_server, + 'dhcp-range' => $dhcp_range, 'dnszoneprefix' => $dnszoneprefix, 'gateway' => $gateway, - 'snat' => $snat - ]; + 'snat' => $snat]; return $this->client->create("/cluster/sdn/vnets/{$this->vnet}/subnets", $params); } } /** * Class PVEItemSubnetsVnetVnetsSdnClusterSubnet - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemSubnetsVnetVnetsSdnClusterSubnet { @@ -4386,37 +5143,106 @@ public function delete() { * @return Result */ public function read($pending = null, $running = null) { - $params = [ - 'pending' => $pending, - 'running' => $running - ]; + $params = ['pending' => $pending, + 'running' => $running]; return $this->client->get("/cluster/sdn/vnets/{$this->vnet}/subnets/{$this->subnet}", $params); } /** * Update sdn subnet object configuration. * @param string $delete A list of settings you want to delete. - * @param string $digest Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications. + * @param string $dhcp_dns_server IP address for the DNS server + * @param string $dhcp_range A list of DHCP ranges for this subnet + * @param string $digest Prevent changes if current configuration file has a different digest. This can be used to prevent concurrent modifications. * @param string $dnszoneprefix dns domain zone prefix ex: 'adm' -> <hostname>.adm.mydomain.com * @param string $gateway Subnet Gateway: Will be assign on vnet for layer3 zones * @param bool $snat enable masquerade for this subnet if pve-firewall * @return Result */ - public function update($delete = null, $digest = null, $dnszoneprefix = null, $gateway = null, $snat = null) { - $params = [ - 'delete' => $delete, + public function update($delete = null, $dhcp_dns_server = null, $dhcp_range = null, $digest = null, $dnszoneprefix = null, $gateway = null, $snat = null) { + $params = ['delete' => $delete, + 'dhcp-dns-server' => $dhcp_dns_server, + 'dhcp-range' => $dhcp_range, 'digest' => $digest, 'dnszoneprefix' => $dnszoneprefix, 'gateway' => $gateway, - 'snat' => $snat - ]; + 'snat' => $snat]; return $this->client->set("/cluster/sdn/vnets/{$this->vnet}/subnets/{$this->subnet}", $params); } } + /** + * Class PVEVnetVnetsSdnClusterIps + * @package Corsinvest\VE\ProxmoxVE\Api + */ + class PVEVnetVnetsSdnClusterIps { + + /** + * @ignore + */ + private $vnet; + + /** + * @ignore + */ + private $client; + + /** + * @ignore + */ + function __construct($client, $vnet) { + $this->client = $client; + $this->vnet = $vnet; + } + + /** + * Delete IP Mappings in a VNet + * @param string $ip The IP address to delete + * @param string $zone The SDN zone object identifier. + * @param string $mac Unicast MAC address. + * @return Result + */ + public function ipdelete($ip, $zone, $mac = null) { + $params = ['ip' => $ip, + 'zone' => $zone, + 'mac' => $mac]; + return $this->client->delete("/cluster/sdn/vnets/{$this->vnet}/ips", $params); + } + + /** + * Create IP Mapping in a VNet + * @param string $ip The IP address to associate with the given MAC address + * @param string $zone The SDN zone object identifier. + * @param string $mac Unicast MAC address. + * @return Result + */ + public function ipcreate($ip, $zone, $mac = null) { + $params = ['ip' => $ip, + 'zone' => $zone, + 'mac' => $mac]; + return $this->client->create("/cluster/sdn/vnets/{$this->vnet}/ips", $params); + } + + /** + * Update IP Mapping in a VNet + * @param string $ip The IP address to associate with the given MAC address + * @param string $zone The SDN zone object identifier. + * @param string $mac Unicast MAC address. + * @param int $vmid The (unique) ID of the VM. + * @return Result + */ + public function ipupdate($ip, $zone, $mac = null, $vmid = null) { + $params = ['ip' => $ip, + 'zone' => $zone, + 'mac' => $mac, + 'vmid' => $vmid]; + return $this->client->set("/cluster/sdn/vnets/{$this->vnet}/ips", $params); + } + } + /** * Class PVESdnClusterZones - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVESdnClusterZones { @@ -4450,11 +5276,9 @@ public function get($zone) { * @return Result */ public function index($pending = null, $running = null, $type = null) { - $params = [ - 'pending' => $pending, + $params = ['pending' => $pending, 'running' => $running, - 'type' => $type - ]; + 'type' => $type]; return $this->client->get("/cluster/sdn/zones", $params); } @@ -4464,9 +5288,11 @@ public function index($pending = null, $running = null, $type = null) { * Enum: evpn,faucet,qinq,simple,vlan,vxlan * @param string $zone The SDN zone object identifier. * @param bool $advertise_subnets Advertise evpn subnets if you have silent hosts - * @param string $bridge + * @param string $bridge * @param bool $bridge_disable_mac_learning Disable auto mac learning. * @param string $controller Frr router name + * @param string $dhcp Type of the DHCP backend for this zone + * Enum: dnsmasq * @param bool $disable_arp_nd_suppression Disable ipv4 arp && ipv6 neighbour discovery suppression * @param string $dns dns api server * @param string $dnszone dns domain zone ex: mydomain.com @@ -4482,20 +5308,20 @@ public function index($pending = null, $running = null, $type = null) { * @param string $reversedns reverse dns api server * @param string $rt_import Route-Target import * @param int $tag Service-VLAN Tag - * @param string $vlan_protocol + * @param string $vlan_protocol * Enum: 802.1q,802.1ad * @param int $vrf_vxlan l3vni. * @param int $vxlan_port Vxlan tunnel udp port (default 4789). * @return Result */ - public function create($type, $zone, $advertise_subnets = null, $bridge = null, $bridge_disable_mac_learning = null, $controller = null, $disable_arp_nd_suppression = null, $dns = null, $dnszone = null, $dp_id = null, $exitnodes = null, $exitnodes_local_routing = null, $exitnodes_primary = null, $ipam = null, $mac = null, $mtu = null, $nodes = null, $peers = null, $reversedns = null, $rt_import = null, $tag = null, $vlan_protocol = null, $vrf_vxlan = null, $vxlan_port = null) { - $params = [ - 'type' => $type, + public function create($type, $zone, $advertise_subnets = null, $bridge = null, $bridge_disable_mac_learning = null, $controller = null, $dhcp = null, $disable_arp_nd_suppression = null, $dns = null, $dnszone = null, $dp_id = null, $exitnodes = null, $exitnodes_local_routing = null, $exitnodes_primary = null, $ipam = null, $mac = null, $mtu = null, $nodes = null, $peers = null, $reversedns = null, $rt_import = null, $tag = null, $vlan_protocol = null, $vrf_vxlan = null, $vxlan_port = null) { + $params = ['type' => $type, 'zone' => $zone, 'advertise-subnets' => $advertise_subnets, 'bridge' => $bridge, 'bridge-disable-mac-learning' => $bridge_disable_mac_learning, 'controller' => $controller, + 'dhcp' => $dhcp, 'disable-arp-nd-suppression' => $disable_arp_nd_suppression, 'dns' => $dns, 'dnszone' => $dnszone, @@ -4513,15 +5339,14 @@ public function create($type, $zone, $advertise_subnets = null, $bridge = null, 'tag' => $tag, 'vlan-protocol' => $vlan_protocol, 'vrf-vxlan' => $vrf_vxlan, - 'vxlan-port' => $vxlan_port - ]; + 'vxlan-port' => $vxlan_port]; return $this->client->create("/cluster/sdn/zones", $params); } } /** * Class PVEItemZonesSdnClusterZone - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemZonesSdnClusterZone { @@ -4558,21 +5383,21 @@ public function delete() { * @return Result */ public function read($pending = null, $running = null) { - $params = [ - 'pending' => $pending, - 'running' => $running - ]; + $params = ['pending' => $pending, + 'running' => $running]; return $this->client->get("/cluster/sdn/zones/{$this->zone}", $params); } /** * Update sdn zone object configuration. * @param bool $advertise_subnets Advertise evpn subnets if you have silent hosts - * @param string $bridge + * @param string $bridge * @param bool $bridge_disable_mac_learning Disable auto mac learning. * @param string $controller Frr router name * @param string $delete A list of settings you want to delete. - * @param string $digest Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications. + * @param string $dhcp Type of the DHCP backend for this zone + * Enum: dnsmasq + * @param string $digest Prevent changes if current configuration file has a different digest. This can be used to prevent concurrent modifications. * @param bool $disable_arp_nd_suppression Disable ipv4 arp && ipv6 neighbour discovery suppression * @param string $dns dns api server * @param string $dnszone dns domain zone ex: mydomain.com @@ -4588,19 +5413,19 @@ public function read($pending = null, $running = null) { * @param string $reversedns reverse dns api server * @param string $rt_import Route-Target import * @param int $tag Service-VLAN Tag - * @param string $vlan_protocol + * @param string $vlan_protocol * Enum: 802.1q,802.1ad * @param int $vrf_vxlan l3vni. * @param int $vxlan_port Vxlan tunnel udp port (default 4789). * @return Result */ - public function update($advertise_subnets = null, $bridge = null, $bridge_disable_mac_learning = null, $controller = null, $delete = null, $digest = null, $disable_arp_nd_suppression = null, $dns = null, $dnszone = null, $dp_id = null, $exitnodes = null, $exitnodes_local_routing = null, $exitnodes_primary = null, $ipam = null, $mac = null, $mtu = null, $nodes = null, $peers = null, $reversedns = null, $rt_import = null, $tag = null, $vlan_protocol = null, $vrf_vxlan = null, $vxlan_port = null) { - $params = [ - 'advertise-subnets' => $advertise_subnets, + public function update($advertise_subnets = null, $bridge = null, $bridge_disable_mac_learning = null, $controller = null, $delete = null, $dhcp = null, $digest = null, $disable_arp_nd_suppression = null, $dns = null, $dnszone = null, $dp_id = null, $exitnodes = null, $exitnodes_local_routing = null, $exitnodes_primary = null, $ipam = null, $mac = null, $mtu = null, $nodes = null, $peers = null, $reversedns = null, $rt_import = null, $tag = null, $vlan_protocol = null, $vrf_vxlan = null, $vxlan_port = null) { + $params = ['advertise-subnets' => $advertise_subnets, 'bridge' => $bridge, 'bridge-disable-mac-learning' => $bridge_disable_mac_learning, 'controller' => $controller, 'delete' => $delete, + 'dhcp' => $dhcp, 'digest' => $digest, 'disable-arp-nd-suppression' => $disable_arp_nd_suppression, 'dns' => $dns, @@ -4619,15 +5444,14 @@ public function update($advertise_subnets = null, $bridge = null, $bridge_disabl 'tag' => $tag, 'vlan-protocol' => $vlan_protocol, 'vrf-vxlan' => $vrf_vxlan, - 'vxlan-port' => $vxlan_port - ]; + 'vxlan-port' => $vxlan_port]; return $this->client->set("/cluster/sdn/zones/{$this->zone}", $params); } } /** * Class PVESdnClusterControllers - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVESdnClusterControllers { @@ -4657,15 +5481,13 @@ public function get($controller) { * @param bool $pending Display pending config. * @param bool $running Display running config. * @param string $type Only list sdn controllers of specific type - * Enum: bgp,evpn,faucet + * Enum: bgp,evpn,faucet,isis * @return Result */ public function index($pending = null, $running = null, $type = null) { - $params = [ - 'pending' => $pending, + $params = ['pending' => $pending, 'running' => $running, - 'type' => $type - ]; + 'type' => $type]; return $this->client->get("/cluster/sdn/controllers", $params); } @@ -4673,35 +5495,39 @@ public function index($pending = null, $running = null, $type = null) { * Create a new sdn controller object. * @param string $controller The SDN controller object identifier. * @param string $type Plugin type. - * Enum: bgp,evpn,faucet + * Enum: bgp,evpn,faucet,isis * @param int $asn autonomous system number - * @param bool $bgp_multipath_as_path_relax + * @param bool $bgp_multipath_as_path_relax * @param bool $ebgp Enable ebgp. (remote-as external) - * @param int $ebgp_multihop + * @param int $ebgp_multihop + * @param string $isis_domain ISIS domain. + * @param string $isis_ifaces ISIS interface. + * @param string $isis_net ISIS network entity title. * @param string $loopback source loopback interface. * @param string $node The cluster node name. * @param string $peers peers address list. * @return Result */ - public function create($controller, $type, $asn = null, $bgp_multipath_as_path_relax = null, $ebgp = null, $ebgp_multihop = null, $loopback = null, $node = null, $peers = null) { - $params = [ - 'controller' => $controller, + public function create($controller, $type, $asn = null, $bgp_multipath_as_path_relax = null, $ebgp = null, $ebgp_multihop = null, $isis_domain = null, $isis_ifaces = null, $isis_net = null, $loopback = null, $node = null, $peers = null) { + $params = ['controller' => $controller, 'type' => $type, 'asn' => $asn, 'bgp-multipath-as-path-relax' => $bgp_multipath_as_path_relax, 'ebgp' => $ebgp, 'ebgp-multihop' => $ebgp_multihop, + 'isis-domain' => $isis_domain, + 'isis-ifaces' => $isis_ifaces, + 'isis-net' => $isis_net, 'loopback' => $loopback, 'node' => $node, - 'peers' => $peers - ]; + 'peers' => $peers]; return $this->client->create("/cluster/sdn/controllers", $params); } } /** * Class PVEItemControllersSdnClusterController - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemControllersSdnClusterController { @@ -4738,45 +5564,47 @@ public function delete() { * @return Result */ public function read($pending = null, $running = null) { - $params = [ - 'pending' => $pending, - 'running' => $running - ]; + $params = ['pending' => $pending, + 'running' => $running]; return $this->client->get("/cluster/sdn/controllers/{$this->controller}", $params); } /** * Update sdn controller object configuration. * @param int $asn autonomous system number - * @param bool $bgp_multipath_as_path_relax + * @param bool $bgp_multipath_as_path_relax * @param string $delete A list of settings you want to delete. - * @param string $digest Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications. + * @param string $digest Prevent changes if current configuration file has a different digest. This can be used to prevent concurrent modifications. * @param bool $ebgp Enable ebgp. (remote-as external) - * @param int $ebgp_multihop + * @param int $ebgp_multihop + * @param string $isis_domain ISIS domain. + * @param string $isis_ifaces ISIS interface. + * @param string $isis_net ISIS network entity title. * @param string $loopback source loopback interface. * @param string $node The cluster node name. * @param string $peers peers address list. * @return Result */ - public function update($asn = null, $bgp_multipath_as_path_relax = null, $delete = null, $digest = null, $ebgp = null, $ebgp_multihop = null, $loopback = null, $node = null, $peers = null) { - $params = [ - 'asn' => $asn, + public function update($asn = null, $bgp_multipath_as_path_relax = null, $delete = null, $digest = null, $ebgp = null, $ebgp_multihop = null, $isis_domain = null, $isis_ifaces = null, $isis_net = null, $loopback = null, $node = null, $peers = null) { + $params = ['asn' => $asn, 'bgp-multipath-as-path-relax' => $bgp_multipath_as_path_relax, 'delete' => $delete, 'digest' => $digest, 'ebgp' => $ebgp, 'ebgp-multihop' => $ebgp_multihop, + 'isis-domain' => $isis_domain, + 'isis-ifaces' => $isis_ifaces, + 'isis-net' => $isis_net, 'loopback' => $loopback, 'node' => $node, - 'peers' => $peers - ]; + 'peers' => $peers]; return $this->client->set("/cluster/sdn/controllers/{$this->controller}", $params); } } /** * Class PVESdnClusterIpams - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVESdnClusterIpams { @@ -4817,26 +5645,24 @@ public function index($type = null) { * @param string $ipam The SDN ipam object identifier. * @param string $type Plugin type. * Enum: netbox,phpipam,pve - * @param int $section - * @param string $token - * @param string $url + * @param int $section + * @param string $token + * @param string $url * @return Result */ public function create($ipam, $type, $section = null, $token = null, $url = null) { - $params = [ - 'ipam' => $ipam, + $params = ['ipam' => $ipam, 'type' => $type, 'section' => $section, 'token' => $token, - 'url' => $url - ]; + 'url' => $url]; return $this->client->create("/cluster/sdn/ipams", $params); } } /** * Class PVEItemIpamsSdnClusterIpam - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemIpamsSdnClusterIpam { @@ -4858,6 +5684,19 @@ function __construct($client, $ipam) { $this->ipam = $ipam; } + /** + * @ignore + */ + private $status; + + /** + * Get IpamIpamsSdnClusterStatus + * @return PVEIpamIpamsSdnClusterStatus + */ + public function getStatus() { + return $this->status ?: ($this->status = new PVEIpamIpamsSdnClusterStatus($this->client, $this->ipam)); + } + /** * Delete sdn ipam object configuration. * @return Result @@ -4870,34 +5709,65 @@ public function delete() { * Read sdn ipam configuration. * @return Result */ - public function read() { - return $this->client->get("/cluster/sdn/ipams/{$this->ipam}"); + public function read() { + return $this->client->get("/cluster/sdn/ipams/{$this->ipam}"); + } + + /** + * Update sdn ipam object configuration. + * @param string $delete A list of settings you want to delete. + * @param string $digest Prevent changes if current configuration file has a different digest. This can be used to prevent concurrent modifications. + * @param int $section + * @param string $token + * @param string $url + * @return Result + */ + public function update($delete = null, $digest = null, $section = null, $token = null, $url = null) { + $params = ['delete' => $delete, + 'digest' => $digest, + 'section' => $section, + 'token' => $token, + 'url' => $url]; + return $this->client->set("/cluster/sdn/ipams/{$this->ipam}", $params); + } + } + + /** + * Class PVEIpamIpamsSdnClusterStatus + * @package Corsinvest\VE\ProxmoxVE\Api + */ + class PVEIpamIpamsSdnClusterStatus { + + /** + * @ignore + */ + private $ipam; + + /** + * @ignore + */ + private $client; + + /** + * @ignore + */ + function __construct($client, $ipam) { + $this->client = $client; + $this->ipam = $ipam; } /** - * Update sdn ipam object configuration. - * @param string $delete A list of settings you want to delete. - * @param string $digest Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications. - * @param int $section - * @param string $token - * @param string $url + * List PVE IPAM Entries * @return Result */ - public function update($delete = null, $digest = null, $section = null, $token = null, $url = null) { - $params = [ - 'delete' => $delete, - 'digest' => $digest, - 'section' => $section, - 'token' => $token, - 'url' => $url - ]; - return $this->client->set("/cluster/sdn/ipams/{$this->ipam}", $params); + public function ipamindex() { + return $this->client->get("/cluster/sdn/ipams/{$this->ipam}/status"); } } /** * Class PVESdnClusterDns - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVESdnClusterDns { @@ -4936,32 +5806,30 @@ public function index($type = null) { /** * Create a new sdn dns object. * @param string $dns The SDN dns object identifier. - * @param string $key + * @param string $key * @param string $type Plugin type. * Enum: powerdns - * @param string $url - * @param int $reversemaskv6 - * @param int $reversev6mask - * @param int $ttl + * @param string $url + * @param int $reversemaskv6 + * @param int $reversev6mask + * @param int $ttl * @return Result */ public function create($dns, $key, $type, $url, $reversemaskv6 = null, $reversev6mask = null, $ttl = null) { - $params = [ - 'dns' => $dns, + $params = ['dns' => $dns, 'key' => $key, 'type' => $type, 'url' => $url, 'reversemaskv6' => $reversemaskv6, 'reversev6mask' => $reversev6mask, - 'ttl' => $ttl - ]; + 'ttl' => $ttl]; return $this->client->create("/cluster/sdn/dns", $params); } } /** * Class PVEItemDnsSdnClusterDns - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemDnsSdnClusterDns { @@ -5002,29 +5870,27 @@ public function read() { /** * Update sdn dns object configuration. * @param string $delete A list of settings you want to delete. - * @param string $digest Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications. - * @param string $key - * @param int $reversemaskv6 - * @param int $ttl - * @param string $url + * @param string $digest Prevent changes if current configuration file has a different digest. This can be used to prevent concurrent modifications. + * @param string $key + * @param int $reversemaskv6 + * @param int $ttl + * @param string $url * @return Result */ public function update($delete = null, $digest = null, $key = null, $reversemaskv6 = null, $ttl = null, $url = null) { - $params = [ - 'delete' => $delete, + $params = ['delete' => $delete, 'digest' => $digest, 'key' => $key, 'reversemaskv6' => $reversemaskv6, 'ttl' => $ttl, - 'url' => $url - ]; + 'url' => $url]; return $this->client->set("/cluster/sdn/dns/{$this->dns}", $params); } } /** * Class PVEClusterLog - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEClusterLog { @@ -5053,7 +5919,7 @@ public function log($max = null) { /** * Class PVEClusterResources - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEClusterResources { @@ -5071,7 +5937,7 @@ function __construct($client) { /** * Resources index (cluster wide). - * @param string $type + * @param string $type * Enum: vm,storage,node,sdn * @return Result */ @@ -5083,7 +5949,7 @@ public function resources($type = null) { /** * Class PVEClusterTasks - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEClusterTasks { @@ -5110,7 +5976,7 @@ public function tasks() { /** * Class PVEClusterOptions - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEClusterOptions { @@ -5150,8 +6016,8 @@ public function getOptions() { * @param string $keyboard Default keybord layout for vnc server. * Enum: de,de-ch,da,en-gb,en-us,es,fi,fr,fr-be,fr-ca,fr-ch,hu,is,it,ja,lt,mk,nl,no,pl,pt,pt-br,sv,sl,tr * @param string $language Default GUI language. - * Enum: ca,da,de,en,es,eu,fa,fr,he,it,ja,nb,nn,pl,pt_BR,ru,sl,sv,tr,zh_CN,zh_TW - * @param string $mac_prefix Prefix for autogenerated MAC addresses. + * Enum: ar,ca,da,de,en,es,eu,fa,fr,hr,he,it,ja,ka,kr,nb,nl,nn,pl,pt_BR,ru,sl,sv,tr,ukr,zh_CN,zh_TW + * @param string $mac_prefix Prefix for the auto-generated MAC addresses of virtual guests. The default 'BC:24:11' is the OUI assigned by the IEEE to Proxmox Server Solutions GmbH for a 24-bit large MAC block. You're allowed to use this in local networks, i.e., those not directly reachable by the public (e.g., in a LAN or behind NAT). * @param int $max_workers Defines how many workers (per node) are maximal started on actions like 'stopall VMs' or task from the ha-manager. * @param string $migration For cluster wide migration settings. * @param bool $migration_unsecure Migration is secure using SSH tunnel by default. For secure private networks you can disable it to speed up migration. Deprecated, use the 'migration' property instead! @@ -5165,8 +6031,7 @@ public function getOptions() { * @return Result */ public function setOptions($bwlimit = null, $console = null, $crs = null, $delete = null, $description = null, $email_from = null, $fencing = null, $ha = null, $http_proxy = null, $keyboard = null, $language = null, $mac_prefix = null, $max_workers = null, $migration = null, $migration_unsecure = null, $next_id = null, $notify = null, $registered_tags = null, $tag_style = null, $u2f = null, $user_tag_access = null, $webauthn = null) { - $params = [ - 'bwlimit' => $bwlimit, + $params = ['bwlimit' => $bwlimit, 'console' => $console, 'crs' => $crs, 'delete' => $delete, @@ -5187,15 +6052,14 @@ public function setOptions($bwlimit = null, $console = null, $crs = null, $delet 'tag-style' => $tag_style, 'u2f' => $u2f, 'user-tag-access' => $user_tag_access, - 'webauthn' => $webauthn - ]; + 'webauthn' => $webauthn]; return $this->client->set("/cluster/options", $params); } } /** * Class PVEClusterStatus - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEClusterStatus { @@ -5222,7 +6086,7 @@ public function getStatus() { /** * Class PVEClusterNextid - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEClusterNextid { @@ -5251,7 +6115,7 @@ public function nextid($vmid = null) { /** * Class PVENodes - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVENodes { @@ -5287,7 +6151,7 @@ public function index() { /** * Class PVEItemNodesNode - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemNodesNode { @@ -5816,6 +6680,19 @@ public function getStopall() { return $this->stopall ?: ($this->stopall = new PVENodeNodesStopall($this->client, $this->node)); } + /** + * @ignore + */ + private $suspendall; + + /** + * Get NodeNodesSuspendall + * @return PVENodeNodesSuspendall + */ + public function getSuspendall() { + return $this->suspendall ?: ($this->suspendall = new PVENodeNodesSuspendall($this->client, $this->node)); + } + /** * @ignore */ @@ -5853,7 +6730,7 @@ public function index() { /** * Class PVENodeNodesQemu - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVENodeNodesQemu { @@ -5933,7 +6810,7 @@ public function vmlist($full = null) { * @param string $hugepages Enable/disable hugepages memory. * Enum: any,2,1024 * @param array $ideN Use volume as IDE hard disk or CD-ROM (n is 0 to 3). Use the special syntax STORAGE_ID:SIZE_IN_GiB to allocate a new volume. Use STORAGE_ID:0 and the 'import-from' parameter to import from an existing volume. - * @param array $ipconfigN cloud-init: Specify IP addresses and gateways for the corresponding interface. IP addresses use CIDR notation, gateways are optional but need an IP of the same type specified. The special string 'dhcp' can be used for IP addresses to use DHCP, in which case no explicit gateway should be provided. For IPv6 the special string 'auto' can be used to use stateless autoconfiguration. This requires cloud-init 19.4 or newer. If cloud-init is enabled and neither an IPv4 nor an IPv6 address is specified, it defaults to using dhcp on IPv4. + * @param array $ipconfigN cloud-init: Specify IP addresses and gateways for the corresponding interface. IP addresses use CIDR notation, gateways are optional but need an IP of the same type specified. The special string 'dhcp' can be used for IP addresses to use DHCP, in which case no explicit gateway should be provided. For IPv6 the special string 'auto' can be used to use stateless autoconfiguration. This requires cloud-init 19.4 or newer. If cloud-init is enabled and neither an IPv4 nor an IPv6 address is specified, it defaults to using dhcp on IPv4. * @param string $ivshmem Inter-VM shared memory. Useful for direct communication between VMs, or to the host. * @param bool $keephugepages Use together with hugepages. If enabled, hugepages will not not be deleted after VM shutdown and can be used for subsequent starts. * @param string $keyboard Keyboard layout for VNC server. This option is generally not required and is often better handled from within the guest OS. @@ -5944,7 +6821,7 @@ public function vmlist($full = null) { * @param string $lock Lock/unlock the VM. * Enum: backup,clone,create,migrate,rollback,snapshot,snapshot-delete,suspending,suspended * @param string $machine Specifies the QEMU machine type. - * @param int $memory Amount of RAM for the VM in MiB. This is the maximum available memory when you use the balloon device. + * @param string $memory Memory properties. * @param float $migrate_downtime Set maximum tolerated downtime (in seconds) for migrations. * @param int $migrate_speed Set maximum speed (in MB/s) for migrations. Value 0 is no limit. * @param string $name Set a name for the VM. Only used on the configuration web interface. @@ -5993,8 +6870,7 @@ public function vmlist($full = null) { * @return Result */ public function createVm($vmid, $acpi = null, $affinity = null, $agent = null, $arch = null, $archive = null, $args = null, $audio0 = null, $autostart = null, $balloon = null, $bios = null, $boot = null, $bootdisk = null, $bwlimit = null, $cdrom = null, $cicustom = null, $cipassword = null, $citype = null, $ciupgrade = null, $ciuser = null, $cores = null, $cpu = null, $cpulimit = null, $cpuunits = null, $description = null, $efidisk0 = null, $force = null, $freeze = null, $hookscript = null, $hostpciN = null, $hotplug = null, $hugepages = null, $ideN = null, $ipconfigN = null, $ivshmem = null, $keephugepages = null, $keyboard = null, $kvm = null, $live_restore = null, $localtime = null, $lock = null, $machine = null, $memory = null, $migrate_downtime = null, $migrate_speed = null, $name = null, $nameserver = null, $netN = null, $numa = null, $numaN = null, $onboot = null, $ostype = null, $parallelN = null, $pool = null, $protection = null, $reboot = null, $rng0 = null, $sataN = null, $scsiN = null, $scsihw = null, $searchdomain = null, $serialN = null, $shares = null, $smbios1 = null, $smp = null, $sockets = null, $spice_enhancements = null, $sshkeys = null, $start = null, $startdate = null, $startup = null, $storage = null, $tablet = null, $tags = null, $tdf = null, $template = null, $tpmstate0 = null, $unique = null, $unusedN = null, $usbN = null, $vcpus = null, $vga = null, $virtioN = null, $vmgenid = null, $vmstatestorage = null, $watchdog = null) { - $params = [ - 'vmid' => $vmid, + $params = ['vmid' => $vmid, 'acpi' => $acpi, 'affinity' => $affinity, 'agent' => $agent, @@ -6067,8 +6943,7 @@ public function createVm($vmid, $acpi = null, $affinity = null, $agent = null, $ 'vga' => $vga, 'vmgenid' => $vmgenid, 'vmstatestorage' => $vmstatestorage, - 'watchdog' => $watchdog - ]; + 'watchdog' => $watchdog]; $this->client->addIndexedParameter($params, 'hostpci', $hostpciN); $this->client->addIndexedParameter($params, 'ide', $ideN); $this->client->addIndexedParameter($params, 'ipconfig', $ipconfigN); @@ -6087,7 +6962,7 @@ public function createVm($vmid, $acpi = null, $affinity = null, $agent = null, $ /** * Class PVEItemQemuNodeNodesVmid - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemQemuNodeNodesVmid { @@ -6448,11 +7323,9 @@ public function getMtunnelwebsocket() { * @return Result */ public function destroyVm($destroy_unreferenced_disks = null, $purge = null, $skiplock = null) { - $params = [ - 'destroy-unreferenced-disks' => $destroy_unreferenced_disks, + $params = ['destroy-unreferenced-disks' => $destroy_unreferenced_disks, 'purge' => $purge, - 'skiplock' => $skiplock - ]; + 'skiplock' => $skiplock]; return $this->client->delete("/nodes/{$this->node}/qemu/{$this->vmid}", $params); } @@ -6467,7 +7340,7 @@ public function vmdiridx() { /** * Class PVEVmidQemuNodeNodesFirewall - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEVmidQemuNodeNodesFirewall { @@ -6584,7 +7457,7 @@ public function index() { /** * Class PVEFirewallVmidQemuNodeNodesRules - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEFirewallVmidQemuNodeNodesRules { @@ -6636,7 +7509,7 @@ public function getRules() { * Enum: in,out,group * @param string $comment Descriptive comment. * @param string $dest Restrict packet destination address. This can refer to a single IP address, an IP set ('+ipsetname') or an IP alias definition. You can also specify an address range like '20.34.101.207-201.3.9.99', or a list of IP addresses and networks (entries are separated by comma). Please do not mix IPv4 and IPv6 addresses inside such lists. - * @param string $digest Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications. + * @param string $digest Prevent changes if current configuration file has a different digest. This can be used to prevent concurrent modifications. * @param string $dport Restrict TCP/UDP destination port. You can use service names or simple numbers (0-65535), as defined in '/etc/services'. Port ranges can be specified with '\d+:\d+', for example '80:85', and you can use comma separated list to match several ports or ranges. * @param int $enable Flag to enable/disable a rule. * @param string $icmp_type Specify icmp-type. Only valid if proto equals 'icmp' or 'icmpv6'/'ipv6-icmp'. @@ -6651,8 +7524,7 @@ public function getRules() { * @return Result */ public function createRule($action, $type, $comment = null, $dest = null, $digest = null, $dport = null, $enable = null, $icmp_type = null, $iface = null, $log = null, $macro = null, $pos = null, $proto = null, $source = null, $sport = null) { - $params = [ - 'action' => $action, + $params = ['action' => $action, 'type' => $type, 'comment' => $comment, 'dest' => $dest, @@ -6666,15 +7538,14 @@ public function createRule($action, $type, $comment = null, $dest = null, $diges 'pos' => $pos, 'proto' => $proto, 'source' => $source, - 'sport' => $sport - ]; + 'sport' => $sport]; return $this->client->create("/nodes/{$this->node}/qemu/{$this->vmid}/firewall/rules", $params); } } /** * Class PVEItemRulesFirewallVmidQemuNodeNodesPos - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemRulesFirewallVmidQemuNodeNodesPos { @@ -6710,7 +7581,7 @@ function __construct($client, $node, $vmid, $pos) { /** * Delete rule. - * @param string $digest Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications. + * @param string $digest Prevent changes if current configuration file has a different digest. This can be used to prevent concurrent modifications. * @return Result */ public function deleteRule($digest = null) { @@ -6732,7 +7603,7 @@ public function getRule() { * @param string $comment Descriptive comment. * @param string $delete A list of settings you want to delete. * @param string $dest Restrict packet destination address. This can refer to a single IP address, an IP set ('+ipsetname') or an IP alias definition. You can also specify an address range like '20.34.101.207-201.3.9.99', or a list of IP addresses and networks (entries are separated by comma). Please do not mix IPv4 and IPv6 addresses inside such lists. - * @param string $digest Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications. + * @param string $digest Prevent changes if current configuration file has a different digest. This can be used to prevent concurrent modifications. * @param string $dport Restrict TCP/UDP destination port. You can use service names or simple numbers (0-65535), as defined in '/etc/services'. Port ranges can be specified with '\d+:\d+', for example '80:85', and you can use comma separated list to match several ports or ranges. * @param int $enable Flag to enable/disable a rule. * @param string $icmp_type Specify icmp-type. Only valid if proto equals 'icmp' or 'icmpv6'/'ipv6-icmp'. @@ -6749,8 +7620,7 @@ public function getRule() { * @return Result */ public function updateRule($action = null, $comment = null, $delete = null, $dest = null, $digest = null, $dport = null, $enable = null, $icmp_type = null, $iface = null, $log = null, $macro = null, $moveto = null, $proto = null, $source = null, $sport = null, $type = null) { - $params = [ - 'action' => $action, + $params = ['action' => $action, 'comment' => $comment, 'delete' => $delete, 'dest' => $dest, @@ -6765,15 +7635,14 @@ public function updateRule($action = null, $comment = null, $delete = null, $des 'proto' => $proto, 'source' => $source, 'sport' => $sport, - 'type' => $type - ]; + 'type' => $type]; return $this->client->set("/nodes/{$this->node}/qemu/{$this->vmid}/firewall/rules/{$this->pos}", $params); } } /** * Class PVEFirewallVmidQemuNodeNodesAliases - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEFirewallVmidQemuNodeNodesAliases { @@ -6822,22 +7691,20 @@ public function getAliases() { * Create IP or Network Alias. * @param string $cidr Network/IP specification in CIDR format. * @param string $name Alias name. - * @param string $comment + * @param string $comment * @return Result */ public function createAlias($cidr, $name, $comment = null) { - $params = [ - 'cidr' => $cidr, + $params = ['cidr' => $cidr, 'name' => $name, - 'comment' => $comment - ]; + 'comment' => $comment]; return $this->client->create("/nodes/{$this->node}/qemu/{$this->vmid}/firewall/aliases", $params); } } /** * Class PVEItemAliasesFirewallVmidQemuNodeNodesName - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemAliasesFirewallVmidQemuNodeNodesName { @@ -6873,7 +7740,7 @@ function __construct($client, $node, $vmid, $name) { /** * Remove IP or Network alias. - * @param string $digest Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications. + * @param string $digest Prevent changes if current configuration file has a different digest. This can be used to prevent concurrent modifications. * @return Result */ public function removeAlias($digest = null) { @@ -6892,25 +7759,23 @@ public function readAlias() { /** * Update IP or Network alias. * @param string $cidr Network/IP specification in CIDR format. - * @param string $comment - * @param string $digest Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications. + * @param string $comment + * @param string $digest Prevent changes if current configuration file has a different digest. This can be used to prevent concurrent modifications. * @param string $rename Rename an existing alias. * @return Result */ public function updateAlias($cidr, $comment = null, $digest = null, $rename = null) { - $params = [ - 'cidr' => $cidr, + $params = ['cidr' => $cidr, 'comment' => $comment, 'digest' => $digest, - 'rename' => $rename - ]; + 'rename' => $rename]; return $this->client->set("/nodes/{$this->node}/qemu/{$this->vmid}/firewall/aliases/{$this->name}", $params); } } /** * Class PVEFirewallVmidQemuNodeNodesIpset - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEFirewallVmidQemuNodeNodesIpset { @@ -6958,25 +7823,23 @@ public function ipsetIndex() { /** * Create new IPSet * @param string $name IP set name. - * @param string $comment - * @param string $digest Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications. + * @param string $comment + * @param string $digest Prevent changes if current configuration file has a different digest. This can be used to prevent concurrent modifications. * @param string $rename Rename an existing IPSet. You can set 'rename' to the same value as 'name' to update the 'comment' of an existing IPSet. * @return Result */ public function createIpset($name, $comment = null, $digest = null, $rename = null) { - $params = [ - 'name' => $name, + $params = ['name' => $name, 'comment' => $comment, 'digest' => $digest, - 'rename' => $rename - ]; + 'rename' => $rename]; return $this->client->create("/nodes/{$this->node}/qemu/{$this->vmid}/firewall/ipset", $params); } } /** * Class PVEItemIpsetFirewallVmidQemuNodeNodesName - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemIpsetFirewallVmidQemuNodeNodesName { @@ -7040,23 +7903,21 @@ public function getIpset() { /** * Add IP or Network to IPSet. * @param string $cidr Network/IP specification in CIDR format. - * @param string $comment - * @param bool $nomatch + * @param string $comment + * @param bool $nomatch * @return Result */ public function createIp($cidr, $comment = null, $nomatch = null) { - $params = [ - 'cidr' => $cidr, + $params = ['cidr' => $cidr, 'comment' => $comment, - 'nomatch' => $nomatch - ]; + 'nomatch' => $nomatch]; return $this->client->create("/nodes/{$this->node}/qemu/{$this->vmid}/firewall/ipset/{$this->name}", $params); } } /** * Class PVEItemNameIpsetFirewallVmidQemuNodeNodesCidr - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemNameIpsetFirewallVmidQemuNodeNodesCidr { @@ -7098,7 +7959,7 @@ function __construct($client, $node, $vmid, $name, $cidr) { /** * Remove IP or Network from IPSet. - * @param string $digest Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications. + * @param string $digest Prevent changes if current configuration file has a different digest. This can be used to prevent concurrent modifications. * @return Result */ public function removeIp($digest = null) { @@ -7116,24 +7977,22 @@ public function readIp() { /** * Update IP or Network settings - * @param string $comment - * @param string $digest Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications. - * @param bool $nomatch + * @param string $comment + * @param string $digest Prevent changes if current configuration file has a different digest. This can be used to prevent concurrent modifications. + * @param bool $nomatch * @return Result */ public function updateIp($comment = null, $digest = null, $nomatch = null) { - $params = [ - 'comment' => $comment, + $params = ['comment' => $comment, 'digest' => $digest, - 'nomatch' => $nomatch - ]; + 'nomatch' => $nomatch]; return $this->client->set("/nodes/{$this->node}/qemu/{$this->vmid}/firewall/ipset/{$this->name}/{$this->cidr}", $params); } } /** * Class PVEFirewallVmidQemuNodeNodesOptions - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEFirewallVmidQemuNodeNodesOptions { @@ -7173,7 +8032,7 @@ public function getOptions() { * Set Firewall options. * @param string $delete A list of settings you want to delete. * @param bool $dhcp Enable DHCP. - * @param string $digest Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications. + * @param string $digest Prevent changes if current configuration file has a different digest. This can be used to prevent concurrent modifications. * @param bool $enable Enable/disable firewall rules. * @param bool $ipfilter Enable default IP filters. This is equivalent to adding an empty ipfilter-net<id> ipset for every interface. Such ipsets implicitly contain sane default restrictions such as restricting IPv6 link local addresses to the one derived from the interface's MAC address. For containers the configured IP addresses will be implicitly added. * @param string $log_level_in Log level for incoming traffic. @@ -7190,8 +8049,7 @@ public function getOptions() { * @return Result */ public function setOptions($delete = null, $dhcp = null, $digest = null, $enable = null, $ipfilter = null, $log_level_in = null, $log_level_out = null, $macfilter = null, $ndp = null, $policy_in = null, $policy_out = null, $radv = null) { - $params = [ - 'delete' => $delete, + $params = ['delete' => $delete, 'dhcp' => $dhcp, 'digest' => $digest, 'enable' => $enable, @@ -7202,15 +8060,14 @@ public function setOptions($delete = null, $dhcp = null, $digest = null, $enable 'ndp' => $ndp, 'policy_in' => $policy_in, 'policy_out' => $policy_out, - 'radv' => $radv - ]; + 'radv' => $radv]; return $this->client->set("/nodes/{$this->node}/qemu/{$this->vmid}/firewall/options", $params); } } /** * Class PVEFirewallVmidQemuNodeNodesLog - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEFirewallVmidQemuNodeNodesLog { @@ -7240,26 +8097,24 @@ function __construct($client, $node, $vmid) { /** * Read firewall log - * @param int $limit + * @param int $limit * @param int $since Display log since this UNIX epoch. - * @param int $start + * @param int $start * @param int $until Display log until this UNIX epoch. * @return Result */ public function log($limit = null, $since = null, $start = null, $until = null) { - $params = [ - 'limit' => $limit, + $params = ['limit' => $limit, 'since' => $since, 'start' => $start, - 'until' => $until - ]; + 'until' => $until]; return $this->client->get("/nodes/{$this->node}/qemu/{$this->vmid}/firewall/log", $params); } } /** * Class PVEFirewallVmidQemuNodeNodesRefs - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEFirewallVmidQemuNodeNodesRefs { @@ -7301,7 +8156,7 @@ public function refs($type = null) { /** * Class PVEVmidQemuNodeNodesAgent - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEVmidQemuNodeNodesAgent { @@ -7676,7 +8531,7 @@ public function agent($command) { /** * Class PVEAgentVmidQemuNodeNodesFsfreezeFreeze - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEAgentVmidQemuNodeNodesFsfreezeFreeze { @@ -7715,7 +8570,7 @@ public function fsfreezeFreeze() { /** * Class PVEAgentVmidQemuNodeNodesFsfreezeStatus - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEAgentVmidQemuNodeNodesFsfreezeStatus { @@ -7754,7 +8609,7 @@ public function fsfreezeStatus() { /** * Class PVEAgentVmidQemuNodeNodesFsfreezeThaw - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEAgentVmidQemuNodeNodesFsfreezeThaw { @@ -7793,7 +8648,7 @@ public function fsfreezeThaw() { /** * Class PVEAgentVmidQemuNodeNodesFstrim - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEAgentVmidQemuNodeNodesFstrim { @@ -7832,7 +8687,7 @@ public function fstrim() { /** * Class PVEAgentVmidQemuNodeNodesGetFsinfo - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEAgentVmidQemuNodeNodesGetFsinfo { @@ -7871,7 +8726,7 @@ public function getFsinfo() { /** * Class PVEAgentVmidQemuNodeNodesGetHostName - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEAgentVmidQemuNodeNodesGetHostName { @@ -7910,7 +8765,7 @@ public function getHostName() { /** * Class PVEAgentVmidQemuNodeNodesGetMemoryBlockInfo - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEAgentVmidQemuNodeNodesGetMemoryBlockInfo { @@ -7949,7 +8804,7 @@ public function getMemoryBlockInfo() { /** * Class PVEAgentVmidQemuNodeNodesGetMemoryBlocks - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEAgentVmidQemuNodeNodesGetMemoryBlocks { @@ -7988,7 +8843,7 @@ public function getMemoryBlocks() { /** * Class PVEAgentVmidQemuNodeNodesGetOsinfo - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEAgentVmidQemuNodeNodesGetOsinfo { @@ -8027,7 +8882,7 @@ public function getOsinfo() { /** * Class PVEAgentVmidQemuNodeNodesGetTime - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEAgentVmidQemuNodeNodesGetTime { @@ -8066,7 +8921,7 @@ public function getTime() { /** * Class PVEAgentVmidQemuNodeNodesGetTimezone - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEAgentVmidQemuNodeNodesGetTimezone { @@ -8105,7 +8960,7 @@ public function getTimezone() { /** * Class PVEAgentVmidQemuNodeNodesGetUsers - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEAgentVmidQemuNodeNodesGetUsers { @@ -8144,7 +8999,7 @@ public function getUsers() { /** * Class PVEAgentVmidQemuNodeNodesGetVcpus - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEAgentVmidQemuNodeNodesGetVcpus { @@ -8183,7 +9038,7 @@ public function getVcpus() { /** * Class PVEAgentVmidQemuNodeNodesInfo - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEAgentVmidQemuNodeNodesInfo { @@ -8222,7 +9077,7 @@ public function info() { /** * Class PVEAgentVmidQemuNodeNodesNetworkGetInterfaces - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEAgentVmidQemuNodeNodesNetworkGetInterfaces { @@ -8261,7 +9116,7 @@ public function networkGetInterfaces() { /** * Class PVEAgentVmidQemuNodeNodesPing - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEAgentVmidQemuNodeNodesPing { @@ -8300,7 +9155,7 @@ public function ping() { /** * Class PVEAgentVmidQemuNodeNodesShutdown - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEAgentVmidQemuNodeNodesShutdown { @@ -8339,7 +9194,7 @@ public function shutdown() { /** * Class PVEAgentVmidQemuNodeNodesSuspendDisk - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEAgentVmidQemuNodeNodesSuspendDisk { @@ -8378,7 +9233,7 @@ public function suspendDisk() { /** * Class PVEAgentVmidQemuNodeNodesSuspendHybrid - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEAgentVmidQemuNodeNodesSuspendHybrid { @@ -8417,7 +9272,7 @@ public function suspendHybrid() { /** * Class PVEAgentVmidQemuNodeNodesSuspendRam - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEAgentVmidQemuNodeNodesSuspendRam { @@ -8456,7 +9311,7 @@ public function suspendRam() { /** * Class PVEAgentVmidQemuNodeNodesSetUserPassword - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEAgentVmidQemuNodeNodesSetUserPassword { @@ -8492,18 +9347,16 @@ function __construct($client, $node, $vmid) { * @return Result */ public function setUserPassword($password, $username, $crypted = null) { - $params = [ - 'password' => $password, + $params = ['password' => $password, 'username' => $username, - 'crypted' => $crypted - ]; + 'crypted' => $crypted]; return $this->client->create("/nodes/{$this->node}/qemu/{$this->vmid}/agent/set-user-password", $params); } } /** * Class PVEAgentVmidQemuNodeNodesExec - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEAgentVmidQemuNodeNodesExec { @@ -8538,17 +9391,15 @@ function __construct($client, $node, $vmid) { * @return Result */ public function exec($command, $input_data = null) { - $params = [ - 'command' => $command, - 'input-data' => $input_data - ]; + $params = ['command' => $command, + 'input-data' => $input_data]; return $this->client->create("/nodes/{$this->node}/qemu/{$this->vmid}/agent/exec", $params); } } /** * Class PVEAgentVmidQemuNodeNodesExecStatus - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEAgentVmidQemuNodeNodesExecStatus { @@ -8589,7 +9440,7 @@ public function execStatus($pid) { /** * Class PVEAgentVmidQemuNodeNodesFileRead - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEAgentVmidQemuNodeNodesFileRead { @@ -8630,7 +9481,7 @@ public function fileRead($file) { /** * Class PVEAgentVmidQemuNodeNodesFileWrite - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEAgentVmidQemuNodeNodesFileWrite { @@ -8666,18 +9517,16 @@ function __construct($client, $node, $vmid) { * @return Result */ public function fileWrite($content, $file, $encode = null) { - $params = [ - 'content' => $content, + $params = ['content' => $content, 'file' => $file, - 'encode' => $encode - ]; + 'encode' => $encode]; return $this->client->create("/nodes/{$this->node}/qemu/{$this->vmid}/agent/file-write", $params); } } /** * Class PVEVmidQemuNodeNodesRrd - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEVmidQemuNodeNodesRrd { @@ -8715,18 +9564,16 @@ function __construct($client, $node, $vmid) { * @return Result */ public function rrd($ds, $timeframe, $cf = null) { - $params = [ - 'ds' => $ds, + $params = ['ds' => $ds, 'timeframe' => $timeframe, - 'cf' => $cf - ]; + 'cf' => $cf]; return $this->client->get("/nodes/{$this->node}/qemu/{$this->vmid}/rrd", $params); } } /** * Class PVEVmidQemuNodeNodesRrddata - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEVmidQemuNodeNodesRrddata { @@ -8763,17 +9610,15 @@ function __construct($client, $node, $vmid) { * @return Result */ public function rrddata($timeframe, $cf = null) { - $params = [ - 'timeframe' => $timeframe, - 'cf' => $cf - ]; + $params = ['timeframe' => $timeframe, + 'cf' => $cf]; return $this->client->get("/nodes/{$this->node}/qemu/{$this->vmid}/rrddata", $params); } } /** * Class PVEVmidQemuNodeNodesConfig - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEVmidQemuNodeNodesConfig { @@ -8808,10 +9653,8 @@ function __construct($client, $node, $vmid) { * @return Result */ public function vmConfig($current = null, $snapshot = null) { - $params = [ - 'current' => $current, - 'snapshot' => $snapshot - ]; + $params = ['current' => $current, + 'snapshot' => $snapshot]; return $this->client->get("/nodes/{$this->node}/qemu/{$this->vmid}/config", $params); } @@ -8854,7 +9697,7 @@ public function vmConfig($current = null, $snapshot = null) { * @param string $hugepages Enable/disable hugepages memory. * Enum: any,2,1024 * @param array $ideN Use volume as IDE hard disk or CD-ROM (n is 0 to 3). Use the special syntax STORAGE_ID:SIZE_IN_GiB to allocate a new volume. Use STORAGE_ID:0 and the 'import-from' parameter to import from an existing volume. - * @param array $ipconfigN cloud-init: Specify IP addresses and gateways for the corresponding interface. IP addresses use CIDR notation, gateways are optional but need an IP of the same type specified. The special string 'dhcp' can be used for IP addresses to use DHCP, in which case no explicit gateway should be provided. For IPv6 the special string 'auto' can be used to use stateless autoconfiguration. This requires cloud-init 19.4 or newer. If cloud-init is enabled and neither an IPv4 nor an IPv6 address is specified, it defaults to using dhcp on IPv4. + * @param array $ipconfigN cloud-init: Specify IP addresses and gateways for the corresponding interface. IP addresses use CIDR notation, gateways are optional but need an IP of the same type specified. The special string 'dhcp' can be used for IP addresses to use DHCP, in which case no explicit gateway should be provided. For IPv6 the special string 'auto' can be used to use stateless autoconfiguration. This requires cloud-init 19.4 or newer. If cloud-init is enabled and neither an IPv4 nor an IPv6 address is specified, it defaults to using dhcp on IPv4. * @param string $ivshmem Inter-VM shared memory. Useful for direct communication between VMs, or to the host. * @param bool $keephugepages Use together with hugepages. If enabled, hugepages will not not be deleted after VM shutdown and can be used for subsequent starts. * @param string $keyboard Keyboard layout for VNC server. This option is generally not required and is often better handled from within the guest OS. @@ -8864,7 +9707,7 @@ public function vmConfig($current = null, $snapshot = null) { * @param string $lock Lock/unlock the VM. * Enum: backup,clone,create,migrate,rollback,snapshot,snapshot-delete,suspending,suspended * @param string $machine Specifies the QEMU machine type. - * @param int $memory Amount of RAM for the VM in MiB. This is the maximum available memory when you use the balloon device. + * @param string $memory Memory properties. * @param float $migrate_downtime Set maximum tolerated downtime (in seconds) for migrations. * @param int $migrate_speed Set maximum speed (in MB/s) for migrations. Value 0 is no limit. * @param string $name Set a name for the VM. Only used on the configuration web interface. @@ -8911,8 +9754,7 @@ public function vmConfig($current = null, $snapshot = null) { * @return Result */ public function updateVmAsync($acpi = null, $affinity = null, $agent = null, $arch = null, $args = null, $audio0 = null, $autostart = null, $background_delay = null, $balloon = null, $bios = null, $boot = null, $bootdisk = null, $cdrom = null, $cicustom = null, $cipassword = null, $citype = null, $ciupgrade = null, $ciuser = null, $cores = null, $cpu = null, $cpulimit = null, $cpuunits = null, $delete = null, $description = null, $digest = null, $efidisk0 = null, $force = null, $freeze = null, $hookscript = null, $hostpciN = null, $hotplug = null, $hugepages = null, $ideN = null, $ipconfigN = null, $ivshmem = null, $keephugepages = null, $keyboard = null, $kvm = null, $localtime = null, $lock = null, $machine = null, $memory = null, $migrate_downtime = null, $migrate_speed = null, $name = null, $nameserver = null, $netN = null, $numa = null, $numaN = null, $onboot = null, $ostype = null, $parallelN = null, $protection = null, $reboot = null, $revert = null, $rng0 = null, $sataN = null, $scsiN = null, $scsihw = null, $searchdomain = null, $serialN = null, $shares = null, $skiplock = null, $smbios1 = null, $smp = null, $sockets = null, $spice_enhancements = null, $sshkeys = null, $startdate = null, $startup = null, $tablet = null, $tags = null, $tdf = null, $template = null, $tpmstate0 = null, $unusedN = null, $usbN = null, $vcpus = null, $vga = null, $virtioN = null, $vmgenid = null, $vmstatestorage = null, $watchdog = null) { - $params = [ - 'acpi' => $acpi, + $params = ['acpi' => $acpi, 'affinity' => $affinity, 'agent' => $agent, 'arch' => $arch, @@ -8982,8 +9824,7 @@ public function updateVmAsync($acpi = null, $affinity = null, $agent = null, $ar 'vga' => $vga, 'vmgenid' => $vmgenid, 'vmstatestorage' => $vmstatestorage, - 'watchdog' => $watchdog - ]; + 'watchdog' => $watchdog]; $this->client->addIndexedParameter($params, 'hostpci', $hostpciN); $this->client->addIndexedParameter($params, 'ide', $ideN); $this->client->addIndexedParameter($params, 'ipconfig', $ipconfigN); @@ -9037,7 +9878,7 @@ public function updateVmAsync($acpi = null, $affinity = null, $agent = null, $ar * @param string $hugepages Enable/disable hugepages memory. * Enum: any,2,1024 * @param array $ideN Use volume as IDE hard disk or CD-ROM (n is 0 to 3). Use the special syntax STORAGE_ID:SIZE_IN_GiB to allocate a new volume. Use STORAGE_ID:0 and the 'import-from' parameter to import from an existing volume. - * @param array $ipconfigN cloud-init: Specify IP addresses and gateways for the corresponding interface. IP addresses use CIDR notation, gateways are optional but need an IP of the same type specified. The special string 'dhcp' can be used for IP addresses to use DHCP, in which case no explicit gateway should be provided. For IPv6 the special string 'auto' can be used to use stateless autoconfiguration. This requires cloud-init 19.4 or newer. If cloud-init is enabled and neither an IPv4 nor an IPv6 address is specified, it defaults to using dhcp on IPv4. + * @param array $ipconfigN cloud-init: Specify IP addresses and gateways for the corresponding interface. IP addresses use CIDR notation, gateways are optional but need an IP of the same type specified. The special string 'dhcp' can be used for IP addresses to use DHCP, in which case no explicit gateway should be provided. For IPv6 the special string 'auto' can be used to use stateless autoconfiguration. This requires cloud-init 19.4 or newer. If cloud-init is enabled and neither an IPv4 nor an IPv6 address is specified, it defaults to using dhcp on IPv4. * @param string $ivshmem Inter-VM shared memory. Useful for direct communication between VMs, or to the host. * @param bool $keephugepages Use together with hugepages. If enabled, hugepages will not not be deleted after VM shutdown and can be used for subsequent starts. * @param string $keyboard Keyboard layout for VNC server. This option is generally not required and is often better handled from within the guest OS. @@ -9047,7 +9888,7 @@ public function updateVmAsync($acpi = null, $affinity = null, $agent = null, $ar * @param string $lock Lock/unlock the VM. * Enum: backup,clone,create,migrate,rollback,snapshot,snapshot-delete,suspending,suspended * @param string $machine Specifies the QEMU machine type. - * @param int $memory Amount of RAM for the VM in MiB. This is the maximum available memory when you use the balloon device. + * @param string $memory Memory properties. * @param float $migrate_downtime Set maximum tolerated downtime (in seconds) for migrations. * @param int $migrate_speed Set maximum speed (in MB/s) for migrations. Value 0 is no limit. * @param string $name Set a name for the VM. Only used on the configuration web interface. @@ -9094,8 +9935,7 @@ public function updateVmAsync($acpi = null, $affinity = null, $agent = null, $ar * @return Result */ public function updateVm($acpi = null, $affinity = null, $agent = null, $arch = null, $args = null, $audio0 = null, $autostart = null, $balloon = null, $bios = null, $boot = null, $bootdisk = null, $cdrom = null, $cicustom = null, $cipassword = null, $citype = null, $ciupgrade = null, $ciuser = null, $cores = null, $cpu = null, $cpulimit = null, $cpuunits = null, $delete = null, $description = null, $digest = null, $efidisk0 = null, $force = null, $freeze = null, $hookscript = null, $hostpciN = null, $hotplug = null, $hugepages = null, $ideN = null, $ipconfigN = null, $ivshmem = null, $keephugepages = null, $keyboard = null, $kvm = null, $localtime = null, $lock = null, $machine = null, $memory = null, $migrate_downtime = null, $migrate_speed = null, $name = null, $nameserver = null, $netN = null, $numa = null, $numaN = null, $onboot = null, $ostype = null, $parallelN = null, $protection = null, $reboot = null, $revert = null, $rng0 = null, $sataN = null, $scsiN = null, $scsihw = null, $searchdomain = null, $serialN = null, $shares = null, $skiplock = null, $smbios1 = null, $smp = null, $sockets = null, $spice_enhancements = null, $sshkeys = null, $startdate = null, $startup = null, $tablet = null, $tags = null, $tdf = null, $template = null, $tpmstate0 = null, $unusedN = null, $usbN = null, $vcpus = null, $vga = null, $virtioN = null, $vmgenid = null, $vmstatestorage = null, $watchdog = null) { - $params = [ - 'acpi' => $acpi, + $params = ['acpi' => $acpi, 'affinity' => $affinity, 'agent' => $agent, 'arch' => $arch, @@ -9164,8 +10004,7 @@ public function updateVm($acpi = null, $affinity = null, $agent = null, $arch = 'vga' => $vga, 'vmgenid' => $vmgenid, 'vmstatestorage' => $vmstatestorage, - 'watchdog' => $watchdog - ]; + 'watchdog' => $watchdog]; $this->client->addIndexedParameter($params, 'hostpci', $hostpciN); $this->client->addIndexedParameter($params, 'ide', $ideN); $this->client->addIndexedParameter($params, 'ipconfig', $ipconfigN); @@ -9184,7 +10023,7 @@ public function updateVm($acpi = null, $affinity = null, $agent = null, $arch = /** * Class PVEVmidQemuNodeNodesPending - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEVmidQemuNodeNodesPending { @@ -9223,7 +10062,7 @@ public function vmPending() { /** * Class PVEVmidQemuNodeNodesCloudinit - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEVmidQemuNodeNodesCloudinit { @@ -9283,7 +10122,7 @@ public function cloudinitUpdate() { /** * Class PVECloudinitVmidQemuNodeNodesDump - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVECloudinitVmidQemuNodeNodesDump { @@ -9325,7 +10164,7 @@ public function cloudinitGeneratedConfigDump($type) { /** * Class PVEVmidQemuNodeNodesUnlink - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEVmidQemuNodeNodesUnlink { @@ -9360,17 +10199,15 @@ function __construct($client, $node, $vmid) { * @return Result */ public function unlink($idlist, $force = null) { - $params = [ - 'idlist' => $idlist, - 'force' => $force - ]; + $params = ['idlist' => $idlist, + 'force' => $force]; return $this->client->set("/nodes/{$this->node}/qemu/{$this->vmid}/unlink", $params); } } /** * Class PVEVmidQemuNodeNodesVncproxy - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEVmidQemuNodeNodesVncproxy { @@ -9401,21 +10238,19 @@ function __construct($client, $node, $vmid) { /** * Creates a TCP VNC proxy connections. * @param bool $generate_password Generates a random password to be used as ticket instead of the API ticket. - * @param bool $websocket starts websockify instead of vncproxy + * @param bool $websocket Prepare for websocket upgrade (only required when using serial terminal, otherwise upgrade is always possible). * @return Result */ public function vncproxy($generate_password = null, $websocket = null) { - $params = [ - 'generate-password' => $generate_password, - 'websocket' => $websocket - ]; + $params = ['generate-password' => $generate_password, + 'websocket' => $websocket]; return $this->client->create("/nodes/{$this->node}/qemu/{$this->vmid}/vncproxy", $params); } } /** * Class PVEVmidQemuNodeNodesTermproxy - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEVmidQemuNodeNodesTermproxy { @@ -9457,7 +10292,7 @@ public function termproxy($serial = null) { /** * Class PVEVmidQemuNodeNodesVncwebsocket - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEVmidQemuNodeNodesVncwebsocket { @@ -9492,17 +10327,15 @@ function __construct($client, $node, $vmid) { * @return Result */ public function vncwebsocket($port, $vncticket) { - $params = [ - 'port' => $port, - 'vncticket' => $vncticket - ]; + $params = ['port' => $port, + 'vncticket' => $vncticket]; return $this->client->get("/nodes/{$this->node}/qemu/{$this->vmid}/vncwebsocket", $params); } } /** * Class PVEVmidQemuNodeNodesSpiceproxy - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEVmidQemuNodeNodesSpiceproxy { @@ -9543,7 +10376,7 @@ public function spiceproxy($proxy = null) { /** * Class PVEVmidQemuNodeNodesStatus - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEVmidQemuNodeNodesStatus { @@ -9686,7 +10519,7 @@ public function vmcmdidx() { /** * Class PVEStatusVmidQemuNodeNodesCurrent - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEStatusVmidQemuNodeNodesCurrent { @@ -9725,7 +10558,7 @@ public function vmStatus() { /** * Class PVEStatusVmidQemuNodeNodesStart - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEStatusVmidQemuNodeNodesStart { @@ -9768,8 +10601,7 @@ function __construct($client, $node, $vmid) { * @return Result */ public function vmStart($force_cpu = null, $machine = null, $migratedfrom = null, $migration_network = null, $migration_type = null, $skiplock = null, $stateuri = null, $targetstorage = null, $timeout = null) { - $params = [ - 'force-cpu' => $force_cpu, + $params = ['force-cpu' => $force_cpu, 'machine' => $machine, 'migratedfrom' => $migratedfrom, 'migration_network' => $migration_network, @@ -9777,15 +10609,14 @@ public function vmStart($force_cpu = null, $machine = null, $migratedfrom = null 'skiplock' => $skiplock, 'stateuri' => $stateuri, 'targetstorage' => $targetstorage, - 'timeout' => $timeout - ]; + 'timeout' => $timeout]; return $this->client->create("/nodes/{$this->node}/qemu/{$this->vmid}/status/start", $params); } } /** * Class PVEStatusVmidQemuNodeNodesStop - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEStatusVmidQemuNodeNodesStop { @@ -9822,19 +10653,17 @@ function __construct($client, $node, $vmid) { * @return Result */ public function vmStop($keepActive = null, $migratedfrom = null, $skiplock = null, $timeout = null) { - $params = [ - 'keepActive' => $keepActive, + $params = ['keepActive' => $keepActive, 'migratedfrom' => $migratedfrom, 'skiplock' => $skiplock, - 'timeout' => $timeout - ]; + 'timeout' => $timeout]; return $this->client->create("/nodes/{$this->node}/qemu/{$this->vmid}/status/stop", $params); } } /** * Class PVEStatusVmidQemuNodeNodesReset - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEStatusVmidQemuNodeNodesReset { @@ -9875,7 +10704,7 @@ public function vmReset($skiplock = null) { /** * Class PVEStatusVmidQemuNodeNodesShutdown - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEStatusVmidQemuNodeNodesShutdown { @@ -9912,19 +10741,17 @@ function __construct($client, $node, $vmid) { * @return Result */ public function vmShutdown($forceStop = null, $keepActive = null, $skiplock = null, $timeout = null) { - $params = [ - 'forceStop' => $forceStop, + $params = ['forceStop' => $forceStop, 'keepActive' => $keepActive, 'skiplock' => $skiplock, - 'timeout' => $timeout - ]; + 'timeout' => $timeout]; return $this->client->create("/nodes/{$this->node}/qemu/{$this->vmid}/status/shutdown", $params); } } /** * Class PVEStatusVmidQemuNodeNodesReboot - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEStatusVmidQemuNodeNodesReboot { @@ -9965,7 +10792,7 @@ public function vmReboot($timeout = null) { /** * Class PVEStatusVmidQemuNodeNodesSuspend - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEStatusVmidQemuNodeNodesSuspend { @@ -10001,18 +10828,16 @@ function __construct($client, $node, $vmid) { * @return Result */ public function vmSuspend($skiplock = null, $statestorage = null, $todisk = null) { - $params = [ - 'skiplock' => $skiplock, + $params = ['skiplock' => $skiplock, 'statestorage' => $statestorage, - 'todisk' => $todisk - ]; + 'todisk' => $todisk]; return $this->client->create("/nodes/{$this->node}/qemu/{$this->vmid}/status/suspend", $params); } } /** * Class PVEStatusVmidQemuNodeNodesResume - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEStatusVmidQemuNodeNodesResume { @@ -10042,22 +10867,20 @@ function __construct($client, $node, $vmid) { /** * Resume virtual machine. - * @param bool $nocheck + * @param bool $nocheck * @param bool $skiplock Ignore locks - only root is allowed to use this option. * @return Result */ public function vmResume($nocheck = null, $skiplock = null) { - $params = [ - 'nocheck' => $nocheck, - 'skiplock' => $skiplock - ]; + $params = ['nocheck' => $nocheck, + 'skiplock' => $skiplock]; return $this->client->create("/nodes/{$this->node}/qemu/{$this->vmid}/status/resume", $params); } } /** * Class PVEVmidQemuNodeNodesSendkey - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEVmidQemuNodeNodesSendkey { @@ -10092,17 +10915,15 @@ function __construct($client, $node, $vmid) { * @return Result */ public function vmSendkey($key, $skiplock = null) { - $params = [ - 'key' => $key, - 'skiplock' => $skiplock - ]; + $params = ['key' => $key, + 'skiplock' => $skiplock]; return $this->client->set("/nodes/{$this->node}/qemu/{$this->vmid}/sendkey", $params); } } /** * Class PVEVmidQemuNodeNodesFeature - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEVmidQemuNodeNodesFeature { @@ -10138,17 +10959,15 @@ function __construct($client, $node, $vmid) { * @return Result */ public function vmFeature($feature, $snapname = null) { - $params = [ - 'feature' => $feature, - 'snapname' => $snapname - ]; + $params = ['feature' => $feature, + 'snapname' => $snapname]; return $this->client->get("/nodes/{$this->node}/qemu/{$this->vmid}/feature", $params); } } /** * Class PVEVmidQemuNodeNodesClone - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEVmidQemuNodeNodesClone { @@ -10192,8 +11011,7 @@ function __construct($client, $node, $vmid) { * @return Result */ public function cloneVm($newid, $bwlimit = null, $description = null, $format = null, $full = null, $name = null, $pool = null, $snapname = null, $storage = null, $target = null) { - $params = [ - 'newid' => $newid, + $params = ['newid' => $newid, 'bwlimit' => $bwlimit, 'description' => $description, 'format' => $format, @@ -10202,15 +11020,14 @@ public function cloneVm($newid, $bwlimit = null, $description = null, $format = 'pool' => $pool, 'snapname' => $snapname, 'storage' => $storage, - 'target' => $target - ]; + 'target' => $target]; return $this->client->create("/nodes/{$this->node}/qemu/{$this->vmid}/clone", $params); } } /** * Class PVEVmidQemuNodeNodesMoveDisk - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEVmidQemuNodeNodesMoveDisk { @@ -10255,8 +11072,7 @@ function __construct($client, $node, $vmid) { * @return Result */ public function moveVmDisk($disk, $bwlimit = null, $delete = null, $digest = null, $format = null, $storage = null, $target_digest = null, $target_disk = null, $target_vmid = null) { - $params = [ - 'disk' => $disk, + $params = ['disk' => $disk, 'bwlimit' => $bwlimit, 'delete' => $delete, 'digest' => $digest, @@ -10264,15 +11080,14 @@ public function moveVmDisk($disk, $bwlimit = null, $delete = null, $digest = nul 'storage' => $storage, 'target-digest' => $target_digest, 'target-disk' => $target_disk, - 'target-vmid' => $target_vmid - ]; + 'target-vmid' => $target_vmid]; return $this->client->create("/nodes/{$this->node}/qemu/{$this->vmid}/move_disk", $params); } } /** * Class PVEVmidQemuNodeNodesMigrate - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEVmidQemuNodeNodesMigrate { @@ -10324,23 +11139,21 @@ public function migrateVmPrecondition($target = null) { * @return Result */ public function migrateVm($target, $bwlimit = null, $force = null, $migration_network = null, $migration_type = null, $online = null, $targetstorage = null, $with_local_disks = null) { - $params = [ - 'target' => $target, + $params = ['target' => $target, 'bwlimit' => $bwlimit, 'force' => $force, 'migration_network' => $migration_network, 'migration_type' => $migration_type, 'online' => $online, 'targetstorage' => $targetstorage, - 'with-local-disks' => $with_local_disks - ]; + 'with-local-disks' => $with_local_disks]; return $this->client->create("/nodes/{$this->node}/qemu/{$this->vmid}/migrate", $params); } } /** * Class PVEVmidQemuNodeNodesRemoteMigrate - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEVmidQemuNodeNodesRemoteMigrate { @@ -10380,22 +11193,20 @@ function __construct($client, $node, $vmid) { * @return Result */ public function remoteMigrateVm($target_bridge, $target_endpoint, $target_storage, $bwlimit = null, $delete = null, $online = null, $target_vmid = null) { - $params = [ - 'target-bridge' => $target_bridge, + $params = ['target-bridge' => $target_bridge, 'target-endpoint' => $target_endpoint, 'target-storage' => $target_storage, 'bwlimit' => $bwlimit, 'delete' => $delete, 'online' => $online, - 'target-vmid' => $target_vmid - ]; + 'target-vmid' => $target_vmid]; return $this->client->create("/nodes/{$this->node}/qemu/{$this->vmid}/remote_migrate", $params); } } /** * Class PVEVmidQemuNodeNodesMonitor - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEVmidQemuNodeNodesMonitor { @@ -10436,7 +11247,7 @@ public function monitor($command) { /** * Class PVEVmidQemuNodeNodesResize - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEVmidQemuNodeNodesResize { @@ -10474,19 +11285,17 @@ function __construct($client, $node, $vmid) { * @return Result */ public function resizeVm($disk, $size, $digest = null, $skiplock = null) { - $params = [ - 'disk' => $disk, + $params = ['disk' => $disk, 'size' => $size, 'digest' => $digest, - 'skiplock' => $skiplock - ]; + 'skiplock' => $skiplock]; return $this->client->set("/nodes/{$this->node}/qemu/{$this->vmid}/resize", $params); } } /** * Class PVEVmidQemuNodeNodesSnapshot - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEVmidQemuNodeNodesSnapshot { @@ -10539,18 +11348,16 @@ public function snapshotList() { * @return Result */ public function snapshot($snapname, $description = null, $vmstate = null) { - $params = [ - 'snapname' => $snapname, + $params = ['snapname' => $snapname, 'description' => $description, - 'vmstate' => $vmstate - ]; + 'vmstate' => $vmstate]; return $this->client->create("/nodes/{$this->node}/qemu/{$this->vmid}/snapshot", $params); } } /** * Class PVEItemSnapshotVmidQemuNodeNodesSnapname - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemSnapshotVmidQemuNodeNodesSnapname { @@ -10621,7 +11428,7 @@ public function delsnapshot($force = null) { } /** - * + * * @return Result */ public function snapshotCmdIdx() { @@ -10631,7 +11438,7 @@ public function snapshotCmdIdx() { /** * Class PVESnapnameSnapshotVmidQemuNodeNodesConfig - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVESnapnameSnapshotVmidQemuNodeNodesConfig { @@ -10686,7 +11493,7 @@ public function updateSnapshotConfig($description = null) { /** * Class PVESnapnameSnapshotVmidQemuNodeNodesRollback - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVESnapnameSnapshotVmidQemuNodeNodesRollback { @@ -10733,7 +11540,7 @@ public function rollback($start = null) { /** * Class PVEVmidQemuNodeNodesTemplate - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEVmidQemuNodeNodesTemplate { @@ -10775,7 +11582,7 @@ public function template($disk = null) { /** * Class PVEVmidQemuNodeNodesMtunnel - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEVmidQemuNodeNodesMtunnel { @@ -10810,17 +11617,15 @@ function __construct($client, $node, $vmid) { * @return Result */ public function mtunnel($bridges = null, $storages = null) { - $params = [ - 'bridges' => $bridges, - 'storages' => $storages - ]; + $params = ['bridges' => $bridges, + 'storages' => $storages]; return $this->client->create("/nodes/{$this->node}/qemu/{$this->vmid}/mtunnel", $params); } } /** * Class PVEVmidQemuNodeNodesMtunnelwebsocket - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEVmidQemuNodeNodesMtunnelwebsocket { @@ -10855,17 +11660,15 @@ function __construct($client, $node, $vmid) { * @return Result */ public function mtunnelwebsocket($socket, $ticket) { - $params = [ - 'socket' => $socket, - 'ticket' => $ticket - ]; + $params = ['socket' => $socket, + 'ticket' => $ticket]; return $this->client->get("/nodes/{$this->node}/qemu/{$this->vmid}/mtunnelwebsocket", $params); } } /** * Class PVENodeNodesLxc - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVENodeNodesLxc { @@ -10919,6 +11722,7 @@ public function vmlist() { * @param int $cpuunits CPU weight for a container, will be clamped to [1, 10000] in cgroup v2. * @param bool $debug Try to be more verbose. For now this only enables debug log-level on start. * @param string $description Description for the Container. Shown in the web-interface CT's summary. This is saved as comment inside the configuration file. + * @param array $devN Device to pass through to the container * @param string $features Allow containers access to advanced features. * @param bool $force Allow to overwrite existing container. * @param string $hookscript Script that will be exectued during various steps in the containers lifetime. @@ -10953,9 +11757,8 @@ public function vmlist() { * @param array $unusedN Reference to unused volumes. This is used internally, and should not be modified manually. * @return Result */ - public function createVm($ostemplate, $vmid, $arch = null, $bwlimit = null, $cmode = null, $console = null, $cores = null, $cpulimit = null, $cpuunits = null, $debug = null, $description = null, $features = null, $force = null, $hookscript = null, $hostname = null, $ignore_unpack_errors = null, $lock = null, $memory = null, $mpN = null, $nameserver = null, $netN = null, $onboot = null, $ostype = null, $password = null, $pool = null, $protection = null, $restore = null, $rootfs = null, $searchdomain = null, $ssh_public_keys = null, $start = null, $startup = null, $storage = null, $swap = null, $tags = null, $template = null, $timezone = null, $tty = null, $unique = null, $unprivileged = null, $unusedN = null) { - $params = [ - 'ostemplate' => $ostemplate, + public function createVm($ostemplate, $vmid, $arch = null, $bwlimit = null, $cmode = null, $console = null, $cores = null, $cpulimit = null, $cpuunits = null, $debug = null, $description = null, $devN = null, $features = null, $force = null, $hookscript = null, $hostname = null, $ignore_unpack_errors = null, $lock = null, $memory = null, $mpN = null, $nameserver = null, $netN = null, $onboot = null, $ostype = null, $password = null, $pool = null, $protection = null, $restore = null, $rootfs = null, $searchdomain = null, $ssh_public_keys = null, $start = null, $startup = null, $storage = null, $swap = null, $tags = null, $template = null, $timezone = null, $tty = null, $unique = null, $unprivileged = null, $unusedN = null) { + $params = ['ostemplate' => $ostemplate, 'vmid' => $vmid, 'arch' => $arch, 'bwlimit' => $bwlimit, @@ -10992,8 +11795,8 @@ public function createVm($ostemplate, $vmid, $arch = null, $bwlimit = null, $cmo 'timezone' => $timezone, 'tty' => $tty, 'unique' => $unique, - 'unprivileged' => $unprivileged - ]; + 'unprivileged' => $unprivileged]; + $this->client->addIndexedParameter($params, 'dev', $devN); $this->client->addIndexedParameter($params, 'mp', $mpN); $this->client->addIndexedParameter($params, 'net', $netN); $this->client->addIndexedParameter($params, 'unused', $unusedN); @@ -11003,7 +11806,7 @@ public function createVm($ostemplate, $vmid, $arch = null, $bwlimit = null, $cmo /** * Class PVEItemLxcNodeNodesVmid - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemLxcNodeNodesVmid { @@ -11265,6 +12068,19 @@ public function getPending() { return $this->pending ?: ($this->pending = new PVEVmidLxcNodeNodesPending($this->client, $this->node, $this->vmid)); } + /** + * @ignore + */ + private $interfaces; + + /** + * Get VmidLxcNodeNodesInterfaces + * @return PVEVmidLxcNodeNodesInterfaces + */ + public function getInterfaces() { + return $this->interfaces ?: ($this->interfaces = new PVEVmidLxcNodeNodesInterfaces($this->client, $this->node, $this->vmid)); + } + /** * @ignore */ @@ -11299,11 +12115,9 @@ public function getMtunnelwebsocket() { * @return Result */ public function destroyVm($destroy_unreferenced_disks = null, $force = null, $purge = null) { - $params = [ - 'destroy-unreferenced-disks' => $destroy_unreferenced_disks, + $params = ['destroy-unreferenced-disks' => $destroy_unreferenced_disks, 'force' => $force, - 'purge' => $purge - ]; + 'purge' => $purge]; return $this->client->delete("/nodes/{$this->node}/lxc/{$this->vmid}", $params); } @@ -11318,7 +12132,7 @@ public function vmdiridx() { /** * Class PVEVmidLxcNodeNodesConfig - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEVmidLxcNodeNodesConfig { @@ -11353,10 +12167,8 @@ function __construct($client, $node, $vmid) { * @return Result */ public function vmConfig($current = null, $snapshot = null) { - $params = [ - 'current' => $current, - 'snapshot' => $snapshot - ]; + $params = ['current' => $current, + 'snapshot' => $snapshot]; return $this->client->get("/nodes/{$this->node}/lxc/{$this->vmid}/config", $params); } @@ -11373,6 +12185,7 @@ public function vmConfig($current = null, $snapshot = null) { * @param bool $debug Try to be more verbose. For now this only enables debug log-level on start. * @param string $delete A list of settings you want to delete. * @param string $description Description for the Container. Shown in the web-interface CT's summary. This is saved as comment inside the configuration file. + * @param array $devN Device to pass through to the container * @param string $digest Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications. * @param string $features Allow containers access to advanced features. * @param string $hookscript Script that will be exectued during various steps in the containers lifetime. @@ -11400,9 +12213,8 @@ public function vmConfig($current = null, $snapshot = null) { * @param array $unusedN Reference to unused volumes. This is used internally, and should not be modified manually. * @return Result */ - public function updateVm($arch = null, $cmode = null, $console = null, $cores = null, $cpulimit = null, $cpuunits = null, $debug = null, $delete = null, $description = null, $digest = null, $features = null, $hookscript = null, $hostname = null, $lock = null, $memory = null, $mpN = null, $nameserver = null, $netN = null, $onboot = null, $ostype = null, $protection = null, $revert = null, $rootfs = null, $searchdomain = null, $startup = null, $swap = null, $tags = null, $template = null, $timezone = null, $tty = null, $unprivileged = null, $unusedN = null) { - $params = [ - 'arch' => $arch, + public function updateVm($arch = null, $cmode = null, $console = null, $cores = null, $cpulimit = null, $cpuunits = null, $debug = null, $delete = null, $description = null, $devN = null, $digest = null, $features = null, $hookscript = null, $hostname = null, $lock = null, $memory = null, $mpN = null, $nameserver = null, $netN = null, $onboot = null, $ostype = null, $protection = null, $revert = null, $rootfs = null, $searchdomain = null, $startup = null, $swap = null, $tags = null, $template = null, $timezone = null, $tty = null, $unprivileged = null, $unusedN = null) { + $params = ['arch' => $arch, 'cmode' => $cmode, 'console' => $console, 'cores' => $cores, @@ -11430,8 +12242,8 @@ public function updateVm($arch = null, $cmode = null, $console = null, $cores = 'template' => $template, 'timezone' => $timezone, 'tty' => $tty, - 'unprivileged' => $unprivileged - ]; + 'unprivileged' => $unprivileged]; + $this->client->addIndexedParameter($params, 'dev', $devN); $this->client->addIndexedParameter($params, 'mp', $mpN); $this->client->addIndexedParameter($params, 'net', $netN); $this->client->addIndexedParameter($params, 'unused', $unusedN); @@ -11441,7 +12253,7 @@ public function updateVm($arch = null, $cmode = null, $console = null, $cores = /** * Class PVEVmidLxcNodeNodesStatus - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEVmidLxcNodeNodesStatus { @@ -11571,7 +12383,7 @@ public function vmcmdidx() { /** * Class PVEStatusVmidLxcNodeNodesCurrent - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEStatusVmidLxcNodeNodesCurrent { @@ -11610,7 +12422,7 @@ public function vmStatus() { /** * Class PVEStatusVmidLxcNodeNodesStart - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEStatusVmidLxcNodeNodesStart { @@ -11645,17 +12457,15 @@ function __construct($client, $node, $vmid) { * @return Result */ public function vmStart($debug = null, $skiplock = null) { - $params = [ - 'debug' => $debug, - 'skiplock' => $skiplock - ]; + $params = ['debug' => $debug, + 'skiplock' => $skiplock]; return $this->client->create("/nodes/{$this->node}/lxc/{$this->vmid}/status/start", $params); } } /** * Class PVEStatusVmidLxcNodeNodesStop - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEStatusVmidLxcNodeNodesStop { @@ -11696,7 +12506,7 @@ public function vmStop($skiplock = null) { /** * Class PVEStatusVmidLxcNodeNodesShutdown - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEStatusVmidLxcNodeNodesShutdown { @@ -11731,17 +12541,15 @@ function __construct($client, $node, $vmid) { * @return Result */ public function vmShutdown($forceStop = null, $timeout = null) { - $params = [ - 'forceStop' => $forceStop, - 'timeout' => $timeout - ]; + $params = ['forceStop' => $forceStop, + 'timeout' => $timeout]; return $this->client->create("/nodes/{$this->node}/lxc/{$this->vmid}/status/shutdown", $params); } } /** * Class PVEStatusVmidLxcNodeNodesSuspend - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEStatusVmidLxcNodeNodesSuspend { @@ -11780,7 +12588,7 @@ public function vmSuspend() { /** * Class PVEStatusVmidLxcNodeNodesResume - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEStatusVmidLxcNodeNodesResume { @@ -11819,7 +12627,7 @@ public function vmResume() { /** * Class PVEStatusVmidLxcNodeNodesReboot - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEStatusVmidLxcNodeNodesReboot { @@ -11860,7 +12668,7 @@ public function vmReboot($timeout = null) { /** * Class PVEVmidLxcNodeNodesSnapshot - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEVmidLxcNodeNodesSnapshot { @@ -11912,17 +12720,15 @@ public function list_() { * @return Result */ public function snapshot($snapname, $description = null) { - $params = [ - 'snapname' => $snapname, - 'description' => $description - ]; + $params = ['snapname' => $snapname, + 'description' => $description]; return $this->client->create("/nodes/{$this->node}/lxc/{$this->vmid}/snapshot", $params); } } /** * Class PVEItemSnapshotVmidLxcNodeNodesSnapname - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemSnapshotVmidLxcNodeNodesSnapname { @@ -11993,7 +12799,7 @@ public function delsnapshot($force = null) { } /** - * + * * @return Result */ public function snapshotCmdIdx() { @@ -12003,7 +12809,7 @@ public function snapshotCmdIdx() { /** * Class PVESnapnameSnapshotVmidLxcNodeNodesRollback - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVESnapnameSnapshotVmidLxcNodeNodesRollback { @@ -12050,7 +12856,7 @@ public function rollback($start = null) { /** * Class PVESnapnameSnapshotVmidLxcNodeNodesConfig - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVESnapnameSnapshotVmidLxcNodeNodesConfig { @@ -12105,7 +12911,7 @@ public function updateSnapshotConfig($description = null) { /** * Class PVEVmidLxcNodeNodesFirewall - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEVmidLxcNodeNodesFirewall { @@ -12222,7 +13028,7 @@ public function index() { /** * Class PVEFirewallVmidLxcNodeNodesRules - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEFirewallVmidLxcNodeNodesRules { @@ -12274,7 +13080,7 @@ public function getRules() { * Enum: in,out,group * @param string $comment Descriptive comment. * @param string $dest Restrict packet destination address. This can refer to a single IP address, an IP set ('+ipsetname') or an IP alias definition. You can also specify an address range like '20.34.101.207-201.3.9.99', or a list of IP addresses and networks (entries are separated by comma). Please do not mix IPv4 and IPv6 addresses inside such lists. - * @param string $digest Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications. + * @param string $digest Prevent changes if current configuration file has a different digest. This can be used to prevent concurrent modifications. * @param string $dport Restrict TCP/UDP destination port. You can use service names or simple numbers (0-65535), as defined in '/etc/services'. Port ranges can be specified with '\d+:\d+', for example '80:85', and you can use comma separated list to match several ports or ranges. * @param int $enable Flag to enable/disable a rule. * @param string $icmp_type Specify icmp-type. Only valid if proto equals 'icmp' or 'icmpv6'/'ipv6-icmp'. @@ -12289,8 +13095,7 @@ public function getRules() { * @return Result */ public function createRule($action, $type, $comment = null, $dest = null, $digest = null, $dport = null, $enable = null, $icmp_type = null, $iface = null, $log = null, $macro = null, $pos = null, $proto = null, $source = null, $sport = null) { - $params = [ - 'action' => $action, + $params = ['action' => $action, 'type' => $type, 'comment' => $comment, 'dest' => $dest, @@ -12304,15 +13109,14 @@ public function createRule($action, $type, $comment = null, $dest = null, $diges 'pos' => $pos, 'proto' => $proto, 'source' => $source, - 'sport' => $sport - ]; + 'sport' => $sport]; return $this->client->create("/nodes/{$this->node}/lxc/{$this->vmid}/firewall/rules", $params); } } /** * Class PVEItemRulesFirewallVmidLxcNodeNodesPos - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemRulesFirewallVmidLxcNodeNodesPos { @@ -12348,7 +13152,7 @@ function __construct($client, $node, $vmid, $pos) { /** * Delete rule. - * @param string $digest Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications. + * @param string $digest Prevent changes if current configuration file has a different digest. This can be used to prevent concurrent modifications. * @return Result */ public function deleteRule($digest = null) { @@ -12370,7 +13174,7 @@ public function getRule() { * @param string $comment Descriptive comment. * @param string $delete A list of settings you want to delete. * @param string $dest Restrict packet destination address. This can refer to a single IP address, an IP set ('+ipsetname') or an IP alias definition. You can also specify an address range like '20.34.101.207-201.3.9.99', or a list of IP addresses and networks (entries are separated by comma). Please do not mix IPv4 and IPv6 addresses inside such lists. - * @param string $digest Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications. + * @param string $digest Prevent changes if current configuration file has a different digest. This can be used to prevent concurrent modifications. * @param string $dport Restrict TCP/UDP destination port. You can use service names or simple numbers (0-65535), as defined in '/etc/services'. Port ranges can be specified with '\d+:\d+', for example '80:85', and you can use comma separated list to match several ports or ranges. * @param int $enable Flag to enable/disable a rule. * @param string $icmp_type Specify icmp-type. Only valid if proto equals 'icmp' or 'icmpv6'/'ipv6-icmp'. @@ -12387,8 +13191,7 @@ public function getRule() { * @return Result */ public function updateRule($action = null, $comment = null, $delete = null, $dest = null, $digest = null, $dport = null, $enable = null, $icmp_type = null, $iface = null, $log = null, $macro = null, $moveto = null, $proto = null, $source = null, $sport = null, $type = null) { - $params = [ - 'action' => $action, + $params = ['action' => $action, 'comment' => $comment, 'delete' => $delete, 'dest' => $dest, @@ -12403,15 +13206,14 @@ public function updateRule($action = null, $comment = null, $delete = null, $des 'proto' => $proto, 'source' => $source, 'sport' => $sport, - 'type' => $type - ]; + 'type' => $type]; return $this->client->set("/nodes/{$this->node}/lxc/{$this->vmid}/firewall/rules/{$this->pos}", $params); } } /** * Class PVEFirewallVmidLxcNodeNodesAliases - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEFirewallVmidLxcNodeNodesAliases { @@ -12460,22 +13262,20 @@ public function getAliases() { * Create IP or Network Alias. * @param string $cidr Network/IP specification in CIDR format. * @param string $name Alias name. - * @param string $comment + * @param string $comment * @return Result */ public function createAlias($cidr, $name, $comment = null) { - $params = [ - 'cidr' => $cidr, + $params = ['cidr' => $cidr, 'name' => $name, - 'comment' => $comment - ]; + 'comment' => $comment]; return $this->client->create("/nodes/{$this->node}/lxc/{$this->vmid}/firewall/aliases", $params); } } /** * Class PVEItemAliasesFirewallVmidLxcNodeNodesName - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemAliasesFirewallVmidLxcNodeNodesName { @@ -12511,7 +13311,7 @@ function __construct($client, $node, $vmid, $name) { /** * Remove IP or Network alias. - * @param string $digest Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications. + * @param string $digest Prevent changes if current configuration file has a different digest. This can be used to prevent concurrent modifications. * @return Result */ public function removeAlias($digest = null) { @@ -12530,25 +13330,23 @@ public function readAlias() { /** * Update IP or Network alias. * @param string $cidr Network/IP specification in CIDR format. - * @param string $comment - * @param string $digest Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications. + * @param string $comment + * @param string $digest Prevent changes if current configuration file has a different digest. This can be used to prevent concurrent modifications. * @param string $rename Rename an existing alias. * @return Result */ public function updateAlias($cidr, $comment = null, $digest = null, $rename = null) { - $params = [ - 'cidr' => $cidr, + $params = ['cidr' => $cidr, 'comment' => $comment, 'digest' => $digest, - 'rename' => $rename - ]; + 'rename' => $rename]; return $this->client->set("/nodes/{$this->node}/lxc/{$this->vmid}/firewall/aliases/{$this->name}", $params); } } /** * Class PVEFirewallVmidLxcNodeNodesIpset - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEFirewallVmidLxcNodeNodesIpset { @@ -12596,25 +13394,23 @@ public function ipsetIndex() { /** * Create new IPSet * @param string $name IP set name. - * @param string $comment - * @param string $digest Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications. + * @param string $comment + * @param string $digest Prevent changes if current configuration file has a different digest. This can be used to prevent concurrent modifications. * @param string $rename Rename an existing IPSet. You can set 'rename' to the same value as 'name' to update the 'comment' of an existing IPSet. * @return Result */ public function createIpset($name, $comment = null, $digest = null, $rename = null) { - $params = [ - 'name' => $name, + $params = ['name' => $name, 'comment' => $comment, 'digest' => $digest, - 'rename' => $rename - ]; + 'rename' => $rename]; return $this->client->create("/nodes/{$this->node}/lxc/{$this->vmid}/firewall/ipset", $params); } } /** * Class PVEItemIpsetFirewallVmidLxcNodeNodesName - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemIpsetFirewallVmidLxcNodeNodesName { @@ -12678,23 +13474,21 @@ public function getIpset() { /** * Add IP or Network to IPSet. * @param string $cidr Network/IP specification in CIDR format. - * @param string $comment - * @param bool $nomatch + * @param string $comment + * @param bool $nomatch * @return Result */ public function createIp($cidr, $comment = null, $nomatch = null) { - $params = [ - 'cidr' => $cidr, + $params = ['cidr' => $cidr, 'comment' => $comment, - 'nomatch' => $nomatch - ]; + 'nomatch' => $nomatch]; return $this->client->create("/nodes/{$this->node}/lxc/{$this->vmid}/firewall/ipset/{$this->name}", $params); } } /** * Class PVEItemNameIpsetFirewallVmidLxcNodeNodesCidr - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemNameIpsetFirewallVmidLxcNodeNodesCidr { @@ -12736,7 +13530,7 @@ function __construct($client, $node, $vmid, $name, $cidr) { /** * Remove IP or Network from IPSet. - * @param string $digest Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications. + * @param string $digest Prevent changes if current configuration file has a different digest. This can be used to prevent concurrent modifications. * @return Result */ public function removeIp($digest = null) { @@ -12754,24 +13548,22 @@ public function readIp() { /** * Update IP or Network settings - * @param string $comment - * @param string $digest Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications. - * @param bool $nomatch + * @param string $comment + * @param string $digest Prevent changes if current configuration file has a different digest. This can be used to prevent concurrent modifications. + * @param bool $nomatch * @return Result */ public function updateIp($comment = null, $digest = null, $nomatch = null) { - $params = [ - 'comment' => $comment, + $params = ['comment' => $comment, 'digest' => $digest, - 'nomatch' => $nomatch - ]; + 'nomatch' => $nomatch]; return $this->client->set("/nodes/{$this->node}/lxc/{$this->vmid}/firewall/ipset/{$this->name}/{$this->cidr}", $params); } } /** * Class PVEFirewallVmidLxcNodeNodesOptions - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEFirewallVmidLxcNodeNodesOptions { @@ -12811,7 +13603,7 @@ public function getOptions() { * Set Firewall options. * @param string $delete A list of settings you want to delete. * @param bool $dhcp Enable DHCP. - * @param string $digest Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications. + * @param string $digest Prevent changes if current configuration file has a different digest. This can be used to prevent concurrent modifications. * @param bool $enable Enable/disable firewall rules. * @param bool $ipfilter Enable default IP filters. This is equivalent to adding an empty ipfilter-net<id> ipset for every interface. Such ipsets implicitly contain sane default restrictions such as restricting IPv6 link local addresses to the one derived from the interface's MAC address. For containers the configured IP addresses will be implicitly added. * @param string $log_level_in Log level for incoming traffic. @@ -12828,8 +13620,7 @@ public function getOptions() { * @return Result */ public function setOptions($delete = null, $dhcp = null, $digest = null, $enable = null, $ipfilter = null, $log_level_in = null, $log_level_out = null, $macfilter = null, $ndp = null, $policy_in = null, $policy_out = null, $radv = null) { - $params = [ - 'delete' => $delete, + $params = ['delete' => $delete, 'dhcp' => $dhcp, 'digest' => $digest, 'enable' => $enable, @@ -12840,15 +13631,14 @@ public function setOptions($delete = null, $dhcp = null, $digest = null, $enable 'ndp' => $ndp, 'policy_in' => $policy_in, 'policy_out' => $policy_out, - 'radv' => $radv - ]; + 'radv' => $radv]; return $this->client->set("/nodes/{$this->node}/lxc/{$this->vmid}/firewall/options", $params); } } /** * Class PVEFirewallVmidLxcNodeNodesLog - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEFirewallVmidLxcNodeNodesLog { @@ -12878,26 +13668,24 @@ function __construct($client, $node, $vmid) { /** * Read firewall log - * @param int $limit + * @param int $limit * @param int $since Display log since this UNIX epoch. - * @param int $start + * @param int $start * @param int $until Display log until this UNIX epoch. * @return Result */ public function log($limit = null, $since = null, $start = null, $until = null) { - $params = [ - 'limit' => $limit, + $params = ['limit' => $limit, 'since' => $since, 'start' => $start, - 'until' => $until - ]; + 'until' => $until]; return $this->client->get("/nodes/{$this->node}/lxc/{$this->vmid}/firewall/log", $params); } } /** * Class PVEFirewallVmidLxcNodeNodesRefs - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEFirewallVmidLxcNodeNodesRefs { @@ -12939,7 +13727,7 @@ public function refs($type = null) { /** * Class PVEVmidLxcNodeNodesRrd - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEVmidLxcNodeNodesRrd { @@ -12977,18 +13765,16 @@ function __construct($client, $node, $vmid) { * @return Result */ public function rrd($ds, $timeframe, $cf = null) { - $params = [ - 'ds' => $ds, + $params = ['ds' => $ds, 'timeframe' => $timeframe, - 'cf' => $cf - ]; + 'cf' => $cf]; return $this->client->get("/nodes/{$this->node}/lxc/{$this->vmid}/rrd", $params); } } /** * Class PVEVmidLxcNodeNodesRrddata - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEVmidLxcNodeNodesRrddata { @@ -13025,17 +13811,15 @@ function __construct($client, $node, $vmid) { * @return Result */ public function rrddata($timeframe, $cf = null) { - $params = [ - 'timeframe' => $timeframe, - 'cf' => $cf - ]; + $params = ['timeframe' => $timeframe, + 'cf' => $cf]; return $this->client->get("/nodes/{$this->node}/lxc/{$this->vmid}/rrddata", $params); } } /** * Class PVEVmidLxcNodeNodesVncproxy - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEVmidLxcNodeNodesVncproxy { @@ -13071,18 +13855,16 @@ function __construct($client, $node, $vmid) { * @return Result */ public function vncproxy($height = null, $websocket = null, $width = null) { - $params = [ - 'height' => $height, + $params = ['height' => $height, 'websocket' => $websocket, - 'width' => $width - ]; + 'width' => $width]; return $this->client->create("/nodes/{$this->node}/lxc/{$this->vmid}/vncproxy", $params); } } /** * Class PVEVmidLxcNodeNodesTermproxy - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEVmidLxcNodeNodesTermproxy { @@ -13121,7 +13903,7 @@ public function termproxy() { /** * Class PVEVmidLxcNodeNodesVncwebsocket - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEVmidLxcNodeNodesVncwebsocket { @@ -13156,17 +13938,15 @@ function __construct($client, $node, $vmid) { * @return Result */ public function vncwebsocket($port, $vncticket) { - $params = [ - 'port' => $port, - 'vncticket' => $vncticket - ]; + $params = ['port' => $port, + 'vncticket' => $vncticket]; return $this->client->get("/nodes/{$this->node}/lxc/{$this->vmid}/vncwebsocket", $params); } } /** * Class PVEVmidLxcNodeNodesSpiceproxy - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEVmidLxcNodeNodesSpiceproxy { @@ -13207,7 +13987,7 @@ public function spiceproxy($proxy = null) { /** * Class PVEVmidLxcNodeNodesRemoteMigrate - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEVmidLxcNodeNodesRemoteMigrate { @@ -13249,8 +14029,7 @@ function __construct($client, $node, $vmid) { * @return Result */ public function remoteMigrateVm($target_bridge, $target_endpoint, $target_storage, $bwlimit = null, $delete = null, $online = null, $restart = null, $target_vmid = null, $timeout = null) { - $params = [ - 'target-bridge' => $target_bridge, + $params = ['target-bridge' => $target_bridge, 'target-endpoint' => $target_endpoint, 'target-storage' => $target_storage, 'bwlimit' => $bwlimit, @@ -13258,15 +14037,14 @@ public function remoteMigrateVm($target_bridge, $target_endpoint, $target_storag 'online' => $online, 'restart' => $restart, 'target-vmid' => $target_vmid, - 'timeout' => $timeout - ]; + 'timeout' => $timeout]; return $this->client->create("/nodes/{$this->node}/lxc/{$this->vmid}/remote_migrate", $params); } } /** * Class PVEVmidLxcNodeNodesMigrate - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEVmidLxcNodeNodesMigrate { @@ -13305,21 +14083,19 @@ function __construct($client, $node, $vmid) { * @return Result */ public function migrateVm($target, $bwlimit = null, $online = null, $restart = null, $target_storage = null, $timeout = null) { - $params = [ - 'target' => $target, + $params = ['target' => $target, 'bwlimit' => $bwlimit, 'online' => $online, 'restart' => $restart, 'target-storage' => $target_storage, - 'timeout' => $timeout - ]; + 'timeout' => $timeout]; return $this->client->create("/nodes/{$this->node}/lxc/{$this->vmid}/migrate", $params); } } /** * Class PVEVmidLxcNodeNodesFeature - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEVmidLxcNodeNodesFeature { @@ -13355,17 +14131,15 @@ function __construct($client, $node, $vmid) { * @return Result */ public function vmFeature($feature, $snapname = null) { - $params = [ - 'feature' => $feature, - 'snapname' => $snapname - ]; + $params = ['feature' => $feature, + 'snapname' => $snapname]; return $this->client->get("/nodes/{$this->node}/lxc/{$this->vmid}/feature", $params); } } /** * Class PVEVmidLxcNodeNodesTemplate - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEVmidLxcNodeNodesTemplate { @@ -13404,7 +14178,7 @@ public function template() { /** * Class PVEVmidLxcNodeNodesClone - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEVmidLxcNodeNodesClone { @@ -13446,8 +14220,7 @@ function __construct($client, $node, $vmid) { * @return Result */ public function cloneVm($newid, $bwlimit = null, $description = null, $full = null, $hostname = null, $pool = null, $snapname = null, $storage = null, $target = null) { - $params = [ - 'newid' => $newid, + $params = ['newid' => $newid, 'bwlimit' => $bwlimit, 'description' => $description, 'full' => $full, @@ -13455,15 +14228,14 @@ public function cloneVm($newid, $bwlimit = null, $description = null, $full = nu 'pool' => $pool, 'snapname' => $snapname, 'storage' => $storage, - 'target' => $target - ]; + 'target' => $target]; return $this->client->create("/nodes/{$this->node}/lxc/{$this->vmid}/clone", $params); } } /** * Class PVEVmidLxcNodeNodesResize - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEVmidLxcNodeNodesResize { @@ -13500,18 +14272,16 @@ function __construct($client, $node, $vmid) { * @return Result */ public function resizeVm($disk, $size, $digest = null) { - $params = [ - 'disk' => $disk, + $params = ['disk' => $disk, 'size' => $size, - 'digest' => $digest - ]; + 'digest' => $digest]; return $this->client->set("/nodes/{$this->node}/lxc/{$this->vmid}/resize", $params); } } /** * Class PVEVmidLxcNodeNodesMoveVolume - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEVmidLxcNodeNodesMoveVolume { @@ -13554,23 +14324,21 @@ function __construct($client, $node, $vmid) { * @return Result */ public function moveVolume($volume, $bwlimit = null, $delete = null, $digest = null, $storage = null, $target_digest = null, $target_vmid = null, $target_volume = null) { - $params = [ - 'volume' => $volume, + $params = ['volume' => $volume, 'bwlimit' => $bwlimit, 'delete' => $delete, 'digest' => $digest, 'storage' => $storage, 'target-digest' => $target_digest, 'target-vmid' => $target_vmid, - 'target-volume' => $target_volume - ]; + 'target-volume' => $target_volume]; return $this->client->create("/nodes/{$this->node}/lxc/{$this->vmid}/move_volume", $params); } } /** * Class PVEVmidLxcNodeNodesPending - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEVmidLxcNodeNodesPending { @@ -13607,9 +14375,48 @@ public function vmPending() { } } + /** + * Class PVEVmidLxcNodeNodesInterfaces + * @package Corsinvest\VE\ProxmoxVE\Api + */ + class PVEVmidLxcNodeNodesInterfaces { + + /** + * @ignore + */ + private $node; + + /** + * @ignore + */ + private $vmid; + + /** + * @ignore + */ + private $client; + + /** + * @ignore + */ + function __construct($client, $node, $vmid) { + $this->client = $client; + $this->node = $node; + $this->vmid = $vmid; + } + + /** + * Get IP addresses of the specified container interface. + * @return Result + */ + public function ip() { + return $this->client->get("/nodes/{$this->node}/lxc/{$this->vmid}/interfaces"); + } + } + /** * Class PVEVmidLxcNodeNodesMtunnel - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEVmidLxcNodeNodesMtunnel { @@ -13644,17 +14451,15 @@ function __construct($client, $node, $vmid) { * @return Result */ public function mtunnel($bridges = null, $storages = null) { - $params = [ - 'bridges' => $bridges, - 'storages' => $storages - ]; + $params = ['bridges' => $bridges, + 'storages' => $storages]; return $this->client->create("/nodes/{$this->node}/lxc/{$this->vmid}/mtunnel", $params); } } /** * Class PVEVmidLxcNodeNodesMtunnelwebsocket - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEVmidLxcNodeNodesMtunnelwebsocket { @@ -13689,17 +14494,15 @@ function __construct($client, $node, $vmid) { * @return Result */ public function mtunnelwebsocket($socket, $ticket) { - $params = [ - 'socket' => $socket, - 'ticket' => $ticket - ]; + $params = ['socket' => $socket, + 'ticket' => $ticket]; return $this->client->get("/nodes/{$this->node}/lxc/{$this->vmid}/mtunnelwebsocket", $params); } } /** * Class PVENodeNodesCeph - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVENodeNodesCeph { @@ -13940,7 +14743,7 @@ public function index() { /** * Class PVECephNodeNodesCfg - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVECephNodeNodesCfg { @@ -13988,6 +14791,19 @@ public function getDb() { return $this->db ?: ($this->db = new PVECfgCephNodeNodesDb($this->client, $this->node)); } + /** + * @ignore + */ + private $value; + + /** + * Get CfgCephNodeNodesValue + * @return PVECfgCephNodeNodesValue + */ + public function getValue() { + return $this->value ?: ($this->value = new PVECfgCephNodeNodesValue($this->client, $this->node)); + } + /** * Directory index. * @return Result @@ -13999,7 +14815,7 @@ public function index() { /** * Class PVECfgCephNodeNodesRaw - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVECfgCephNodeNodesRaw { @@ -14032,7 +14848,7 @@ public function raw() { /** * Class PVECfgCephNodeNodesDb - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVECfgCephNodeNodesDb { @@ -14063,9 +14879,44 @@ public function db() { } } + /** + * Class PVECfgCephNodeNodesValue + * @package Corsinvest\VE\ProxmoxVE\Api + */ + class PVECfgCephNodeNodesValue { + + /** + * @ignore + */ + private $node; + + /** + * @ignore + */ + private $client; + + /** + * @ignore + */ + function __construct($client, $node) { + $this->client = $client; + $this->node = $node; + } + + /** + * Get configured values from either the config file or config DB. + * @param string $config_keys List of <section>:<config key> items. + * @return Result + */ + public function value($config_keys) { + $params = ['config-keys' => $config_keys]; + return $this->client->get("/nodes/{$this->node}/ceph/cfg/value", $params); + } + } + /** * Class PVECephNodeNodesOsd - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVECephNodeNodesOsd { @@ -14111,27 +14962,27 @@ public function index() { * @param string $db_dev Block device name for block.db. * @param float $db_dev_size Size in GiB for block.db. * @param bool $encrypted Enables encryption of the OSD. + * @param int $osds_per_device OSD services per physical device. Only useful for fast NVMe devices" ." to utilize their performance better. * @param string $wal_dev Block device name for block.wal. * @param float $wal_dev_size Size in GiB for block.wal. * @return Result */ - public function createosd($dev, $crush_device_class = null, $db_dev = null, $db_dev_size = null, $encrypted = null, $wal_dev = null, $wal_dev_size = null) { - $params = [ - 'dev' => $dev, + public function createosd($dev, $crush_device_class = null, $db_dev = null, $db_dev_size = null, $encrypted = null, $osds_per_device = null, $wal_dev = null, $wal_dev_size = null) { + $params = ['dev' => $dev, 'crush-device-class' => $crush_device_class, 'db_dev' => $db_dev, 'db_dev_size' => $db_dev_size, 'encrypted' => $encrypted, + 'osds-per-device' => $osds_per_device, 'wal_dev' => $wal_dev, - 'wal_dev_size' => $wal_dev_size - ]; + 'wal_dev_size' => $wal_dev_size]; return $this->client->create("/nodes/{$this->node}/ceph/osd", $params); } } /** * Class PVEItemOsdCephNodeNodesOsdid - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemOsdCephNodeNodesOsdid { @@ -14245,7 +15096,7 @@ public function osdindex() { /** * Class PVEOsdidOsdCephNodeNodesMetadata - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEOsdidOsdCephNodeNodesMetadata { @@ -14284,7 +15135,7 @@ public function osddetails() { /** * Class PVEOsdidOsdCephNodeNodesLvInfo - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEOsdidOsdCephNodeNodesLvInfo { @@ -14326,7 +15177,7 @@ public function osdvolume($type = null) { /** * Class PVEOsdidOsdCephNodeNodesIn - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEOsdidOsdCephNodeNodesIn { @@ -14365,7 +15216,7 @@ public function in() { /** * Class PVEOsdidOsdCephNodeNodesOut - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEOsdidOsdCephNodeNodesOut { @@ -14404,7 +15255,7 @@ public function out() { /** * Class PVEOsdidOsdCephNodeNodesScrub - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEOsdidOsdCephNodeNodesScrub { @@ -14445,7 +15296,7 @@ public function scrub($deep = null) { /** * Class PVECephNodeNodesMds - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVECephNodeNodesMds { @@ -14487,7 +15338,7 @@ public function index() { /** * Class PVEItemMdsCephNodeNodesName - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemMdsCephNodeNodesName { @@ -14536,7 +15387,7 @@ public function createmds($hotstandby = null) { /** * Class PVECephNodeNodesMgr - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVECephNodeNodesMgr { @@ -14578,7 +15429,7 @@ public function index() { /** * Class PVEItemMgrCephNodeNodesId - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemMgrCephNodeNodesId { @@ -14625,7 +15476,7 @@ public function createmgr() { /** * Class PVECephNodeNodesMon - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVECephNodeNodesMon { @@ -14667,7 +15518,7 @@ public function listmon() { /** * Class PVEItemMonCephNodeNodesMonid - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemMonCephNodeNodesMonid { @@ -14716,7 +15567,7 @@ public function createmon($mon_address = null) { /** * Class PVECephNodeNodesFs - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVECephNodeNodesFs { @@ -14758,7 +15609,7 @@ public function index() { /** * Class PVEItemFsCephNodeNodesName - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemFsCephNodeNodesName { @@ -14793,17 +15644,15 @@ function __construct($client, $node, $name) { * @return Result */ public function createfs($add_storage = null, $pg_num = null) { - $params = [ - 'add-storage' => $add_storage, - 'pg_num' => $pg_num - ]; + $params = ['add-storage' => $add_storage, + 'pg_num' => $pg_num]; return $this->client->create("/nodes/{$this->node}/ceph/fs/{$this->name}", $params); } } /** * Class PVECephNodeNodesPool - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVECephNodeNodesPool { @@ -14861,8 +15710,7 @@ public function lspools() { * @return Result */ public function createpool($name, $add_storages = null, $application = null, $crush_rule = null, $erasure_coding = null, $min_size = null, $pg_autoscale_mode = null, $pg_num = null, $pg_num_min = null, $size = null, $target_size = null, $target_size_ratio = null) { - $params = [ - 'name' => $name, + $params = ['name' => $name, 'add_storages' => $add_storages, 'application' => $application, 'crush_rule' => $crush_rule, @@ -14873,15 +15721,14 @@ public function createpool($name, $add_storages = null, $application = null, $cr 'pg_num_min' => $pg_num_min, 'size' => $size, 'target_size' => $target_size, - 'target_size_ratio' => $target_size_ratio - ]; + 'target_size_ratio' => $target_size_ratio]; return $this->client->create("/nodes/{$this->node}/ceph/pool", $params); } } /** * Class PVEItemPoolCephNodeNodesName - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemPoolCephNodeNodesName { @@ -14930,11 +15777,9 @@ public function getStatus() { * @return Result */ public function destroypool($force = null, $remove_ecprofile = null, $remove_storages = null) { - $params = [ - 'force' => $force, + $params = ['force' => $force, 'remove_ecprofile' => $remove_ecprofile, - 'remove_storages' => $remove_storages - ]; + 'remove_storages' => $remove_storages]; return $this->client->delete("/nodes/{$this->node}/ceph/pool/{$this->name}", $params); } @@ -14962,8 +15807,7 @@ public function poolindex() { * @return Result */ public function setpool($application = null, $crush_rule = null, $min_size = null, $pg_autoscale_mode = null, $pg_num = null, $pg_num_min = null, $size = null, $target_size = null, $target_size_ratio = null) { - $params = [ - 'application' => $application, + $params = ['application' => $application, 'crush_rule' => $crush_rule, 'min_size' => $min_size, 'pg_autoscale_mode' => $pg_autoscale_mode, @@ -14971,15 +15815,14 @@ public function setpool($application = null, $crush_rule = null, $min_size = nul 'pg_num_min' => $pg_num_min, 'size' => $size, 'target_size' => $target_size, - 'target_size_ratio' => $target_size_ratio - ]; + 'target_size_ratio' => $target_size_ratio]; return $this->client->set("/nodes/{$this->node}/ceph/pool/{$this->name}", $params); } } /** * Class PVENamePoolCephNodeNodesStatus - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVENamePoolCephNodeNodesStatus { @@ -15020,7 +15863,7 @@ public function getpool($verbose = null) { /** * Class PVECephNodeNodesInit - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVECephNodeNodesInit { @@ -15048,26 +15891,24 @@ function __construct($client, $node) { * @param bool $disable_cephx Disable cephx authentication. WARNING: cephx is a security feature protecting against man-in-the-middle attacks. Only consider disabling cephx if your network is private! * @param int $min_size Minimum number of available replicas per object to allow I/O * @param string $network Use specific network for all ceph related traffic - * @param int $pg_bits Placement group bits, used to specify the default number of placement groups. NOTE: 'osd pool default pg num' does not work for default pools. + * @param int $pg_bits Placement group bits, used to specify the default number of placement groups. Depreacted. This setting was deprecated in recent Ceph versions. * @param int $size Targeted number of replicas per object * @return Result */ public function init($cluster_network = null, $disable_cephx = null, $min_size = null, $network = null, $pg_bits = null, $size = null) { - $params = [ - 'cluster-network' => $cluster_network, + $params = ['cluster-network' => $cluster_network, 'disable_cephx' => $disable_cephx, 'min_size' => $min_size, 'network' => $network, 'pg_bits' => $pg_bits, - 'size' => $size - ]; + 'size' => $size]; return $this->client->create("/nodes/{$this->node}/ceph/init", $params); } } /** * Class PVECephNodeNodesStop - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVECephNodeNodesStop { @@ -15102,7 +15943,7 @@ public function stop($service = null) { /** * Class PVECephNodeNodesStart - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVECephNodeNodesStart { @@ -15137,7 +15978,7 @@ public function start($service = null) { /** * Class PVECephNodeNodesRestart - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVECephNodeNodesRestart { @@ -15172,7 +16013,7 @@ public function restart($service = null) { /** * Class PVECephNodeNodesStatus - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVECephNodeNodesStatus { @@ -15205,7 +16046,7 @@ public function status() { /** * Class PVECephNodeNodesCrush - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVECephNodeNodesCrush { @@ -15238,7 +16079,7 @@ public function crush() { /** * Class PVECephNodeNodesLog - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVECephNodeNodesLog { @@ -15262,22 +16103,20 @@ function __construct($client, $node) { /** * Read ceph log - * @param int $limit - * @param int $start + * @param int $limit + * @param int $start * @return Result */ public function log($limit = null, $start = null) { - $params = [ - 'limit' => $limit, - 'start' => $start - ]; + $params = ['limit' => $limit, + 'start' => $start]; return $this->client->get("/nodes/{$this->node}/ceph/log", $params); } } /** * Class PVECephNodeNodesRules - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVECephNodeNodesRules { @@ -15310,7 +16149,7 @@ public function rules() { /** * Class PVECephNodeNodesCmdSafety - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVECephNodeNodesCmdSafety { @@ -15342,18 +16181,16 @@ function __construct($client, $node) { * @return Result */ public function cmdSafety($action, $id, $service) { - $params = [ - 'action' => $action, + $params = ['action' => $action, 'id' => $id, - 'service' => $service - ]; + 'service' => $service]; return $this->client->get("/nodes/{$this->node}/ceph/cmd-safety", $params); } } /** * Class PVENodeNodesVzdump - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVENodeNodesVzdump { @@ -15412,13 +16249,16 @@ public function getExtractconfig() { * @param string $exclude_path Exclude certain files/directories (shell globs). Paths starting with '/' are anchored to the container's root, other paths match relative to each subdirectory. * @param int $ionice Set IO priority when using the BFQ scheduler. For snapshot and suspend mode backups of VMs, this only affects the compressor. A value of 8 means the idle priority is used, otherwise the best-effort priority is used with the specified value. * @param int $lockwait Maximal time to wait for the global lock (minutes). - * @param string $mailnotification Specify when to send an email + * @param string $mailnotification Deprecated: use 'notification-policy' instead. * Enum: always,failure - * @param string $mailto Comma-separated list of email addresses or users that should receive email notifications. + * @param string $mailto Comma-separated list of email addresses or users that should receive email notifications. Has no effect if the 'notification-target' option is set at the same time. * @param int $maxfiles Deprecated: use 'prune-backups' instead. Maximal number of backup files per guest system. * @param string $mode Backup mode. * Enum: snapshot,suspend,stop * @param string $notes_template Template string for generating notes for the backup(s). It can contain variables which will be replaced by their values. Currently supported are {{cluster}}, {{guestname}}, {{node}}, and {{vmid}}, but more might be added in the future. Needs to be a single line, newline and backslash need to be escaped as '\n' and '\\' respectively. + * @param string $notification_policy Specify when to send a notification + * Enum: always,failure,never + * @param string $notification_target Determine the target to which notifications should be sent. Can either be a notification endpoint or a notification group. This option takes precedence over 'mailto', meaning that if both are set, the 'mailto' option will be ignored. * @param string $performance Other performance-related settings. * @param int $pigz Use pigz instead of gzip when N>0. N=1 uses half of cores, N>1 uses N as thread count. * @param string $pool Backup all known guest systems included in the specified pool. @@ -15437,9 +16277,8 @@ public function getExtractconfig() { * @param int $zstd Zstd threads. N=0 uses half of the available cores, N>0 uses N as thread count. * @return Result */ - public function vzdump($all = null, $bwlimit = null, $compress = null, $dumpdir = null, $exclude = null, $exclude_path = null, $ionice = null, $lockwait = null, $mailnotification = null, $mailto = null, $maxfiles = null, $mode = null, $notes_template = null, $performance = null, $pigz = null, $pool = null, $protected = null, $prune_backups = null, $quiet = null, $remove = null, $script = null, $stdexcludes = null, $stdout = null, $stop = null, $stopwait = null, $storage = null, $tmpdir = null, $vmid = null, $zstd = null) { - $params = [ - 'all' => $all, + public function vzdump($all = null, $bwlimit = null, $compress = null, $dumpdir = null, $exclude = null, $exclude_path = null, $ionice = null, $lockwait = null, $mailnotification = null, $mailto = null, $maxfiles = null, $mode = null, $notes_template = null, $notification_policy = null, $notification_target = null, $performance = null, $pigz = null, $pool = null, $protected = null, $prune_backups = null, $quiet = null, $remove = null, $script = null, $stdexcludes = null, $stdout = null, $stop = null, $stopwait = null, $storage = null, $tmpdir = null, $vmid = null, $zstd = null) { + $params = ['all' => $all, 'bwlimit' => $bwlimit, 'compress' => $compress, 'dumpdir' => $dumpdir, @@ -15452,6 +16291,8 @@ public function vzdump($all = null, $bwlimit = null, $compress = null, $dumpdir 'maxfiles' => $maxfiles, 'mode' => $mode, 'notes-template' => $notes_template, + 'notification-policy' => $notification_policy, + 'notification-target' => $notification_target, 'performance' => $performance, 'pigz' => $pigz, 'pool' => $pool, @@ -15467,15 +16308,14 @@ public function vzdump($all = null, $bwlimit = null, $compress = null, $dumpdir 'storage' => $storage, 'tmpdir' => $tmpdir, 'vmid' => $vmid, - 'zstd' => $zstd - ]; + 'zstd' => $zstd]; return $this->client->create("/nodes/{$this->node}/vzdump", $params); } } /** * Class PVEVzdumpNodeNodesDefaults - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEVzdumpNodeNodesDefaults { @@ -15510,7 +16350,7 @@ public function defaults($storage = null) { /** * Class PVEVzdumpNodeNodesExtractconfig - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEVzdumpNodeNodesExtractconfig { @@ -15545,7 +16385,7 @@ public function extractconfig($volume) { /** * Class PVENodeNodesServices - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVENodeNodesServices { @@ -15587,7 +16427,7 @@ public function index() { /** * Class PVEItemServicesNodeNodesService - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemServicesNodeNodesService { @@ -15691,7 +16531,7 @@ public function srvcmdidx() { /** * Class PVEServiceServicesNodeNodesState - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEServiceServicesNodeNodesState { @@ -15730,7 +16570,7 @@ public function serviceState() { /** * Class PVEServiceServicesNodeNodesStart - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEServiceServicesNodeNodesStart { @@ -15769,7 +16609,7 @@ public function serviceStart() { /** * Class PVEServiceServicesNodeNodesStop - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEServiceServicesNodeNodesStop { @@ -15808,7 +16648,7 @@ public function serviceStop() { /** * Class PVEServiceServicesNodeNodesRestart - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEServiceServicesNodeNodesRestart { @@ -15847,7 +16687,7 @@ public function serviceRestart() { /** * Class PVEServiceServicesNodeNodesReload - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEServiceServicesNodeNodesReload { @@ -15886,7 +16726,7 @@ public function serviceReload() { /** * Class PVENodeNodesSubscription - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVENodeNodesSubscription { @@ -15947,7 +16787,7 @@ public function set($key) { /** * Class PVENodeNodesNetwork - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVENodeNodesNetwork { @@ -16032,8 +16872,7 @@ public function index($type = null) { * @return Result */ public function createNetwork($iface, $type, $address = null, $address6 = null, $autostart = null, $bond_primary = null, $bond_mode = null, $bond_xmit_hash_policy = null, $bridge_ports = null, $bridge_vlan_aware = null, $cidr = null, $cidr6 = null, $comments = null, $comments6 = null, $gateway = null, $gateway6 = null, $mtu = null, $netmask = null, $netmask6 = null, $ovs_bonds = null, $ovs_bridge = null, $ovs_options = null, $ovs_ports = null, $ovs_tag = null, $slaves = null, $vlan_id = null, $vlan_raw_device = null) { - $params = [ - 'iface' => $iface, + $params = ['iface' => $iface, 'type' => $type, 'address' => $address, 'address6' => $address6, @@ -16059,8 +16898,7 @@ public function createNetwork($iface, $type, $address = null, $address6 = null, 'ovs_tag' => $ovs_tag, 'slaves' => $slaves, 'vlan-id' => $vlan_id, - 'vlan-raw-device' => $vlan_raw_device - ]; + 'vlan-raw-device' => $vlan_raw_device]; return $this->client->create("/nodes/{$this->node}/network", $params); } @@ -16075,7 +16913,7 @@ public function reloadNetworkConfig() { /** * Class PVEItemNetworkNodeNodesIface - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemNetworkNodeNodesIface { @@ -16154,8 +16992,7 @@ public function networkConfig() { * @return Result */ public function updateNetwork($type, $address = null, $address6 = null, $autostart = null, $bond_primary = null, $bond_mode = null, $bond_xmit_hash_policy = null, $bridge_ports = null, $bridge_vlan_aware = null, $cidr = null, $cidr6 = null, $comments = null, $comments6 = null, $delete = null, $gateway = null, $gateway6 = null, $mtu = null, $netmask = null, $netmask6 = null, $ovs_bonds = null, $ovs_bridge = null, $ovs_options = null, $ovs_ports = null, $ovs_tag = null, $slaves = null, $vlan_id = null, $vlan_raw_device = null) { - $params = [ - 'type' => $type, + $params = ['type' => $type, 'address' => $address, 'address6' => $address6, 'autostart' => $autostart, @@ -16181,15 +17018,14 @@ public function updateNetwork($type, $address = null, $address6 = null, $autosta 'ovs_tag' => $ovs_tag, 'slaves' => $slaves, 'vlan-id' => $vlan_id, - 'vlan-raw-device' => $vlan_raw_device - ]; + 'vlan-raw-device' => $vlan_raw_device]; return $this->client->set("/nodes/{$this->node}/network/{$this->iface}", $params); } } /** * Class PVENodeNodesTasks - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVENodeNodesTasks { @@ -16236,8 +17072,7 @@ public function get($upid) { * @return Result */ public function nodeTasks($errors = null, $limit = null, $since = null, $source = null, $start = null, $statusfilter = null, $typefilter = null, $until = null, $userfilter = null, $vmid = null) { - $params = [ - 'errors' => $errors, + $params = ['errors' => $errors, 'limit' => $limit, 'since' => $since, 'source' => $source, @@ -16246,15 +17081,14 @@ public function nodeTasks($errors = null, $limit = null, $since = null, $source 'typefilter' => $typefilter, 'until' => $until, 'userfilter' => $userfilter, - 'vmid' => $vmid - ]; + 'vmid' => $vmid]; return $this->client->get("/nodes/{$this->node}/tasks", $params); } } /** * Class PVEItemTasksNodeNodesUpid - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemTasksNodeNodesUpid { @@ -16317,7 +17151,7 @@ public function stopTask() { } /** - * + * * @return Result */ public function upidIndex() { @@ -16327,7 +17161,7 @@ public function upidIndex() { /** * Class PVEUpidTasksNodeNodesLog - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEUpidTasksNodeNodesLog { @@ -16363,18 +17197,16 @@ function __construct($client, $node, $upid) { * @return Result */ public function readTaskLog($download = null, $limit = null, $start = null) { - $params = [ - 'download' => $download, + $params = ['download' => $download, 'limit' => $limit, - 'start' => $start - ]; + 'start' => $start]; return $this->client->get("/nodes/{$this->node}/tasks/{$this->upid}/log", $params); } } /** * Class PVEUpidTasksNodeNodesStatus - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEUpidTasksNodeNodesStatus { @@ -16413,7 +17245,7 @@ public function readTaskStatus() { /** * Class PVENodeNodesScan - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVENodeNodesScan { @@ -16550,7 +17382,7 @@ public function index() { /** * Class PVEScanNodeNodesNfs - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEScanNodeNodesNfs { @@ -16585,7 +17417,7 @@ public function nfsscan($server) { /** * Class PVEScanNodeNodesCifs - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEScanNodeNodesCifs { @@ -16616,19 +17448,17 @@ function __construct($client, $node) { * @return Result */ public function cifsscan($server, $domain = null, $password = null, $username = null) { - $params = [ - 'server' => $server, + $params = ['server' => $server, 'domain' => $domain, 'password' => $password, - 'username' => $username - ]; + 'username' => $username]; return $this->client->get("/nodes/{$this->node}/scan/cifs", $params); } } /** * Class PVEScanNodeNodesPbs - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEScanNodeNodesPbs { @@ -16660,20 +17490,18 @@ function __construct($client, $node) { * @return Result */ public function pbsscan($password, $server, $username, $fingerprint = null, $port = null) { - $params = [ - 'password' => $password, + $params = ['password' => $password, 'server' => $server, 'username' => $username, 'fingerprint' => $fingerprint, - 'port' => $port - ]; + 'port' => $port]; return $this->client->get("/nodes/{$this->node}/scan/pbs", $params); } } /** * Class PVEScanNodeNodesGlusterfs - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEScanNodeNodesGlusterfs { @@ -16708,7 +17536,7 @@ public function glusterfsscan($server) { /** * Class PVEScanNodeNodesIscsi - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEScanNodeNodesIscsi { @@ -16743,7 +17571,7 @@ public function iscsiscan($portal) { /** * Class PVEScanNodeNodesLvm - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEScanNodeNodesLvm { @@ -16776,7 +17604,7 @@ public function lvmscan() { /** * Class PVEScanNodeNodesLvmthin - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEScanNodeNodesLvmthin { @@ -16800,7 +17628,7 @@ function __construct($client, $node) { /** * List local LVM Thin Pools. - * @param string $vg + * @param string $vg * @return Result */ public function lvmthinscan($vg) { @@ -16811,7 +17639,7 @@ public function lvmthinscan($vg) { /** * Class PVEScanNodeNodesZfs - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEScanNodeNodesZfs { @@ -16844,7 +17672,7 @@ public function zfsscan() { /** * Class PVENodeNodesHardware - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVENodeNodesHardware { @@ -16903,7 +17731,7 @@ public function index() { /** * Class PVEHardwareNodeNodesPci - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEHardwareNodeNodesPci { @@ -16941,17 +17769,15 @@ public function get($pciid) { * @return Result */ public function pciscan($pci_class_blacklist = null, $verbose = null) { - $params = [ - 'pci-class-blacklist' => $pci_class_blacklist, - 'verbose' => $verbose - ]; + $params = ['pci-class-blacklist' => $pci_class_blacklist, + 'verbose' => $verbose]; return $this->client->get("/nodes/{$this->node}/hardware/pci", $params); } } /** * Class PVEItemPciHardwareNodeNodesPciid - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemPciHardwareNodeNodesPciid { @@ -17003,7 +17829,7 @@ public function pciindex() { /** * Class PVEPciidPciHardwareNodeNodesMdev - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEPciidPciHardwareNodeNodesMdev { @@ -17042,7 +17868,7 @@ public function mdevscan() { /** * Class PVEHardwareNodeNodesUsb - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEHardwareNodeNodesUsb { @@ -17075,7 +17901,7 @@ public function usbscan() { /** * Class PVENodeNodesCapabilities - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVENodeNodesCapabilities { @@ -17121,7 +17947,7 @@ public function index() { /** * Class PVECapabilitiesNodeNodesQemu - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVECapabilitiesNodeNodesQemu { @@ -17180,7 +18006,7 @@ public function qemuCapsIndex() { /** * Class PVEQemuCapabilitiesNodeNodesCpu - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEQemuCapabilitiesNodeNodesCpu { @@ -17213,7 +18039,7 @@ public function index() { /** * Class PVEQemuCapabilitiesNodeNodesMachines - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEQemuCapabilitiesNodeNodesMachines { @@ -17246,7 +18072,7 @@ public function types() { /** * Class PVENodeNodesStorage - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVENodeNodesStorage { @@ -17287,20 +18113,18 @@ public function get($storage) { * @return Result */ public function index($content = null, $enabled = null, $format = null, $storage = null, $target = null) { - $params = [ - 'content' => $content, + $params = ['content' => $content, 'enabled' => $enabled, 'format' => $format, 'storage' => $storage, - 'target' => $target - ]; + 'target' => $target]; return $this->client->get("/nodes/{$this->node}/storage", $params); } } /** * Class PVEItemStorageNodeNodesStorage - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemStorageNodeNodesStorage { @@ -17433,7 +18257,7 @@ public function getDownloadUrl() { } /** - * + * * @return Result */ public function diridx() { @@ -17443,7 +18267,7 @@ public function diridx() { /** * Class PVEStorageStorageNodeNodesPrunebackups - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEStorageStorageNodeNodesPrunebackups { @@ -17480,11 +18304,9 @@ function __construct($client, $node, $storage) { * @return Result */ public function delete($prune_backups = null, $type = null, $vmid = null) { - $params = [ - 'prune-backups' => $prune_backups, + $params = ['prune-backups' => $prune_backups, 'type' => $type, - 'vmid' => $vmid - ]; + 'vmid' => $vmid]; return $this->client->delete("/nodes/{$this->node}/storage/{$this->storage}/prunebackups", $params); } @@ -17497,18 +18319,16 @@ public function delete($prune_backups = null, $type = null, $vmid = null) { * @return Result */ public function dryrun($prune_backups = null, $type = null, $vmid = null) { - $params = [ - 'prune-backups' => $prune_backups, + $params = ['prune-backups' => $prune_backups, 'type' => $type, - 'vmid' => $vmid - ]; + 'vmid' => $vmid]; return $this->client->get("/nodes/{$this->node}/storage/{$this->storage}/prunebackups", $params); } } /** * Class PVEStorageStorageNodeNodesContent - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEStorageStorageNodeNodesContent { @@ -17552,10 +18372,8 @@ public function get($volume) { * @return Result */ public function index($content = null, $vmid = null) { - $params = [ - 'content' => $content, - 'vmid' => $vmid - ]; + $params = ['content' => $content, + 'vmid' => $vmid]; return $this->client->get("/nodes/{$this->node}/storage/{$this->storage}/content", $params); } @@ -17564,24 +18382,22 @@ public function index($content = null, $vmid = null) { * @param string $filename The name of the file to create. * @param string $size Size in kilobyte (1024 bytes). Optional suffixes 'M' (megabyte, 1024K) and 'G' (gigabyte, 1024M) * @param int $vmid Specify owner VM - * @param string $format + * @param string $format * Enum: raw,qcow2,subvol * @return Result */ public function create($filename, $size, $vmid, $format = null) { - $params = [ - 'filename' => $filename, + $params = ['filename' => $filename, 'size' => $size, 'vmid' => $vmid, - 'format' => $format - ]; + 'format' => $format]; return $this->client->create("/nodes/{$this->node}/storage/{$this->storage}/content", $params); } } /** * Class PVEItemContentStorageStorageNodeNodesVolume - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemContentStorageStorageNodeNodesVolume { @@ -17640,10 +18456,8 @@ public function info() { * @return Result */ public function copy($target, $target_node = null) { - $params = [ - 'target' => $target, - 'target_node' => $target_node - ]; + $params = ['target' => $target, + 'target_node' => $target_node]; return $this->client->create("/nodes/{$this->node}/storage/{$this->storage}/content/{$this->volume}", $params); } @@ -17654,17 +18468,15 @@ public function copy($target, $target_node = null) { * @return Result */ public function updateattributes($notes = null, $protected = null) { - $params = [ - 'notes' => $notes, - 'protected' => $protected - ]; + $params = ['notes' => $notes, + 'protected' => $protected]; return $this->client->set("/nodes/{$this->node}/storage/{$this->storage}/content/{$this->volume}", $params); } } /** * Class PVEStorageStorageNodeNodesFileRestore - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEStorageStorageNodeNodesFileRestore { @@ -17721,7 +18533,7 @@ public function getDownload() { /** * Class PVEFileRestoreStorageStorageNodeNodesList - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEFileRestoreStorageStorageNodeNodesList { @@ -17756,17 +18568,15 @@ function __construct($client, $node, $storage) { * @return Result */ public function list_($filepath, $volume) { - $params = [ - 'filepath' => $filepath, - 'volume' => $volume - ]; + $params = ['filepath' => $filepath, + 'volume' => $volume]; return $this->client->get("/nodes/{$this->node}/storage/{$this->storage}/file-restore/list", $params); } } /** * Class PVEFileRestoreStorageStorageNodeNodesDownload - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEFileRestoreStorageStorageNodeNodesDownload { @@ -17798,20 +18608,20 @@ function __construct($client, $node, $storage) { * Extract a file or directory (as zip archive) from a PBS backup. * @param string $filepath base64-path to the directory or file to download. * @param string $volume Backup volume ID or name. Currently only PBS snapshots are supported. + * @param bool $tar Download dirs as 'tar.zst' instead of 'zip'. * @return Result */ - public function download($filepath, $volume) { - $params = [ - 'filepath' => $filepath, - 'volume' => $volume - ]; + public function download($filepath, $volume, $tar = null) { + $params = ['filepath' => $filepath, + 'volume' => $volume, + 'tar' => $tar]; return $this->client->get("/nodes/{$this->node}/storage/{$this->storage}/file-restore/download", $params); } } /** * Class PVEStorageStorageNodeNodesStatus - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEStorageStorageNodeNodesStatus { @@ -17850,7 +18660,7 @@ public function readStatus() { /** * Class PVEStorageStorageNodeNodesRrd - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEStorageStorageNodeNodesRrd { @@ -17888,18 +18698,16 @@ function __construct($client, $node, $storage) { * @return Result */ public function rrd($ds, $timeframe, $cf = null) { - $params = [ - 'ds' => $ds, + $params = ['ds' => $ds, 'timeframe' => $timeframe, - 'cf' => $cf - ]; + 'cf' => $cf]; return $this->client->get("/nodes/{$this->node}/storage/{$this->storage}/rrd", $params); } } /** * Class PVEStorageStorageNodeNodesRrddata - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEStorageStorageNodeNodesRrddata { @@ -17936,17 +18744,15 @@ function __construct($client, $node, $storage) { * @return Result */ public function rrddata($timeframe, $cf = null) { - $params = [ - 'timeframe' => $timeframe, - 'cf' => $cf - ]; + $params = ['timeframe' => $timeframe, + 'cf' => $cf]; return $this->client->get("/nodes/{$this->node}/storage/{$this->storage}/rrddata", $params); } } /** * Class PVEStorageStorageNodeNodesUpload - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEStorageStorageNodeNodesUpload { @@ -17986,20 +18792,18 @@ function __construct($client, $node, $storage) { * @return Result */ public function upload($content, $filename, $checksum = null, $checksum_algorithm = null, $tmpfilename = null) { - $params = [ - 'content' => $content, + $params = ['content' => $content, 'filename' => $filename, 'checksum' => $checksum, 'checksum-algorithm' => $checksum_algorithm, - 'tmpfilename' => $tmpfilename - ]; + 'tmpfilename' => $tmpfilename]; return $this->client->create("/nodes/{$this->node}/storage/{$this->storage}/upload", $params); } } /** * Class PVEStorageStorageNodeNodesDownloadUrl - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEStorageStorageNodeNodesDownloadUrl { @@ -18036,25 +18840,25 @@ function __construct($client, $node, $storage) { * @param string $checksum The expected checksum of the file. * @param string $checksum_algorithm The algorithm to calculate the checksum of the file. * Enum: md5,sha1,sha224,sha256,sha384,sha512 + * @param string $compression Decompress the downloaded file using the specified compression algorithm. * @param bool $verify_certificates If false, no SSL/TLS certificates will be verified. * @return Result */ - public function downloadUrl($content, $filename, $url, $checksum = null, $checksum_algorithm = null, $verify_certificates = null) { - $params = [ - 'content' => $content, + public function downloadUrl($content, $filename, $url, $checksum = null, $checksum_algorithm = null, $compression = null, $verify_certificates = null) { + $params = ['content' => $content, 'filename' => $filename, 'url' => $url, 'checksum' => $checksum, 'checksum-algorithm' => $checksum_algorithm, - 'verify-certificates' => $verify_certificates - ]; + 'compression' => $compression, + 'verify-certificates' => $verify_certificates]; return $this->client->create("/nodes/{$this->node}/storage/{$this->storage}/download-url", $params); } } /** * Class PVENodeNodesDisks - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVENodeNodesDisks { @@ -18191,7 +18995,7 @@ public function index() { /** * Class PVEDisksNodeNodesLvm - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEDisksNodeNodesLvm { @@ -18238,18 +19042,16 @@ public function index() { * @return Result */ public function create($device, $name, $add_storage = null) { - $params = [ - 'device' => $device, + $params = ['device' => $device, 'name' => $name, - 'add_storage' => $add_storage - ]; + 'add_storage' => $add_storage]; return $this->client->create("/nodes/{$this->node}/disks/lvm", $params); } } /** * Class PVEItemLvmDisksNodeNodesName - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemLvmDisksNodeNodesName { @@ -18284,17 +19086,15 @@ function __construct($client, $node, $name) { * @return Result */ public function delete($cleanup_config = null, $cleanup_disks = null) { - $params = [ - 'cleanup-config' => $cleanup_config, - 'cleanup-disks' => $cleanup_disks - ]; + $params = ['cleanup-config' => $cleanup_config, + 'cleanup-disks' => $cleanup_disks]; return $this->client->delete("/nodes/{$this->node}/disks/lvm/{$this->name}", $params); } } /** * Class PVEDisksNodeNodesLvmthin - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEDisksNodeNodesLvmthin { @@ -18341,18 +19141,16 @@ public function index() { * @return Result */ public function create($device, $name, $add_storage = null) { - $params = [ - 'device' => $device, + $params = ['device' => $device, 'name' => $name, - 'add_storage' => $add_storage - ]; + 'add_storage' => $add_storage]; return $this->client->create("/nodes/{$this->node}/disks/lvmthin", $params); } } /** * Class PVEItemLvmthinDisksNodeNodesName - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemLvmthinDisksNodeNodesName { @@ -18388,18 +19186,16 @@ function __construct($client, $node, $name) { * @return Result */ public function delete($volume_group, $cleanup_config = null, $cleanup_disks = null) { - $params = [ - 'volume-group' => $volume_group, + $params = ['volume-group' => $volume_group, 'cleanup-config' => $cleanup_config, - 'cleanup-disks' => $cleanup_disks - ]; + 'cleanup-disks' => $cleanup_disks]; return $this->client->delete("/nodes/{$this->node}/disks/lvmthin/{$this->name}", $params); } } /** * Class PVEDisksNodeNodesDirectory - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEDisksNodeNodesDirectory { @@ -18448,19 +19244,17 @@ public function index() { * @return Result */ public function create($device, $name, $add_storage = null, $filesystem = null) { - $params = [ - 'device' => $device, + $params = ['device' => $device, 'name' => $name, 'add_storage' => $add_storage, - 'filesystem' => $filesystem - ]; + 'filesystem' => $filesystem]; return $this->client->create("/nodes/{$this->node}/disks/directory", $params); } } /** * Class PVEItemDirectoryDisksNodeNodesName - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemDirectoryDisksNodeNodesName { @@ -18495,17 +19289,15 @@ function __construct($client, $node, $name) { * @return Result */ public function delete($cleanup_config = null, $cleanup_disks = null) { - $params = [ - 'cleanup-config' => $cleanup_config, - 'cleanup-disks' => $cleanup_disks - ]; + $params = ['cleanup-config' => $cleanup_config, + 'cleanup-disks' => $cleanup_disks]; return $this->client->delete("/nodes/{$this->node}/disks/directory/{$this->name}", $params); } } /** * Class PVEDisksNodeNodesZfs - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEDisksNodeNodesZfs { @@ -18554,26 +19346,24 @@ public function index() { * @param int $ashift Pool sector size exponent. * @param string $compression The compression algorithm to use. * Enum: on,off,gzip,lz4,lzjb,zle,zstd - * @param string $draid_config + * @param string $draid_config * @return Result */ public function create($devices, $name, $raidlevel, $add_storage = null, $ashift = null, $compression = null, $draid_config = null) { - $params = [ - 'devices' => $devices, + $params = ['devices' => $devices, 'name' => $name, 'raidlevel' => $raidlevel, 'add_storage' => $add_storage, 'ashift' => $ashift, 'compression' => $compression, - 'draid-config' => $draid_config - ]; + 'draid-config' => $draid_config]; return $this->client->create("/nodes/{$this->node}/disks/zfs", $params); } } /** * Class PVEItemZfsDisksNodeNodesName - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemZfsDisksNodeNodesName { @@ -18608,10 +19398,8 @@ function __construct($client, $node, $name) { * @return Result */ public function delete($cleanup_config = null, $cleanup_disks = null) { - $params = [ - 'cleanup-config' => $cleanup_config, - 'cleanup-disks' => $cleanup_disks - ]; + $params = ['cleanup-config' => $cleanup_config, + 'cleanup-disks' => $cleanup_disks]; return $this->client->delete("/nodes/{$this->node}/disks/zfs/{$this->name}", $params); } @@ -18626,7 +19414,7 @@ public function detail() { /** * Class PVEDisksNodeNodesList - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEDisksNodeNodesList { @@ -18657,18 +19445,16 @@ function __construct($client, $node) { * @return Result */ public function list_($include_partitions = null, $skipsmart = null, $type = null) { - $params = [ - 'include-partitions' => $include_partitions, + $params = ['include-partitions' => $include_partitions, 'skipsmart' => $skipsmart, - 'type' => $type - ]; + 'type' => $type]; return $this->client->get("/nodes/{$this->node}/disks/list", $params); } } /** * Class PVEDisksNodeNodesSmart - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEDisksNodeNodesSmart { @@ -18697,17 +19483,15 @@ function __construct($client, $node) { * @return Result */ public function smart($disk, $healthonly = null) { - $params = [ - 'disk' => $disk, - 'healthonly' => $healthonly - ]; + $params = ['disk' => $disk, + 'healthonly' => $healthonly]; return $this->client->get("/nodes/{$this->node}/disks/smart", $params); } } /** * Class PVEDisksNodeNodesInitgpt - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEDisksNodeNodesInitgpt { @@ -18736,17 +19520,15 @@ function __construct($client, $node) { * @return Result */ public function initgpt($disk, $uuid = null) { - $params = [ - 'disk' => $disk, - 'uuid' => $uuid - ]; + $params = ['disk' => $disk, + 'uuid' => $uuid]; return $this->client->create("/nodes/{$this->node}/disks/initgpt", $params); } } /** * Class PVEDisksNodeNodesWipedisk - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEDisksNodeNodesWipedisk { @@ -18781,7 +19563,7 @@ public function wipeDisk($disk) { /** * Class PVENodeNodesApt - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVENodeNodesApt { @@ -18866,7 +19648,7 @@ public function index() { /** * Class PVEAptNodeNodesUpdate - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEAptNodeNodesUpdate { @@ -18898,22 +19680,20 @@ public function listUpdates() { /** * This is used to resynchronize the package index files from their sources (apt-get update). - * @param bool $notify Send notification mail about new packages (to email address specified for user 'root@pam'). + * @param bool $notify Send notification about new packages. * @param bool $quiet Only produces output suitable for logging, omitting progress indicators. * @return Result */ public function updateDatabase($notify = null, $quiet = null) { - $params = [ - 'notify' => $notify, - 'quiet' => $quiet - ]; + $params = ['notify' => $notify, + 'quiet' => $quiet]; return $this->client->create("/nodes/{$this->node}/apt/update", $params); } } /** * Class PVEAptNodeNodesChangelog - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEAptNodeNodesChangelog { @@ -18942,17 +19722,15 @@ function __construct($client, $node) { * @return Result */ public function changelog($name, $version = null) { - $params = [ - 'name' => $name, - 'version' => $version - ]; + $params = ['name' => $name, + 'version' => $version]; return $this->client->get("/nodes/{$this->node}/apt/changelog", $params); } } /** * Class PVEAptNodeNodesRepositories - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEAptNodeNodesRepositories { @@ -18991,12 +19769,10 @@ public function repositories() { * @return Result */ public function changeRepository($index, $path, $digest = null, $enabled = null) { - $params = [ - 'index' => $index, + $params = ['index' => $index, 'path' => $path, 'digest' => $digest, - 'enabled' => $enabled - ]; + 'enabled' => $enabled]; return $this->client->create("/nodes/{$this->node}/apt/repositories", $params); } @@ -19007,17 +19783,15 @@ public function changeRepository($index, $path, $digest = null, $enabled = null) * @return Result */ public function addRepository($handle, $digest = null) { - $params = [ - 'handle' => $handle, - 'digest' => $digest - ]; + $params = ['handle' => $handle, + 'digest' => $digest]; return $this->client->set("/nodes/{$this->node}/apt/repositories", $params); } } /** * Class PVEAptNodeNodesVersions - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEAptNodeNodesVersions { @@ -19050,7 +19824,7 @@ public function versions() { /** * Class PVENodeNodesFirewall - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVENodeNodesFirewall { @@ -19122,7 +19896,7 @@ public function index() { /** * Class PVEFirewallNodeNodesRules - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEFirewallNodeNodesRules { @@ -19168,7 +19942,7 @@ public function getRules() { * Enum: in,out,group * @param string $comment Descriptive comment. * @param string $dest Restrict packet destination address. This can refer to a single IP address, an IP set ('+ipsetname') or an IP alias definition. You can also specify an address range like '20.34.101.207-201.3.9.99', or a list of IP addresses and networks (entries are separated by comma). Please do not mix IPv4 and IPv6 addresses inside such lists. - * @param string $digest Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications. + * @param string $digest Prevent changes if current configuration file has a different digest. This can be used to prevent concurrent modifications. * @param string $dport Restrict TCP/UDP destination port. You can use service names or simple numbers (0-65535), as defined in '/etc/services'. Port ranges can be specified with '\d+:\d+', for example '80:85', and you can use comma separated list to match several ports or ranges. * @param int $enable Flag to enable/disable a rule. * @param string $icmp_type Specify icmp-type. Only valid if proto equals 'icmp' or 'icmpv6'/'ipv6-icmp'. @@ -19183,8 +19957,7 @@ public function getRules() { * @return Result */ public function createRule($action, $type, $comment = null, $dest = null, $digest = null, $dport = null, $enable = null, $icmp_type = null, $iface = null, $log = null, $macro = null, $pos = null, $proto = null, $source = null, $sport = null) { - $params = [ - 'action' => $action, + $params = ['action' => $action, 'type' => $type, 'comment' => $comment, 'dest' => $dest, @@ -19198,15 +19971,14 @@ public function createRule($action, $type, $comment = null, $dest = null, $diges 'pos' => $pos, 'proto' => $proto, 'source' => $source, - 'sport' => $sport - ]; + 'sport' => $sport]; return $this->client->create("/nodes/{$this->node}/firewall/rules", $params); } } /** * Class PVEItemRulesFirewallNodeNodesPos - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemRulesFirewallNodeNodesPos { @@ -19236,7 +20008,7 @@ function __construct($client, $node, $pos) { /** * Delete rule. - * @param string $digest Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications. + * @param string $digest Prevent changes if current configuration file has a different digest. This can be used to prevent concurrent modifications. * @return Result */ public function deleteRule($digest = null) { @@ -19258,7 +20030,7 @@ public function getRule() { * @param string $comment Descriptive comment. * @param string $delete A list of settings you want to delete. * @param string $dest Restrict packet destination address. This can refer to a single IP address, an IP set ('+ipsetname') or an IP alias definition. You can also specify an address range like '20.34.101.207-201.3.9.99', or a list of IP addresses and networks (entries are separated by comma). Please do not mix IPv4 and IPv6 addresses inside such lists. - * @param string $digest Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications. + * @param string $digest Prevent changes if current configuration file has a different digest. This can be used to prevent concurrent modifications. * @param string $dport Restrict TCP/UDP destination port. You can use service names or simple numbers (0-65535), as defined in '/etc/services'. Port ranges can be specified with '\d+:\d+', for example '80:85', and you can use comma separated list to match several ports or ranges. * @param int $enable Flag to enable/disable a rule. * @param string $icmp_type Specify icmp-type. Only valid if proto equals 'icmp' or 'icmpv6'/'ipv6-icmp'. @@ -19275,8 +20047,7 @@ public function getRule() { * @return Result */ public function updateRule($action = null, $comment = null, $delete = null, $dest = null, $digest = null, $dport = null, $enable = null, $icmp_type = null, $iface = null, $log = null, $macro = null, $moveto = null, $proto = null, $source = null, $sport = null, $type = null) { - $params = [ - 'action' => $action, + $params = ['action' => $action, 'comment' => $comment, 'delete' => $delete, 'dest' => $dest, @@ -19291,15 +20062,14 @@ public function updateRule($action = null, $comment = null, $delete = null, $des 'proto' => $proto, 'source' => $source, 'sport' => $sport, - 'type' => $type - ]; + 'type' => $type]; return $this->client->set("/nodes/{$this->node}/firewall/rules/{$this->pos}", $params); } } /** * Class PVEFirewallNodeNodesOptions - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEFirewallNodeNodesOptions { @@ -19332,7 +20102,7 @@ public function getOptions() { /** * Set Firewall options. * @param string $delete A list of settings you want to delete. - * @param string $digest Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications. + * @param string $digest Prevent changes if current configuration file has a different digest. This can be used to prevent concurrent modifications. * @param bool $enable Enable host firewall rules. * @param string $log_level_in Log level for incoming traffic. * Enum: emerg,alert,crit,err,warning,notice,info,debug,nolog @@ -19357,8 +20127,7 @@ public function getOptions() { * @return Result */ public function setOptions($delete = null, $digest = null, $enable = null, $log_level_in = null, $log_level_out = null, $log_nf_conntrack = null, $ndp = null, $nf_conntrack_allow_invalid = null, $nf_conntrack_helpers = null, $nf_conntrack_max = null, $nf_conntrack_tcp_timeout_established = null, $nf_conntrack_tcp_timeout_syn_recv = null, $nosmurfs = null, $protection_synflood = null, $protection_synflood_burst = null, $protection_synflood_rate = null, $smurf_log_level = null, $tcp_flags_log_level = null, $tcpflags = null) { - $params = [ - 'delete' => $delete, + $params = ['delete' => $delete, 'digest' => $digest, 'enable' => $enable, 'log_level_in' => $log_level_in, @@ -19376,15 +20145,14 @@ public function setOptions($delete = null, $digest = null, $enable = null, $log_ 'protection_synflood_rate' => $protection_synflood_rate, 'smurf_log_level' => $smurf_log_level, 'tcp_flags_log_level' => $tcp_flags_log_level, - 'tcpflags' => $tcpflags - ]; + 'tcpflags' => $tcpflags]; return $this->client->set("/nodes/{$this->node}/firewall/options", $params); } } /** * Class PVEFirewallNodeNodesLog - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEFirewallNodeNodesLog { @@ -19408,26 +20176,24 @@ function __construct($client, $node) { /** * Read firewall log - * @param int $limit + * @param int $limit * @param int $since Display log since this UNIX epoch. - * @param int $start + * @param int $start * @param int $until Display log until this UNIX epoch. * @return Result */ public function log($limit = null, $since = null, $start = null, $until = null) { - $params = [ - 'limit' => $limit, + $params = ['limit' => $limit, 'since' => $since, 'start' => $start, - 'until' => $until - ]; + 'until' => $until]; return $this->client->get("/nodes/{$this->node}/firewall/log", $params); } } /** * Class PVENodeNodesReplication - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVENodeNodesReplication { @@ -19471,7 +20237,7 @@ public function status($guest = null) { /** * Class PVEItemReplicationNodeNodesId - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemReplicationNodeNodesId { @@ -19549,7 +20315,7 @@ public function index() { /** * Class PVEIdReplicationNodeNodesStatus - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEIdReplicationNodeNodesStatus { @@ -19588,7 +20354,7 @@ public function jobStatus() { /** * Class PVEIdReplicationNodeNodesLog - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEIdReplicationNodeNodesLog { @@ -19618,22 +20384,20 @@ function __construct($client, $node, $id) { /** * Read replication job log. - * @param int $limit - * @param int $start + * @param int $limit + * @param int $start * @return Result */ public function readJobLog($limit = null, $start = null) { - $params = [ - 'limit' => $limit, - 'start' => $start - ]; + $params = ['limit' => $limit, + 'start' => $start]; return $this->client->get("/nodes/{$this->node}/replication/{$this->id}/log", $params); } } /** * Class PVEIdReplicationNodeNodesScheduleNow - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEIdReplicationNodeNodesScheduleNow { @@ -19672,7 +20436,7 @@ public function scheduleNow() { /** * Class PVENodeNodesCertificates - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVENodeNodesCertificates { @@ -19744,7 +20508,7 @@ public function index() { /** * Class PVECertificatesNodeNodesAcme - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVECertificatesNodeNodesAcme { @@ -19790,7 +20554,7 @@ public function index() { /** * Class PVEAcmeCertificatesNodeNodesCertificate - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEAcmeCertificatesNodeNodesCertificate { @@ -19843,7 +20607,7 @@ public function renewCertificate($force = null) { /** * Class PVECertificatesNodeNodesInfo - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVECertificatesNodeNodesInfo { @@ -19876,7 +20640,7 @@ public function info() { /** * Class PVECertificatesNodeNodesCustom - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVECertificatesNodeNodesCustom { @@ -19917,19 +20681,17 @@ public function removeCustomCert($restart = null) { * @return Result */ public function uploadCustomCert($certificates, $force = null, $key = null, $restart = null) { - $params = [ - 'certificates' => $certificates, + $params = ['certificates' => $certificates, 'force' => $force, 'key' => $key, - 'restart' => $restart - ]; + 'restart' => $restart]; return $this->client->create("/nodes/{$this->node}/certificates/custom", $params); } } /** * Class PVENodeNodesConfig - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVENodeNodesConfig { @@ -19974,14 +20736,12 @@ public function getConfig($property = null) { * @return Result */ public function setOptions($acme = null, $acmedomainN = null, $delete = null, $description = null, $digest = null, $startall_onboot_delay = null, $wakeonlan = null) { - $params = [ - 'acme' => $acme, + $params = ['acme' => $acme, 'delete' => $delete, 'description' => $description, 'digest' => $digest, 'startall-onboot-delay' => $startall_onboot_delay, - 'wakeonlan' => $wakeonlan - ]; + 'wakeonlan' => $wakeonlan]; $this->client->addIndexedParameter($params, 'acmedomain', $acmedomainN); return $this->client->set("/nodes/{$this->node}/config", $params); } @@ -19989,7 +20749,7 @@ public function setOptions($acme = null, $acmedomainN = null, $delete = null, $d /** * Class PVENodeNodesSdn - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVENodeNodesSdn { @@ -20035,7 +20795,7 @@ public function sdnindex() { /** * Class PVESdnNodeNodesZones - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVESdnNodeNodesZones { @@ -20077,7 +20837,7 @@ public function index() { /** * Class PVEItemZonesSdnNodeNodesZone - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemZonesSdnNodeNodesZone { @@ -20119,7 +20879,7 @@ public function getContent() { } /** - * + * * @return Result */ public function diridx() { @@ -20129,7 +20889,7 @@ public function diridx() { /** * Class PVEZoneZonesSdnNodeNodesContent - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEZoneZonesSdnNodeNodesContent { @@ -20168,7 +20928,7 @@ public function index() { /** * Class PVENodeNodesVersion - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVENodeNodesVersion { @@ -20201,7 +20961,7 @@ public function version() { /** * Class PVENodeNodesStatus - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVENodeNodesStatus { @@ -20245,7 +21005,7 @@ public function nodeCmd($command) { /** * Class PVENodeNodesNetstat - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVENodeNodesNetstat { @@ -20278,7 +21038,7 @@ public function netstat() { /** * Class PVENodeNodesExecute - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVENodeNodesExecute { @@ -20313,7 +21073,7 @@ public function execute($commands) { /** * Class PVENodeNodesWakeonlan - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVENodeNodesWakeonlan { @@ -20346,7 +21106,7 @@ public function wakeonlan() { /** * Class PVENodeNodesRrd - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVENodeNodesRrd { @@ -20378,18 +21138,16 @@ function __construct($client, $node) { * @return Result */ public function rrd($ds, $timeframe, $cf = null) { - $params = [ - 'ds' => $ds, + $params = ['ds' => $ds, 'timeframe' => $timeframe, - 'cf' => $cf - ]; + 'cf' => $cf]; return $this->client->get("/nodes/{$this->node}/rrd", $params); } } /** * Class PVENodeNodesRrddata - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVENodeNodesRrddata { @@ -20420,17 +21178,15 @@ function __construct($client, $node) { * @return Result */ public function rrddata($timeframe, $cf = null) { - $params = [ - 'timeframe' => $timeframe, - 'cf' => $cf - ]; + $params = ['timeframe' => $timeframe, + 'cf' => $cf]; return $this->client->get("/nodes/{$this->node}/rrddata", $params); } } /** * Class PVENodeNodesSyslog - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVENodeNodesSyslog { @@ -20454,28 +21210,26 @@ function __construct($client, $node) { /** * Read system log - * @param int $limit + * @param int $limit * @param string $service Service ID * @param string $since Display all log since this date-time string. - * @param int $start + * @param int $start * @param string $until Display all log until this date-time string. * @return Result */ public function syslog($limit = null, $service = null, $since = null, $start = null, $until = null) { - $params = [ - 'limit' => $limit, + $params = ['limit' => $limit, 'service' => $service, 'since' => $since, 'start' => $start, - 'until' => $until - ]; + 'until' => $until]; return $this->client->get("/nodes/{$this->node}/syslog", $params); } } /** * Class PVENodeNodesJournal - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVENodeNodesJournal { @@ -20507,20 +21261,18 @@ function __construct($client, $node) { * @return Result */ public function journal($endcursor = null, $lastentries = null, $since = null, $startcursor = null, $until = null) { - $params = [ - 'endcursor' => $endcursor, + $params = ['endcursor' => $endcursor, 'lastentries' => $lastentries, 'since' => $since, 'startcursor' => $startcursor, - 'until' => $until - ]; + 'until' => $until]; return $this->client->get("/nodes/{$this->node}/journal", $params); } } /** * Class PVENodeNodesVncshell - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVENodeNodesVncshell { @@ -20544,8 +21296,8 @@ function __construct($client, $node) { /** * Creates a VNC Shell proxy. - * @param string $cmd Run specific command or default to login. - * Enum: login,ceph_install,upgrade + * @param string $cmd Run specific command or default to login (requires 'root@pam') + * Enum: ceph_install,login,upgrade * @param string $cmd_opts Add parameters to a command. Encoded as null terminated strings. * @param int $height sets the height of the console in pixels. * @param bool $websocket use websocket instead of standard vnc. @@ -20553,20 +21305,18 @@ function __construct($client, $node) { * @return Result */ public function vncshell($cmd = null, $cmd_opts = null, $height = null, $websocket = null, $width = null) { - $params = [ - 'cmd' => $cmd, + $params = ['cmd' => $cmd, 'cmd-opts' => $cmd_opts, 'height' => $height, 'websocket' => $websocket, - 'width' => $width - ]; + 'width' => $width]; return $this->client->create("/nodes/{$this->node}/vncshell", $params); } } /** * Class PVENodeNodesTermproxy - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVENodeNodesTermproxy { @@ -20590,23 +21340,21 @@ function __construct($client, $node) { /** * Creates a VNC Shell proxy. - * @param string $cmd Run specific command or default to login. - * Enum: login,ceph_install,upgrade + * @param string $cmd Run specific command or default to login (requires 'root@pam') + * Enum: ceph_install,login,upgrade * @param string $cmd_opts Add parameters to a command. Encoded as null terminated strings. * @return Result */ public function termproxy($cmd = null, $cmd_opts = null) { - $params = [ - 'cmd' => $cmd, - 'cmd-opts' => $cmd_opts - ]; + $params = ['cmd' => $cmd, + 'cmd-opts' => $cmd_opts]; return $this->client->create("/nodes/{$this->node}/termproxy", $params); } } /** * Class PVENodeNodesVncwebsocket - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVENodeNodesVncwebsocket { @@ -20635,17 +21383,15 @@ function __construct($client, $node) { * @return Result */ public function vncwebsocket($port, $vncticket) { - $params = [ - 'port' => $port, - 'vncticket' => $vncticket - ]; + $params = ['port' => $port, + 'vncticket' => $vncticket]; return $this->client->get("/nodes/{$this->node}/vncwebsocket", $params); } } /** * Class PVENodeNodesSpiceshell - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVENodeNodesSpiceshell { @@ -20669,25 +21415,23 @@ function __construct($client, $node) { /** * Creates a SPICE shell. - * @param string $cmd Run specific command or default to login. - * Enum: login,ceph_install,upgrade + * @param string $cmd Run specific command or default to login (requires 'root@pam') + * Enum: ceph_install,login,upgrade * @param string $cmd_opts Add parameters to a command. Encoded as null terminated strings. * @param string $proxy SPICE proxy server. This can be used by the client to specify the proxy server. All nodes in a cluster runs 'spiceproxy', so it is up to the client to choose one. By default, we return the node where the VM is currently running. As reasonable setting is to use same node you use to connect to the API (This is window.location.hostname for the JS GUI). * @return Result */ public function spiceshell($cmd = null, $cmd_opts = null, $proxy = null) { - $params = [ - 'cmd' => $cmd, + $params = ['cmd' => $cmd, 'cmd-opts' => $cmd_opts, - 'proxy' => $proxy - ]; + 'proxy' => $proxy]; return $this->client->create("/nodes/{$this->node}/spiceshell", $params); } } /** * Class PVENodeNodesDns - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVENodeNodesDns { @@ -20726,19 +21470,17 @@ public function dns() { * @return Result */ public function updateDns($search, $dns1 = null, $dns2 = null, $dns3 = null) { - $params = [ - 'search' => $search, + $params = ['search' => $search, 'dns1' => $dns1, 'dns2' => $dns2, - 'dns3' => $dns3 - ]; + 'dns3' => $dns3]; return $this->client->set("/nodes/{$this->node}/dns", $params); } } /** * Class PVENodeNodesTime - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVENodeNodesTime { @@ -20781,7 +21523,7 @@ public function setTimezone($timezone) { /** * Class PVENodeNodesAplinfo - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVENodeNodesAplinfo { @@ -20818,17 +21560,15 @@ public function aplinfo() { * @return Result */ public function aplDownload($storage, $template) { - $params = [ - 'storage' => $storage, - 'template' => $template - ]; + $params = ['storage' => $storage, + 'template' => $template]; return $this->client->create("/nodes/{$this->node}/aplinfo", $params); } } /** * Class PVENodeNodesQueryUrlMetadata - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVENodeNodesQueryUrlMetadata { @@ -20857,17 +21597,15 @@ function __construct($client, $node) { * @return Result */ public function queryUrlMetadata($url, $verify_certificates = null) { - $params = [ - 'url' => $url, - 'verify-certificates' => $verify_certificates - ]; + $params = ['url' => $url, + 'verify-certificates' => $verify_certificates]; return $this->client->get("/nodes/{$this->node}/query-url-metadata", $params); } } /** * Class PVENodeNodesReport - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVENodeNodesReport { @@ -20900,7 +21638,7 @@ public function report() { /** * Class PVENodeNodesStartall - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVENodeNodesStartall { @@ -20929,17 +21667,15 @@ function __construct($client, $node) { * @return Result */ public function startall($force = null, $vms = null) { - $params = [ - 'force' => $force, - 'vms' => $vms - ]; + $params = ['force' => $force, + 'vms' => $vms]; return $this->client->create("/nodes/{$this->node}/startall", $params); } } /** * Class PVENodeNodesStopall - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVENodeNodesStopall { @@ -20969,18 +21705,51 @@ function __construct($client, $node) { * @return Result */ public function stopall($force_stop = null, $timeout = null, $vms = null) { - $params = [ - 'force-stop' => $force_stop, + $params = ['force-stop' => $force_stop, 'timeout' => $timeout, - 'vms' => $vms - ]; + 'vms' => $vms]; return $this->client->create("/nodes/{$this->node}/stopall", $params); } } + /** + * Class PVENodeNodesSuspendall + * @package Corsinvest\VE\ProxmoxVE\Api + */ + class PVENodeNodesSuspendall { + + /** + * @ignore + */ + private $node; + + /** + * @ignore + */ + private $client; + + /** + * @ignore + */ + function __construct($client, $node) { + $this->client = $client; + $this->node = $node; + } + + /** + * Suspend all VMs. + * @param string $vms Only consider Guests with these IDs. + * @return Result + */ + public function suspendall($vms = null) { + $params = ['vms' => $vms]; + return $this->client->create("/nodes/{$this->node}/suspendall", $params); + } + } + /** * Class PVENodeNodesMigrateall - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVENodeNodesMigrateall { @@ -21011,19 +21780,17 @@ function __construct($client, $node) { * @return Result */ public function migrateall($target, $maxworkers = null, $vms = null, $with_local_disks = null) { - $params = [ - 'target' => $target, + $params = ['target' => $target, 'maxworkers' => $maxworkers, 'vms' => $vms, - 'with-local-disks' => $with_local_disks - ]; + 'with-local-disks' => $with_local_disks]; return $this->client->create("/nodes/{$this->node}/migrateall", $params); } } /** * Class PVENodeNodesHosts - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVENodeNodesHosts { @@ -21056,21 +21823,19 @@ public function getEtcHosts() { /** * Write /etc/hosts. * @param string $data The target content of /etc/hosts. - * @param string $digest Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications. + * @param string $digest Prevent changes if current configuration file has a different digest. This can be used to prevent concurrent modifications. * @return Result */ public function writeEtcHosts($data, $digest = null) { - $params = [ - 'data' => $data, - 'digest' => $digest - ]; + $params = ['data' => $data, + 'digest' => $digest]; return $this->client->create("/nodes/{$this->node}/hosts", $params); } } /** * Class PVEStorage - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEStorage { @@ -21117,7 +21882,7 @@ public function index($type = null) { * @param string $bwlimit Set I/O bandwidth limit for various operations (in KiB/s). * @param string $comstar_hg host group for comstar views * @param string $comstar_tg target group for comstar views - * @param string $content Allowed content types. NOTE: the value 'rootdir' is used for Containers, and value 'images' for VMs. + * @param string $content Allowed content types. NOTE: the value 'rootdir' is used for Containers, and value 'images' for VMs. * @param string $content_dirs Overrides for default content type directories. * @param bool $create_base_path Create the base directory if it doesn't exist. * @param bool $create_subdirs Populate the directory with the default structure. @@ -21176,8 +21941,7 @@ public function index($type = null) { * @return Result */ public function create($storage, $type, $authsupported = null, $base = null, $blocksize = null, $bwlimit = null, $comstar_hg = null, $comstar_tg = null, $content = null, $content_dirs = null, $create_base_path = null, $create_subdirs = null, $data_pool = null, $datastore = null, $disable = null, $domain = null, $encryption_key = null, $export = null, $fingerprint = null, $format = null, $fs_name = null, $fuse = null, $is_mountpoint = null, $iscsiprovider = null, $keyring = null, $krbd = null, $lio_tpg = null, $master_pubkey = null, $max_protected_backups = null, $maxfiles = null, $mkdir = null, $monhost = null, $mountpoint = null, $namespace = null, $nocow = null, $nodes = null, $nowritecache = null, $options = null, $password = null, $path = null, $pool = null, $port = null, $portal = null, $preallocation = null, $prune_backups = null, $saferemove = null, $saferemove_throughput = null, $server = null, $server2 = null, $share = null, $shared = null, $smbversion = null, $sparse = null, $subdir = null, $tagged_only = null, $target = null, $thinpool = null, $transport = null, $username = null, $vgname = null, $volume = null) { - $params = [ - 'storage' => $storage, + $params = ['storage' => $storage, 'type' => $type, 'authsupported' => $authsupported, 'base' => $base, @@ -21237,15 +22001,14 @@ public function create($storage, $type, $authsupported = null, $base = null, $bl 'transport' => $transport, 'username' => $username, 'vgname' => $vgname, - 'volume' => $volume - ]; + 'volume' => $volume]; return $this->client->create("/storage", $params); } } /** * Class PVEItemStorageStorage - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemStorageStorage { @@ -21289,13 +22052,13 @@ public function read() { * @param string $bwlimit Set I/O bandwidth limit for various operations (in KiB/s). * @param string $comstar_hg host group for comstar views * @param string $comstar_tg target group for comstar views - * @param string $content Allowed content types. NOTE: the value 'rootdir' is used for Containers, and value 'images' for VMs. + * @param string $content Allowed content types. NOTE: the value 'rootdir' is used for Containers, and value 'images' for VMs. * @param string $content_dirs Overrides for default content type directories. * @param bool $create_base_path Create the base directory if it doesn't exist. * @param bool $create_subdirs Populate the directory with the default structure. * @param string $data_pool Data Pool (for erasure coding only) * @param string $delete A list of settings you want to delete. - * @param string $digest Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications. + * @param string $digest Prevent changes if current configuration file has a different digest. This can be used to prevent concurrent modifications. * @param bool $disable Flag to disable the storage. * @param string $domain CIFS domain. * @param string $encryption_key Encryption key. Use 'autogen' to generate one automatically without passphrase. @@ -21340,8 +22103,7 @@ public function read() { * @return Result */ public function update($blocksize = null, $bwlimit = null, $comstar_hg = null, $comstar_tg = null, $content = null, $content_dirs = null, $create_base_path = null, $create_subdirs = null, $data_pool = null, $delete = null, $digest = null, $disable = null, $domain = null, $encryption_key = null, $fingerprint = null, $format = null, $fs_name = null, $fuse = null, $is_mountpoint = null, $keyring = null, $krbd = null, $lio_tpg = null, $master_pubkey = null, $max_protected_backups = null, $maxfiles = null, $mkdir = null, $monhost = null, $mountpoint = null, $namespace = null, $nocow = null, $nodes = null, $nowritecache = null, $options = null, $password = null, $pool = null, $port = null, $preallocation = null, $prune_backups = null, $saferemove = null, $saferemove_throughput = null, $server = null, $server2 = null, $shared = null, $smbversion = null, $sparse = null, $subdir = null, $tagged_only = null, $transport = null, $username = null) { - $params = [ - 'blocksize' => $blocksize, + $params = ['blocksize' => $blocksize, 'bwlimit' => $bwlimit, 'comstar_hg' => $comstar_hg, 'comstar_tg' => $comstar_tg, @@ -21389,15 +22151,14 @@ public function update($blocksize = null, $bwlimit = null, $comstar_hg = null, $ 'subdir' => $subdir, 'tagged_only' => $tagged_only, 'transport' => $transport, - 'username' => $username - ]; + 'username' => $username]; return $this->client->set("/storage/{$this->storage}", $params); } } /** * Class PVEAccess - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEAccess { @@ -21554,7 +22315,7 @@ public function index() { /** * Class PVEAccessUsers - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEAccessUsers { @@ -21586,30 +22347,27 @@ public function get($userid) { * @return Result */ public function index($enabled = null, $full = null) { - $params = [ - 'enabled' => $enabled, - 'full' => $full - ]; + $params = ['enabled' => $enabled, + 'full' => $full]; return $this->client->get("/access/users", $params); } /** * Create new user. * @param string $userid Full User ID, in the `name@realm` format. - * @param string $comment - * @param string $email + * @param string $comment + * @param string $email * @param bool $enable Enable the account (default). You can set this to '0' to disable the account * @param int $expire Account expiration date (seconds since epoch). '0' means no expiration date. - * @param string $firstname - * @param string $groups + * @param string $firstname + * @param string $groups * @param string $keys Keys for two factor auth (yubico). - * @param string $lastname + * @param string $lastname * @param string $password Initial password. * @return Result */ public function createUser($userid, $comment = null, $email = null, $enable = null, $expire = null, $firstname = null, $groups = null, $keys = null, $lastname = null, $password = null) { - $params = [ - 'userid' => $userid, + $params = ['userid' => $userid, 'comment' => $comment, 'email' => $email, 'enable' => $enable, @@ -21618,15 +22376,14 @@ public function createUser($userid, $comment = null, $email = null, $enable = nu 'groups' => $groups, 'keys' => $keys, 'lastname' => $lastname, - 'password' => $password - ]; + 'password' => $password]; return $this->client->create("/access/users", $params); } } /** * Class PVEItemUsersAccessUserid - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemUsersAccessUserid { @@ -21705,20 +22462,19 @@ public function readUser() { /** * Update user configuration. - * @param bool $append - * @param string $comment - * @param string $email + * @param bool $append + * @param string $comment + * @param string $email * @param bool $enable Enable the account (default). You can set this to '0' to disable the account * @param int $expire Account expiration date (seconds since epoch). '0' means no expiration date. - * @param string $firstname - * @param string $groups + * @param string $firstname + * @param string $groups * @param string $keys Keys for two factor auth (yubico). - * @param string $lastname + * @param string $lastname * @return Result */ public function updateUser($append = null, $comment = null, $email = null, $enable = null, $expire = null, $firstname = null, $groups = null, $keys = null, $lastname = null) { - $params = [ - 'append' => $append, + $params = ['append' => $append, 'comment' => $comment, 'email' => $email, 'enable' => $enable, @@ -21726,15 +22482,14 @@ public function updateUser($append = null, $comment = null, $email = null, $enab 'firstname' => $firstname, 'groups' => $groups, 'keys' => $keys, - 'lastname' => $lastname - ]; + 'lastname' => $lastname]; return $this->client->set("/access/users/{$this->userid}", $params); } } /** * Class PVEUseridUsersAccessTfa - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEUseridUsersAccessTfa { @@ -21769,7 +22524,7 @@ public function readUserTfaType($multiple = null) { /** * Class PVEUseridUsersAccessUnlockTfa - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEUseridUsersAccessUnlockTfa { @@ -21802,7 +22557,7 @@ public function unlockTfa() { /** * Class PVEUseridUsersAccessToken - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEUseridUsersAccessToken { @@ -21844,7 +22599,7 @@ public function tokenIndex() { /** * Class PVEItemTokenUseridUsersAccessTokenid - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemTokenUseridUsersAccessTokenid { @@ -21890,40 +22645,36 @@ public function readToken() { /** * Generate a new API token for a specific user. NOTE: returns API token value, which needs to be stored as it cannot be retrieved afterwards! - * @param string $comment + * @param string $comment * @param int $expire API token expiration date (seconds since epoch). '0' means no expiration date. * @param bool $privsep Restrict API token privileges with separate ACLs (default), or give full privileges of corresponding user. * @return Result */ public function generateToken($comment = null, $expire = null, $privsep = null) { - $params = [ - 'comment' => $comment, + $params = ['comment' => $comment, 'expire' => $expire, - 'privsep' => $privsep - ]; + 'privsep' => $privsep]; return $this->client->create("/access/users/{$this->userid}/token/{$this->tokenid}", $params); } /** * Update API token for a specific user. - * @param string $comment + * @param string $comment * @param int $expire API token expiration date (seconds since epoch). '0' means no expiration date. * @param bool $privsep Restrict API token privileges with separate ACLs (default), or give full privileges of corresponding user. * @return Result */ public function updateTokenInfo($comment = null, $expire = null, $privsep = null) { - $params = [ - 'comment' => $comment, + $params = ['comment' => $comment, 'expire' => $expire, - 'privsep' => $privsep - ]; + 'privsep' => $privsep]; return $this->client->set("/access/users/{$this->userid}/token/{$this->tokenid}", $params); } } /** * Class PVEAccessGroups - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEAccessGroups { @@ -21958,22 +22709,20 @@ public function index() { /** * Create new group. - * @param string $groupid - * @param string $comment + * @param string $groupid + * @param string $comment * @return Result */ public function createGroup($groupid, $comment = null) { - $params = [ - 'groupid' => $groupid, - 'comment' => $comment - ]; + $params = ['groupid' => $groupid, + 'comment' => $comment]; return $this->client->create("/access/groups", $params); } } /** * Class PVEItemGroupsAccessGroupid - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemGroupsAccessGroupid { @@ -22013,7 +22762,7 @@ public function readGroup() { /** * Update group data. - * @param string $comment + * @param string $comment * @return Result */ public function updateGroup($comment = null) { @@ -22024,7 +22773,7 @@ public function updateGroup($comment = null) { /** * Class PVEAccessRoles - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEAccessRoles { @@ -22059,22 +22808,20 @@ public function index() { /** * Create new role. - * @param string $roleid - * @param string $privs + * @param string $roleid + * @param string $privs * @return Result */ public function createRole($roleid, $privs = null) { - $params = [ - 'roleid' => $roleid, - 'privs' => $privs - ]; + $params = ['roleid' => $roleid, + 'privs' => $privs]; return $this->client->create("/access/roles", $params); } } /** * Class PVEItemRolesAccessRoleid - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemRolesAccessRoleid { @@ -22114,22 +22861,20 @@ public function readRole() { /** * Update an existing role. - * @param bool $append - * @param string $privs + * @param bool $append + * @param string $privs * @return Result */ public function updateRole($append = null, $privs = null) { - $params = [ - 'append' => $append, - 'privs' => $privs - ]; + $params = ['append' => $append, + 'privs' => $privs]; return $this->client->set("/access/roles/{$this->roleid}", $params); } } /** * Class PVEAccessAcl - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEAccessAcl { @@ -22165,22 +22910,20 @@ public function readAcl() { * @return Result */ public function updateAcl($path, $roles, $delete = null, $groups = null, $propagate = null, $tokens = null, $users = null) { - $params = [ - 'path' => $path, + $params = ['path' => $path, 'roles' => $roles, 'delete' => $delete, 'groups' => $groups, 'propagate' => $propagate, 'tokens' => $tokens, - 'users' => $users - ]; + 'users' => $users]; return $this->client->set("/access/acl", $params); } } /** * Class PVEAccessDomains - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEAccessDomains { @@ -22226,6 +22969,7 @@ public function index() { * @param bool $case_sensitive username is case-sensitive * @param string $cert Path to the client certificate * @param string $certkey Path to the client certificate key + * @param bool $check_connection Check bind connection to the server. * @param string $client_id OpenID Client ID * @param string $client_key OpenID Client Key * @param string $comment Description. @@ -22257,9 +23001,8 @@ public function index() { * @param bool $verify Verify the server's SSL certificate * @return Result */ - public function create($realm, $type, $acr_values = null, $autocreate = null, $base_dn = null, $bind_dn = null, $capath = null, $case_sensitive = null, $cert = null, $certkey = null, $client_id = null, $client_key = null, $comment = null, $default = null, $domain = null, $filter = null, $group_classes = null, $group_dn = null, $group_filter = null, $group_name_attr = null, $issuer_url = null, $mode = null, $password = null, $port = null, $prompt = null, $scopes = null, $secure = null, $server1 = null, $server2 = null, $sslversion = null, $sync_defaults_options = null, $sync_attributes = null, $tfa = null, $user_attr = null, $user_classes = null, $username_claim = null, $verify = null) { - $params = [ - 'realm' => $realm, + public function create($realm, $type, $acr_values = null, $autocreate = null, $base_dn = null, $bind_dn = null, $capath = null, $case_sensitive = null, $cert = null, $certkey = null, $check_connection = null, $client_id = null, $client_key = null, $comment = null, $default = null, $domain = null, $filter = null, $group_classes = null, $group_dn = null, $group_filter = null, $group_name_attr = null, $issuer_url = null, $mode = null, $password = null, $port = null, $prompt = null, $scopes = null, $secure = null, $server1 = null, $server2 = null, $sslversion = null, $sync_defaults_options = null, $sync_attributes = null, $tfa = null, $user_attr = null, $user_classes = null, $username_claim = null, $verify = null) { + $params = ['realm' => $realm, 'type' => $type, 'acr-values' => $acr_values, 'autocreate' => $autocreate, @@ -22269,6 +23012,7 @@ public function create($realm, $type, $acr_values = null, $autocreate = null, $b 'case-sensitive' => $case_sensitive, 'cert' => $cert, 'certkey' => $certkey, + 'check-connection' => $check_connection, 'client-id' => $client_id, 'client-key' => $client_key, 'comment' => $comment, @@ -22295,15 +23039,14 @@ public function create($realm, $type, $acr_values = null, $autocreate = null, $b 'user_attr' => $user_attr, 'user_classes' => $user_classes, 'username-claim' => $username_claim, - 'verify' => $verify - ]; + 'verify' => $verify]; return $this->client->create("/access/domains", $params); } } /** * Class PVEItemDomainsAccessRealm - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemDomainsAccessRealm { @@ -22364,12 +23107,13 @@ public function read() { * @param bool $case_sensitive username is case-sensitive * @param string $cert Path to the client certificate * @param string $certkey Path to the client certificate key + * @param bool $check_connection Check bind connection to the server. * @param string $client_id OpenID Client ID * @param string $client_key OpenID Client Key * @param string $comment Description. * @param bool $default Use this as default realm * @param string $delete A list of settings you want to delete. - * @param string $digest Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications. + * @param string $digest Prevent changes if current configuration file has a different digest. This can be used to prevent concurrent modifications. * @param string $domain AD domain name * @param string $filter LDAP filter for user sync. * @param string $group_classes The objectclasses for groups. @@ -22396,9 +23140,8 @@ public function read() { * @param bool $verify Verify the server's SSL certificate * @return Result */ - public function update($acr_values = null, $autocreate = null, $base_dn = null, $bind_dn = null, $capath = null, $case_sensitive = null, $cert = null, $certkey = null, $client_id = null, $client_key = null, $comment = null, $default = null, $delete = null, $digest = null, $domain = null, $filter = null, $group_classes = null, $group_dn = null, $group_filter = null, $group_name_attr = null, $issuer_url = null, $mode = null, $password = null, $port = null, $prompt = null, $scopes = null, $secure = null, $server1 = null, $server2 = null, $sslversion = null, $sync_defaults_options = null, $sync_attributes = null, $tfa = null, $user_attr = null, $user_classes = null, $verify = null) { - $params = [ - 'acr-values' => $acr_values, + public function update($acr_values = null, $autocreate = null, $base_dn = null, $bind_dn = null, $capath = null, $case_sensitive = null, $cert = null, $certkey = null, $check_connection = null, $client_id = null, $client_key = null, $comment = null, $default = null, $delete = null, $digest = null, $domain = null, $filter = null, $group_classes = null, $group_dn = null, $group_filter = null, $group_name_attr = null, $issuer_url = null, $mode = null, $password = null, $port = null, $prompt = null, $scopes = null, $secure = null, $server1 = null, $server2 = null, $sslversion = null, $sync_defaults_options = null, $sync_attributes = null, $tfa = null, $user_attr = null, $user_classes = null, $verify = null) { + $params = ['acr-values' => $acr_values, 'autocreate' => $autocreate, 'base_dn' => $base_dn, 'bind_dn' => $bind_dn, @@ -22406,6 +23149,7 @@ public function update($acr_values = null, $autocreate = null, $base_dn = null, 'case-sensitive' => $case_sensitive, 'cert' => $cert, 'certkey' => $certkey, + 'check-connection' => $check_connection, 'client-id' => $client_id, 'client-key' => $client_key, 'comment' => $comment, @@ -22433,15 +23177,14 @@ public function update($acr_values = null, $autocreate = null, $base_dn = null, 'tfa' => $tfa, 'user_attr' => $user_attr, 'user_classes' => $user_classes, - 'verify' => $verify - ]; + 'verify' => $verify]; return $this->client->set("/access/domains/{$this->realm}", $params); } } /** * Class PVERealmDomainsAccessSync - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVERealmDomainsAccessSync { @@ -22475,21 +23218,19 @@ function __construct($client, $realm) { * @return Result */ public function sync($dry_run = null, $enable_new = null, $full = null, $purge = null, $remove_vanished = null, $scope = null) { - $params = [ - 'dry-run' => $dry_run, + $params = ['dry-run' => $dry_run, 'enable-new' => $enable_new, 'full' => $full, 'purge' => $purge, 'remove-vanished' => $remove_vanished, - 'scope' => $scope - ]; + 'scope' => $scope]; return $this->client->create("/access/domains/{$this->realm}/sync", $params); } } /** * Class PVEAccessOpenid - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEAccessOpenid { @@ -22542,7 +23283,7 @@ public function index() { /** * Class PVEOpenidAccessAuthUrl - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEOpenidAccessAuthUrl { @@ -22565,17 +23306,15 @@ function __construct($client) { * @return Result */ public function authUrl($realm, $redirect_url) { - $params = [ - 'realm' => $realm, - 'redirect-url' => $redirect_url - ]; + $params = ['realm' => $realm, + 'redirect-url' => $redirect_url]; return $this->client->create("/access/openid/auth-url", $params); } } /** * Class PVEOpenidAccessLogin - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEOpenidAccessLogin { @@ -22599,18 +23338,16 @@ function __construct($client) { * @return Result */ public function login($code, $redirect_url, $state) { - $params = [ - 'code' => $code, + $params = ['code' => $code, 'redirect-url' => $redirect_url, - 'state' => $state - ]; + 'state' => $state]; return $this->client->create("/access/openid/login", $params); } } /** * Class PVEAccessTfa - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEAccessTfa { @@ -22646,7 +23383,7 @@ public function listTfa() { /** * Class PVEItemTfaAccessUserid - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemTfaAccessUserid { @@ -22697,21 +23434,19 @@ public function listUserTfa() { * @return Result */ public function addTfaEntry($type, $challenge = null, $description = null, $password = null, $totp = null, $value = null) { - $params = [ - 'type' => $type, + $params = ['type' => $type, 'challenge' => $challenge, 'description' => $description, 'password' => $password, 'totp' => $totp, - 'value' => $value - ]; + 'value' => $value]; return $this->client->create("/access/tfa/{$this->userid}", $params); } } /** * Class PVEItemUseridTfaAccessId - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemUseridTfaAccessId { @@ -22765,18 +23500,16 @@ public function getTfaEntry() { * @return Result */ public function updateTfaEntry($description = null, $enable = null, $password = null) { - $params = [ - 'description' => $description, + $params = ['description' => $description, 'enable' => $enable, - 'password' => $password - ]; + 'password' => $password]; return $this->client->set("/access/tfa/{$this->userid}/{$this->id}", $params); } } /** * Class PVEAccessTicket - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEAccessTicket { @@ -22813,23 +23546,21 @@ public function getTicket() { * @return Result */ public function createTicket($password, $username, $new_format = null, $otp = null, $path = null, $privs = null, $realm = null, $tfa_challenge = null) { - $params = [ - 'password' => $password, + $params = ['password' => $password, 'username' => $username, 'new-format' => $new_format, 'otp' => $otp, 'path' => $path, 'privs' => $privs, 'realm' => $realm, - 'tfa-challenge' => $tfa_challenge - ]; + 'tfa-challenge' => $tfa_challenge]; return $this->client->create("/access/ticket", $params); } } /** * Class PVEAccessPassword - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEAccessPassword { @@ -22852,17 +23583,15 @@ function __construct($client) { * @return Result */ public function changePassword($password, $userid) { - $params = [ - 'password' => $password, - 'userid' => $userid - ]; + $params = ['password' => $password, + 'userid' => $userid]; return $this->client->set("/access/password", $params); } } /** * Class PVEAccessPermissions - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEAccessPermissions { @@ -22885,17 +23614,15 @@ function __construct($client) { * @return Result */ public function permissions($path = null, $userid = null) { - $params = [ - 'path' => $path, - 'userid' => $userid - ]; + $params = ['path' => $path, + 'userid' => $userid]; return $this->client->get("/access/permissions", $params); } } /** * Class PVEPools - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEPools { @@ -22921,31 +23648,64 @@ public function get($poolid) { } /** - * Pool index. + * Delete pool. + * @param string $poolid * @return Result */ - public function index() { - return $this->client->get("/pools"); + public function deletePool($poolid) { + $params = ['poolid' => $poolid]; + return $this->client->delete("/pools", $params); + } + + /** + * List pools or get pool configuration. + * @param string $poolid + * @param string $type + * Enum: qemu,lxc,storage + * @return Result + */ + public function index($poolid = null, $type = null) { + $params = ['poolid' => $poolid, + 'type' => $type]; + return $this->client->get("/pools", $params); } /** * Create new pool. - * @param string $poolid - * @param string $comment + * @param string $poolid + * @param string $comment * @return Result */ public function createPool($poolid, $comment = null) { - $params = [ - 'poolid' => $poolid, - 'comment' => $comment - ]; + $params = ['poolid' => $poolid, + 'comment' => $comment]; return $this->client->create("/pools", $params); } + + /** + * Update pool. + * @param string $poolid + * @param bool $allow_move Allow adding a guest even if already in another pool. The guest will be removed from its current pool and added to this one. + * @param string $comment + * @param bool $delete Remove the passed VMIDs and/or storage IDs instead of adding them. + * @param string $storage List of storage IDs to add or remove from this pool. + * @param string $vms List of guest VMIDs to add or remove from this pool. + * @return Result + */ + public function updatePool($poolid, $allow_move = null, $comment = null, $delete = null, $storage = null, $vms = null) { + $params = ['poolid' => $poolid, + 'allow-move' => $allow_move, + 'comment' => $comment, + 'delete' => $delete, + 'storage' => $storage, + 'vms' => $vms]; + return $this->client->set("/pools", $params); + } } /** * Class PVEItemPoolsPoolid - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEItemPoolsPoolid { @@ -22968,16 +23728,16 @@ function __construct($client, $poolid) { } /** - * Delete pool. + * Delete pool (deprecated, no support for nested pools, use 'DELETE /pools/?poolid={poolid}'). * @return Result */ - public function deletePool() { + public function deletePoolDeprecated() { return $this->client->delete("/pools/{$this->poolid}"); } /** - * Get pool configuration. - * @param string $type + * Get pool configuration (deprecated, no support for nested pools, use 'GET /pools/?poolid={poolid}'). + * @param string $type * Enum: qemu,lxc,storage * @return Result */ @@ -22987,27 +23747,27 @@ public function readPool($type = null) { } /** - * Update pool data. - * @param string $comment - * @param bool $delete Remove vms/storage (instead of adding it). - * @param string $storage List of storage IDs. - * @param string $vms List of virtual machines. + * Update pool data (deprecated, no support for nested pools - use 'PUT /pools/?poolid={poolid}' instead). + * @param bool $allow_move Allow adding a guest even if already in another pool. The guest will be removed from its current pool and added to this one. + * @param string $comment + * @param bool $delete Remove the passed VMIDs and/or storage IDs instead of adding them. + * @param string $storage List of storage IDs to add or remove from this pool. + * @param string $vms List of guest VMIDs to add or remove from this pool. * @return Result */ - public function updatePool($comment = null, $delete = null, $storage = null, $vms = null) { - $params = [ + public function updatePoolDeprecated($allow_move = null, $comment = null, $delete = null, $storage = null, $vms = null) { + $params = ['allow-move' => $allow_move, 'comment' => $comment, 'delete' => $delete, 'storage' => $storage, - 'vms' => $vms - ]; + 'vms' => $vms]; return $this->client->set("/pools/{$this->poolid}", $params); } } /** * Class PVEVersion - * @package Corsinvest\VE\ProxmoxVE\Api + * @package Corsinvest\VE\ProxmoxVE\Api */ class PVEVersion { @@ -23032,4 +23792,4 @@ public function version() { } } -} +} \ No newline at end of file