From: Dietmar Maurer Date: Sat, 30 Apr 2016 10:03:57 +0000 (+0200) Subject: update auto-generate docs X-Git-Url: https://git.proxmox.com/?p=pve-docs.git;a=commitdiff_plain;h=44660702242b1670808d0603d90d48e24211638d update auto-generate docs Which are now sorted, so that we can detect changes easily. --- diff --git a/api-viewer/apidata.js b/api-viewer/apidata.js index 26307a5..ef072a2 100644 --- a/api-viewer/apidata.js +++ b/api-viewer/apidata.js @@ -1,447 +1,195 @@ var pveapi = [ { - "leaf" : 0, - "path" : "/cluster", - "info" : { - "GET" : { - "method" : "GET", - "returns" : { - "links" : [ - { - "rel" : "child", - "href" : "{name}" - } - ], - "items" : { - "type" : "object", - "properties" : {} - }, - "type" : "array" - }, - "permissions" : { - "user" : "all" - }, - "parameters" : { - "additionalProperties" : 0 - }, - "name" : "index", - "description" : "Cluster index." - } - }, "children" : [ { - "info" : { - "GET" : { - "method" : "GET", - "returns" : { - "type" : "array", - "items" : { - "type" : "object", - "properties" : {} - }, - "links" : [ - { - "rel" : "child", - "href" : "{name}" - } - ] - }, - "description" : "Directory index.", - "permissions" : { - "user" : "all" - }, - "parameters" : { - "additionalProperties" : 0 - }, - "name" : "index" - } - }, - "text" : "firewall", "children" : [ { - "info" : { - "GET" : { - "method" : "GET", - "returns" : { - "type" : "array", - "links" : [ - { - "href" : "{group}", - "rel" : "child" - } - ], - "items" : { - "properties" : { - "group" : { - "maxLength" : 20, - "minLength" : 2, - "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", - "description" : "Security Group name.", - "type" : "string" - }, - "digest" : { - "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", - "optional" : 0, - "type" : "string", - "maxLength" : 40 - }, - "comment" : { - "type" : "string", - "optional" : 1 - } - }, - "type" : "object" - } - }, - "description" : "List security groups.", - "permissions" : { - "user" : "all" - }, - "parameters" : { - "additionalProperties" : 0 - }, - "name" : "list_security_groups" - }, - "POST" : { - "returns" : { - "type" : "null" - }, - "method" : "POST", - "parameters" : { - "additionalProperties" : 0, - "properties" : { - "group" : { - "maxLength" : 20, - "description" : "Security Group name.", - "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", - "minLength" : 2, - "type" : "string" - }, - "digest" : { - "maxLength" : 40, - "optional" : 1, - "type" : "string", - "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications." - }, - "rename" : { - "maxLength" : 20, - "optional" : 1, - "type" : "string", - "minLength" : 2, - "description" : "Rename/update an existing security group. You can set 'rename' to the same value as 'name' to update the 'comment' of an existing group.", - "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+" - }, - "comment" : { - "type" : "string", - "optional" : 1 - } - } - }, - "permissions" : { - "check" : [ - "perm", - "/", - [ - "Sys.Modify" - ] - ] - }, - "name" : "create_security_group", - "description" : "Create new security group.", - "protected" : 1 - } - }, - "text" : "groups", "children" : [ { - "leaf" : 0, - "path" : "/cluster/firewall/groups/{group}", - "info" : { - "GET" : { - "proxyto" : null, - "description" : "List rules.", - "permissions" : { - "check" : [ - "perm", - "/", - [ - "Sys.Audit" - ] - ] - }, - "parameters" : { - "properties" : { - "group" : { - "minLength" : 2, - "description" : "Security Group name.", - "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", - "type" : "string", - "maxLength" : 20 + "children" : [ + { + "info" : { + "DELETE" : { + "description" : "Delete rule.", + "method" : "DELETE", + "name" : "delete_rule", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "digest" : { + "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", + "maxLength" : 40, + "optional" : 1, + "type" : "string" + }, + "group" : { + "description" : "Security Group name.", + "maxLength" : 20, + "minLength" : 2, + "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", + "type" : "string" + }, + "pos" : { + "description" : "Update rule at position .", + "minimum" : 0, + "optional" : 1, + "type" : "integer" + } + } + }, + "permissions" : { + "check" : [ + "perm", + "/", + [ + "Sys.Modify" + ] + ] + }, + "protected" : 1, + "proxyto" : null, + "returns" : { + "type" : "null" } }, - "additionalProperties" : 0 - }, - "name" : "get_rules", - "method" : "GET", - "returns" : { - "items" : { - "properties" : { - "pos" : { - "type" : "integer" + "GET" : { + "description" : "Get single rule data.", + "method" : "GET", + "name" : "get_rule", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "group" : { + "description" : "Security Group name.", + "maxLength" : 20, + "minLength" : 2, + "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", + "type" : "string" + }, + "pos" : { + "description" : "Update rule at position .", + "minimum" : 0, + "optional" : 1, + "type" : "integer" + } } }, - "type" : "object" - }, - "links" : [ - { - "href" : "{pos}", - "rel" : "child" + "permissions" : { + "check" : [ + "perm", + "/", + [ + "Sys.Audit" + ] + ] + }, + "proxyto" : null, + "returns" : { + "properties" : { + "pos" : { + "type" : "integer" + } + }, + "type" : "object" } - ], - "type" : "array" - } - }, - "DELETE" : { - "name" : "delete_security_group", - "parameters" : { - "additionalProperties" : 0, - "properties" : { - "group" : { - "maxLength" : 20, - "minLength" : 2, - "description" : "Security Group name.", - "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", - "type" : "string" - } - } - }, - "permissions" : { - "check" : [ - "perm", - "/", - [ - "Sys.Modify" - ] - ] - }, - "protected" : 1, - "description" : "Delete security group.", - "returns" : { - "type" : "null" - }, - "method" : "DELETE" - }, - "POST" : { - "method" : "POST", - "parameters" : { - "additionalProperties" : 0, - "properties" : { - "iface" : { - "maxLength" : 20, - "format" : "pve-iface", - "description" : "Network interface name. You have to use network configuration key names for VMs and containers ('net\\d+'). Host related rules can use arbitrary strings.", - "minLength" : 2, - "optional" : 1, - "type" : "string" - }, - "comment" : { - "type" : "string", - "optional" : 1 - }, - "digest" : { - "maxLength" : 40, - "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", - "optional" : 1, - "type" : "string" - }, - "source" : { - "description" : "Restrict packet source 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.", - "optional" : 1, - "type" : "string", - "format" : "pve-fw-addr-spec" - }, - "sport" : { - "format" : "pve-fw-sport-spec", - "description" : "Restrict TCP/UDP source 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.", - "optional" : 1, - "type" : "string" - }, - "dest" : { - "optional" : 1, - "type" : "string", - "description" : "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.", - "format" : "pve-fw-addr-spec" - }, - "action" : { - "maxLength" : 20, - "type" : "string", - "optional" : 0, - "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", - "description" : "Rule action ('ACCEPT', 'DROP', 'REJECT') or security group name.", - "minLength" : 2 - }, - "enable" : { - "minimum" : 0, - "type" : "integer", - "optional" : 1 - }, - "dport" : { - "format" : "pve-fw-dport-spec", - "description" : "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.", - "type" : "string", - "optional" : 1 - }, - "type" : { - "enum" : [ - "in", - "out", - "group" - ], - "optional" : 0, - "type" : "string" - }, - "macro" : { - "type" : "string", - "optional" : 1, - "maxLength" : 128 - }, - "group" : { - "type" : "string", - "description" : "Security Group name.", - "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", - "minLength" : 2, - "maxLength" : 20 - }, - "proto" : { - "optional" : 1, - "type" : "string", - "description" : "IP protocol. You can use protocol names ('tcp'/'udp') or simple numbers, as defined in '/etc/protocols'.", - "format" : "pve-fw-protocol-spec" - }, - "pos" : { - "minimum" : 0, - "description" : "Update rule at position .", - "type" : "integer", - "optional" : 1 - } - } - }, - "name" : "create_rule", - "protected" : 1, - "returns" : { - "type" : "null" - }, - "permissions" : { - "check" : [ - "perm", - "/", - [ - "Sys.Modify" - ] - ] - }, - "description" : "Create new rule.", - "proxyto" : null - } - }, - "children" : [ - { - "text" : "{pos}", - "info" : { + }, "PUT" : { + "description" : "Modify rule data.", + "method" : "PUT", + "name" : "update_rule", "parameters" : { "additionalProperties" : 0, "properties" : { - "sport" : { - "format" : "pve-fw-sport-spec", - "description" : "Restrict TCP/UDP source 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.", - "type" : "string", - "optional" : 1 - }, - "iface" : { - "minLength" : 2, - "description" : "Network interface name. You have to use network configuration key names for VMs and containers ('net\\d+'). Host related rules can use arbitrary strings.", - "type" : "string", - "optional" : 1, + "action" : { + "description" : "Rule action ('ACCEPT', 'DROP', 'REJECT') or security group name.", "maxLength" : 20, - "format" : "pve-iface" - }, - "macro" : { - "maxLength" : 128, + "minLength" : 2, "optional" : 1, + "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", "type" : "string" }, - "proto" : { - "format" : "pve-fw-protocol-spec", - "type" : "string", - "optional" : 1, - "description" : "IP protocol. You can use protocol names ('tcp'/'udp') or simple numbers, as defined in '/etc/protocols'." - }, - "pos" : { - "description" : "Update rule at position .", - "type" : "integer", + "comment" : { "optional" : 1, - "minimum" : 0 + "type" : "string" }, - "action" : { + "delete" : { + "description" : "A list of settings you want to delete.", + "format" : "pve-configid-list", "optional" : 1, - "type" : "string", - "minLength" : 2, - "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", - "description" : "Rule action ('ACCEPT', 'DROP', 'REJECT') or security group name.", - "maxLength" : 20 + "type" : "string" }, - "enable" : { + "dest" : { + "description" : "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.", + "format" : "pve-fw-addr-spec", "optional" : 1, - "type" : "integer", - "minimum" : 0 + "type" : "string" }, "digest" : { "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", + "maxLength" : 40, "optional" : 1, - "type" : "string", - "maxLength" : 40 + "type" : "string" }, - "source" : { + "dport" : { + "description" : "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.", + "format" : "pve-fw-dport-spec", "optional" : 1, - "type" : "string", - "description" : "Restrict packet source 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.", - "format" : "pve-fw-addr-spec" + "type" : "string" }, - "dest" : { - "format" : "pve-fw-addr-spec", + "enable" : { + "minimum" : 0, "optional" : 1, - "type" : "string", - "description" : "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." + "type" : "integer" }, - "delete" : { - "description" : "A list of settings you want to delete.", - "type" : "string", + "group" : { + "description" : "Security Group name.", + "maxLength" : 20, + "minLength" : 2, + "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", + "type" : "string" + }, + "iface" : { + "description" : "Network interface name. You have to use network configuration key names for VMs and containers ('net\\d+'). Host related rules can use arbitrary strings.", + "format" : "pve-iface", + "maxLength" : 20, + "minLength" : 2, "optional" : 1, - "format" : "pve-configid-list" + "type" : "string" }, - "comment" : { - "type" : "string", - "optional" : 1 + "macro" : { + "maxLength" : 128, + "optional" : 1, + "type" : "string" }, "moveto" : { "description" : "Move rule to new position . Other arguments are ignored.", - "type" : "integer", + "minimum" : 0, "optional" : 1, - "minimum" : 0 + "type" : "integer" }, - "group" : { - "maxLength" : 20, - "type" : "string", - "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", - "description" : "Security Group name.", - "minLength" : 2 + "pos" : { + "description" : "Update rule at position .", + "minimum" : 0, + "optional" : 1, + "type" : "integer" }, - "dport" : { - "type" : "string", + "proto" : { + "description" : "IP protocol. You can use protocol names ('tcp'/'udp') or simple numbers, as defined in '/etc/protocols'.", + "format" : "pve-fw-protocol-spec", "optional" : 1, - "description" : "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.", - "format" : "pve-fw-dport-spec" + "type" : "string" + }, + "source" : { + "description" : "Restrict packet source 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.", + "format" : "pve-fw-addr-spec", + "optional" : 1, + "type" : "string" + }, + "sport" : { + "description" : "Restrict TCP/UDP source 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.", + "format" : "pve-fw-sport-spec", + "optional" : 1, + "type" : "string" }, "type" : { "enum" : [ @@ -454,9 +202,6 @@ var pveapi = [ } } }, - "name" : "update_rule", - "protected" : 1, - "method" : "PUT", "permissions" : { "check" : [ "perm", @@ -466,263 +211,64 @@ var pveapi = [ ] ] }, - "description" : "Modify rule data.", + "protected" : 1, "proxyto" : null, "returns" : { "type" : "null" } - }, - "DELETE" : { - "returns" : { - "type" : "null" - }, - "description" : "Delete rule.", - "proxyto" : null, - "permissions" : { - "check" : [ - "perm", - "/", - [ - "Sys.Modify" - ] - ] - }, - "method" : "DELETE", - "protected" : 1, - "name" : "delete_rule", - "parameters" : { - "properties" : { - "pos" : { - "type" : "integer", - "optional" : 1, - "description" : "Update rule at position .", - "minimum" : 0 - }, - "group" : { - "maxLength" : 20, - "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", - "description" : "Security Group name.", - "minLength" : 2, - "type" : "string" - }, - "digest" : { - "type" : "string", - "optional" : 1, - "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", - "maxLength" : 40 - } - }, - "additionalProperties" : 0 - } - }, - "GET" : { - "name" : "get_rule", - "permissions" : { - "check" : [ - "perm", - "/", - [ - "Sys.Audit" - ] - ] - }, - "parameters" : { - "properties" : { - "pos" : { - "description" : "Update rule at position .", - "type" : "integer", - "optional" : 1, - "minimum" : 0 - }, - "group" : { - "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", - "description" : "Security Group name.", - "minLength" : 2, - "type" : "string", - "maxLength" : 20 - } - }, - "additionalProperties" : 0 - }, - "proxyto" : null, - "description" : "Get single rule data.", - "returns" : { - "properties" : { - "pos" : { - "type" : "integer" - } - }, - "type" : "object" - }, - "method" : "GET" } }, + "leaf" : 1, "path" : "/cluster/firewall/groups/{group}/{pos}", - "leaf" : 1 + "text" : "{pos}" } ], - "text" : "{group}" - } - ], - "leaf" : 0, - "path" : "/cluster/firewall/groups" - }, - { - "info" : { - "GET" : { - "method" : "GET", - "returns" : { - "type" : "array", - "links" : [ - { - "rel" : "child", - "href" : "{pos}" - } - ], - "items" : { - "properties" : { - "pos" : { - "type" : "integer" + "info" : { + "DELETE" : { + "description" : "Delete security group.", + "method" : "DELETE", + "name" : "delete_security_group", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "group" : { + "description" : "Security Group name.", + "maxLength" : 20, + "minLength" : 2, + "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", + "type" : "string" + } } }, - "type" : "object" - } - }, - "name" : "get_rules", - "parameters" : { - "additionalProperties" : 0 - }, - "permissions" : { - "check" : [ - "perm", - "/", - [ - "Sys.Audit" - ] - ] - }, - "description" : "List rules.", - "proxyto" : null - }, - "POST" : { - "method" : "POST", - "protected" : 1, - "name" : "create_rule", - "parameters" : { - "properties" : { - "dport" : { - "description" : "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.", - "optional" : 1, - "type" : "string", - "format" : "pve-fw-dport-spec" - }, - "type" : { - "type" : "string", - "optional" : 0, - "enum" : [ - "in", - "out", - "group" + "permissions" : { + "check" : [ + "perm", + "/", + [ + "Sys.Modify" + ] ] }, - "enable" : { - "type" : "integer", - "optional" : 1, - "minimum" : 0 - }, - "action" : { - "type" : "string", - "optional" : 0, - "minLength" : 2, - "description" : "Rule action ('ACCEPT', 'DROP', 'REJECT') or security group name.", - "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", - "maxLength" : 20 - }, - "macro" : { - "optional" : 1, - "type" : "string", - "maxLength" : 128 - }, - "pos" : { - "description" : "Update rule at position .", - "type" : "integer", - "optional" : 1, - "minimum" : 0 - }, - "proto" : { - "description" : "IP protocol. You can use protocol names ('tcp'/'udp') or simple numbers, as defined in '/etc/protocols'.", - "type" : "string", - "optional" : 1, - "format" : "pve-fw-protocol-spec" - }, - "iface" : { - "description" : "Network interface name. You have to use network configuration key names for VMs and containers ('net\\d+'). Host related rules can use arbitrary strings.", - "minLength" : 2, - "type" : "string", - "optional" : 1, - "maxLength" : 20, - "format" : "pve-iface" - }, - "comment" : { - "type" : "string", - "optional" : 1 - }, - "source" : { - "description" : "Restrict packet source 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.", - "optional" : 1, - "type" : "string", - "format" : "pve-fw-addr-spec" - }, - "digest" : { - "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", - "type" : "string", - "optional" : 1, - "maxLength" : 40 - }, - "dest" : { - "format" : "pve-fw-addr-spec", - "description" : "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.", - "optional" : 1, - "type" : "string" - }, - "sport" : { - "format" : "pve-fw-sport-spec", - "description" : "Restrict TCP/UDP source 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.", - "optional" : 1, - "type" : "string" + "protected" : 1, + "returns" : { + "type" : "null" } }, - "additionalProperties" : 0 - }, - "returns" : { - "type" : "null" - }, - "proxyto" : null, - "description" : "Create new rule.", - "permissions" : { - "check" : [ - "perm", - "/", - [ - "Sys.Modify" - ] - ] - } - } - }, - "children" : [ - { - "text" : "{pos}", - "info" : { "GET" : { + "description" : "List rules.", "method" : "GET", - "returns" : { + "name" : "get_rules", + "parameters" : { + "additionalProperties" : 0, "properties" : { - "pos" : { - "type" : "integer" + "group" : { + "description" : "Security Group name.", + "maxLength" : 20, + "minLength" : 2, + "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", + "type" : "string" } - }, - "type" : "object" + } }, "permissions" : { "check" : [ @@ -733,125 +279,122 @@ var pveapi = [ ] ] }, + "proxyto" : null, + "returns" : { + "items" : { + "properties" : { + "pos" : { + "type" : "integer" + } + }, + "type" : "object" + }, + "links" : [ + { + "href" : "{pos}", + "rel" : "child" + } + ], + "type" : "array" + } + }, + "POST" : { + "description" : "Create new rule.", + "method" : "POST", + "name" : "create_rule", "parameters" : { "additionalProperties" : 0, "properties" : { - "pos" : { - "description" : "Update rule at position .", - "optional" : 1, - "type" : "integer", - "minimum" : 0 - } - } - }, - "name" : "get_rule", - "description" : "Get single rule data.", - "proxyto" : null - }, - "PUT" : { - "protected" : 1, - "name" : "update_rule", - "parameters" : { - "properties" : { - "delete" : { - "description" : "A list of settings you want to delete.", - "optional" : 1, - "type" : "string", - "format" : "pve-configid-list" - }, - "iface" : { + "action" : { + "description" : "Rule action ('ACCEPT', 'DROP', 'REJECT') or security group name.", + "maxLength" : 20, "minLength" : 2, - "description" : "Network interface name. You have to use network configuration key names for VMs and containers ('net\\d+'). Host related rules can use arbitrary strings.", - "type" : "string", - "optional" : 1, - "format" : "pve-iface", - "maxLength" : 20 - }, - "moveto" : { - "minimum" : 0, - "description" : "Move rule to new position . Other arguments are ignored.", - "type" : "integer", - "optional" : 1 - }, - "comment" : { - "optional" : 1, + "optional" : 0, + "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", "type" : "string" }, - "digest" : { - "maxLength" : 40, - "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", + "comment" : { "optional" : 1, "type" : "string" }, - "source" : { + "dest" : { + "description" : "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.", "format" : "pve-fw-addr-spec", - "type" : "string", "optional" : 1, - "description" : "Restrict packet source 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." + "type" : "string" }, - "sport" : { + "digest" : { + "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", + "maxLength" : 40, "optional" : 1, - "type" : "string", - "description" : "Restrict TCP/UDP source 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.", - "format" : "pve-fw-sport-spec" + "type" : "string" }, - "dest" : { - "type" : "string", + "dport" : { + "description" : "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.", + "format" : "pve-fw-dport-spec", "optional" : 1, - "description" : "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.", - "format" : "pve-fw-addr-spec" + "type" : "string" }, "enable" : { + "minimum" : 0, "optional" : 1, - "type" : "integer", - "minimum" : 0 - }, - "dport" : { - "optional" : 1, - "type" : "string", - "description" : "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.", - "format" : "pve-fw-dport-spec" - }, - "type" : { - "enum" : [ - "in", - "out", - "group" - ], - "type" : "string", - "optional" : 1 + "type" : "integer" }, - "action" : { - "type" : "string", - "optional" : 1, + "group" : { + "description" : "Security Group name.", + "maxLength" : 20, + "minLength" : 2, "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", - "description" : "Rule action ('ACCEPT', 'DROP', 'REJECT') or security group name.", + "type" : "string" + }, + "iface" : { + "description" : "Network interface name. You have to use network configuration key names for VMs and containers ('net\\d+'). Host related rules can use arbitrary strings.", + "format" : "pve-iface", + "maxLength" : 20, "minLength" : 2, - "maxLength" : 20 + "optional" : 1, + "type" : "string" }, "macro" : { + "maxLength" : 128, "optional" : 1, - "type" : "string", - "maxLength" : 128 + "type" : "string" }, "pos" : { "description" : "Update rule at position .", + "minimum" : 0, "optional" : 1, - "type" : "integer", - "minimum" : 0 + "type" : "integer" }, "proto" : { "description" : "IP protocol. You can use protocol names ('tcp'/'udp') or simple numbers, as defined in '/etc/protocols'.", + "format" : "pve-fw-protocol-spec", "optional" : 1, - "type" : "string", - "format" : "pve-fw-protocol-spec" + "type" : "string" + }, + "source" : { + "description" : "Restrict packet source 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.", + "format" : "pve-fw-addr-spec", + "optional" : 1, + "type" : "string" + }, + "sport" : { + "description" : "Restrict TCP/UDP source 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.", + "format" : "pve-fw-sport-spec", + "optional" : 1, + "type" : "string" + }, + "type" : { + "enum" : [ + "in", + "out", + "group" + ], + "optional" : 0, + "type" : "string" } - }, - "additionalProperties" : 0 + } }, - "method" : "PUT", - "proxyto" : null, - "description" : "Modify rule data.", "permissions" : { "check" : [ "perm", @@ -861,11 +404,139 @@ var pveapi = [ ] ] }, + "protected" : 1, + "proxyto" : null, "returns" : { "type" : "null" } + } + }, + "leaf" : 0, + "path" : "/cluster/firewall/groups/{group}", + "text" : "{group}" + } + ], + "info" : { + "GET" : { + "description" : "List security groups.", + "method" : "GET", + "name" : "list_security_groups", + "parameters" : { + "additionalProperties" : 0 + }, + "permissions" : { + "user" : "all" + }, + "returns" : { + "items" : { + "properties" : { + "comment" : { + "optional" : 1, + "type" : "string" + }, + "digest" : { + "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", + "maxLength" : 40, + "optional" : 0, + "type" : "string" + }, + "group" : { + "description" : "Security Group name.", + "maxLength" : 20, + "minLength" : 2, + "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", + "type" : "string" + } + }, + "type" : "object" }, + "links" : [ + { + "href" : "{group}", + "rel" : "child" + } + ], + "type" : "array" + } + }, + "POST" : { + "description" : "Create new security group.", + "method" : "POST", + "name" : "create_security_group", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "comment" : { + "optional" : 1, + "type" : "string" + }, + "digest" : { + "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", + "maxLength" : 40, + "optional" : 1, + "type" : "string" + }, + "group" : { + "description" : "Security Group name.", + "maxLength" : 20, + "minLength" : 2, + "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", + "type" : "string" + }, + "rename" : { + "description" : "Rename/update an existing security group. You can set 'rename' to the same value as 'name' to update the 'comment' of an existing group.", + "maxLength" : 20, + "minLength" : 2, + "optional" : 1, + "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", + "type" : "string" + } + } + }, + "permissions" : { + "check" : [ + "perm", + "/", + [ + "Sys.Modify" + ] + ] + }, + "protected" : 1, + "returns" : { + "type" : "null" + } + } + }, + "leaf" : 0, + "path" : "/cluster/firewall/groups", + "text" : "groups" + }, + { + "children" : [ + { + "info" : { "DELETE" : { + "description" : "Delete rule.", + "method" : "DELETE", + "name" : "delete_rule", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "digest" : { + "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", + "maxLength" : 40, + "optional" : 1, + "type" : "string" + }, + "pos" : { + "description" : "Update rule at position .", + "minimum" : 0, + "optional" : 1, + "type" : "integer" + } + } + }, "permissions" : { "check" : [ "perm", @@ -875,112 +546,27 @@ var pveapi = [ ] ] }, + "protected" : 1, "proxyto" : null, - "description" : "Delete rule.", "returns" : { "type" : "null" - }, + } + }, + "GET" : { + "description" : "Get single rule data.", + "method" : "GET", + "name" : "get_rule", "parameters" : { "additionalProperties" : 0, "properties" : { "pos" : { - "optional" : 1, - "type" : "integer", "description" : "Update rule at position .", - "minimum" : 0 - }, - "digest" : { - "maxLength" : 40, + "minimum" : 0, "optional" : 1, - "type" : "string", - "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications." - } - } - }, - "name" : "delete_rule", - "protected" : 1, - "method" : "DELETE" - } - }, - "path" : "/cluster/firewall/rules/{pos}", - "leaf" : 1 - } - ], - "text" : "rules", - "leaf" : 0, - "path" : "/cluster/firewall/rules" - }, - { - "path" : "/cluster/firewall/ipset", - "leaf" : 0, - "children" : [ - { - "leaf" : 0, - "path" : "/cluster/firewall/ipset/{name}", - "info" : { - "DELETE" : { - "protected" : 1, - "description" : "Delete IPSet", - "permissions" : { - "check" : [ - "perm", - "/", - [ - "Sys.Modify" - ] - ] - }, - "parameters" : { - "additionalProperties" : 0, - "properties" : { - "name" : { - "description" : "IP set name.", - "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", - "minLength" : 2, - "type" : "string", - "maxLength" : 64 + "type" : "integer" } } }, - "name" : "delete_ipset", - "returns" : { - "type" : "null" - }, - "method" : "DELETE" - }, - "GET" : { - "returns" : { - "items" : { - "type" : "object", - "properties" : { - "comment" : { - "type" : "string", - "optional" : 1 - }, - "nomatch" : { - "type" : "boolean", - "optional" : 1 - }, - "cidr" : { - "type" : "string" - }, - "digest" : { - "maxLength" : 40, - "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", - "type" : "string", - "optional" : 0 - } - } - }, - "links" : [ - { - "href" : "{cidr}", - "rel" : "child" - } - ], - "type" : "array" - }, - "method" : "GET", "permissions" : { "check" : [ "perm", @@ -990,49 +576,115 @@ var pveapi = [ ] ] }, - "name" : "get_ipset", - "parameters" : { - "additionalProperties" : 0, + "proxyto" : null, + "returns" : { "properties" : { - "name" : { - "description" : "IP set name.", - "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", - "minLength" : 2, - "type" : "string", - "maxLength" : 64 + "pos" : { + "type" : "integer" } - } - }, - "description" : "List IPSet content" + }, + "type" : "object" + } }, - "POST" : { - "returns" : { - "type" : "null" - }, - "method" : "POST", - "name" : "create_ip", + "PUT" : { + "description" : "Modify rule data.", + "method" : "PUT", + "name" : "update_rule", "parameters" : { "additionalProperties" : 0, "properties" : { - "cidr" : { - "format" : "IPorCIDRorAlias", - "type" : "string", - "description" : "Network/IP specification in CIDR format." + "action" : { + "description" : "Rule action ('ACCEPT', 'DROP', 'REJECT') or security group name.", + "maxLength" : 20, + "minLength" : 2, + "optional" : 1, + "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", + "type" : "string" }, - "nomatch" : { - "type" : "boolean", - "optional" : 1 + "comment" : { + "optional" : 1, + "type" : "string" }, - "name" : { - "type" : "string", - "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", - "description" : "IP set name.", + "delete" : { + "description" : "A list of settings you want to delete.", + "format" : "pve-configid-list", + "optional" : 1, + "type" : "string" + }, + "dest" : { + "description" : "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.", + "format" : "pve-fw-addr-spec", + "optional" : 1, + "type" : "string" + }, + "digest" : { + "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", + "maxLength" : 40, + "optional" : 1, + "type" : "string" + }, + "dport" : { + "description" : "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.", + "format" : "pve-fw-dport-spec", + "optional" : 1, + "type" : "string" + }, + "enable" : { + "minimum" : 0, + "optional" : 1, + "type" : "integer" + }, + "iface" : { + "description" : "Network interface name. You have to use network configuration key names for VMs and containers ('net\\d+'). Host related rules can use arbitrary strings.", + "format" : "pve-iface", + "maxLength" : 20, "minLength" : 2, - "maxLength" : 64 + "optional" : 1, + "type" : "string" }, - "comment" : { - "type" : "string", - "optional" : 1 + "macro" : { + "maxLength" : 128, + "optional" : 1, + "type" : "string" + }, + "moveto" : { + "description" : "Move rule to new position . Other arguments are ignored.", + "minimum" : 0, + "optional" : 1, + "type" : "integer" + }, + "pos" : { + "description" : "Update rule at position .", + "minimum" : 0, + "optional" : 1, + "type" : "integer" + }, + "proto" : { + "description" : "IP protocol. You can use protocol names ('tcp'/'udp') or simple numbers, as defined in '/etc/protocols'.", + "format" : "pve-fw-protocol-spec", + "optional" : 1, + "type" : "string" + }, + "source" : { + "description" : "Restrict packet source 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.", + "format" : "pve-fw-addr-spec", + "optional" : 1, + "type" : "string" + }, + "sport" : { + "description" : "Restrict TCP/UDP source 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.", + "format" : "pve-fw-sport-spec", + "optional" : 1, + "type" : "string" + }, + "type" : { + "enum" : [ + "in", + "out", + "group" + ], + "optional" : 1, + "type" : "string" } } }, @@ -1045,274 +697,141 @@ var pveapi = [ ] ] }, - "description" : "Add IP or Network to IPSet.", - "protected" : 1 + "protected" : 1, + "proxyto" : null, + "returns" : { + "type" : "null" + } } }, - "text" : "{name}", - "children" : [ - { - "text" : "{cidr}", - "info" : { - "GET" : { - "returns" : { - "type" : "object" - }, - "method" : "GET", - "description" : "Read IP or Network settings from IPSet.", - "protected" : 1, - "permissions" : { - "check" : [ - "perm", - "/", - [ - "Sys.Audit" - ] - ] - }, - "parameters" : { - "additionalProperties" : 0, - "properties" : { - "cidr" : { - "description" : "Network/IP specification in CIDR format.", - "type" : "string", - "format" : "IPorCIDRorAlias" - }, - "name" : { - "maxLength" : 64, - "type" : "string", - "minLength" : 2, - "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", - "description" : "IP set name." - } - } - }, - "name" : "read_ip" - }, - "PUT" : { - "method" : "PUT", - "returns" : { - "type" : "null" - }, - "parameters" : { - "additionalProperties" : 0, - "properties" : { - "nomatch" : { - "optional" : 1, - "type" : "boolean" - }, - "name" : { - "maxLength" : 64, - "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", - "description" : "IP set name.", - "minLength" : 2, - "type" : "string" - }, - "comment" : { - "type" : "string", - "optional" : 1 - }, - "cidr" : { - "format" : "IPorCIDRorAlias", - "description" : "Network/IP specification in CIDR format.", - "type" : "string" - }, - "digest" : { - "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", - "optional" : 1, - "type" : "string", - "maxLength" : 40 - } - } - }, - "name" : "update_ip", - "permissions" : { - "check" : [ - "perm", - "/", - [ - "Sys.Modify" - ] - ] - }, - "description" : "Update IP or Network settings", - "protected" : 1 - }, - "DELETE" : { - "method" : "DELETE", - "returns" : { - "type" : "null" - }, - "description" : "Remove IP or Network from IPSet.", - "protected" : 1, - "permissions" : { - "check" : [ - "perm", - "/", - [ - "Sys.Modify" - ] - ] - }, - "parameters" : { - "properties" : { - "digest" : { - "maxLength" : 40, - "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", - "optional" : 1, - "type" : "string" - }, - "cidr" : { - "description" : "Network/IP specification in CIDR format.", - "type" : "string", - "format" : "IPorCIDRorAlias" - }, - "name" : { - "minLength" : 2, - "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", - "description" : "IP set name.", - "type" : "string", - "maxLength" : 64 - } - }, - "additionalProperties" : 0 - }, - "name" : "remove_ip" - } - }, - "path" : "/cluster/firewall/ipset/{name}/{cidr}", - "leaf" : 1 - } - ] + "leaf" : 1, + "path" : "/cluster/firewall/rules/{pos}", + "text" : "{pos}" } ], - "text" : "ipset", "info" : { - "POST" : { - "returns" : { - "type" : "null" - }, - "method" : "POST", - "protected" : 1, - "description" : "Create new IPSet", + "GET" : { + "description" : "List rules.", + "method" : "GET", + "name" : "get_rules", "parameters" : { - "additionalProperties" : 0, - "properties" : { - "comment" : { - "type" : "string", - "optional" : 1 - }, - "name" : { - "description" : "IP set name.", - "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", - "minLength" : 2, - "type" : "string", - "maxLength" : 64 - }, - "rename" : { - "type" : "string", - "optional" : 1, - "minLength" : 2, - "description" : "Rename an existing IPSet. You can set 'rename' to the same value as 'name' to update the 'comment' of an existing IPSet.", - "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", - "maxLength" : 64 - }, - "digest" : { - "maxLength" : 40, - "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", - "type" : "string", - "optional" : 1 - } - } + "additionalProperties" : 0 }, "permissions" : { "check" : [ "perm", "/", [ - "Sys.Modify" + "Sys.Audit" ] ] }, - "name" : "create_ipset" - }, - "GET" : { + "proxyto" : null, "returns" : { - "type" : "array", "items" : { "properties" : { - "comment" : { - "type" : "string", - "optional" : 1 - }, - "name" : { - "maxLength" : 64, - "type" : "string", - "minLength" : 2, - "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", - "description" : "IP set name." - }, - "digest" : { - "maxLength" : 40, - "type" : "string", - "optional" : 0, - "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications." + "pos" : { + "type" : "integer" } }, "type" : "object" }, "links" : [ { - "href" : "{name}", + "href" : "{pos}", "rel" : "child" } - ] - }, - "method" : "GET", - "description" : "List IPSets", - "name" : "ipset_index", - "parameters" : { - "additionalProperties" : 0 - }, - "permissions" : { - "check" : [ - "perm", - "/", - [ - "Sys.Audit" - ] - ] + ], + "type" : "array" } - } - } - }, - { - "info" : { + }, "POST" : { + "description" : "Create new rule.", "method" : "POST", - "returns" : { - "type" : "null" - }, - "protected" : 1, - "description" : "Create IP or Network Alias.", + "name" : "create_rule", "parameters" : { "additionalProperties" : 0, "properties" : { - "cidr" : { - "description" : "Network/IP specification in CIDR format.", - "type" : "string", - "format" : "IPorCIDR" - }, - "name" : { - "maxLength" : 64, - "type" : "string", + "action" : { + "description" : "Rule action ('ACCEPT', 'DROP', 'REJECT') or security group name.", + "maxLength" : 20, "minLength" : 2, - "description" : "Alias name.", - "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+" + "optional" : 0, + "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", + "type" : "string" }, "comment" : { "optional" : 1, "type" : "string" + }, + "dest" : { + "description" : "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.", + "format" : "pve-fw-addr-spec", + "optional" : 1, + "type" : "string" + }, + "digest" : { + "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", + "maxLength" : 40, + "optional" : 1, + "type" : "string" + }, + "dport" : { + "description" : "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.", + "format" : "pve-fw-dport-spec", + "optional" : 1, + "type" : "string" + }, + "enable" : { + "minimum" : 0, + "optional" : 1, + "type" : "integer" + }, + "iface" : { + "description" : "Network interface name. You have to use network configuration key names for VMs and containers ('net\\d+'). Host related rules can use arbitrary strings.", + "format" : "pve-iface", + "maxLength" : 20, + "minLength" : 2, + "optional" : 1, + "type" : "string" + }, + "macro" : { + "maxLength" : 128, + "optional" : 1, + "type" : "string" + }, + "pos" : { + "description" : "Update rule at position .", + "minimum" : 0, + "optional" : 1, + "type" : "integer" + }, + "proto" : { + "description" : "IP protocol. You can use protocol names ('tcp'/'udp') or simple numbers, as defined in '/etc/protocols'.", + "format" : "pve-fw-protocol-spec", + "optional" : 1, + "type" : "string" + }, + "source" : { + "description" : "Restrict packet source 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.", + "format" : "pve-fw-addr-spec", + "optional" : 1, + "type" : "string" + }, + "sport" : { + "description" : "Restrict TCP/UDP source 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.", + "format" : "pve-fw-sport-spec", + "optional" : 1, + "type" : "string" + }, + "type" : { + "enum" : [ + "in", + "out", + "group" + ], + "optional" : 0, + "type" : "string" } } }, @@ -1325,80 +844,171 @@ var pveapi = [ ] ] }, - "name" : "create_alias" - }, - "GET" : { - "method" : "GET", + "protected" : 1, + "proxyto" : null, "returns" : { - "type" : "array", - "links" : [ - { - "rel" : "child", - "href" : "{name}" - } - ], - "items" : { - "properties" : { - "digest" : { - "optional" : 0, - "type" : "string", - "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", - "maxLength" : 40 - }, - "cidr" : { - "type" : "string" + "type" : "null" + } + } + }, + "leaf" : 0, + "path" : "/cluster/firewall/rules", + "text" : "rules" + }, + { + "children" : [ + { + "children" : [ + { + "info" : { + "DELETE" : { + "description" : "Remove IP or Network from IPSet.", + "method" : "DELETE", + "name" : "remove_ip", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "cidr" : { + "description" : "Network/IP specification in CIDR format.", + "format" : "IPorCIDRorAlias", + "type" : "string" + }, + "digest" : { + "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", + "maxLength" : 40, + "optional" : 1, + "type" : "string" + }, + "name" : { + "description" : "IP set name.", + "maxLength" : 64, + "minLength" : 2, + "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", + "type" : "string" + } + } + }, + "permissions" : { + "check" : [ + "perm", + "/", + [ + "Sys.Modify" + ] + ] + }, + "protected" : 1, + "returns" : { + "type" : "null" + } }, - "comment" : { - "optional" : 1, - "type" : "string" + "GET" : { + "description" : "Read IP or Network settings from IPSet.", + "method" : "GET", + "name" : "read_ip", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "cidr" : { + "description" : "Network/IP specification in CIDR format.", + "format" : "IPorCIDRorAlias", + "type" : "string" + }, + "name" : { + "description" : "IP set name.", + "maxLength" : 64, + "minLength" : 2, + "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", + "type" : "string" + } + } + }, + "permissions" : { + "check" : [ + "perm", + "/", + [ + "Sys.Audit" + ] + ] + }, + "protected" : 1, + "returns" : { + "type" : "object" + } }, - "name" : { - "type" : "string" + "PUT" : { + "description" : "Update IP or Network settings", + "method" : "PUT", + "name" : "update_ip", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "cidr" : { + "description" : "Network/IP specification in CIDR format.", + "format" : "IPorCIDRorAlias", + "type" : "string" + }, + "comment" : { + "optional" : 1, + "type" : "string" + }, + "digest" : { + "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", + "maxLength" : 40, + "optional" : 1, + "type" : "string" + }, + "name" : { + "description" : "IP set name.", + "maxLength" : 64, + "minLength" : 2, + "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", + "type" : "string" + }, + "nomatch" : { + "optional" : 1, + "type" : "boolean" + } + } + }, + "permissions" : { + "check" : [ + "perm", + "/", + [ + "Sys.Modify" + ] + ] + }, + "protected" : 1, + "returns" : { + "type" : "null" + } } }, - "type" : "object" + "leaf" : 1, + "path" : "/cluster/firewall/ipset/{name}/{cidr}", + "text" : "{cidr}" } - }, - "description" : "List aliases", - "parameters" : { - "additionalProperties" : 0 - }, - "permissions" : { - "check" : [ - "perm", - "/", - [ - "Sys.Audit" - ] - ] - }, - "name" : "get_aliases" - } - }, - "text" : "aliases", - "children" : [ - { + ], "info" : { "DELETE" : { + "description" : "Delete IPSet", + "method" : "DELETE", + "name" : "delete_ipset", "parameters" : { + "additionalProperties" : 0, "properties" : { - "digest" : { - "type" : "string", - "optional" : 1, - "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", - "maxLength" : 40 - }, "name" : { + "description" : "IP set name.", "maxLength" : 64, - "type" : "string", - "description" : "Alias name.", + "minLength" : 2, "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", - "minLength" : 2 + "type" : "string" } - }, - "additionalProperties" : 0 + } }, - "name" : "remove_alias", "permissions" : { "check" : [ "perm", @@ -1408,76 +1018,94 @@ var pveapi = [ ] ] }, - "description" : "Remove IP or Network alias.", "protected" : 1, "returns" : { "type" : "null" - }, - "method" : "DELETE" + } }, - "PUT" : { - "method" : "PUT", - "returns" : { - "type" : "null" - }, - "description" : "Update IP or Network alias.", - "protected" : 1, + "GET" : { + "description" : "List IPSet content", + "method" : "GET", + "name" : "get_ipset", "parameters" : { "additionalProperties" : 0, "properties" : { - "rename" : { - "maxLength" : 64, - "minLength" : 2, - "description" : "Rename an existing alias.", - "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", - "optional" : 1, - "type" : "string" - }, "name" : { + "description" : "IP set name.", "maxLength" : 64, - "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", - "description" : "Alias name.", "minLength" : 2, + "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", "type" : "string" - }, - "comment" : { - "type" : "string", - "optional" : 1 - }, - "cidr" : { - "description" : "Network/IP specification in CIDR format.", - "type" : "string", - "format" : "IPorCIDR" - }, - "digest" : { - "maxLength" : 40, - "type" : "string", - "optional" : 1, - "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications." } } }, - "name" : "update_alias", "permissions" : { "check" : [ "perm", "/", [ - "Sys.Modify" + "Sys.Audit" ] ] + }, + "returns" : { + "items" : { + "properties" : { + "cidr" : { + "type" : "string" + }, + "comment" : { + "optional" : 1, + "type" : "string" + }, + "digest" : { + "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", + "maxLength" : 40, + "optional" : 0, + "type" : "string" + }, + "nomatch" : { + "optional" : 1, + "type" : "boolean" + } + }, + "type" : "object" + }, + "links" : [ + { + "href" : "{cidr}", + "rel" : "child" + } + ], + "type" : "array" } }, - "GET" : { + "POST" : { + "description" : "Add IP or Network to IPSet.", + "method" : "POST", + "name" : "create_ip", "parameters" : { "additionalProperties" : 0, "properties" : { - "name" : { - "maxLength" : 64, - "type" : "string", - "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", - "description" : "Alias name.", - "minLength" : 2 + "cidr" : { + "description" : "Network/IP specification in CIDR format.", + "format" : "IPorCIDRorAlias", + "type" : "string" + }, + "comment" : { + "optional" : 1, + "type" : "string" + }, + "name" : { + "description" : "IP set name.", + "maxLength" : 64, + "minLength" : 2, + "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", + "type" : "string" + }, + "nomatch" : { + "optional" : 1, + "type" : "boolean" } } }, @@ -1486,90 +1114,29 @@ var pveapi = [ "perm", "/", [ - "Sys.Audit" + "Sys.Modify" ] ] }, - "name" : "read_alias", - "description" : "Read alias.", + "protected" : 1, "returns" : { - "type" : "object" - }, - "method" : "GET" + "type" : "null" + } } }, - "text" : "{name}", - "leaf" : 1, - "path" : "/cluster/firewall/aliases/{name}" + "leaf" : 0, + "path" : "/cluster/firewall/ipset/{name}", + "text" : "{name}" } ], - "leaf" : 0, - "path" : "/cluster/firewall/aliases" - }, - { "info" : { - "PUT" : { - "description" : "Set Firewall options.", - "protected" : 1, + "GET" : { + "description" : "List IPSets", + "method" : "GET", + "name" : "ipset_index", "parameters" : { - "properties" : { - "policy_out" : { - "type" : "string", - "optional" : 1, - "description" : "Output policy.", - "enum" : [ - "ACCEPT", - "REJECT", - "DROP" - ] - }, - "delete" : { - "optional" : 1, - "type" : "string", - "description" : "A list of settings you want to delete.", - "format" : "pve-configid-list" - }, - "enable" : { - "type" : "integer", - "optional" : 1, - "description" : "Enable or disable the firewall cluster wide.", - "minimum" : 0 - }, - "digest" : { - "maxLength" : 40, - "optional" : 1, - "type" : "string", - "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications." - }, - "policy_in" : { - "optional" : 1, - "type" : "string", - "description" : "Input policy.", - "enum" : [ - "ACCEPT", - "REJECT", - "DROP" - ] - } - }, "additionalProperties" : 0 }, - "name" : "set_options", - "permissions" : { - "check" : [ - "perm", - "/", - [ - "Sys.Modify" - ] - ] - }, - "method" : "PUT", - "returns" : { - "type" : "null" - } - }, - "GET" : { "permissions" : { "check" : [ "perm", @@ -1579,99 +1146,69 @@ var pveapi = [ ] ] }, - "parameters" : { - "additionalProperties" : 0 - }, - "name" : "get_options", - "description" : "Get Firewall options.", - "method" : "GET", - "returns" : { - "type" : "object", - "properties" : { - "policy_in" : { - "optional" : 1, - "type" : "string", - "description" : "Input policy.", - "enum" : [ - "ACCEPT", - "REJECT", - "DROP" - ] - }, - "enable" : { - "description" : "Enable or disable the firewall cluster wide.", - "optional" : 1, - "type" : "integer", - "minimum" : 0 - }, - "policy_out" : { - "optional" : 1, - "type" : "string", - "description" : "Output policy.", - "enum" : [ - "ACCEPT", - "REJECT", - "DROP" - ] - } - } - } - } - }, - "text" : "options", - "leaf" : 1, - "path" : "/cluster/firewall/options" - }, - { - "info" : { - "GET" : { - "description" : "List available macros", - "name" : "get_macros", - "permissions" : { - "user" : "all" - }, - "parameters" : { - "additionalProperties" : 0 - }, - "method" : "GET", "returns" : { - "type" : "array", "items" : { "properties" : { - "descr" : { - "type" : "string", - "description" : "More verbose description (if available)." + "comment" : { + "optional" : 1, + "type" : "string" }, - "macro" : { - "description" : "Macro name.", + "digest" : { + "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", + "maxLength" : 40, + "optional" : 0, + "type" : "string" + }, + "name" : { + "description" : "IP set name.", + "maxLength" : 64, + "minLength" : 2, + "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", "type" : "string" } }, "type" : "object" - } + }, + "links" : [ + { + "href" : "{name}", + "rel" : "child" + } + ], + "type" : "array" } - } - }, - "text" : "macros", - "leaf" : 1, - "path" : "/cluster/firewall/macros" - }, - { - "leaf" : 1, - "path" : "/cluster/firewall/refs", - "info" : { - "GET" : { + }, + "POST" : { + "description" : "Create new IPSet", + "method" : "POST", + "name" : "create_ipset", "parameters" : { "additionalProperties" : 0, "properties" : { - "type" : { - "description" : "Only list references of specified type.", - "enum" : [ - "alias", - "ipset" - ], - "type" : "string", - "optional" : 1 + "comment" : { + "optional" : 1, + "type" : "string" + }, + "digest" : { + "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", + "maxLength" : 40, + "optional" : 1, + "type" : "string" + }, + "name" : { + "description" : "IP set name.", + "maxLength" : 64, + "minLength" : 2, + "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", + "type" : "string" + }, + "rename" : { + "description" : "Rename an existing IPSet. You can set 'rename' to the same value as 'name' to update the 'comment' of an existing IPSet.", + "maxLength" : 64, + "minLength" : 2, + "optional" : 1, + "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", + "type" : "string" } } }, @@ -1680,61 +1217,218 @@ var pveapi = [ "perm", "/", [ - "Sys.Audit" + "Sys.Modify" ] ] }, - "name" : "refs", - "description" : "Lists possible IPSet/Alias reference which are allowed in source/dest properties.", + "protected" : 1, "returns" : { - "items" : { - "properties" : { - "name" : { - "type" : "string" - }, - "type" : { - "type" : "string", - "enum" : [ - "alias", - "ipset" - ] - }, - "ref" : { - "type" : "string" - }, - "comment" : { - "type" : "string", - "optional" : 1 - } - }, - "type" : "object" - }, - "type" : "array" - }, - "method" : "GET" + "type" : "null" + } } }, - "text" : "refs" - } - ], - "leaf" : 0, - "path" : "/cluster/firewall" - }, - { - "children" : [ + "leaf" : 0, + "path" : "/cluster/firewall/ipset", + "text" : "ipset" + }, { - "info" : { - "DELETE" : { - "protected" : 1, - "description" : "Delete vzdump backup job definition.", - "name" : "delete_job", + "children" : [ + { + "info" : { + "DELETE" : { + "description" : "Remove IP or Network alias.", + "method" : "DELETE", + "name" : "remove_alias", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "digest" : { + "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", + "maxLength" : 40, + "optional" : 1, + "type" : "string" + }, + "name" : { + "description" : "Alias name.", + "maxLength" : 64, + "minLength" : 2, + "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", + "type" : "string" + } + } + }, + "permissions" : { + "check" : [ + "perm", + "/", + [ + "Sys.Modify" + ] + ] + }, + "protected" : 1, + "returns" : { + "type" : "null" + } + }, + "GET" : { + "description" : "Read alias.", + "method" : "GET", + "name" : "read_alias", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "name" : { + "description" : "Alias name.", + "maxLength" : 64, + "minLength" : 2, + "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", + "type" : "string" + } + } + }, + "permissions" : { + "check" : [ + "perm", + "/", + [ + "Sys.Audit" + ] + ] + }, + "returns" : { + "type" : "object" + } + }, + "PUT" : { + "description" : "Update IP or Network alias.", + "method" : "PUT", + "name" : "update_alias", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "cidr" : { + "description" : "Network/IP specification in CIDR format.", + "format" : "IPorCIDR", + "type" : "string" + }, + "comment" : { + "optional" : 1, + "type" : "string" + }, + "digest" : { + "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", + "maxLength" : 40, + "optional" : 1, + "type" : "string" + }, + "name" : { + "description" : "Alias name.", + "maxLength" : 64, + "minLength" : 2, + "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", + "type" : "string" + }, + "rename" : { + "description" : "Rename an existing alias.", + "maxLength" : 64, + "minLength" : 2, + "optional" : 1, + "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", + "type" : "string" + } + } + }, + "permissions" : { + "check" : [ + "perm", + "/", + [ + "Sys.Modify" + ] + ] + }, + "protected" : 1, + "returns" : { + "type" : "null" + } + } + }, + "leaf" : 1, + "path" : "/cluster/firewall/aliases/{name}", + "text" : "{name}" + } + ], + "info" : { + "GET" : { + "description" : "List aliases", + "method" : "GET", + "name" : "get_aliases", + "parameters" : { + "additionalProperties" : 0 + }, + "permissions" : { + "check" : [ + "perm", + "/", + [ + "Sys.Audit" + ] + ] + }, + "returns" : { + "items" : { + "properties" : { + "cidr" : { + "type" : "string" + }, + "comment" : { + "optional" : 1, + "type" : "string" + }, + "digest" : { + "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", + "maxLength" : 40, + "optional" : 0, + "type" : "string" + }, + "name" : { + "type" : "string" + } + }, + "type" : "object" + }, + "links" : [ + { + "href" : "{name}", + "rel" : "child" + } + ], + "type" : "array" + } + }, + "POST" : { + "description" : "Create IP or Network Alias.", + "method" : "POST", + "name" : "create_alias", "parameters" : { "additionalProperties" : 0, "properties" : { - "id" : { - "type" : "string", - "description" : "The job ID.", - "maxLength" : 50 + "cidr" : { + "description" : "Network/IP specification in CIDR format.", + "format" : "IPorCIDR", + "type" : "string" + }, + "comment" : { + "optional" : 1, + "type" : "string" + }, + "name" : { + "description" : "Alias name.", + "maxLength" : 64, + "minLength" : 2, + "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", + "type" : "string" } } }, @@ -1747,240 +1441,185 @@ var pveapi = [ ] ] }, - "method" : "DELETE", + "protected" : 1, "returns" : { "type" : "null" } - }, - "PUT" : { - "method" : "PUT", - "returns" : { - "type" : "null" + } + }, + "leaf" : 0, + "path" : "/cluster/firewall/aliases", + "text" : "aliases" + }, + { + "info" : { + "GET" : { + "description" : "Get Firewall options.", + "method" : "GET", + "name" : "get_options", + "parameters" : { + "additionalProperties" : 0 }, - "name" : "update_job", "permissions" : { "check" : [ "perm", "/", [ - "Sys.Modify" + "Sys.Audit" ] ] }, - "parameters" : { + "returns" : { "properties" : { - "size" : { - "minimum" : 500, - "description" : "Unused, will be removed in a future release.", - "default" : 1024, + "enable" : { + "description" : "Enable or disable the firewall cluster wide.", + "minimum" : 0, "optional" : 1, "type" : "integer" }, - "node" : { - "type" : "string", - "optional" : 1, - "description" : "Only run if executed on this node.", - "format" : "pve-node" - }, - "exclude" : { - "optional" : 1, - "type" : "string", - "description" : "Exclude specified guest systems (assumes --all)", - "format" : "pve-vmid-list" - }, - "delete" : { - "format" : "pve-configid-list", + "policy_in" : { + "description" : "Input policy.", + "enum" : [ + "ACCEPT", + "REJECT", + "DROP" + ], "optional" : 1, - "type" : "string", - "description" : "A list of settings you want to delete." + "type" : "string" }, - "stdexcludes" : { - "description" : "Exclude temporary files and logs.", - "default" : 1, + "policy_out" : { + "description" : "Output policy.", + "enum" : [ + "ACCEPT", + "REJECT", + "DROP" + ], "optional" : 1, - "type" : "boolean" - }, - "exclude-path" : { - "format" : "string-alist", - "type" : "string", - "optional" : 1, - "description" : "Exclude certain files/directories (shell globs)." - }, - "enabled" : { - "description" : "Enable or disable the job.", - "type" : "boolean", - "optional" : 1, - "default" : "1" - }, - "storage" : { - "format" : "pve-storage-id", + "type" : "string" + } + }, + "type" : "object" + } + }, + "PUT" : { + "description" : "Set Firewall options.", + "method" : "PUT", + "name" : "set_options", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "delete" : { + "description" : "A list of settings you want to delete.", + "format" : "pve-configid-list", "optional" : 1, - "type" : "string", - "description" : "Store resulting file to this storage." + "type" : "string" }, - "pigz" : { - "default" : 0, + "digest" : { + "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", + "maxLength" : 40, "optional" : 1, - "type" : "integer", - "description" : "Use pigz instead of gzip when N>0. N=1 uses half of cores, N>1 uses N as thread count." + "type" : "string" }, - "stopwait" : { + "enable" : { + "description" : "Enable or disable the firewall cluster wide.", "minimum" : 0, - "description" : "Maximal time to wait until a guest system is stopped (minutes).", - "type" : "integer", - "optional" : 1, - "default" : 10 - }, - "quiet" : { - "description" : "Be quiet.", - "default" : 0, "optional" : 1, - "type" : "boolean" + "type" : "integer" }, - "mailnotification" : { + "policy_in" : { + "description" : "Input policy.", "enum" : [ - "always", - "failure" + "ACCEPT", + "REJECT", + "DROP" ], - "description" : "Specify when to send an email", - "type" : "string", - "optional" : 1, - "default" : "always" - }, - "all" : { - "type" : "boolean", - "optional" : 1, - "default" : 0, - "description" : "Backup all known guest systems on this host." - }, - "id" : { - "description" : "The job ID.", - "type" : "string", - "maxLength" : 50 - }, - "remove" : { - "default" : 1, - "optional" : 1, - "type" : "boolean", - "description" : "Remove old backup files if there are more than 'maxfiles' backup files." - }, - "script" : { - "optional" : 1, - "type" : "string", - "description" : "Use specified hook script." - }, - "lockwait" : { - "minimum" : 0, - "default" : 180, - "optional" : 1, - "type" : "integer", - "description" : "Maximal time to wait for the global lock (minutes)." - }, - "mailto" : { - "type" : "string", - "optional" : 1, - "description" : "Comma-separated list of email addresses that should receive email notifications.", - "format" : "string-list" - }, - "dumpdir" : { - "description" : "Store resulting files to specified directory.", - "type" : "string", - "optional" : 1 - }, - "starttime" : { - "pattern" : "\\d{1,2}:\\d{1,2}", - "description" : "Job Start time.", - "type" : "string", - "typetext" : "HH:MM" - }, - "bwlimit" : { - "minimum" : 0, - "description" : "Limit I/O bandwidth (KBytes per second).", - "default" : 0, - "optional" : 1, - "type" : "integer" - }, - "ionice" : { - "minimum" : 0, - "description" : "Set CFQ ionice priority.", - "optional" : 1, - "type" : "integer", - "default" : 7, - "maximum" : 8 - }, - "stop" : { - "default" : 0, - "optional" : 1, - "type" : "boolean", - "description" : "Stop runnig backup jobs on this host." - }, - "maxfiles" : { - "description" : "Maximal number of backup files per guest system.", - "default" : 1, "optional" : 1, - "type" : "integer", - "minimum" : 1 + "type" : "string" }, - "mode" : { - "description" : "Backup mode.", + "policy_out" : { + "description" : "Output policy.", "enum" : [ - "snapshot", - "suspend", - "stop" + "ACCEPT", + "REJECT", + "DROP" ], - "default" : "snapshot", - "type" : "string", - "optional" : 1 - }, - "compress" : { - "default" : "0", - "optional" : 1, - "type" : "string", - "description" : "Compress dump file.", - "enum" : [ - "0", - "1", - "gzip", - "lzo" - ] - }, - "tmpdir" : { - "optional" : 1, - "type" : "string", - "description" : "Store temporary files to specified directory." - }, - "vmid" : { - "format" : "pve-vmid-list", - "type" : "string", - "optional" : 1, - "description" : "The ID of the guest system you want to backup." - }, - "dow" : { - "description" : "Day of week selection.", "optional" : 1, - "type" : "string", - "format" : "pve-day-of-week-list" + "type" : "string" } - }, - "additionalProperties" : 0 + } + }, + "permissions" : { + "check" : [ + "perm", + "/", + [ + "Sys.Modify" + ] + ] }, "protected" : 1, - "description" : "Update vzdump backup job definition." - }, + "returns" : { + "type" : "null" + } + } + }, + "leaf" : 1, + "path" : "/cluster/firewall/options", + "text" : "options" + }, + { + "info" : { "GET" : { + "description" : "List available macros", "method" : "GET", - "returns" : { - "type" : "object" + "name" : "get_macros", + "parameters" : { + "additionalProperties" : 0 }, + "permissions" : { + "user" : "all" + }, + "returns" : { + "items" : { + "properties" : { + "descr" : { + "description" : "More verbose description (if available).", + "type" : "string" + }, + "macro" : { + "description" : "Macro name.", + "type" : "string" + } + }, + "type" : "object" + }, + "type" : "array" + } + } + }, + "leaf" : 1, + "path" : "/cluster/firewall/macros", + "text" : "macros" + }, + { + "info" : { + "GET" : { + "description" : "Lists possible IPSet/Alias reference which are allowed in source/dest properties.", + "method" : "GET", + "name" : "refs", "parameters" : { + "additionalProperties" : 0, "properties" : { - "id" : { - "description" : "The job ID.", - "type" : "string", - "maxLength" : 50 + "type" : { + "description" : "Only list references of specified type.", + "enum" : [ + "alias", + "ipset" + ], + "optional" : 1, + "type" : "string" } - }, - "additionalProperties" : 0 + } }, "permissions" : { "check" : [ @@ -1991,454 +1630,618 @@ var pveapi = [ ] ] }, - "name" : "read_job", - "description" : "Read vzdump backup job definition." + "returns" : { + "items" : { + "properties" : { + "comment" : { + "optional" : 1, + "type" : "string" + }, + "name" : { + "type" : "string" + }, + "ref" : { + "type" : "string" + }, + "type" : { + "enum" : [ + "alias", + "ipset" + ], + "type" : "string" + } + }, + "type" : "object" + }, + "type" : "array" + } } }, - "text" : "{id}", "leaf" : 1, - "path" : "/cluster/backup/{id}" + "path" : "/cluster/firewall/refs", + "text" : "refs" } ], - "text" : "backup", "info" : { - "POST" : { - "description" : "Create new vzdump backup job.", - "protected" : 1, - "name" : "create_job", - "permissions" : { - "check" : [ - "perm", - "/", - [ - "Sys.Modify" - ] - ] - }, + "GET" : { + "description" : "Directory index.", + "method" : "GET", + "name" : "index", "parameters" : { - "properties" : { - "stopwait" : { - "default" : 10, - "optional" : 1, - "type" : "integer", - "description" : "Maximal time to wait until a guest system is stopped (minutes).", - "minimum" : 0 - }, - "quiet" : { - "description" : "Be quiet.", - "default" : 0, - "type" : "boolean", - "optional" : 1 - }, - "remove" : { - "default" : 1, - "type" : "boolean", - "optional" : 1, - "description" : "Remove old backup files if there are more than 'maxfiles' backup files." - }, - "mailnotification" : { - "description" : "Specify when to send an email", - "enum" : [ - "always", - "failure" - ], - "default" : "always", - "type" : "string", - "optional" : 1 - }, - "all" : { - "description" : "Backup all known guest systems on this host.", - "optional" : 1, - "type" : "boolean", - "default" : 0 - }, - "exclude" : { - "description" : "Exclude specified guest systems (assumes --all)", - "type" : "string", - "optional" : 1, - "format" : "pve-vmid-list" - }, - "size" : { - "description" : "Unused, will be removed in a future release.", - "default" : 1024, - "type" : "integer", - "optional" : 1, - "minimum" : 500 - }, - "node" : { - "optional" : 1, - "type" : "string", - "description" : "Only run if executed on this node.", - "format" : "pve-node" - }, - "pigz" : { - "default" : 0, - "type" : "integer", - "optional" : 1, - "description" : "Use pigz instead of gzip when N>0. N=1 uses half of cores, N>1 uses N as thread count." - }, - "stdexcludes" : { - "description" : "Exclude temporary files and logs.", - "default" : 1, - "type" : "boolean", - "optional" : 1 - }, - "exclude-path" : { - "type" : "string", - "optional" : 1, - "description" : "Exclude certain files/directories (shell globs).", - "format" : "string-alist" - }, - "storage" : { - "optional" : 1, - "type" : "string", - "description" : "Store resulting file to this storage.", - "format" : "pve-storage-id" - }, - "enabled" : { - "description" : "Enable or disable the job.", - "default" : "1", - "optional" : 1, - "type" : "boolean" - }, - "maxfiles" : { - "minimum" : 1, - "default" : 1, - "optional" : 1, - "type" : "integer", - "description" : "Maximal number of backup files per guest system." - }, - "stop" : { - "type" : "boolean", - "optional" : 1, - "default" : 0, - "description" : "Stop runnig backup jobs on this host." - }, - "tmpdir" : { - "optional" : 1, - "type" : "string", - "description" : "Store temporary files to specified directory." - }, - "compress" : { - "optional" : 1, - "type" : "string", - "default" : "0", - "enum" : [ - "0", - "1", - "gzip", - "lzo" - ], - "description" : "Compress dump file." - }, - "mode" : { - "type" : "string", - "optional" : 1, - "default" : "snapshot", - "enum" : [ - "snapshot", - "suspend", - "stop" - ], - "description" : "Backup mode." - }, - "bwlimit" : { - "description" : "Limit I/O bandwidth (KBytes per second).", - "default" : 0, - "optional" : 1, - "type" : "integer", - "minimum" : 0 - }, - "ionice" : { - "minimum" : 0, - "default" : 7, - "maximum" : 8, - "type" : "integer", - "optional" : 1, - "description" : "Set CFQ ionice priority." - }, - "dow" : { - "format" : "pve-day-of-week-list", - "default" : "mon,tue,wed,thu,fri,sat,sun", - "optional" : 1, - "type" : "string", - "description" : "Day of week selection." - }, - "vmid" : { - "description" : "The ID of the guest system you want to backup.", - "type" : "string", - "optional" : 1, - "format" : "pve-vmid-list" - }, - "lockwait" : { - "minimum" : 0, - "description" : "Maximal time to wait for the global lock (minutes).", - "type" : "integer", - "optional" : 1, - "default" : 180 - }, - "script" : { - "type" : "string", - "optional" : 1, - "description" : "Use specified hook script." - }, - "mailto" : { - "description" : "Comma-separated list of email addresses that should receive email notifications.", - "optional" : 1, - "type" : "string", - "format" : "string-list" - }, - "dumpdir" : { - "description" : "Store resulting files to specified directory.", - "type" : "string", - "optional" : 1 - }, - "starttime" : { - "typetext" : "HH:MM", - "description" : "Job Start time.", - "pattern" : "\\d{1,2}:\\d{1,2}", - "type" : "string" - } - }, "additionalProperties" : 0 }, - "method" : "POST", - "returns" : { - "type" : "null" - } - }, - "GET" : { - "method" : "GET", + "permissions" : { + "user" : "all" + }, "returns" : { + "items" : { + "properties" : {}, + "type" : "object" + }, "links" : [ { - "rel" : "child", - "href" : "{id}" + "href" : "{name}", + "rel" : "child" } ], - "items" : { - "type" : "object", - "properties" : { - "id" : { - "type" : "string" - } - } - }, "type" : "array" - }, - "description" : "List vzdump backup schedule.", - "permissions" : { - "check" : [ - "perm", - "/", - [ - "Sys.Audit" - ] - ] - }, - "name" : "index", - "parameters" : { - "additionalProperties" : 0 } } }, - "path" : "/cluster/backup", - "leaf" : 0 + "leaf" : 0, + "path" : "/cluster/firewall", + "text" : "firewall" }, { - "path" : "/cluster/ha", - "leaf" : 0, - "text" : "ha", "children" : [ { "info" : { - "POST" : { - "method" : "POST", + "DELETE" : { + "description" : "Delete vzdump backup job definition.", + "method" : "DELETE", + "name" : "delete_job", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "id" : { + "description" : "The job ID.", + "maxLength" : 50, + "type" : "string" + } + } + }, + "permissions" : { + "check" : [ + "perm", + "/", + [ + "Sys.Modify" + ] + ] + }, + "protected" : 1, "returns" : { "type" : "null" + } + }, + "GET" : { + "description" : "Read vzdump backup job definition.", + "method" : "GET", + "name" : "read_job", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "id" : { + "description" : "The job ID.", + "maxLength" : 50, + "type" : "string" + } + } }, - "name" : "create", "permissions" : { "check" : [ "perm", "/", [ - "Sys.Console" + "Sys.Audit" ] ] }, + "returns" : { + "type" : "object" + } + }, + "PUT" : { + "description" : "Update vzdump backup job definition.", + "method" : "PUT", + "name" : "update_job", "parameters" : { + "additionalProperties" : 0, "properties" : { - "max_restart" : { - "description" : "Maximal number of tries to restart the service on a node after its start failed.", - "default" : 1, - "type" : "integer", + "all" : { + "default" : 0, + "description" : "Backup all known guest systems on this host.", "optional" : 1, - "minimum" : 0 + "type" : "boolean" }, - "state" : { - "type" : "string", - "optional" : 1, - "default" : "enabled", + "bwlimit" : { + "default" : 0, + "description" : "Limit I/O bandwidth (KBytes per second).", + "minimum" : 0, + "optional" : 1, + "type" : "integer" + }, + "compress" : { + "default" : "0", + "description" : "Compress dump file.", "enum" : [ - "enabled", - "disabled" + "0", + "1", + "gzip", + "lzo" ], - "description" : "Resource state." + "optional" : 1, + "type" : "string" }, - "max_relocate" : { - "default" : 1, + "delete" : { + "description" : "A list of settings you want to delete.", + "format" : "pve-configid-list", "optional" : 1, - "type" : "integer", - "description" : "Maximal number of service relocate tries when a service failes to start.", - "minimum" : 0 + "type" : "string" }, - "group" : { - "type" : "string", + "dow" : { + "description" : "Day of week selection.", + "format" : "pve-day-of-week-list", "optional" : 1, - "description" : "The HA group identifier.", - "format" : "pve-configid" + "type" : "string" }, - "comment" : { + "dumpdir" : { + "description" : "Store resulting files to specified directory.", "optional" : 1, - "type" : "string", - "description" : "Description.", - "maxLength" : 4096 + "type" : "string" }, - "type" : { + "enabled" : { + "default" : "1", + "description" : "Enable or disable the job.", + "optional" : 1, + "type" : "boolean" + }, + "exclude" : { + "description" : "Exclude specified guest systems (assumes --all)", + "format" : "pve-vmid-list", + "optional" : 1, + "type" : "string" + }, + "exclude-path" : { + "description" : "Exclude certain files/directories (shell globs).", + "format" : "string-alist", + "optional" : 1, + "type" : "string" + }, + "id" : { + "description" : "The job ID.", + "maxLength" : 50, + "type" : "string" + }, + "ionice" : { + "default" : 7, + "description" : "Set CFQ ionice priority.", + "maximum" : 8, + "minimum" : 0, + "optional" : 1, + "type" : "integer" + }, + "lockwait" : { + "default" : 180, + "description" : "Maximal time to wait for the global lock (minutes).", + "minimum" : 0, + "optional" : 1, + "type" : "integer" + }, + "mailnotification" : { + "default" : "always", + "description" : "Specify when to send an email", "enum" : [ - "vm", - "ct" + "always", + "failure" ], - "description" : "Resource type.", + "optional" : 1, + "type" : "string" + }, + "mailto" : { + "description" : "Comma-separated list of email addresses that should receive email notifications.", + "format" : "string-list", + "optional" : 1, + "type" : "string" + }, + "maxfiles" : { + "default" : 1, + "description" : "Maximal number of backup files per guest system.", + "minimum" : 1, + "optional" : 1, + "type" : "integer" + }, + "mode" : { + "default" : "snapshot", + "description" : "Backup mode.", + "enum" : [ + "snapshot", + "suspend", + "stop" + ], + "optional" : 1, + "type" : "string" + }, + "node" : { + "description" : "Only run if executed on this node.", + "format" : "pve-node", + "optional" : 1, + "type" : "string" + }, + "pigz" : { + "default" : 0, + "description" : "Use pigz instead of gzip when N>0. N=1 uses half of cores, N>1 uses N as thread count.", + "optional" : 1, + "type" : "integer" + }, + "quiet" : { + "default" : 0, + "description" : "Be quiet.", + "optional" : 1, + "type" : "boolean" + }, + "remove" : { + "default" : 1, + "description" : "Remove old backup files if there are more than 'maxfiles' backup files.", + "optional" : 1, + "type" : "boolean" + }, + "script" : { + "description" : "Use specified hook script.", + "optional" : 1, + "type" : "string" + }, + "size" : { + "default" : 1024, + "description" : "Unused, will be removed in a future release.", + "minimum" : 500, + "optional" : 1, + "type" : "integer" + }, + "starttime" : { + "description" : "Job Start time.", + "pattern" : "\\d{1,2}:\\d{1,2}", "type" : "string", - "optional" : 1 + "typetext" : "HH:MM" }, - "sid" : { - "format" : "pve-ha-resource-or-vm-id", - "typetext" : ":", - "description" : "HA resource ID. This consists of a resource type followed by a resource specific name, separated with colon (example: vm:100 / ct:100). For virtual machines and containers, you can simply use the VM or CT id as a shortcut (example: 100).", + "stdexcludes" : { + "default" : 1, + "description" : "Exclude temporary files and logs.", + "optional" : 1, + "type" : "boolean" + }, + "stop" : { + "default" : 0, + "description" : "Stop runnig backup jobs on this host.", + "optional" : 1, + "type" : "boolean" + }, + "stopwait" : { + "default" : 10, + "description" : "Maximal time to wait until a guest system is stopped (minutes).", + "minimum" : 0, + "optional" : 1, + "type" : "integer" + }, + "storage" : { + "description" : "Store resulting file to this storage.", + "format" : "pve-storage-id", + "optional" : 1, "type" : "string" - } - }, - "additionalProperties" : 0, - "type" : "object" - }, - "protected" : 1, - "description" : "Create a new HA resource." - }, - "GET" : { - "returns" : { - "items" : { - "properties" : { - "sid" : { - "type" : "string" - } }, - "type" : "object" - }, - "links" : [ - { - "href" : "{sid}", - "rel" : "child" + "tmpdir" : { + "description" : "Store temporary files to specified directory.", + "optional" : 1, + "type" : "string" + }, + "vmid" : { + "description" : "The ID of the guest system you want to backup.", + "format" : "pve-vmid-list", + "optional" : 1, + "type" : "string" } - ], - "type" : "array" + } }, - "method" : "GET", - "description" : "List HA resources.", - "name" : "index", "permissions" : { "check" : [ "perm", "/", [ - "Sys.Audit" + "Sys.Modify" ] ] }, - "parameters" : { - "additionalProperties" : 0, - "properties" : { - "type" : { - "type" : "string", - "optional" : 1, - "enum" : [ - "vm", - "ct" - ], - "description" : "Only list resources of specific type" - } - } + "protected" : 1, + "returns" : { + "type" : "null" } } }, - "text" : "resources", - "children" : [ - { - "text" : "{sid}", - "children" : [ - { - "path" : "/cluster/ha/resources/{sid}/migrate", - "leaf" : 1, - "text" : "migrate", - "info" : { - "POST" : { - "name" : "migrate", - "parameters" : { - "properties" : { - "sid" : { - "typetext" : ":", - "format" : "pve-ha-resource-or-vm-id", - "type" : "string", - "description" : "HA resource ID. This consists of a resource type followed by a resource specific name, separated with colon (example: vm:100 / ct:100). For virtual machines and containers, you can simply use the VM or CT id as a shortcut (example: 100)." - }, - "node" : { - "format" : "pve-node", - "description" : "The cluster node name.", - "type" : "string" - } - }, - "additionalProperties" : 0 - }, - "permissions" : { - "check" : [ - "perm", - "/", - [ - "Sys.Console" - ] - ] - }, - "protected" : 1, - "description" : "Request resource migration (online) to another node.", - "returns" : { - "type" : "null" - }, - "method" : "POST" - } - } - }, + "leaf" : 1, + "path" : "/cluster/backup/{id}", + "text" : "{id}" + } + ], + "info" : { + "GET" : { + "description" : "List vzdump backup schedule.", + "method" : "GET", + "name" : "index", + "parameters" : { + "additionalProperties" : 0 + }, + "permissions" : { + "check" : [ + "perm", + "/", + [ + "Sys.Audit" + ] + ] + }, + "returns" : { + "items" : { + "properties" : { + "id" : { + "type" : "string" + } + }, + "type" : "object" + }, + "links" : [ + { + "href" : "{id}", + "rel" : "child" + } + ], + "type" : "array" + } + }, + "POST" : { + "description" : "Create new vzdump backup job.", + "method" : "POST", + "name" : "create_job", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "all" : { + "default" : 0, + "description" : "Backup all known guest systems on this host.", + "optional" : 1, + "type" : "boolean" + }, + "bwlimit" : { + "default" : 0, + "description" : "Limit I/O bandwidth (KBytes per second).", + "minimum" : 0, + "optional" : 1, + "type" : "integer" + }, + "compress" : { + "default" : "0", + "description" : "Compress dump file.", + "enum" : [ + "0", + "1", + "gzip", + "lzo" + ], + "optional" : 1, + "type" : "string" + }, + "dow" : { + "default" : "mon,tue,wed,thu,fri,sat,sun", + "description" : "Day of week selection.", + "format" : "pve-day-of-week-list", + "optional" : 1, + "type" : "string" + }, + "dumpdir" : { + "description" : "Store resulting files to specified directory.", + "optional" : 1, + "type" : "string" + }, + "enabled" : { + "default" : "1", + "description" : "Enable or disable the job.", + "optional" : 1, + "type" : "boolean" + }, + "exclude" : { + "description" : "Exclude specified guest systems (assumes --all)", + "format" : "pve-vmid-list", + "optional" : 1, + "type" : "string" + }, + "exclude-path" : { + "description" : "Exclude certain files/directories (shell globs).", + "format" : "string-alist", + "optional" : 1, + "type" : "string" + }, + "ionice" : { + "default" : 7, + "description" : "Set CFQ ionice priority.", + "maximum" : 8, + "minimum" : 0, + "optional" : 1, + "type" : "integer" + }, + "lockwait" : { + "default" : 180, + "description" : "Maximal time to wait for the global lock (minutes).", + "minimum" : 0, + "optional" : 1, + "type" : "integer" + }, + "mailnotification" : { + "default" : "always", + "description" : "Specify when to send an email", + "enum" : [ + "always", + "failure" + ], + "optional" : 1, + "type" : "string" + }, + "mailto" : { + "description" : "Comma-separated list of email addresses that should receive email notifications.", + "format" : "string-list", + "optional" : 1, + "type" : "string" + }, + "maxfiles" : { + "default" : 1, + "description" : "Maximal number of backup files per guest system.", + "minimum" : 1, + "optional" : 1, + "type" : "integer" + }, + "mode" : { + "default" : "snapshot", + "description" : "Backup mode.", + "enum" : [ + "snapshot", + "suspend", + "stop" + ], + "optional" : 1, + "type" : "string" + }, + "node" : { + "description" : "Only run if executed on this node.", + "format" : "pve-node", + "optional" : 1, + "type" : "string" + }, + "pigz" : { + "default" : 0, + "description" : "Use pigz instead of gzip when N>0. N=1 uses half of cores, N>1 uses N as thread count.", + "optional" : 1, + "type" : "integer" + }, + "quiet" : { + "default" : 0, + "description" : "Be quiet.", + "optional" : 1, + "type" : "boolean" + }, + "remove" : { + "default" : 1, + "description" : "Remove old backup files if there are more than 'maxfiles' backup files.", + "optional" : 1, + "type" : "boolean" + }, + "script" : { + "description" : "Use specified hook script.", + "optional" : 1, + "type" : "string" + }, + "size" : { + "default" : 1024, + "description" : "Unused, will be removed in a future release.", + "minimum" : 500, + "optional" : 1, + "type" : "integer" + }, + "starttime" : { + "description" : "Job Start time.", + "pattern" : "\\d{1,2}:\\d{1,2}", + "type" : "string", + "typetext" : "HH:MM" + }, + "stdexcludes" : { + "default" : 1, + "description" : "Exclude temporary files and logs.", + "optional" : 1, + "type" : "boolean" + }, + "stop" : { + "default" : 0, + "description" : "Stop runnig backup jobs on this host.", + "optional" : 1, + "type" : "boolean" + }, + "stopwait" : { + "default" : 10, + "description" : "Maximal time to wait until a guest system is stopped (minutes).", + "minimum" : 0, + "optional" : 1, + "type" : "integer" + }, + "storage" : { + "description" : "Store resulting file to this storage.", + "format" : "pve-storage-id", + "optional" : 1, + "type" : "string" + }, + "tmpdir" : { + "description" : "Store temporary files to specified directory.", + "optional" : 1, + "type" : "string" + }, + "vmid" : { + "description" : "The ID of the guest system you want to backup.", + "format" : "pve-vmid-list", + "optional" : 1, + "type" : "string" + } + } + }, + "permissions" : { + "check" : [ + "perm", + "/", + [ + "Sys.Modify" + ] + ] + }, + "protected" : 1, + "returns" : { + "type" : "null" + } + } + }, + "leaf" : 0, + "path" : "/cluster/backup", + "text" : "backup" + }, + { + "children" : [ + { + "children" : [ + { + "children" : [ { - "path" : "/cluster/ha/resources/{sid}/relocate", - "leaf" : 1, - "text" : "relocate", "info" : { "POST" : { - "name" : "relocate", + "description" : "Request resource migration (online) to another node.", + "method" : "POST", + "name" : "migrate", "parameters" : { "additionalProperties" : 0, "properties" : { "node" : { - "format" : "pve-node", "description" : "The cluster node name.", + "format" : "pve-node", "type" : "string" }, "sid" : { - "typetext" : ":", + "description" : "HA resource ID. This consists of a resource type followed by a resource specific name, separated with colon (example: vm:100 / ct:100). For virtual machines and containers, you can simply use the VM or CT id as a shortcut (example: 100).", "format" : "pve-ha-resource-or-vm-id", "type" : "string", - "description" : "HA resource ID. This consists of a resource type followed by a resource specific name, separated with colon (example: vm:100 / ct:100). For virtual machines and containers, you can simply use the VM or CT id as a shortcut (example: 100)." + "typetext" : ":" } } }, @@ -2452,29 +2255,101 @@ var pveapi = [ ] }, "protected" : 1, - "description" : "Request resource relocatzion to another node. This stops the service on the old node, and restarts it on the target node.", "returns" : { "type" : "null" - }, - "method" : "POST" + } } - } - } - ], - "info" : { - "GET" : { - "returns" : {}, - "method" : "GET", + }, + "leaf" : 1, + "path" : "/cluster/ha/resources/{sid}/migrate", + "text" : "migrate" + }, + { + "info" : { + "POST" : { + "description" : "Request resource relocatzion to another node. This stops the service on the old node, and restarts it on the target node.", + "method" : "POST", + "name" : "relocate", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, + "sid" : { + "description" : "HA resource ID. This consists of a resource type followed by a resource specific name, separated with colon (example: vm:100 / ct:100). For virtual machines and containers, you can simply use the VM or CT id as a shortcut (example: 100).", + "format" : "pve-ha-resource-or-vm-id", + "type" : "string", + "typetext" : ":" + } + } + }, + "permissions" : { + "check" : [ + "perm", + "/", + [ + "Sys.Console" + ] + ] + }, + "protected" : 1, + "returns" : { + "type" : "null" + } + } + }, + "leaf" : 1, + "path" : "/cluster/ha/resources/{sid}/relocate", + "text" : "relocate" + } + ], + "info" : { + "DELETE" : { + "description" : "Delete resource configuration.", + "method" : "DELETE", + "name" : "delete", "parameters" : { + "additionalProperties" : 0, "properties" : { "sid" : { "description" : "HA resource ID. This consists of a resource type followed by a resource specific name, separated with colon (example: vm:100 / ct:100). For virtual machines and containers, you can simply use the VM or CT id as a shortcut (example: 100).", + "format" : "pve-ha-resource-or-vm-id", "type" : "string", + "typetext" : ":" + } + } + }, + "permissions" : { + "check" : [ + "perm", + "/", + [ + "Sys.Console" + ] + ] + }, + "protected" : 1, + "returns" : { + "type" : "null" + } + }, + "GET" : { + "description" : "Read resource configuration.", + "method" : "GET", + "name" : "read", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "sid" : { + "description" : "HA resource ID. This consists of a resource type followed by a resource specific name, separated with colon (example: vm:100 / ct:100). For virtual machines and containers, you can simply use the VM or CT id as a shortcut (example: 100).", "format" : "pve-ha-resource-or-vm-id", + "type" : "string", "typetext" : ":" } - }, - "additionalProperties" : 0 + } }, "permissions" : { "check" : [ @@ -2485,76 +2360,73 @@ var pveapi = [ ] ] }, - "name" : "read", - "description" : "Read resource configuration." + "returns" : {} }, "PUT" : { - "returns" : { - "type" : "null" - }, + "description" : "Update resource configuration.", "method" : "PUT", + "name" : "update", "parameters" : { "additionalProperties" : 0, - "type" : "object", "properties" : { - "group" : { - "format" : "pve-configid", - "optional" : 1, - "type" : "string", - "description" : "The HA group identifier." - }, - "max_restart" : { - "minimum" : 0, + "comment" : { + "description" : "Description.", + "maxLength" : 4096, "optional" : 1, - "type" : "integer", - "default" : 1, - "description" : "Maximal number of tries to restart the service on a node after its start failed." + "type" : "string" }, "delete" : { "description" : "A list of settings you want to delete.", - "optional" : 1, - "type" : "string", "format" : "pve-configid-list", - "maxLength" : 4096 + "maxLength" : 4096, + "optional" : 1, + "type" : "string" }, - "sid" : { - "description" : "HA resource ID. This consists of a resource type followed by a resource specific name, separated with colon (example: vm:100 / ct:100). For virtual machines and containers, you can simply use the VM or CT id as a shortcut (example: 100).", - "type" : "string", - "format" : "pve-ha-resource-or-vm-id", - "typetext" : ":" + "digest" : { + "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", + "maxLength" : 40, + "optional" : 1, + "type" : "string" }, - "comment" : { - "description" : "Description.", + "group" : { + "description" : "The HA group identifier.", + "format" : "pve-configid", "optional" : 1, - "type" : "string", - "maxLength" : 4096 + "type" : "string" }, "max_relocate" : { - "optional" : 1, - "type" : "integer", "default" : 1, "description" : "Maximal number of service relocate tries when a service failes to start.", - "minimum" : 0 + "minimum" : 0, + "optional" : 1, + "type" : "integer" }, - "digest" : { - "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", - "type" : "string", + "max_restart" : { + "default" : 1, + "description" : "Maximal number of tries to restart the service on a node after its start failed.", + "minimum" : 0, "optional" : 1, - "maxLength" : 40 + "type" : "integer" + }, + "sid" : { + "description" : "HA resource ID. This consists of a resource type followed by a resource specific name, separated with colon (example: vm:100 / ct:100). For virtual machines and containers, you can simply use the VM or CT id as a shortcut (example: 100).", + "format" : "pve-ha-resource-or-vm-id", + "type" : "string", + "typetext" : ":" }, "state" : { + "default" : "enabled", + "description" : "Resource state.", "enum" : [ "enabled", "disabled" ], - "description" : "Resource state.", - "type" : "string", "optional" : 1, - "default" : "enabled" + "type" : "string" } - } + }, + "type" : "object" }, - "name" : "update", "permissions" : { "check" : [ "perm", @@ -2564,55 +2436,36 @@ var pveapi = [ ] ] }, - "description" : "Update resource configuration.", - "protected" : 1 - }, - "DELETE" : { "protected" : 1, - "description" : "Delete resource configuration.", - "name" : "delete", - "permissions" : { - "check" : [ - "perm", - "/", - [ - "Sys.Console" - ] - ] - }, - "parameters" : { - "properties" : { - "sid" : { - "description" : "HA resource ID. This consists of a resource type followed by a resource specific name, separated with colon (example: vm:100 / ct:100). For virtual machines and containers, you can simply use the VM or CT id as a shortcut (example: 100).", - "type" : "string", - "format" : "pve-ha-resource-or-vm-id", - "typetext" : ":" - } - }, - "additionalProperties" : 0 - }, - "method" : "DELETE", "returns" : { "type" : "null" } } }, + "leaf" : 0, "path" : "/cluster/ha/resources/{sid}", - "leaf" : 0 + "text" : "{sid}" } ], - "leaf" : 0, - "path" : "/cluster/ha/resources" - }, - { - "leaf" : 0, - "path" : "/cluster/ha/groups", "info" : { "GET" : { + "description" : "List HA resources.", + "method" : "GET", + "name" : "index", "parameters" : { - "additionalProperties" : 0 + "additionalProperties" : 0, + "properties" : { + "type" : { + "description" : "Only list resources of specific type", + "enum" : [ + "ct", + "vm" + ], + "optional" : 1, + "type" : "string" + } + } }, - "name" : "index", "permissions" : { "check" : [ "perm", @@ -2622,76 +2475,84 @@ var pveapi = [ ] ] }, - "description" : "Get HA groups.", - "method" : "GET", "returns" : { - "type" : "array", "items" : { - "type" : "object", "properties" : { - "group" : { + "sid" : { "type" : "string" } - } + }, + "type" : "object" }, "links" : [ { - "href" : "{group}", + "href" : "{sid}", "rel" : "child" } - ] + ], + "type" : "array" } }, "POST" : { + "description" : "Create a new HA resource.", "method" : "POST", - "returns" : { - "type" : "null" - }, - "description" : "Create a new HA group.", - "protected" : 1, + "name" : "create", "parameters" : { + "additionalProperties" : 0, "properties" : { "comment" : { - "maxLength" : 4096, "description" : "Description.", + "maxLength" : 4096, "optional" : 1, "type" : "string" }, - "restricted" : { - "description" : "Services on unrestricted groups may run on any cluster members if all group members are offline. But they will migrate back as soon as a group member comes online. One can implement a 'preferred node' behavior using an unrestricted group with one member.", + "group" : { + "description" : "The HA group identifier.", + "format" : "pve-configid", "optional" : 1, - "type" : "boolean", - "default" : 0 + "type" : "string" }, - "nofailback" : { - "type" : "boolean", + "max_relocate" : { + "default" : 1, + "description" : "Maximal number of service relocate tries when a service failes to start.", + "minimum" : 0, "optional" : 1, - "default" : 0, - "description" : "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." + "type" : "integer" }, - "type" : { + "max_restart" : { + "default" : 1, + "description" : "Maximal number of tries to restart the service on a node after its start failed.", + "minimum" : 0, + "optional" : 1, + "type" : "integer" + }, + "sid" : { + "description" : "HA resource ID. This consists of a resource type followed by a resource specific name, separated with colon (example: vm:100 / ct:100). For virtual machines and containers, you can simply use the VM or CT id as a shortcut (example: 100).", + "format" : "pve-ha-resource-or-vm-id", + "type" : "string", + "typetext" : ":" + }, + "state" : { + "default" : "enabled", + "description" : "Resource state.", "enum" : [ - "group" + "enabled", + "disabled" ], - "description" : "Group type.", "optional" : 1, "type" : "string" }, - "nodes" : { - "description" : "List of cluster node names with optional priority. We use priority '0' as default. The CRM tries to run services on the node with highest priority (also see option 'nofailback').", - "type" : "string", - "optional" : 0, - "format" : "pve-ha-group-node-list", - "typetext" : "[:]{,[:]}*" - }, - "group" : { - "format" : "pve-configid", - "type" : "string", - "description" : "The HA group identifier." - } + "type" : { + "description" : "Resource type.", + "enum" : [ + "ct", + "vm" + ], + "optional" : 1, + "type" : "string" + } }, - "type" : "object", - "additionalProperties" : 0 + "type" : "object" }, "permissions" : { "check" : [ @@ -2702,66 +2563,34 @@ var pveapi = [ ] ] }, - "name" : "create" + "protected" : 1, + "returns" : { + "type" : "null" + } } }, - "text" : "groups", + "leaf" : 0, + "path" : "/cluster/ha/resources", + "text" : "resources" + }, + { "children" : [ { "info" : { - "PUT" : { - "protected" : 1, - "description" : "Update ha group configuration.", + "DELETE" : { + "description" : "Delete ha group configuration.", + "method" : "DELETE", + "name" : "delete", "parameters" : { - "type" : "object", "additionalProperties" : 0, "properties" : { - "nodes" : { - "format" : "pve-ha-group-node-list", - "typetext" : "[:]{,[:]}*", - "description" : "List of cluster node names with optional priority. We use priority '0' as default. The CRM tries to run services on the node with highest priority (also see option 'nofailback').", - "optional" : 1, - "type" : "string" - }, - "digest" : { - "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", - "type" : "string", - "optional" : 1, - "maxLength" : 40 - }, "group" : { "description" : "The HA group identifier.", - "type" : "string", - "format" : "pve-configid" - }, - "comment" : { - "maxLength" : 4096, - "type" : "string", - "optional" : 1, - "description" : "Description." - }, - "nofailback" : { - "default" : 0, - "optional" : 1, - "type" : "boolean", - "description" : "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." - }, - "restricted" : { - "description" : "Services on unrestricted groups may run on any cluster members if all group members are offline. But they will migrate back as soon as a group member comes online. One can implement a 'preferred node' behavior using an unrestricted group with one member.", - "default" : 0, - "type" : "boolean", - "optional" : 1 - }, - "delete" : { - "format" : "pve-configid-list", - "maxLength" : 4096, - "optional" : 1, - "type" : "string", - "description" : "A list of settings you want to delete." + "format" : "pve-configid", + "type" : "string" } } }, - "name" : "update", "permissions" : { "check" : [ "perm", @@ -2771,83 +2600,222 @@ var pveapi = [ ] ] }, - "method" : "PUT", + "protected" : 1, "returns" : { "type" : "null" } }, - "DELETE" : { - "method" : "DELETE", - "returns" : { - "type" : "null" - }, - "name" : "delete", + "GET" : { + "description" : "Read ha group configuration.", + "method" : "GET", + "name" : "read", "parameters" : { + "additionalProperties" : 0, "properties" : { "group" : { "description" : "The HA group identifier.", - "type" : "string", - "format" : "pve-configid" + "format" : "pve-configid", + "type" : "string" } - }, - "additionalProperties" : 0 + } }, "permissions" : { "check" : [ "perm", "/", [ - "Sys.Console" + "Sys.Audit" ] ] }, - "description" : "Delete ha group configuration.", - "protected" : 1 + "returns" : {} }, - "GET" : { + "PUT" : { + "description" : "Update ha group configuration.", + "method" : "PUT", + "name" : "update", "parameters" : { + "additionalProperties" : 0, "properties" : { + "comment" : { + "description" : "Description.", + "maxLength" : 4096, + "optional" : 1, + "type" : "string" + }, + "delete" : { + "description" : "A list of settings you want to delete.", + "format" : "pve-configid-list", + "maxLength" : 4096, + "optional" : 1, + "type" : "string" + }, + "digest" : { + "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", + "maxLength" : 40, + "optional" : 1, + "type" : "string" + }, "group" : { "description" : "The HA group identifier.", + "format" : "pve-configid", + "type" : "string" + }, + "nodes" : { + "description" : "List of cluster node names with optional priority. We use priority '0' as default. The CRM tries to run services on the node with highest priority (also see option 'nofailback').", + "format" : "pve-ha-group-node-list", + "optional" : 1, "type" : "string", - "format" : "pve-configid" + "typetext" : "[:]{,[:]}*" + }, + "nofailback" : { + "default" : 0, + "description" : "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.", + "optional" : 1, + "type" : "boolean" + }, + "restricted" : { + "default" : 0, + "description" : "Services on unrestricted groups may run on any cluster members if all group members are offline. But they will migrate back as soon as a group member comes online. One can implement a 'preferred node' behavior using an unrestricted group with one member.", + "optional" : 1, + "type" : "boolean" } }, - "additionalProperties" : 0 + "type" : "object" }, - "name" : "read", "permissions" : { "check" : [ "perm", "/", [ - "Sys.Audit" + "Sys.Console" ] ] }, - "description" : "Read ha group configuration.", - "returns" : {}, - "method" : "GET" + "protected" : 1, + "returns" : { + "type" : "null" + } } }, - "text" : "{group}", "leaf" : 1, - "path" : "/cluster/ha/groups/{group}" + "path" : "/cluster/ha/groups/{group}", + "text" : "{group}" } - ] + ], + "info" : { + "GET" : { + "description" : "Get HA groups.", + "method" : "GET", + "name" : "index", + "parameters" : { + "additionalProperties" : 0 + }, + "permissions" : { + "check" : [ + "perm", + "/", + [ + "Sys.Audit" + ] + ] + }, + "returns" : { + "items" : { + "properties" : { + "group" : { + "type" : "string" + } + }, + "type" : "object" + }, + "links" : [ + { + "href" : "{group}", + "rel" : "child" + } + ], + "type" : "array" + } + }, + "POST" : { + "description" : "Create a new HA group.", + "method" : "POST", + "name" : "create", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "comment" : { + "description" : "Description.", + "maxLength" : 4096, + "optional" : 1, + "type" : "string" + }, + "group" : { + "description" : "The HA group identifier.", + "format" : "pve-configid", + "type" : "string" + }, + "nodes" : { + "description" : "List of cluster node names with optional priority. We use priority '0' as default. The CRM tries to run services on the node with highest priority (also see option 'nofailback').", + "format" : "pve-ha-group-node-list", + "optional" : 0, + "type" : "string", + "typetext" : "[:]{,[:]}*" + }, + "nofailback" : { + "default" : 0, + "description" : "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.", + "optional" : 1, + "type" : "boolean" + }, + "restricted" : { + "default" : 0, + "description" : "Services on unrestricted groups may run on any cluster members if all group members are offline. But they will migrate back as soon as a group member comes online. One can implement a 'preferred node' behavior using an unrestricted group with one member.", + "optional" : 1, + "type" : "boolean" + }, + "type" : { + "description" : "Group type.", + "enum" : [ + "group" + ], + "optional" : 1, + "type" : "string" + } + }, + "type" : "object" + }, + "permissions" : { + "check" : [ + "perm", + "/", + [ + "Sys.Console" + ] + ] + }, + "protected" : 1, + "returns" : { + "type" : "null" + } + } + }, + "leaf" : 0, + "path" : "/cluster/ha/groups", + "text" : "groups" }, { - "text" : "status", "children" : [ { "info" : { "GET" : { - "returns" : { - "type" : "array" - }, - "method" : "GET", "description" : "Get HA manger status.", + "method" : "GET", "name" : "status", + "parameters" : { + "additionalProperties" : 0 + }, "permissions" : { "check" : [ "perm", @@ -2857,27 +2825,24 @@ var pveapi = [ ] ] }, - "parameters" : { - "additionalProperties" : 0 + "returns" : { + "type" : "array" } } }, - "text" : "current", "leaf" : 1, - "path" : "/cluster/ha/status/current" + "path" : "/cluster/ha/status/current", + "text" : "current" }, { "info" : { "GET" : { - "method" : "GET", - "returns" : { - "type" : "object" - }, "description" : "Get full HA manger status, including LRM status.", + "method" : "GET", + "name" : "manager_status", "parameters" : { "additionalProperties" : 0 }, - "name" : "manager_status", "permissions" : { "check" : [ "perm", @@ -2886,17 +2851,28 @@ var pveapi = [ "Sys.Audit" ] ] + }, + "returns" : { + "type" : "object" } } }, - "text" : "manager_status", "leaf" : 1, - "path" : "/cluster/ha/status/manager_status" + "path" : "/cluster/ha/status/manager_status", + "text" : "manager_status" } ], "info" : { "GET" : { + "description" : "Directory index.", "method" : "GET", + "name" : "index", + "parameters" : { + "additionalProperties" : 0 + }, + "permissions" : { + "user" : "all" + }, "returns" : { "items" : { "properties" : {}, @@ -2904,29 +2880,27 @@ var pveapi = [ }, "links" : [ { - "rel" : "child", - "href" : "{name}" + "href" : "{name}", + "rel" : "child" } ], "type" : "array" - }, - "description" : "Directory index.", - "permissions" : { - "user" : "all" - }, - "parameters" : { - "additionalProperties" : 0 - }, - "name" : "index" + } } }, + "leaf" : 0, "path" : "/cluster/ha/status", - "leaf" : 0 + "text" : "status" } ], "info" : { "GET" : { "description" : "Directory index.", + "method" : "GET", + "name" : "index", + "parameters" : { + "additionalProperties" : 0 + }, "permissions" : { "check" : [ "perm", @@ -2936,134 +2910,133 @@ var pveapi = [ ] ] }, - "name" : "index", - "parameters" : { - "additionalProperties" : 0 - }, - "method" : "GET", "returns" : { - "type" : "array", "items" : { - "type" : "object", "properties" : { "id" : { "type" : "string" } - } + }, + "type" : "object" }, "links" : [ { "href" : "{id}", "rel" : "child" } - ] + ], + "type" : "array" } } - } + }, + "leaf" : 0, + "path" : "/cluster/ha", + "text" : "ha" }, { - "path" : "/cluster/log", - "leaf" : 1, - "text" : "log", "info" : { "GET" : { "description" : "Read cluster log", - "permissions" : { - "user" : "all" - }, + "method" : "GET", + "name" : "log", "parameters" : { "additionalProperties" : 0, "properties" : { "max" : { - "type" : "integer", - "optional" : 1, "description" : "Maximum number of entries.", - "minimum" : 1 + "minimum" : 1, + "optional" : 1, + "type" : "integer" } } }, - "name" : "log", - "method" : "GET", + "permissions" : { + "user" : "all" + }, "returns" : { - "type" : "array", "items" : { - "type" : "object", - "properties" : {} - } + "properties" : {}, + "type" : "object" + }, + "type" : "array" } } - } + }, + "leaf" : 1, + "path" : "/cluster/log", + "text" : "log" }, { "info" : { "GET" : { + "description" : "Resources index (cluster wide).", "method" : "GET", - "returns" : { - "items" : { - "properties" : {}, - "type" : "object" - }, - "type" : "array" - }, "name" : "resources", - "permissions" : { - "user" : "all" - }, "parameters" : { "additionalProperties" : 0, "properties" : { "type" : { - "optional" : 1, - "type" : "string", "enum" : [ "vm", "storage", "node" - ] + ], + "optional" : 1, + "type" : "string" } } }, - "description" : "Resources index (cluster wide)." + "permissions" : { + "user" : "all" + }, + "returns" : { + "items" : { + "properties" : {}, + "type" : "object" + }, + "type" : "array" + } } }, - "text" : "resources", "leaf" : 1, - "path" : "/cluster/resources" + "path" : "/cluster/resources", + "text" : "resources" }, { "info" : { "GET" : { "description" : "List recent tasks (cluster wide).", - "permissions" : { - "user" : "all" - }, + "method" : "GET", "name" : "tasks", "parameters" : { "additionalProperties" : 0 }, - "method" : "GET", + "permissions" : { + "user" : "all" + }, "returns" : { - "type" : "array", "items" : { - "type" : "object", "properties" : { "upid" : { "type" : "string" } - } - } + }, + "type" : "object" + }, + "type" : "array" } } }, - "text" : "tasks", "leaf" : 1, - "path" : "/cluster/tasks" + "path" : "/cluster/tasks", + "text" : "tasks" }, { - "leaf" : 1, - "path" : "/cluster/options", "info" : { "GET" : { + "description" : "Get datacenter options.", + "method" : "GET", + "name" : "get_options", "parameters" : { "additionalProperties" : 0 }, @@ -3076,139 +3049,139 @@ var pveapi = [ ] ] }, - "name" : "get_options", - "description" : "Get datacenter options.", - "method" : "GET", "returns" : { - "type" : "object", - "properties" : {} + "properties" : {}, + "type" : "object" } }, "PUT" : { - "permissions" : { - "check" : [ - "perm", - "/", - [ - "Sys.Modify" - ] - ] - }, + "description" : "Set datacenter options.", + "method" : "PUT", "name" : "set_options", "parameters" : { "additionalProperties" : 0, "properties" : { - "fencing" : { - "default" : "watchdog", - "type" : "string", - "optional" : 1, - "description" : "Set the fencing mode of the HA cluster. Hardware mode needs a valid configuration of fence devices in /etc/pve/ha/fence.cfg. With both all two modes are used.\n\nWARNING: 'hardware' and 'both' are EXPERIMENTAL & WIP", - "enum" : [ - "watchdog", - "hardware", - "both" - ] - }, "console" : { - "optional" : 1, - "type" : "string", "description" : "Select the default Console viewer. You can either use the builtin java applet (VNC), an external virt-viewer comtatible application (SPICE), or an HTML5 based viewer (noVNC).", "enum" : [ "applet", "vv", "html5" - ] + ], + "optional" : 1, + "type" : "string" }, "delete" : { - "format" : "pve-configid-list", "description" : "A list of settings you want to delete.", + "format" : "pve-configid-list", "optional" : 1, "type" : "string" }, - "max_workers" : { - "minimum" : 1, - "description" : "Defines how many workers (per node) are maximal started on actions like 'stopall VMs' or task from the ha-manager.", - "type" : "integer", - "optional" : 1 - }, - "language" : { - "type" : "string", + "email_from" : { + "description" : "Specify email address to send notification from (default is root@$hostname)", + "format" : "email-opt", "optional" : 1, + "type" : "string" + }, + "fencing" : { + "default" : "watchdog", + "description" : "Set the fencing mode of the HA cluster. Hardware mode needs a valid configuration of fence devices in /etc/pve/ha/fence.cfg. With both all two modes are used.\n\nWARNING: 'hardware' and 'both' are EXPERIMENTAL & WIP", "enum" : [ - "en", - "de" + "watchdog", + "hardware", + "both" ], - "description" : "Default GUI language." + "optional" : 1, + "type" : "string" + }, + "http_proxy" : { + "description" : "Specify external http proxy which is used for downloads (example: 'http://username:password@host:port/')", + "optional" : 1, + "pattern" : "http://.*", + "type" : "string" }, "keyboard" : { + "description" : "Default keybord layout for vnc server.", "enum" : [ + "de", + "de-ch", "da", - "sv", "en-gb", - "lt", + "en-us", + "es", + "fi", + "fr", + "fr-be", + "fr-ca", + "fr-ch", + "hu", "is", + "it", + "ja", + "lt", "mk", - "pl", - "hu", - "fr-be", - "pt-br", - "de-ch", "nl", "no", - "tr", - "sl", - "de", - "fr-ca", - "ja", - "es", - "it", + "pl", "pt", - "fr", - "en-us", - "fi", - "fr-ch" + "pt-br", + "sv", + "sl", + "tr" ], - "description" : "Default keybord layout for vnc server.", "optional" : 1, "type" : "string" }, - "http_proxy" : { + "language" : { + "description" : "Default GUI language.", + "enum" : [ + "en", + "de" + ], "optional" : 1, - "type" : "string", - "pattern" : "http://.*", - "description" : "Specify external http proxy which is used for downloads (example: 'http://username:password@host:port/')" + "type" : "string" }, - "email_from" : { - "format" : "email-opt", + "max_workers" : { + "description" : "Defines how many workers (per node) are maximal started on actions like 'stopall VMs' or task from the ha-manager.", + "minimum" : 1, "optional" : 1, - "type" : "string", - "description" : "Specify email address to send notification from (default is root@$hostname)" + "type" : "integer" }, "migration_unsecure" : { - "type" : "boolean", + "description" : "Migration is secure using SSH tunnel by default. For secure private networks you can disable it to speed up migration.", "optional" : 1, - "description" : "Migration is secure using SSH tunnel by default. For secure private networks you can disable it to speed up migration." + "type" : "boolean" } } }, + "permissions" : { + "check" : [ + "perm", + "/", + [ + "Sys.Modify" + ] + ] + }, "protected" : 1, - "description" : "Set datacenter options.", "returns" : { "type" : "null" - }, - "method" : "PUT" + } } }, + "leaf" : 1, + "path" : "/cluster/options", "text" : "options" }, { - "text" : "status", "info" : { "GET" : { + "description" : "Get cluster status informations.", + "method" : "GET", + "name" : "get_status", "parameters" : { "additionalProperties" : 0 }, - "name" : "get_status", "permissions" : { "check" : [ "perm", @@ -3218,151 +3191,131 @@ var pveapi = [ ] ] }, - "description" : "Get cluster status informations.", "protected" : 1, - "method" : "GET", "returns" : { "items" : { - "type" : "object", "properties" : { "type" : { "type" : "string" } - } + }, + "type" : "object" }, "type" : "array" } } }, + "leaf" : 1, "path" : "/cluster/status", - "leaf" : 1 + "text" : "status" }, { "info" : { "GET" : { - "method" : "GET", - "returns" : { - "type" : "integer", - "description" : "The next free VMID." - }, "description" : "Get next free VMID. If you pass an VMID it will raise an error if the ID is already used.", + "method" : "GET", + "name" : "nextid", "parameters" : { + "additionalProperties" : 0, "properties" : { "vmid" : { + "description" : "The (unique) ID of the VM.", "format" : "pve-vmid", "minimum" : 1, - "description" : "The (unique) ID of the VM.", "optional" : 1, "type" : "integer" } - }, - "additionalProperties" : 0 + } }, - "name" : "nextid", "permissions" : { "user" : "all" + }, + "returns" : { + "description" : "The next free VMID.", + "type" : "integer" } } }, - "text" : "nextid", "leaf" : 1, - "path" : "/cluster/nextid" + "path" : "/cluster/nextid", + "text" : "nextid" } ], + "info" : { + "GET" : { + "description" : "Cluster index.", + "method" : "GET", + "name" : "index", + "parameters" : { + "additionalProperties" : 0 + }, + "permissions" : { + "user" : "all" + }, + "returns" : { + "items" : { + "properties" : {}, + "type" : "object" + }, + "links" : [ + { + "href" : "{name}", + "rel" : "child" + } + ], + "type" : "array" + } + } + }, + "leaf" : 0, + "path" : "/cluster", "text" : "cluster" }, { - "path" : "/nodes", - "leaf" : 0, - "text" : "nodes", "children" : [ { - "info" : { - "GET" : { - "returns" : { - "links" : [ - { - "rel" : "child", - "href" : "{name}" - } - ], - "items" : { - "type" : "object", - "properties" : {} - }, - "type" : "array" - }, - "method" : "GET", - "description" : "Node index.", - "parameters" : { - "additionalProperties" : 0, - "properties" : { - "node" : { - "format" : "pve-node", - "description" : "The cluster node name.", - "type" : "string" - } - } - }, - "permissions" : { - "user" : "all" - }, - "name" : "index" - } - }, "children" : [ { "children" : [ { - "path" : "/nodes/{node}/qemu/{vmid}", - "leaf" : 0, - "text" : "{vmid}", "children" : [ { - "path" : "/nodes/{node}/qemu/{vmid}/firewall", - "leaf" : 0, - "text" : "firewall", "children" : [ { - "text" : "rules", "children" : [ { - "text" : "{pos}", "info" : { "DELETE" : { + "description" : "Delete rule.", "method" : "DELETE", + "name" : "delete_rule", "parameters" : { + "additionalProperties" : 0, "properties" : { + "digest" : { + "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", + "maxLength" : 40, + "optional" : 1, + "type" : "string" + }, "node" : { - "type" : "string", "description" : "The cluster node name.", - "format" : "pve-node" - }, - "vmid" : { - "minimum" : 1, - "format" : "pve-vmid", - "description" : "The (unique) ID of the VM.", - "type" : "integer" + "format" : "pve-node", + "type" : "string" }, "pos" : { - "type" : "integer", - "optional" : 1, "description" : "Update rule at position .", - "minimum" : 0 - }, - "digest" : { + "minimum" : 0, "optional" : 1, - "type" : "string", - "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", - "maxLength" : 40 + "type" : "integer" + }, + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" } - }, - "additionalProperties" : 0 - }, - "name" : "delete_rule", - "protected" : 1, - "returns" : { - "type" : "null" + } }, "permissions" : { "check" : [ @@ -3373,321 +3326,338 @@ var pveapi = [ ] ] }, - "description" : "Delete rule.", - "proxyto" : null - }, - "PUT" : { + "protected" : 1, + "proxyto" : null, "returns" : { "type" : "null" + } + }, + "GET" : { + "description" : "Get single rule data.", + "method" : "GET", + "name" : "get_rule", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, + "pos" : { + "description" : "Update rule at position .", + "minimum" : 0, + "optional" : 1, + "type" : "integer" + }, + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" + } + } }, "permissions" : { "check" : [ "perm", "/vms/{vmid}", [ - "VM.Config.Network" + "VM.Audit" ] ] }, "proxyto" : null, + "returns" : { + "properties" : { + "pos" : { + "type" : "integer" + } + }, + "type" : "object" + } + }, + "PUT" : { "description" : "Modify rule data.", "method" : "PUT", + "name" : "update_rule", "parameters" : { + "additionalProperties" : 0, "properties" : { - "dport" : { - "format" : "pve-fw-dport-spec", - "description" : "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.", + "action" : { + "description" : "Rule action ('ACCEPT', 'DROP', 'REJECT') or security group name.", + "maxLength" : 20, + "minLength" : 2, "optional" : 1, + "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", "type" : "string" }, - "type" : { - "enum" : [ - "in", - "out", - "group" - ], - "type" : "string", - "optional" : 1 - }, - "node" : { - "format" : "pve-node", - "type" : "string", - "description" : "The cluster node name." - }, - "moveto" : { - "minimum" : 0, - "type" : "integer", - "optional" : 1, - "description" : "Move rule to new position . Other arguments are ignored." - }, "comment" : { "optional" : 1, "type" : "string" }, "delete" : { - "format" : "pve-configid-list", "description" : "A list of settings you want to delete.", - "type" : "string", - "optional" : 1 + "format" : "pve-configid-list", + "optional" : 1, + "type" : "string" }, "dest" : { + "description" : "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.", "format" : "pve-fw-addr-spec", "optional" : 1, - "type" : "string", - "description" : "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." - }, - "source" : { - "description" : "Restrict packet source 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.", - "type" : "string", - "optional" : 1, - "format" : "pve-fw-addr-spec" + "type" : "string" }, "digest" : { + "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", "maxLength" : 40, - "type" : "string", "optional" : 1, - "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications." + "type" : "string" + }, + "dport" : { + "description" : "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.", + "format" : "pve-fw-dport-spec", + "optional" : 1, + "type" : "string" }, "enable" : { + "minimum" : 0, "optional" : 1, - "type" : "integer", - "minimum" : 0 + "type" : "integer" }, - "action" : { - "description" : "Rule action ('ACCEPT', 'DROP', 'REJECT') or security group name.", - "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", + "iface" : { + "description" : "Network interface name. You have to use network configuration key names for VMs and containers ('net\\d+'). Host related rules can use arbitrary strings.", + "format" : "pve-iface", + "maxLength" : 20, "minLength" : 2, "optional" : 1, - "type" : "string", - "maxLength" : 20 + "type" : "string" }, - "pos" : { - "type" : "integer", + "macro" : { + "maxLength" : 128, "optional" : 1, - "description" : "Update rule at position .", - "minimum" : 0 + "type" : "string" }, - "proto" : { - "description" : "IP protocol. You can use protocol names ('tcp'/'udp') or simple numbers, as defined in '/etc/protocols'.", - "type" : "string", + "moveto" : { + "description" : "Move rule to new position . Other arguments are ignored.", + "minimum" : 0, "optional" : 1, - "format" : "pve-fw-protocol-spec" + "type" : "integer" }, - "vmid" : { - "format" : "pve-vmid", - "minimum" : 1, - "description" : "The (unique) ID of the VM.", + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, + "pos" : { + "description" : "Update rule at position .", + "minimum" : 0, + "optional" : 1, "type" : "integer" }, - "macro" : { - "maxLength" : 128, - "type" : "string", - "optional" : 1 + "proto" : { + "description" : "IP protocol. You can use protocol names ('tcp'/'udp') or simple numbers, as defined in '/etc/protocols'.", + "format" : "pve-fw-protocol-spec", + "optional" : 1, + "type" : "string" }, - "iface" : { - "format" : "pve-iface", - "maxLength" : 20, - "description" : "Network interface name. You have to use network configuration key names for VMs and containers ('net\\d+'). Host related rules can use arbitrary strings.", - "minLength" : 2, + "source" : { + "description" : "Restrict packet source 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.", + "format" : "pve-fw-addr-spec", "optional" : 1, "type" : "string" }, "sport" : { - "format" : "pve-fw-sport-spec", "description" : "Restrict TCP/UDP source 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.", + "format" : "pve-fw-sport-spec", + "optional" : 1, + "type" : "string" + }, + "type" : { + "enum" : [ + "in", + "out", + "group" + ], "optional" : 1, "type" : "string" + }, + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" } - }, - "additionalProperties" : 0 + } }, - "name" : "update_rule", - "protected" : 1 - }, - "GET" : { "permissions" : { "check" : [ "perm", "/vms/{vmid}", [ - "VM.Audit" + "VM.Config.Network" ] ] }, - "name" : "get_rule", - "parameters" : { - "properties" : { - "node" : { - "type" : "string", - "description" : "The cluster node name.", - "format" : "pve-node" - }, - "pos" : { - "minimum" : 0, - "type" : "integer", - "optional" : 1, - "description" : "Update rule at position ." - }, - "vmid" : { - "format" : "pve-vmid", - "minimum" : 1, - "type" : "integer", - "description" : "The (unique) ID of the VM." - } - }, - "additionalProperties" : 0 - }, + "protected" : 1, "proxyto" : null, - "description" : "Get single rule data.", "returns" : { - "type" : "object", - "properties" : { - "pos" : { - "type" : "integer" - } - } - }, - "method" : "GET" + "type" : "null" + } } }, + "leaf" : 1, "path" : "/nodes/{node}/qemu/{vmid}/firewall/rules/{pos}", - "leaf" : 1 + "text" : "{pos}" } ], "info" : { - "POST" : { - "returns" : { - "type" : "null" + "GET" : { + "description" : "List rules.", + "method" : "GET", + "name" : "get_rules", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" + } + } }, - "description" : "Create new rule.", - "proxyto" : null, "permissions" : { "check" : [ "perm", "/vms/{vmid}", [ - "VM.Config.Network" + "VM.Audit" ] ] }, + "proxyto" : null, + "returns" : { + "items" : { + "properties" : { + "pos" : { + "type" : "integer" + } + }, + "type" : "object" + }, + "links" : [ + { + "href" : "{pos}", + "rel" : "child" + } + ], + "type" : "array" + } + }, + "POST" : { + "description" : "Create new rule.", "method" : "POST", - "protected" : 1, + "name" : "create_rule", "parameters" : { + "additionalProperties" : 0, "properties" : { - "pos" : { - "optional" : 1, - "type" : "integer", - "description" : "Update rule at position .", - "minimum" : 0 + "action" : { + "description" : "Rule action ('ACCEPT', 'DROP', 'REJECT') or security group name.", + "maxLength" : 20, + "minLength" : 2, + "optional" : 0, + "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", + "type" : "string" }, - "proto" : { - "format" : "pve-fw-protocol-spec", - "description" : "IP protocol. You can use protocol names ('tcp'/'udp') or simple numbers, as defined in '/etc/protocols'.", + "comment" : { "optional" : 1, "type" : "string" }, - "vmid" : { - "description" : "The (unique) ID of the VM.", - "type" : "integer", - "format" : "pve-vmid", - "minimum" : 1 + "dest" : { + "description" : "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.", + "format" : "pve-fw-addr-spec", + "optional" : 1, + "type" : "string" }, - "macro" : { + "digest" : { + "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", + "maxLength" : 40, "optional" : 1, - "type" : "string", - "maxLength" : 128 + "type" : "string" }, "dport" : { "description" : "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.", - "type" : "string", + "format" : "pve-fw-dport-spec", "optional" : 1, - "format" : "pve-fw-dport-spec" - }, - "type" : { - "optional" : 0, - "type" : "string", - "enum" : [ - "in", - "out", - "group" - ] + "type" : "string" }, "enable" : { "minimum" : 0, - "type" : "integer", - "optional" : 1 + "optional" : 1, + "type" : "integer" }, - "action" : { - "optional" : 0, - "type" : "string", + "iface" : { + "description" : "Network interface name. You have to use network configuration key names for VMs and containers ('net\\d+'). Host related rules can use arbitrary strings.", + "format" : "pve-iface", + "maxLength" : 20, "minLength" : 2, - "description" : "Rule action ('ACCEPT', 'DROP', 'REJECT') or security group name.", - "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", - "maxLength" : 20 + "optional" : 1, + "type" : "string" }, - "sport" : { - "type" : "string", + "macro" : { + "maxLength" : 128, "optional" : 1, - "description" : "Restrict TCP/UDP source 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.", - "format" : "pve-fw-sport-spec" + "type" : "string" }, - "dest" : { - "format" : "pve-fw-addr-spec", - "description" : "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.", + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, + "pos" : { + "description" : "Update rule at position .", + "minimum" : 0, + "optional" : 1, + "type" : "integer" + }, + "proto" : { + "description" : "IP protocol. You can use protocol names ('tcp'/'udp') or simple numbers, as defined in '/etc/protocols'.", + "format" : "pve-fw-protocol-spec", "optional" : 1, "type" : "string" }, "source" : { "description" : "Restrict packet source 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.", + "format" : "pve-fw-addr-spec", "optional" : 1, - "type" : "string", - "format" : "pve-fw-addr-spec" + "type" : "string" }, - "digest" : { - "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", + "sport" : { + "description" : "Restrict TCP/UDP source 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.", + "format" : "pve-fw-sport-spec", "optional" : 1, - "type" : "string", - "maxLength" : 40 - }, - "node" : { - "type" : "string", - "description" : "The cluster node name.", - "format" : "pve-node" + "type" : "string" }, - "comment" : { - "type" : "string", - "optional" : 1 + "type" : { + "enum" : [ + "in", + "out", + "group" + ], + "optional" : 0, + "type" : "string" }, - "iface" : { - "optional" : 1, - "type" : "string", - "description" : "Network interface name. You have to use network configuration key names for VMs and containers ('net\\d+'). Host related rules can use arbitrary strings.", - "minLength" : 2, - "format" : "pve-iface", - "maxLength" : 20 - } - }, - "additionalProperties" : 0 - }, - "name" : "create_rule" - }, - "GET" : { - "description" : "List rules.", - "proxyto" : null, - "name" : "get_rules", - "parameters" : { - "additionalProperties" : 0, - "properties" : { "vmid" : { + "description" : "The (unique) ID of the VM.", "format" : "pve-vmid", "minimum" : 1, - "description" : "The (unique) ID of the VM.", "type" : "integer" - }, - "node" : { - "description" : "The cluster node name.", - "type" : "string", - "format" : "pve-node" } } }, @@ -3696,81 +3666,58 @@ var pveapi = [ "perm", "/vms/{vmid}", [ - "VM.Audit" + "VM.Config.Network" ] ] }, + "protected" : 1, + "proxyto" : null, "returns" : { - "type" : "array", - "links" : [ - { - "href" : "{pos}", - "rel" : "child" - } - ], - "items" : { - "properties" : { - "pos" : { - "type" : "integer" - } - }, - "type" : "object" - } - }, - "method" : "GET" + "type" : "null" + } } }, + "leaf" : 0, "path" : "/nodes/{node}/qemu/{vmid}/firewall/rules", - "leaf" : 0 + "text" : "rules" }, { - "path" : "/nodes/{node}/qemu/{vmid}/firewall/aliases", - "leaf" : 0, "children" : [ { - "text" : "{name}", "info" : { - "GET" : { - "method" : "GET", - "returns" : { - "type" : "object" - }, - "description" : "Read alias.", + "DELETE" : { + "description" : "Remove IP or Network alias.", + "method" : "DELETE", + "name" : "remove_alias", "parameters" : { + "additionalProperties" : 0, "properties" : { - "vmid" : { - "type" : "integer", - "description" : "The (unique) ID of the VM.", - "minimum" : 1, - "format" : "pve-vmid" + "digest" : { + "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", + "maxLength" : 40, + "optional" : 1, + "type" : "string" }, "name" : { - "maxLength" : 64, - "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", "description" : "Alias name.", + "maxLength" : 64, "minLength" : 2, + "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", "type" : "string" }, "node" : { + "description" : "The cluster node name.", "format" : "pve-node", - "type" : "string", - "description" : "The cluster node name." + "type" : "string" + }, + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" } - }, - "additionalProperties" : 0 + } }, - "name" : "read_alias", - "permissions" : { - "check" : [ - "perm", - "/vms/{vmid}", - [ - "VM.Audit" - ] - ] - } - }, - "PUT" : { "permissions" : { "check" : [ "perm", @@ -3780,88 +3727,98 @@ var pveapi = [ ] ] }, + "protected" : 1, + "returns" : { + "type" : "null" + } + }, + "GET" : { + "description" : "Read alias.", + "method" : "GET", + "name" : "read_alias", "parameters" : { + "additionalProperties" : 0, "properties" : { - "vmid" : { - "description" : "The (unique) ID of the VM.", - "type" : "integer", - "format" : "pve-vmid", - "minimum" : 1 - }, - "digest" : { - "maxLength" : 40, - "type" : "string", - "optional" : 1, - "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications." - }, - "cidr" : { - "description" : "Network/IP specification in CIDR format.", - "type" : "string", - "format" : "IPorCIDR" - }, - "comment" : { - "type" : "string", - "optional" : 1 - }, - "rename" : { - "maxLength" : 64, - "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", - "description" : "Rename an existing alias.", - "minLength" : 2, - "type" : "string", - "optional" : 1 - }, "name" : { - "maxLength" : 64, - "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", "description" : "Alias name.", + "maxLength" : 64, "minLength" : 2, + "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", "type" : "string" }, "node" : { "description" : "The cluster node name.", - "type" : "string", - "format" : "pve-node" + "format" : "pve-node", + "type" : "string" + }, + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" } - }, - "additionalProperties" : 0 + } }, - "name" : "update_alias", - "protected" : 1, - "description" : "Update IP or Network alias.", - "returns" : { - "type" : "null" + "permissions" : { + "check" : [ + "perm", + "/vms/{vmid}", + [ + "VM.Audit" + ] + ] }, - "method" : "PUT" + "returns" : { + "type" : "object" + } }, - "DELETE" : { - "name" : "remove_alias", + "PUT" : { + "description" : "Update IP or Network alias.", + "method" : "PUT", + "name" : "update_alias", "parameters" : { "additionalProperties" : 0, "properties" : { - "vmid" : { - "format" : "pve-vmid", - "minimum" : 1, - "description" : "The (unique) ID of the VM.", - "type" : "integer" + "cidr" : { + "description" : "Network/IP specification in CIDR format.", + "format" : "IPorCIDR", + "type" : "string" + }, + "comment" : { + "optional" : 1, + "type" : "string" }, "digest" : { + "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", "maxLength" : 40, "optional" : 1, - "type" : "string", - "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications." + "type" : "string" }, "name" : { + "description" : "Alias name.", "maxLength" : 64, - "type" : "string", "minLength" : 2, "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", - "description" : "Alias name." + "type" : "string" }, "node" : { - "type" : "string", "description" : "The cluster node name.", - "format" : "pve-node" + "format" : "pve-node", + "type" : "string" + }, + "rename" : { + "description" : "Rename an existing alias.", + "maxLength" : 64, + "minLength" : 2, + "optional" : 1, + "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", + "type" : "string" + }, + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" } } }, @@ -3875,347 +3832,176 @@ var pveapi = [ ] }, "protected" : 1, - "description" : "Remove IP or Network alias.", "returns" : { "type" : "null" - }, - "method" : "DELETE" + } } }, + "leaf" : 1, "path" : "/nodes/{node}/qemu/{vmid}/firewall/aliases/{name}", - "leaf" : 1 + "text" : "{name}" } ], - "text" : "aliases", "info" : { - "POST" : { - "description" : "Create IP or Network Alias.", - "protected" : 1, + "GET" : { + "description" : "List aliases", + "method" : "GET", + "name" : "get_aliases", "parameters" : { + "additionalProperties" : 0, "properties" : { - "vmid" : { - "description" : "The (unique) ID of the VM.", - "type" : "integer", - "format" : "pve-vmid", - "minimum" : 1 - }, - "cidr" : { - "format" : "IPorCIDR", - "description" : "Network/IP specification in CIDR format.", - "type" : "string" - }, "node" : { - "format" : "pve-node", "description" : "The cluster node name.", + "format" : "pve-node", "type" : "string" }, - "name" : { - "maxLength" : 64, - "type" : "string", - "minLength" : 2, - "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", - "description" : "Alias name." - }, - "comment" : { - "optional" : 1, - "type" : "string" + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" } - }, - "additionalProperties" : 0 + } }, - "name" : "create_alias", "permissions" : { "check" : [ "perm", "/vms/{vmid}", [ - "VM.Config.Network" + "VM.Audit" ] ] }, - "method" : "POST", - "returns" : { - "type" : "null" - } - }, - "GET" : { - "method" : "GET", "returns" : { - "type" : "array", "items" : { - "type" : "object", "properties" : { - "comment" : { - "optional" : 1, + "cidr" : { "type" : "string" }, - "name" : { + "comment" : { + "optional" : 1, "type" : "string" }, "digest" : { - "maxLength" : 40, "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", + "maxLength" : 40, "optional" : 0, "type" : "string" }, - "cidr" : { + "name" : { "type" : "string" } - } + }, + "type" : "object" }, "links" : [ { "href" : "{name}", "rel" : "child" } - ] - }, - "permissions" : { - "check" : [ - "perm", - "/vms/{vmid}", - [ - "VM.Audit" - ] - ] - }, - "name" : "get_aliases", + ], + "type" : "array" + } + }, + "POST" : { + "description" : "Create IP or Network Alias.", + "method" : "POST", + "name" : "create_alias", "parameters" : { "additionalProperties" : 0, "properties" : { - "vmid" : { - "type" : "integer", - "description" : "The (unique) ID of the VM.", - "format" : "pve-vmid", - "minimum" : 1 + "cidr" : { + "description" : "Network/IP specification in CIDR format.", + "format" : "IPorCIDR", + "type" : "string" + }, + "comment" : { + "optional" : 1, + "type" : "string" + }, + "name" : { + "description" : "Alias name.", + "maxLength" : 64, + "minLength" : 2, + "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", + "type" : "string" }, "node" : { - "format" : "pve-node", "description" : "The cluster node name.", + "format" : "pve-node", "type" : "string" + }, + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" } } }, - "description" : "List aliases" + "permissions" : { + "check" : [ + "perm", + "/vms/{vmid}", + [ + "VM.Config.Network" + ] + ] + }, + "protected" : 1, + "returns" : { + "type" : "null" + } } - } + }, + "leaf" : 0, + "path" : "/nodes/{node}/qemu/{vmid}/firewall/aliases", + "text" : "aliases" }, { - "path" : "/nodes/{node}/qemu/{vmid}/firewall/ipset", - "leaf" : 0, "children" : [ { - "leaf" : 0, - "path" : "/nodes/{node}/qemu/{vmid}/firewall/ipset/{name}", - "info" : { - "POST" : { - "returns" : { - "type" : "null" - }, - "method" : "POST", - "name" : "create_ip", - "parameters" : { - "properties" : { - "nomatch" : { - "type" : "boolean", - "optional" : 1 - }, - "comment" : { - "type" : "string", - "optional" : 1 - }, - "name" : { - "maxLength" : 64, - "type" : "string", - "minLength" : 2, - "description" : "IP set name.", - "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+" - }, - "node" : { - "type" : "string", - "description" : "The cluster node name.", - "format" : "pve-node" - }, - "cidr" : { - "description" : "Network/IP specification in CIDR format.", - "type" : "string", - "format" : "IPorCIDRorAlias" - }, - "vmid" : { - "format" : "pve-vmid", - "minimum" : 1, - "description" : "The (unique) ID of the VM.", - "type" : "integer" - } - }, - "additionalProperties" : 0 - }, - "permissions" : { - "check" : [ - "perm", - "/vms/{vmid}", - [ - "VM.Config.Network" - ] - ] - }, - "description" : "Add IP or Network to IPSet.", - "protected" : 1 - }, - "DELETE" : { - "method" : "DELETE", - "returns" : { - "type" : "null" - }, - "description" : "Delete IPSet", - "protected" : 1, - "name" : "delete_ipset", - "permissions" : { - "check" : [ - "perm", - "/vms/{vmid}", - [ - "VM.Config.Network" - ] - ] - }, - "parameters" : { - "additionalProperties" : 0, - "properties" : { - "node" : { - "format" : "pve-node", - "type" : "string", - "description" : "The cluster node name." - }, - "name" : { - "type" : "string", - "description" : "IP set name.", - "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", - "minLength" : 2, - "maxLength" : 64 - }, - "vmid" : { - "description" : "The (unique) ID of the VM.", - "type" : "integer", - "format" : "pve-vmid", - "minimum" : 1 - } - } - } - }, - "GET" : { - "method" : "GET", - "returns" : { - "links" : [ - { - "rel" : "child", - "href" : "{cidr}" - } - ], - "items" : { - "properties" : { - "cidr" : { - "type" : "string" - }, - "digest" : { - "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", - "optional" : 0, - "type" : "string", - "maxLength" : 40 - }, - "nomatch" : { - "type" : "boolean", - "optional" : 1 - }, - "comment" : { - "type" : "string", - "optional" : 1 - } - }, - "type" : "object" - }, - "type" : "array" - }, - "description" : "List IPSet content", - "permissions" : { - "check" : [ - "perm", - "/vms/{vmid}", - [ - "VM.Audit" - ] - ] - }, - "parameters" : { - "properties" : { - "vmid" : { - "format" : "pve-vmid", - "minimum" : 1, - "description" : "The (unique) ID of the VM.", - "type" : "integer" - }, - "name" : { - "type" : "string", - "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", - "description" : "IP set name.", - "minLength" : 2, - "maxLength" : 64 - }, - "node" : { - "description" : "The cluster node name.", - "type" : "string", - "format" : "pve-node" - } - }, - "additionalProperties" : 0 - }, - "name" : "get_ipset" - } - }, - "text" : "{name}", "children" : [ { "info" : { "DELETE" : { + "description" : "Remove IP or Network from IPSet.", "method" : "DELETE", - "returns" : { - "type" : "null" - }, + "name" : "remove_ip", "parameters" : { + "additionalProperties" : 0, "properties" : { + "cidr" : { + "description" : "Network/IP specification in CIDR format.", + "format" : "IPorCIDRorAlias", + "type" : "string" + }, + "digest" : { + "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", + "maxLength" : 40, + "optional" : 1, + "type" : "string" + }, "name" : { - "maxLength" : 64, - "type" : "string", "description" : "IP set name.", + "maxLength" : 64, + "minLength" : 2, "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", - "minLength" : 2 + "type" : "string" }, "node" : { "description" : "The cluster node name.", - "type" : "string", - "format" : "pve-node" + "format" : "pve-node", + "type" : "string" }, "vmid" : { - "minimum" : 1, + "description" : "The (unique) ID of the VM.", "format" : "pve-vmid", - "type" : "integer", - "description" : "The (unique) ID of the VM." - }, - "digest" : { - "maxLength" : 40, - "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", - "type" : "string", - "optional" : 1 - }, - "cidr" : { - "format" : "IPorCIDRorAlias", - "type" : "string", - "description" : "Network/IP specification in CIDR format." + "minimum" : 1, + "type" : "integer" } - }, - "additionalProperties" : 0 + } }, - "name" : "remove_ip", "permissions" : { "check" : [ "perm", @@ -4226,94 +4012,99 @@ var pveapi = [ ] }, "protected" : 1, - "description" : "Remove IP or Network from IPSet." + "returns" : { + "type" : "null" + } }, - "PUT" : { - "description" : "Update IP or Network settings", - "protected" : 1, - "name" : "update_ip", - "permissions" : { - "check" : [ - "perm", - "/vms/{vmid}", - [ - "VM.Config.Network" - ] - ] - }, + "GET" : { + "description" : "Read IP or Network settings from IPSet.", + "method" : "GET", + "name" : "read_ip", "parameters" : { + "additionalProperties" : 0, "properties" : { - "vmid" : { - "description" : "The (unique) ID of the VM.", - "type" : "integer", - "format" : "pve-vmid", - "minimum" : 1 - }, "cidr" : { + "description" : "Network/IP specification in CIDR format.", "format" : "IPorCIDRorAlias", - "type" : "string", - "description" : "Network/IP specification in CIDR format." - }, - "digest" : { - "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", - "type" : "string", - "optional" : 1, - "maxLength" : 40 - }, - "node" : { - "type" : "string", - "description" : "The cluster node name.", - "format" : "pve-node" + "type" : "string" }, "name" : { - "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", "description" : "IP set name.", + "maxLength" : 64, "minLength" : 2, - "type" : "string", - "maxLength" : 64 + "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", + "type" : "string" }, - "comment" : { - "optional" : 1, + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", "type" : "string" }, - "nomatch" : { - "optional" : 1, - "type" : "boolean" + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" } - }, - "additionalProperties" : 0 + } }, - "method" : "PUT", + "permissions" : { + "check" : [ + "perm", + "/vms/{vmid}", + [ + "VM.Audit" + ] + ] + }, + "protected" : 1, "returns" : { - "type" : "null" + "type" : "object" } }, - "GET" : { + "PUT" : { + "description" : "Update IP or Network settings", + "method" : "PUT", + "name" : "update_ip", "parameters" : { "additionalProperties" : 0, "properties" : { + "cidr" : { + "description" : "Network/IP specification in CIDR format.", + "format" : "IPorCIDRorAlias", + "type" : "string" + }, + "comment" : { + "optional" : 1, + "type" : "string" + }, + "digest" : { + "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", + "maxLength" : 40, + "optional" : 1, + "type" : "string" + }, "name" : { - "type" : "string", - "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", "description" : "IP set name.", + "maxLength" : 64, "minLength" : 2, - "maxLength" : 64 + "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", + "type" : "string" }, "node" : { - "format" : "pve-node", "description" : "The cluster node name.", + "format" : "pve-node", "type" : "string" }, - "cidr" : { - "description" : "Network/IP specification in CIDR format.", - "type" : "string", - "format" : "IPorCIDRorAlias" + "nomatch" : { + "optional" : 1, + "type" : "boolean" }, "vmid" : { "description" : "The (unique) ID of the VM.", - "type" : "integer", + "format" : "pve-vmid", "minimum" : 1, - "format" : "pve-vmid" + "type" : "integer" } } }, @@ -4322,156 +4113,298 @@ var pveapi = [ "perm", "/vms/{vmid}", [ - "VM.Audit" + "VM.Config.Network" ] ] }, - "name" : "read_ip", - "description" : "Read IP or Network settings from IPSet.", "protected" : 1, - "method" : "GET", "returns" : { - "type" : "object" + "type" : "null" } } }, - "text" : "{cidr}", "leaf" : 1, - "path" : "/nodes/{node}/qemu/{vmid}/firewall/ipset/{name}/{cidr}" + "path" : "/nodes/{node}/qemu/{vmid}/firewall/ipset/{name}/{cidr}", + "text" : "{cidr}" } - ] - } - ], - "text" : "ipset", - "info" : { - "POST" : { - "protected" : 1, - "description" : "Create new IPSet", - "parameters" : { - "properties" : { - "digest" : { - "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", - "optional" : 1, - "type" : "string", - "maxLength" : 40 - }, - "vmid" : { - "format" : "pve-vmid", - "minimum" : 1, - "description" : "The (unique) ID of the VM.", - "type" : "integer" + ], + "info" : { + "DELETE" : { + "description" : "Delete IPSet", + "method" : "DELETE", + "name" : "delete_ipset", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "name" : { + "description" : "IP set name.", + "maxLength" : 64, + "minLength" : 2, + "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", + "type" : "string" + }, + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" + } + } }, - "node" : { - "format" : "pve-node", - "description" : "The cluster node name.", - "type" : "string" + "permissions" : { + "check" : [ + "perm", + "/vms/{vmid}", + [ + "VM.Config.Network" + ] + ] }, - "name" : { - "minLength" : 2, - "description" : "IP set name.", - "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", - "type" : "string", - "maxLength" : 64 + "protected" : 1, + "returns" : { + "type" : "null" + } + }, + "GET" : { + "description" : "List IPSet content", + "method" : "GET", + "name" : "get_ipset", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "name" : { + "description" : "IP set name.", + "maxLength" : 64, + "minLength" : 2, + "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", + "type" : "string" + }, + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" + } + } }, - "rename" : { - "optional" : 1, - "type" : "string", - "minLength" : 2, - "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", - "description" : "Rename an existing IPSet. You can set 'rename' to the same value as 'name' to update the 'comment' of an existing IPSet.", - "maxLength" : 64 + "permissions" : { + "check" : [ + "perm", + "/vms/{vmid}", + [ + "VM.Audit" + ] + ] }, - "comment" : { - "type" : "string", - "optional" : 1 + "returns" : { + "items" : { + "properties" : { + "cidr" : { + "type" : "string" + }, + "comment" : { + "optional" : 1, + "type" : "string" + }, + "digest" : { + "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", + "maxLength" : 40, + "optional" : 0, + "type" : "string" + }, + "nomatch" : { + "optional" : 1, + "type" : "boolean" + } + }, + "type" : "object" + }, + "links" : [ + { + "href" : "{cidr}", + "rel" : "child" + } + ], + "type" : "array" } }, - "additionalProperties" : 0 + "POST" : { + "description" : "Add IP or Network to IPSet.", + "method" : "POST", + "name" : "create_ip", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "cidr" : { + "description" : "Network/IP specification in CIDR format.", + "format" : "IPorCIDRorAlias", + "type" : "string" + }, + "comment" : { + "optional" : 1, + "type" : "string" + }, + "name" : { + "description" : "IP set name.", + "maxLength" : 64, + "minLength" : 2, + "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", + "type" : "string" + }, + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, + "nomatch" : { + "optional" : 1, + "type" : "boolean" + }, + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" + } + } + }, + "permissions" : { + "check" : [ + "perm", + "/vms/{vmid}", + [ + "VM.Config.Network" + ] + ] + }, + "protected" : 1, + "returns" : { + "type" : "null" + } + } + }, + "leaf" : 0, + "path" : "/nodes/{node}/qemu/{vmid}/firewall/ipset/{name}", + "text" : "{name}" + } + ], + "info" : { + "GET" : { + "description" : "List IPSets", + "method" : "GET", + "name" : "ipset_index", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" + } + } }, - "name" : "create_ipset", "permissions" : { "check" : [ "perm", "/vms/{vmid}", [ - "VM.Config.Network" + "VM.Audit" ] ] }, "returns" : { - "type" : "null" - }, - "method" : "POST" - }, - "GET" : { - "returns" : { - "type" : "array", "items" : { "properties" : { - "name" : { - "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", - "description" : "IP set name.", - "minLength" : 2, - "type" : "string", - "maxLength" : 64 - }, "comment" : { "optional" : 1, "type" : "string" }, "digest" : { - "optional" : 0, - "type" : "string", "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", - "maxLength" : 40 + "maxLength" : 40, + "optional" : 0, + "type" : "string" + }, + "name" : { + "description" : "IP set name.", + "maxLength" : 64, + "minLength" : 2, + "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", + "type" : "string" } }, "type" : "object" }, "links" : [ { - "rel" : "child", - "href" : "{name}" + "href" : "{name}", + "rel" : "child" } - ] - }, - "method" : "GET", - "description" : "List IPSets", - "permissions" : { - "check" : [ - "perm", - "/vms/{vmid}", - [ - "VM.Audit" - ] - ] - }, + ], + "type" : "array" + } + }, + "POST" : { + "description" : "Create new IPSet", + "method" : "POST", + "name" : "create_ipset", "parameters" : { "additionalProperties" : 0, "properties" : { - "vmid" : { - "type" : "integer", - "description" : "The (unique) ID of the VM.", - "format" : "pve-vmid", - "minimum" : 1 + "comment" : { + "optional" : 1, + "type" : "string" }, - "node" : { - "type" : "string", - "description" : "The cluster node name.", - "format" : "pve-node" - } - } - }, - "name" : "ipset_index" - } - } - }, - { - "text" : "options", - "info" : { - "PUT" : { - "description" : "Set Firewall options.", - "proxyto" : "node", + "digest" : { + "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", + "maxLength" : 40, + "optional" : 1, + "type" : "string" + }, + "name" : { + "description" : "IP set name.", + "maxLength" : 64, + "minLength" : 2, + "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", + "type" : "string" + }, + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, + "rename" : { + "description" : "Rename an existing IPSet. You can set 'rename' to the same value as 'name' to update the 'comment' of an existing IPSet.", + "maxLength" : 64, + "minLength" : 2, + "optional" : 1, + "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", + "type" : "string" + }, + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" + } + } + }, "permissions" : { "check" : [ "perm", @@ -4481,44 +4414,64 @@ var pveapi = [ ] ] }, + "protected" : 1, "returns" : { "type" : "null" - }, - "protected" : 1, - "name" : "set_options", + } + } + }, + "leaf" : 0, + "path" : "/nodes/{node}/qemu/{vmid}/firewall/ipset", + "text" : "ipset" + }, + { + "info" : { + "GET" : { + "description" : "Get VM firewall options.", + "method" : "GET", + "name" : "get_options", "parameters" : { "additionalProperties" : 0, "properties" : { - "ipfilter" : { - "description" : "Enable default IP filters. This is equivalent to adding an empty ipfilter-net 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.", - "type" : "boolean", - "optional" : 1 - }, "node" : { "description" : "The cluster node name.", - "type" : "string", - "format" : "pve-node" + "format" : "pve-node", + "type" : "string" }, - "radv" : { + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" + } + } + }, + "permissions" : { + "check" : [ + "perm", + "/vms/{vmid}", + [ + "VM.Audit" + ] + ] + }, + "proxyto" : "node", + "returns" : { + "properties" : { + "dhcp" : { + "description" : "Enable DHCP.", "optional" : 1, - "type" : "boolean", - "description" : "Allow sending Router Advertisement." + "type" : "boolean" }, - "policy_out" : { - "enum" : [ - "ACCEPT", - "REJECT", - "DROP" - ], - "description" : "Output policy.", + "enable" : { + "description" : "Enable/disable firewall rules.", "optional" : 1, - "type" : "string" + "type" : "boolean" }, - "delete" : { - "type" : "string", + "ipfilter" : { + "description" : "Enable default IP filters. This is equivalent to adding an empty ipfilter-net 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.", "optional" : 1, - "description" : "A list of settings you want to delete.", - "format" : "pve-configid-list" + "type" : "boolean" }, "log_level_in" : { "description" : "Log level for incoming traffic.", @@ -4536,44 +4489,97 @@ var pveapi = [ "optional" : 1, "type" : "string" }, - "dhcp" : { - "description" : "Enable DHCP.", + "log_level_out" : { + "description" : "Log level for outgoing traffic.", + "enum" : [ + "emerg", + "alert", + "crit", + "err", + "warning", + "notice", + "info", + "debug", + "nolog" + ], + "optional" : 1, + "type" : "string" + }, + "macfilter" : { + "description" : "Enable/disable MAC address filter.", "optional" : 1, "type" : "boolean" }, "ndp" : { + "description" : "Enable NDP.", "optional" : 1, - "type" : "boolean", - "description" : "Enable NDP." + "type" : "boolean" }, "policy_in" : { - "type" : "string", - "optional" : 1, "description" : "Input policy.", "enum" : [ "ACCEPT", "REJECT", "DROP" - ] + ], + "optional" : 1, + "type" : "string" }, - "macfilter" : { + "policy_out" : { + "description" : "Output policy.", + "enum" : [ + "ACCEPT", + "REJECT", + "DROP" + ], + "optional" : 1, + "type" : "string" + }, + "radv" : { + "description" : "Allow sending Router Advertisement.", + "optional" : 1, + "type" : "boolean" + } + }, + "type" : "object" + } + }, + "PUT" : { + "description" : "Set Firewall options.", + "method" : "PUT", + "name" : "set_options", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "delete" : { + "description" : "A list of settings you want to delete.", + "format" : "pve-configid-list", + "optional" : 1, + "type" : "string" + }, + "dhcp" : { + "description" : "Enable DHCP.", "optional" : 1, - "type" : "boolean", - "description" : "Enable/disable MAC address filter." + "type" : "boolean" }, "digest" : { "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", + "maxLength" : 40, "optional" : 1, - "type" : "string", - "maxLength" : 40 + "type" : "string" }, "enable" : { "description" : "Enable/disable firewall rules.", "optional" : 1, "type" : "boolean" }, - "log_level_out" : { - "description" : "Log level for outgoing traffic.", + "ipfilter" : { + "description" : "Enable default IP filters. This is equivalent to adding an empty ipfilter-net 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.", + "optional" : 1, + "type" : "boolean" + }, + "log_level_in" : { + "description" : "Log level for incoming traffic.", "enum" : [ "emerg", "alert", @@ -4585,35 +4591,11 @@ var pveapi = [ "debug", "nolog" ], - "type" : "string", - "optional" : 1 - }, - "vmid" : { - "format" : "pve-vmid", - "minimum" : 1, - "type" : "integer", - "description" : "The (unique) ID of the VM." - } - } - }, - "method" : "PUT" - }, - "GET" : { - "method" : "GET", - "returns" : { - "type" : "object", - "properties" : { - "policy_out" : { "optional" : 1, - "type" : "string", - "enum" : [ - "ACCEPT", - "REJECT", - "DROP" - ], - "description" : "Output policy." + "type" : "string" }, - "log_level_in" : { + "log_level_out" : { + "description" : "Log level for outgoing traffic.", "enum" : [ "emerg", "alert", @@ -4625,82 +4607,54 @@ var pveapi = [ "debug", "nolog" ], - "description" : "Log level for incoming traffic.", - "type" : "string", - "optional" : 1 - }, - "ipfilter" : { - "type" : "boolean", "optional" : 1, - "description" : "Enable default IP filters. This is equivalent to adding an empty ipfilter-net 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." - }, - "radv" : { - "description" : "Allow sending Router Advertisement.", - "type" : "boolean", - "optional" : 1 + "type" : "string" }, "macfilter" : { "description" : "Enable/disable MAC address filter.", "optional" : 1, "type" : "boolean" }, + "ndp" : { + "description" : "Enable NDP.", + "optional" : 1, + "type" : "boolean" + }, + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, "policy_in" : { + "description" : "Input policy.", "enum" : [ "ACCEPT", "REJECT", "DROP" ], - "description" : "Input policy.", "optional" : 1, "type" : "string" }, - "ndp" : { - "description" : "Enable NDP.", - "type" : "boolean", - "optional" : 1 - }, - "dhcp" : { + "policy_out" : { + "description" : "Output policy.", + "enum" : [ + "ACCEPT", + "REJECT", + "DROP" + ], "optional" : 1, - "type" : "boolean", - "description" : "Enable DHCP." + "type" : "string" }, - "enable" : { + "radv" : { + "description" : "Allow sending Router Advertisement.", "optional" : 1, - "type" : "boolean", - "description" : "Enable/disable firewall rules." - }, - "log_level_out" : { - "description" : "Log level for outgoing traffic.", - "enum" : [ - "emerg", - "alert", - "crit", - "err", - "warning", - "notice", - "info", - "debug", - "nolog" - ], - "type" : "string", - "optional" : 1 - } - } - }, - "name" : "get_options", - "parameters" : { - "additionalProperties" : 0, - "properties" : { - "node" : { - "description" : "The cluster node name.", - "type" : "string", - "format" : "pve-node" + "type" : "boolean" }, "vmid" : { "description" : "The (unique) ID of the VM.", - "type" : "integer", + "format" : "pve-vmid", "minimum" : 1, - "format" : "pve-vmid" + "type" : "integer" } } }, @@ -4709,39 +4663,53 @@ var pveapi = [ "perm", "/vms/{vmid}", [ - "VM.Audit" + "VM.Config.Network" ] ] }, + "protected" : 1, "proxyto" : "node", - "description" : "Get VM firewall options." + "returns" : { + "type" : "null" + } } }, + "leaf" : 1, "path" : "/nodes/{node}/qemu/{vmid}/firewall/options", - "leaf" : 1 + "text" : "options" }, { - "text" : "log", "info" : { "GET" : { - "returns" : { - "items" : { - "properties" : { - "t" : { - "description" : "Line text", - "type" : "string" - }, - "n" : { - "type" : "integer", - "description" : "Line number" - } + "description" : "Read firewall log", + "method" : "GET", + "name" : "log", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "limit" : { + "minimum" : 0, + "optional" : 1, + "type" : "integer" }, - "type" : "object" - }, - "type" : "array" + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, + "start" : { + "minimum" : 0, + "optional" : 1, + "type" : "integer" + }, + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" + } + } }, - "proxyto" : "node", - "description" : "Read firewall log", "permissions" : { "check" : [ "perm", @@ -4751,67 +4719,42 @@ var pveapi = [ ] ] }, - "method" : "GET", "protected" : 1, - "name" : "log", - "parameters" : { - "properties" : { - "vmid" : { - "format" : "pve-vmid", - "minimum" : 1, - "description" : "The (unique) ID of the VM.", - "type" : "integer" - }, - "start" : { - "optional" : 1, - "type" : "integer", - "minimum" : 0 - }, - "node" : { - "type" : "string", - "description" : "The cluster node name.", - "format" : "pve-node" + "proxyto" : "node", + "returns" : { + "items" : { + "properties" : { + "n" : { + "description" : "Line number", + "type" : "integer" + }, + "t" : { + "description" : "Line text", + "type" : "string" + } }, - "limit" : { - "optional" : 1, - "type" : "integer", - "minimum" : 0 - } + "type" : "object" }, - "additionalProperties" : 0 + "type" : "array" } } }, + "leaf" : 1, "path" : "/nodes/{node}/qemu/{vmid}/firewall/log", - "leaf" : 1 + "text" : "log" }, { - "path" : "/nodes/{node}/qemu/{vmid}/firewall/refs", - "leaf" : 1, - "text" : "refs", "info" : { "GET" : { "description" : "Lists possible IPSet/Alias reference which are allowed in source/dest properties.", - "permissions" : { - "check" : [ - "perm", - "/vms/{vmid}", - [ - "VM.Audit" - ] - ] - }, + "method" : "GET", + "name" : "refs", "parameters" : { + "additionalProperties" : 0, "properties" : { - "vmid" : { - "format" : "pve-vmid", - "minimum" : 1, - "type" : "integer", - "description" : "The (unique) ID of the VM." - }, "node" : { - "format" : "pve-node", "description" : "The cluster node name.", + "format" : "pve-node", "type" : "string" }, "type" : { @@ -4820,29 +4763,41 @@ var pveapi = [ "alias", "ipset" ], - "type" : "string", - "optional" : 1 + "optional" : 1, + "type" : "string" + }, + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" } - }, - "additionalProperties" : 0 + } + }, + "permissions" : { + "check" : [ + "perm", + "/vms/{vmid}", + [ + "VM.Audit" + ] + ] }, - "name" : "refs", - "method" : "GET", "returns" : { "items" : { "properties" : { - "type" : { - "enum" : [ - "alias", - "ipset" - ], + "comment" : { + "optional" : 1, "type" : "string" }, "name" : { "type" : "string" }, - "comment" : { - "optional" : 1, + "type" : { + "enum" : [ + "alias", + "ipset" + ], "type" : "string" } }, @@ -4851,80 +4806,85 @@ var pveapi = [ "type" : "array" } } - } + }, + "leaf" : 1, + "path" : "/nodes/{node}/qemu/{vmid}/firewall/refs", + "text" : "refs" } ], "info" : { "GET" : { + "description" : "Directory index.", "method" : "GET", - "returns" : { - "links" : [ - { - "href" : "{name}", - "rel" : "child" - } - ], - "items" : { - "type" : "object", - "properties" : {} - }, - "type" : "array" - }, + "name" : "index", "parameters" : { + "additionalProperties" : 0, "properties" : { "node" : { - "type" : "string", "description" : "The cluster node name.", - "format" : "pve-node" + "format" : "pve-node", + "type" : "string" }, "vmid" : { + "description" : "The (unique) ID of the VM.", "format" : "pve-vmid", "minimum" : 1, - "type" : "integer", - "description" : "The (unique) ID of the VM." + "type" : "integer" } - }, - "additionalProperties" : 0 + } }, "permissions" : { "user" : "all" }, - "name" : "index", - "description" : "Directory index." + "returns" : { + "items" : { + "properties" : {}, + "type" : "object" + }, + "links" : [ + { + "href" : "{name}", + "rel" : "child" + } + ], + "type" : "array" + } } - } + }, + "leaf" : 0, + "path" : "/nodes/{node}/qemu/{vmid}/firewall", + "text" : "firewall" }, { - "path" : "/nodes/{node}/qemu/{vmid}/rrd", - "leaf" : 1, - "text" : "rrd", "info" : { "GET" : { + "description" : "Read VM RRD statistics (returns PNG)", + "method" : "GET", "name" : "rrd", "parameters" : { "additionalProperties" : 0, "properties" : { "cf" : { + "description" : "The RRD consolidation function", "enum" : [ "AVERAGE", "MAX" ], - "description" : "The RRD consolidation function", "optional" : 1, "type" : "string" }, - "vmid" : { - "type" : "integer", - "description" : "The (unique) ID of the VM.", - "format" : "pve-vmid", - "minimum" : 1 + "ds" : { + "description" : "The list of datasources you want to display.", + "format" : "pve-configid-list", + "type" : "string" }, "node" : { + "description" : "The cluster node name.", "format" : "pve-node", - "type" : "string", - "description" : "The cluster node name." + "type" : "string" }, "timeframe" : { + "description" : "Specify the time frame you are interested in.", "enum" : [ "hour", "day", @@ -4932,13 +4892,13 @@ var pveapi = [ "month", "year" ], - "description" : "Specify the time frame you are interested in.", "type" : "string" }, - "ds" : { - "description" : "The list of datasources you want to display.", - "type" : "string", - "format" : "pve-configid-list" + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" } } }, @@ -4951,7 +4911,6 @@ var pveapi = [ ] ] }, - "description" : "Read VM RRD statistics (returns PNG)", "protected" : 1, "returns" : { "properties" : { @@ -4960,28 +4919,38 @@ var pveapi = [ } }, "type" : "object" - }, - "method" : "GET" + } } - } + }, + "leaf" : 1, + "path" : "/nodes/{node}/qemu/{vmid}/rrd", + "text" : "rrd" }, { - "leaf" : 1, - "path" : "/nodes/{node}/qemu/{vmid}/rrddata", "info" : { "GET" : { - "protected" : 1, "description" : "Read VM RRD statistics", + "method" : "GET", "name" : "rrddata", "parameters" : { + "additionalProperties" : 0, "properties" : { + "cf" : { + "description" : "The RRD consolidation function", + "enum" : [ + "AVERAGE", + "MAX" + ], + "optional" : 1, + "type" : "string" + }, "node" : { + "description" : "The cluster node name.", "format" : "pve-node", - "type" : "string", - "description" : "The cluster node name." + "type" : "string" }, "timeframe" : { - "type" : "string", + "description" : "Specify the time frame you are interested in.", "enum" : [ "hour", "day", @@ -4989,25 +4958,15 @@ var pveapi = [ "month", "year" ], - "description" : "Specify the time frame you are interested in." + "type" : "string" }, "vmid" : { - "type" : "integer", "description" : "The (unique) ID of the VM.", "format" : "pve-vmid", - "minimum" : 1 - }, - "cf" : { - "description" : "The RRD consolidation function", - "enum" : [ - "AVERAGE", - "MAX" - ], - "type" : "string", - "optional" : 1 + "minimum" : 1, + "type" : "integer" } - }, - "additionalProperties" : 0 + } }, "permissions" : { "check" : [ @@ -5018,255 +4977,335 @@ var pveapi = [ ] ] }, - "method" : "GET", + "protected" : 1, "returns" : { - "type" : "array", "items" : { - "type" : "object", - "properties" : {} - } + "properties" : {}, + "type" : "object" + }, + "type" : "array" } } }, + "leaf" : 1, + "path" : "/nodes/{node}/qemu/{vmid}/rrddata", "text" : "rrddata" }, { - "leaf" : 1, - "path" : "/nodes/{node}/qemu/{vmid}/config", "info" : { - "POST" : { - "returns" : { - "type" : "string", - "optional" : 1 + "GET" : { + "description" : "Get current virtual machine configuration. This does not include pending configuration changes (see 'pending' API).", + "method" : "GET", + "name" : "vm_config", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "current" : { + "default" : 0, + "description" : "Get current values (instead of pending values).", + "optional" : 1, + "type" : "boolean" + }, + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" + } + } }, "permissions" : { "check" : [ "perm", "/vms/{vmid}", [ - "VM.Config.Disk", - "VM.Config.CDROM", - "VM.Config.CPU", - "VM.Config.Memory", - "VM.Config.Network", - "VM.Config.HWType", - "VM.Config.Options" - ], - "any", - 1 + "VM.Audit" + ] ] }, "proxyto" : "node", + "returns" : { + "properties" : { + "digest" : { + "description" : "SHA1 digest of configuration file. This can be used to prevent concurrent modifications.", + "type" : "string" + } + }, + "type" : "object" + } + }, + "POST" : { "description" : "Set virtual machine options (asynchrounous API).", "method" : "POST", + "name" : "update_vm_async", "parameters" : { + "additionalProperties" : 0, "properties" : { - "cpulimit" : { - "description" : "Limit of CPU usage.\n\nNOTE: If the computer has 2 CPUs, it has total of '2' CPU time. Value '0' indicates no CPU limit.", + "acpi" : { + "default" : 1, + "description" : "Enable/disable ACPI.", + "optional" : 1, + "type" : "boolean" + }, + "agent" : { "default" : 0, - "maximum" : 128, + "description" : "Enable/disable Qemu GuestAgent.", "optional" : 1, - "type" : "number", - "minimum" : 0 + "type" : "boolean" }, - "node" : { - "description" : "The cluster node name.", - "type" : "string", - "format" : "pve-node" + "args" : { + "description" : "Arbitrary arguments passed to kvm, for example:\n\nargs: -no-reboot -no-hpet\n\nNOTE: this option is for experts only.\n", + "optional" : 1, + "type" : "string" }, - "force" : { + "autostart" : { + "default" : 0, + "description" : "Automatic restart after crash (currently ignored).", "optional" : 1, - "type" : "boolean", - "description" : "Force physical removal. Without this, we simple remove the disk from the config file and create an additional configuration entry called 'unused[n]', which contains the volume ID. Unlink of unused[n] always cause physical removal.", - "requires" : "delete" + "type" : "boolean" }, - "kvm" : { - "default" : 1, + "background_delay" : { + "description" : "Time to wait for the task to finish. We return 'null' if the task finish within that time.", + "maximum" : 30, + "minimum" : 1, "optional" : 1, - "type" : "boolean", - "description" : "Enable/disable KVM hardware virtualization." + "type" : "integer" }, - "localtime" : { - "description" : "Set the real time clock to local time. This is enabled by default if ostype indicates a Microsoft OS.", + "balloon" : { + "description" : "Amount of target RAM for the VM in MB. Using zero disables the ballon driver.", + "minimum" : 0, "optional" : 1, - "type" : "boolean" + "type" : "integer" }, - "migrate_speed" : { - "description" : "Set maximum speed (in MB/s) for migrations. Value 0 is no limit.", - "default" : 0, + "bios" : { + "default" : "seabios", + "description" : "Select BIOS implementation.", + "enum" : [ + "seabios", + "ovmf" + ], "optional" : 1, - "type" : "integer", - "minimum" : 0 + "type" : "string" }, - "startdate" : { - "pattern" : "(now|\\d{4}-\\d{1,2}-\\d{1,2}(T\\d{1,2}:\\d{1,2}:\\d{1,2})?)", - "description" : "Set the initial date of the real time clock. Valid format for date are: 'now' or '2006-06-17T16:01:21' or '2006-06-17'.", + "boot" : { + "default" : "cdn", + "description" : "Boot on floppy (a), hard disk (c), CD-ROM (d), or network (n).", + "optional" : 1, + "pattern" : "[acdn]{1,4}", + "type" : "string" + }, + "bootdisk" : { + "description" : "Enable booting from specified disk.", + "format" : "pve-qm-bootdisk", + "optional" : 1, + "pattern" : "(ide|sata|scsi|virtio)\\d+", + "type" : "string" + }, + "cdrom" : { + "description" : "This is an alias for option -ide2", + "format" : "pve-qm-drive", + "optional" : 1, "type" : "string", + "typetext" : "volume" + }, + "cores" : { + "default" : 1, + "description" : "The number of cores per socket.", + "minimum" : 1, "optional" : 1, - "default" : "now", - "typetext" : "(now | YYYY-MM-DD | YYYY-MM-DDTHH:MM:SS)" + "type" : "integer" }, - "sata[n]" : { + "cpu" : { + "description" : "Emulated CPU type.", "format" : { - "mbps" : { - "format_description" : "mbps", - "description" : "Maximum r/w speed speed in megabytes per second.", - "type" : "number", - "optional" : 1 - }, - "cyls" : { - "format_description" : "count", - "optional" : 1, - "type" : "integer", - "description" : "Force the drive's physical geometry to have a specific cylinder count." - }, - "bps_rd" : { - "description" : "Maximum read speed speed in bytes per second.", - "optional" : 1, - "type" : "integer", - "format_description" : "bps" - }, - "trans" : { - "format_description" : "none|lba|auto", - "type" : "string", - "optional" : 1, - "enum" : [ - "none", - "lba", - "auto" - ], - "description" : "Force disk geometry bios translation mode." - }, - "volume" : { - "alias" : "file" - }, - "iops" : { - "format_description" : "iops", - "description" : "Maximum r/w I/O speed in operations per second.", - "optional" : 1, - "type" : "integer" - }, - "file" : { + "cputype" : { + "default" : "kvm64", "default_key" : 1, - "format_description" : "volume", - "format" : "pve-volume-id-or-qm-path", - "type" : "string", - "description" : "The drive's backing volume." - }, - "mbps_wr" : { - "optional" : 1, - "type" : "number", - "description" : "Maximum write speed speed in megabytes per second.", - "format_description" : "mbps" - }, - "mbps_rd" : { - "format_description" : "mbps", - "description" : "Maximum read speed speed in megabytes per second.", - "type" : "number", - "optional" : 1 - }, - "backup" : { - "format_description" : "on|off", - "type" : "boolean", - "optional" : 1, - "description" : "Whether the drive should be included when making backups." - }, - "iops_wr_max" : { - "type" : "integer", - "optional" : 1, - "description" : "Maximum unthrottled write I/O pool speed in operations per second.", - "format_description" : "iops" - }, - "aio" : { - "format_description" : "native|threads", - "description" : "AIO type to use.", + "description" : "Emulated CPU type.", "enum" : [ - "native", - "threads" + "486", + "athlon", + "pentium", + "pentium2", + "pentium3", + "coreduo", + "core2duo", + "kvm32", + "kvm64", + "qemu32", + "qemu64", + "phenom", + "Conroe", + "Penryn", + "Nehalem", + "Westmere", + "SandyBridge", + "IvyBridge", + "Haswell", + "Haswell-noTSX", + "Broadwell", + "Broadwell-noTSX", + "Opteron_G1", + "Opteron_G2", + "Opteron_G3", + "Opteron_G4", + "Opteron_G5", + "host" ], - "optional" : 1, + "format_description" : "cputype", "type" : "string" }, - "werror" : { - "format_description" : "enospc|ignore|report|stop", - "optional" : 1, - "type" : "string", - "enum" : [ - "enospc", - "ignore", - "report", - "stop" - ], - "description" : "Write error action." - }, - "size" : { - "format" : "disk-size", - "type" : "string", - "optional" : 1, - "description" : "Disk size. This is purely informational and has no effect." - }, - "iops_rd" : { - "format_description" : "iops", - "type" : "integer", - "optional" : 1, - "description" : "Maximum read I/O speed in operations per second." - }, - "mbps_max" : { - "format_description" : "mbps", - "description" : "Maximum unthrottled r/w pool speed in megabytes per second.", - "optional" : 1, - "type" : "number" - }, - "bps_wr" : { - "format_description" : "bps", - "type" : "integer", - "optional" : 1, - "description" : "Maximum write speed speed in bytes per second." - }, - "mbps_rd_max" : { - "format_description" : "mbps", + "hidden" : { + "default" : 0, + "description" : "Do not identify as a KVM virtual machine.", "optional" : 1, - "type" : "number", - "description" : "Maximum unthrottled read pool speed in megabytes per second." - }, - "discard" : { - "enum" : [ - "ignore", - "on" + "type" : "boolean" + } + }, + "optional" : 1, + "type" : "string" + }, + "cpulimit" : { + "default" : 0, + "description" : "Limit of CPU usage.\n\nNOTE: If the computer has 2 CPUs, it has total of '2' CPU time. Value '0' indicates no CPU limit.", + "maximum" : 128, + "minimum" : 0, + "optional" : 1, + "type" : "number" + }, + "cpuunits" : { + "default" : 1000, + "description" : "CPU weight for a VM. Argument is used in the kernel fair scheduler. The larger the number is, the more CPU time this VM gets. Number is relative to weights of all the other running VMs.\n\nNOTE: You can disable fair-scheduler configuration by setting this to 0.", + "maximum" : 500000, + "minimum" : 0, + "optional" : 1, + "type" : "integer" + }, + "delete" : { + "description" : "A list of settings you want to delete.", + "format" : "pve-configid-list", + "optional" : 1, + "type" : "string" + }, + "description" : { + "description" : "Description for the VM. Only used on the configuration web interface. This is saved as comment inside the configuration file.", + "optional" : 1, + "type" : "string" + }, + "digest" : { + "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", + "maxLength" : 40, + "optional" : 1, + "type" : "string" + }, + "force" : { + "description" : "Force physical removal. Without this, we simple remove the disk from the config file and create an additional configuration entry called 'unused[n]', which contains the volume ID. Unlink of unused[n] always cause physical removal.", + "optional" : 1, + "requires" : "delete", + "type" : "boolean" + }, + "freeze" : { + "description" : "Freeze CPU at startup (use 'c' monitor command to start execution).", + "optional" : 1, + "type" : "boolean" + }, + "hostpci[n]" : { + "description" : "Map host pci devices. HOSTPCIDEVICE syntax is:\n\n'bus:dev.func' (hexadecimal numbers)\n\nYou can us the 'lspci' command to list existing pci devices.\n\nThe 'rombar' option determines whether or not the device's ROM will be visible in the guest's memory map (default is 'on').\n\nNOTE: This option allows direct access to host hardware. So it is no longer possible to migrate such machines - use with special care.\n\nExperimental: user reported problems with this option.\n", + "format" : "pve-qm-hostpci", + "optional" : 1, + "type" : "string" + }, + "hotplug" : { + "default" : "network,disk,usb", + "description" : "Selectively enable hotplug features. This is a comma separated list of hotplug features: 'network', 'disk', 'cpu', 'memory' and 'usb'. Use '0' to disable hotplug completely. Value '1' is an alias for the default 'network,disk,usb'.", + "format" : "pve-hotplug-features", + "optional" : 1, + "type" : "string" + }, + "ide[n]" : { + "description" : "Use volume as IDE hard disk or CD-ROM (n is 0 to 3).", + "format" : { + "aio" : { + "description" : "AIO type to use.", + "enum" : [ + "native", + "threads" ], - "description" : "Controls whether to pass discard/trim requests to the underlying storage.", - "type" : "string", + "format_description" : "native|threads", "optional" : 1, - "format_description" : "ignore|on" - }, - "serial" : { - "maxLength" : 60, - "format" : "urlencoded", - "format_description" : "serial", - "description" : "The drive's reported serial number, url-encoded, up to 20 bytes long.", - "type" : "string", - "optional" : 1 + "type" : "string" }, - "heads" : { - "description" : "Force the drive's physical geometry to have a specific head count.", - "type" : "integer", + "backup" : { + "description" : "Whether the drive should be included when making backups.", + "format_description" : "on|off", "optional" : 1, - "format_description" : "count" + "type" : "boolean" }, "bps" : { "description" : "Maximum r/w speed speed in bytes per second.", - "type" : "integer", + "format_description" : "bps", + "optional" : 1, + "type" : "integer" + }, + "bps_rd" : { + "description" : "Maximum read speed speed in bytes per second.", + "format_description" : "bps", "optional" : 1, - "format_description" : "bps" + "type" : "integer" }, - "iops_rd_max" : { - "description" : "Maximum unthrottled read I/O pool speed in operations per second.", + "bps_wr" : { + "description" : "Maximum write speed speed in bytes per second.", + "format_description" : "bps", + "optional" : 1, + "type" : "integer" + }, + "cache" : { + "description" : "The drive's cache mode", + "enum" : [ + "none", + "writethrough", + "writeback", + "unsafe", + "directsync" + ], + "format_description" : "none|writethrough|writeback|unsafe|directsync", + "optional" : 1, + "type" : "string" + }, + "cyls" : { + "description" : "Force the drive's physical geometry to have a specific cylinder count.", + "format_description" : "count", + "optional" : 1, + "type" : "integer" + }, + "detect_zeroes" : { + "description" : "Controls whether to detect and try to optimize writes of zeroes.", + "optional" : 1, + "type" : "boolean" + }, + "discard" : { + "description" : "Controls whether to pass discard/trim requests to the underlying storage.", + "enum" : [ + "ignore", + "on" + ], + "format_description" : "ignore|on", "optional" : 1, - "type" : "integer", - "format_description" : "iops" + "type" : "string" + }, + "file" : { + "default_key" : 1, + "description" : "The drive's backing volume.", + "format" : "pve-volume-id-or-qm-path", + "format_description" : "volume", + "type" : "string" }, "format" : { - "format_description" : "drive format", "description" : "The drive's backing file's data format.", "enum" : [ "raw", @@ -5277,147 +5316,325 @@ var pveapi = [ "vmdk", "cloop" ], + "format_description" : "drive format", "optional" : 1, "type" : "string" }, - "mbps_wr_max" : { - "format_description" : "mbps", - "description" : "Maximum unthrottled write pool speed in megabytes per second.", - "type" : "number", - "optional" : 1 + "heads" : { + "description" : "Force the drive's physical geometry to have a specific head count.", + "format_description" : "count", + "optional" : 1, + "type" : "integer" }, - "detect_zeroes" : { - "description" : "Controls whether to detect and try to optimize writes of zeroes.", + "iops" : { + "description" : "Maximum r/w I/O speed in operations per second.", + "format_description" : "iops", "optional" : 1, - "type" : "boolean" + "type" : "integer" }, - "secs" : { - "format_description" : "count", + "iops_max" : { + "description" : "Maximum unthrottled r/w I/O pool speed in operations per second.", + "format_description" : "iops", "optional" : 1, - "type" : "integer", - "description" : "Force the drive's physical geometry to have a specific sector count." + "type" : "integer" }, - "iops_wr" : { + "iops_rd" : { + "description" : "Maximum read I/O speed in operations per second.", + "format_description" : "iops", + "optional" : 1, + "type" : "integer" + }, + "iops_rd_max" : { + "description" : "Maximum unthrottled read I/O pool speed in operations per second.", "format_description" : "iops", + "optional" : 1, + "type" : "integer" + }, + "iops_wr" : { "description" : "Maximum write I/O speed in operations per second.", + "format_description" : "iops", "optional" : 1, "type" : "integer" }, - "cache" : { + "iops_wr_max" : { + "description" : "Maximum unthrottled write I/O pool speed in operations per second.", + "format_description" : "iops", "optional" : 1, - "type" : "string", - "enum" : [ - "none", - "writethrough", - "writeback", - "unsafe", - "directsync" - ], - "description" : "The drive's cache mode", - "format_description" : "none|writethrough|writeback|unsafe|directsync" + "type" : "integer" }, - "rerror" : { - "enum" : [ - "ignore", - "report", - "stop" - ], - "description" : "Read error action.", - "type" : "string", + "mbps" : { + "description" : "Maximum r/w speed speed in megabytes per second.", + "format_description" : "mbps", + "optional" : 1, + "type" : "number" + }, + "mbps_max" : { + "description" : "Maximum unthrottled r/w pool speed in megabytes per second.", + "format_description" : "mbps", + "optional" : 1, + "type" : "number" + }, + "mbps_rd" : { + "description" : "Maximum read speed speed in megabytes per second.", + "format_description" : "mbps", + "optional" : 1, + "type" : "number" + }, + "mbps_rd_max" : { + "description" : "Maximum unthrottled read pool speed in megabytes per second.", + "format_description" : "mbps", + "optional" : 1, + "type" : "number" + }, + "mbps_wr" : { + "description" : "Maximum write speed speed in megabytes per second.", + "format_description" : "mbps", + "optional" : 1, + "type" : "number" + }, + "mbps_wr_max" : { + "description" : "Maximum unthrottled write pool speed in megabytes per second.", + "format_description" : "mbps", "optional" : 1, - "format_description" : "ignore|report|stop" + "type" : "number" }, "media" : { - "format_description" : "cdrom|disk", "default" : "disk", - "type" : "string", - "optional" : 1, "description" : "The drive's media type.", "enum" : [ "cdrom", "disk" - ] + ], + "format_description" : "cdrom|disk", + "optional" : 1, + "type" : "string" }, - "snapshot" : { - "description" : "Whether the drive should be included when making snapshots.", - "type" : "boolean", + "model" : { + "description" : "The drive's reported model name, url-encoded, up to 40 bytes long.", + "format" : "urlencoded", + "format_description" : "model", + "maxLength" : 120, "optional" : 1, - "format_description" : "on|off" + "type" : "string" }, - "iops_max" : { + "rerror" : { + "description" : "Read error action.", + "enum" : [ + "ignore", + "report", + "stop" + ], + "format_description" : "ignore|report|stop", "optional" : 1, - "type" : "integer", - "description" : "Maximum unthrottled r/w I/O pool speed in operations per second.", - "format_description" : "iops" + "type" : "string" + }, + "secs" : { + "description" : "Force the drive's physical geometry to have a specific sector count.", + "format_description" : "count", + "optional" : 1, + "type" : "integer" + }, + "serial" : { + "description" : "The drive's reported serial number, url-encoded, up to 20 bytes long.", + "format" : "urlencoded", + "format_description" : "serial", + "maxLength" : 60, + "optional" : 1, + "type" : "string" + }, + "size" : { + "description" : "Disk size. This is purely informational and has no effect.", + "format" : "disk-size", + "optional" : 1, + "type" : "string" + }, + "snapshot" : { + "description" : "Whether the drive should be included when making snapshots.", + "format_description" : "on|off", + "optional" : 1, + "type" : "boolean" + }, + "trans" : { + "description" : "Force disk geometry bios translation mode.", + "enum" : [ + "none", + "lba", + "auto" + ], + "format_description" : "none|lba|auto", + "optional" : 1, + "type" : "string" + }, + "volume" : { + "alias" : "file" + }, + "werror" : { + "description" : "Write error action.", + "enum" : [ + "enospc", + "ignore", + "report", + "stop" + ], + "format_description" : "enospc|ignore|report|stop", + "optional" : 1, + "type" : "string" } }, - "description" : "Use volume as SATA hard disk or CD-ROM (n is 0 to 5).", - "type" : "string", - "optional" : 1 + "optional" : 1, + "type" : "string" }, - "tablet" : { + "keyboard" : { + "default" : "en-us", + "description" : "Keybord layout for vnc server. Default is read from the datacenter configuration file.", + "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" + ], "optional" : 1, - "type" : "boolean", + "type" : "string" + }, + "kvm" : { "default" : 1, - "description" : "Enable/disable the USB tablet device. This device is usually needed to allow absolute mouse positioning with VNC. Else the mouse runs out of sync with normal VNC clients. If you're running lots of console-only guests on one host, you may consider disabling this to save some context switches. This is turned off by default if you use spice (-vga=qxl)." + "description" : "Enable/disable KVM hardware virtualization.", + "optional" : 1, + "type" : "boolean" }, - "boot" : { - "pattern" : "[acdn]{1,4}", - "description" : "Boot on floppy (a), hard disk (c), CD-ROM (d), or network (n).", + "localtime" : { + "description" : "Set the real time clock to local time. This is enabled by default if ostype indicates a Microsoft OS.", "optional" : 1, - "type" : "string", - "default" : "cdn" + "type" : "boolean" }, - "numa[n]" : { + "lock" : { + "description" : "Lock/unlock the VM.", + "enum" : [ + "migrate", + "backup", + "snapshot", + "rollback" + ], "optional" : 1, - "type" : "string", + "type" : "string" + }, + "machine" : { + "description" : "Specific the Qemu machine type.", + "maxLength" : 40, + "optional" : 1, + "pattern" : "(pc|pc(-i440fx)?-\\d+\\.\\d+(\\.pxe)?|q35|pc-q35-\\d+\\.\\d+(\\.pxe)?)", + "type" : "string" + }, + "memory" : { + "default" : 512, + "description" : "Amount of RAM for the VM in MB. This is the maximum available memory when you use the balloon device.", + "minimum" : 16, + "optional" : 1, + "type" : "integer" + }, + "migrate_downtime" : { + "default" : 0.1, + "description" : "Set maximum tolerated downtime (in seconds) for migrations.", + "minimum" : 0, + "optional" : 1, + "type" : "number" + }, + "migrate_speed" : { + "default" : 0, + "description" : "Set maximum speed (in MB/s) for migrations. Value 0 is no limit.", + "minimum" : 0, + "optional" : 1, + "type" : "integer" + }, + "name" : { + "description" : "Set a name for the VM. Only used on the configuration web interface.", + "format" : "dns-name", + "optional" : 1, + "type" : "string" + }, + "net[n]" : { + "description" : "Specify network devices.\n\nMODEL is one of: e1000 e1000-82540em e1000-82544gc e1000-82545em i82551 i82557b i82559er ne2k_isa ne2k_pci pcnet rtl8139 virtio vmxnet3\n\nXX:XX:XX:XX:XX:XX should be an unique MAC address. This is\nautomatically generated if not specified.\n\nThe bridge parameter can be used to automatically add the interface to a bridge device. The Proxmox VE standard bridge is called 'vmbr0'.\n\nOption 'rate' is used to limit traffic bandwidth from and to this interface. It is specified as floating point number, unit is 'Megabytes per second'.\n\nIf you specify no bridge, we create a kvm 'user' (NATed) network device, which provides DHCP and DNS services. The following addresses are used:\n\n10.0.2.2 Gateway\n10.0.2.3 DNS Server\n10.0.2.4 SMB Server\n\nThe DHCP server assign addresses to the guest starting from 10.0.2.15.\n\n", + "format" : "pve-qm-net", + "optional" : 1, + "type" : "string" + }, + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, + "numa" : { + "default" : 0, + "description" : "Enable/disable NUMA.", + "optional" : 1, + "type" : "boolean" + }, + "numa[n]" : { "description" : "numa topology", "format" : { - "memory" : { - "format_description" : "mb", - "description" : "Amount of memory this numa node provides.", - "optional" : 1, - "type" : "number" - }, "cpus" : { - "type" : "string", - "pattern" : "(?^:\\d+(?:-\\d+)?(?:;\\d+(?:-\\d+)?)*)", "description" : "CPUs accessing this numa node.", - "format_description" : "id[-id];..." + "format_description" : "id[-id];...", + "pattern" : "(?^:\\d+(?:-\\d+)?(?:;\\d+(?:-\\d+)?)*)", + "type" : "string" }, "hostnodes" : { + "description" : "host numa nodes to use", + "format_description" : "id[-id];...", "optional" : 1, - "type" : "string", "pattern" : "(?^:\\d+(?:-\\d+)?(?:;\\d+(?:-\\d+)?)*)", - "description" : "host numa nodes to use", - "format_description" : "id[-id];..." + "type" : "string" }, - "policy" : { + "memory" : { + "description" : "Amount of memory this numa node provides.", + "format_description" : "mb", "optional" : 1, - "type" : "string", + "type" : "number" + }, + "policy" : { "description" : "numa allocation policy.", "enum" : [ "preferred", "bind", "interleave" ], - "format_description" : "preferred|bind|interleave" + "format_description" : "preferred|bind|interleave", + "optional" : 1, + "type" : "string" } - } - }, - "tdf" : { - "description" : "Enable/disable time drift fix.", - "type" : "boolean", + }, "optional" : 1, - "default" : 0 + "type" : "string" }, - "autostart" : { - "description" : "Automatic restart after crash (currently ignored).", + "onboot" : { "default" : 0, - "type" : "boolean", - "optional" : 1 + "description" : "Specifies whether a VM will be started during system bootup.", + "optional" : 1, + "type" : "boolean" }, "ostype" : { + "description" : "Used to enable special optimization/features for specific\noperating systems:\n\nother => unspecified OS\nwxp => Microsoft Windows XP\nw2k => Microsoft Windows 2000\nw2k3 => Microsoft Windows 2003\nw2k8 => Microsoft Windows 2008\nwvista => Microsoft Windows Vista\nwin7 => Microsoft Windows 7\nwin8 => Microsoft Windows 8/2012\nl24 => Linux 2.4 Kernel\nl26 => Linux 2.6/3.X Kernel\nsolaris => solaris/opensolaris/openindiania kernel\n\nother|l24|l26|solaris ... no special behaviour\nwxp|w2k|w2k3|w2k8|wvista|win7|win8 ... use --localtime switch\n", "enum" : [ "other", "wxp", @@ -5431,189 +5648,72 @@ var pveapi = [ "l26", "solaris" ], - "description" : "Used to enable special optimization/features for specific\noperating systems:\n\nother => unspecified OS\nwxp => Microsoft Windows XP\nw2k => Microsoft Windows 2000\nw2k3 => Microsoft Windows 2003\nw2k8 => Microsoft Windows 2008\nwvista => Microsoft Windows Vista\nwin7 => Microsoft Windows 7\nwin8 => Microsoft Windows 8/2012\nl24 => Linux 2.4 Kernel\nl26 => Linux 2.6/3.X Kernel\nsolaris => solaris/opensolaris/openindiania kernel\n\nother|l24|l26|solaris ... no special behaviour\nwxp|w2k|w2k3|w2k8|wvista|win7|win8 ... use --localtime switch\n", "optional" : 1, "type" : "string" }, - "unused[n]" : { - "format" : "pve-volume-id", - "type" : "string", - "optional" : 1, - "description" : "Reference to unused volumes." - }, - "template" : { - "description" : "Enable/disable Template.", - "default" : 0, - "type" : "boolean", - "optional" : 1 - }, - "shares" : { - "default" : 1000, - "maximum" : 50000, - "type" : "integer", - "optional" : 1, - "description" : "Amount of memory shares for auto-ballooning. The larger the number is, the more memory this VM gets. Number is relative to weights of all other running VMs. Using zero disables auto-ballooning", - "minimum" : 0 - }, - "bios" : { - "enum" : [ - "seabios", - "ovmf" - ], - "description" : "Select BIOS implementation.", + "parallel[n]" : { + "description" : "Map host parallel devices (n is 0 to 2).\n\nNOTE: This option allows direct access to host hardware. So it is no longer possible to migrate such machines - use with special care.\n\nExperimental: user reported problems with this option.\n", "optional" : 1, - "type" : "string", - "default" : "seabios" + "pattern" : "/dev/parport\\d+|/dev/usb/lp\\d+", + "type" : "string" }, "protection" : { "default" : 0, - "type" : "boolean", + "description" : "Sets the protection flag of the VM. This will prevent the remove operation.", "optional" : 1, - "description" : "Sets the protection flag of the VM. This will prevent the remove operation." + "type" : "boolean" }, - "memory" : { - "description" : "Amount of RAM for the VM in MB. This is the maximum available memory when you use the balloon device.", - "default" : 512, - "type" : "integer", + "reboot" : { + "default" : 1, + "description" : "Allow reboot. If set to '0' the VM exit on reboot.", "optional" : 1, - "minimum" : 16 - }, - "args" : { - "description" : "Arbitrary arguments passed to kvm, for example:\n\nargs: -no-reboot -no-hpet\n\nNOTE: this option is for experts only.\n", - "type" : "string", - "optional" : 1 - }, - "background_delay" : { - "minimum" : 1, - "description" : "Time to wait for the task to finish. We return 'null' if the task finish within that time.", - "maximum" : 30, - "type" : "integer", - "optional" : 1 + "type" : "boolean" }, - "cpu" : { - "description" : "Emulated CPU type.", - "type" : "string", + "revert" : { + "description" : "Revert a pending change.", + "format" : "pve-configid-list", "optional" : 1, + "type" : "string" + }, + "sata[n]" : { + "description" : "Use volume as SATA hard disk or CD-ROM (n is 0 to 5).", "format" : { - "cputype" : { - "description" : "Emulated CPU type.", + "aio" : { + "description" : "AIO type to use.", "enum" : [ - "486", - "athlon", - "pentium", - "pentium2", - "pentium3", - "coreduo", - "core2duo", - "kvm32", - "kvm64", - "qemu32", - "qemu64", - "phenom", - "Conroe", - "Penryn", - "Nehalem", - "Westmere", - "SandyBridge", - "IvyBridge", - "Haswell", - "Haswell-noTSX", - "Broadwell", - "Broadwell-noTSX", - "Opteron_G1", - "Opteron_G2", - "Opteron_G3", - "Opteron_G4", - "Opteron_G5", - "host" + "native", + "threads" ], - "default" : "kvm64", - "type" : "string", - "format_description" : "cputype", - "default_key" : 1 + "format_description" : "native|threads", + "optional" : 1, + "type" : "string" }, - "hidden" : { - "description" : "Do not identify as a KVM virtual machine.", - "default" : 0, + "backup" : { + "description" : "Whether the drive should be included when making backups.", + "format_description" : "on|off", "optional" : 1, "type" : "boolean" - } - } - }, - "scsihw" : { - "type" : "string", - "optional" : 1, - "default" : "lsi", - "enum" : [ - "lsi", - "lsi53c810", - "virtio-scsi-pci", - "virtio-scsi-single", - "megasas", - "pvscsi" - ], - "description" : "scsi controller model" - }, - "usb[n]" : { - "format" : { - "usb3" : { - "format_description" : "yes|no", - "description" : "Specifies whether if given host option is a USB3 device or port", + }, + "bps" : { + "description" : "Maximum r/w speed speed in bytes per second.", + "format_description" : "bps", "optional" : 1, - "type" : "boolean" + "type" : "integer" }, - "host" : { - "description" : "The Host USB device or port or the value spice", - "type" : "string", - "format_description" : "HOSTUSBDEVICE|spice", - "format" : "pve-qm-usb-device", - "default_key" : 1 - } - }, - "description" : "Configure an USB device (n is 0 to 4). This can be used to\npass-through usb devices to the guest. HOSTUSBDEVICE syntax is:\n\n'bus-port(.port)*' (decimal numbers) or\n'vendor_id:product_id' (hexadeciaml numbers) or\n'spice'\n\nYou can use the 'lsusb -t' command to list existing usb devices.\n\nNOTE: This option allows direct access to host hardware. So it is no longer possible to migrate such machines - use with special care.\n\nThe value 'spice' can be used to add a usb redirection devices for spice.\n\nThe 'usb3' option determines whether the device is a USB3 device or not (this does currently not work reliably with spice redirection and is then ignored).\n\n", - "optional" : 1, - "type" : "string" - }, - "cdrom" : { - "description" : "This is an alias for option -ide2", - "type" : "string", - "optional" : 1, - "format" : "pve-qm-drive", - "typetext" : "volume" - }, - "skiplock" : { - "type" : "boolean", - "optional" : 1, - "description" : "Ignore locks - only root is allowed to use this option." - }, - "net[n]" : { - "format" : "pve-qm-net", - "type" : "string", - "optional" : 1, - "description" : "Specify network devices.\n\nMODEL is one of: e1000 e1000-82540em e1000-82544gc e1000-82545em i82551 i82557b i82559er ne2k_isa ne2k_pci pcnet rtl8139 virtio vmxnet3\n\nXX:XX:XX:XX:XX:XX should be an unique MAC address. This is\nautomatically generated if not specified.\n\nThe bridge parameter can be used to automatically add the interface to a bridge device. The Proxmox VE standard bridge is called 'vmbr0'.\n\nOption 'rate' is used to limit traffic bandwidth from and to this interface. It is specified as floating point number, unit is 'Megabytes per second'.\n\nIf you specify no bridge, we create a kvm 'user' (NATed) network device, which provides DHCP and DNS services. The following addresses are used:\n\n10.0.2.2 Gateway\n10.0.2.3 DNS Server\n10.0.2.4 SMB Server\n\nThe DHCP server assign addresses to the guest starting from 10.0.2.15.\n\n" - }, - "scsi[n]" : { - "format" : { - "media" : { - "format_description" : "cdrom|disk", - "enum" : [ - "cdrom", - "disk" - ], - "description" : "The drive's media type.", - "type" : "string", + "bps_rd" : { + "description" : "Maximum read speed speed in bytes per second.", + "format_description" : "bps", "optional" : 1, - "default" : "disk" + "type" : "integer" }, - "iothread" : { - "format_description" : "off|on", + "bps_wr" : { + "description" : "Maximum write speed speed in bytes per second.", + "format_description" : "bps", "optional" : 1, - "type" : "boolean", - "description" : "Whether to use iothreads for this drive" + "type" : "integer" }, "cache" : { - "optional" : 1, - "type" : "string", + "description" : "The drive's cache mode", "enum" : [ "none", "writethrough", @@ -5621,71 +5721,40 @@ var pveapi = [ "unsafe", "directsync" ], - "description" : "The drive's cache mode", - "format_description" : "none|writethrough|writeback|unsafe|directsync" - }, - "secs" : { - "description" : "Force the drive's physical geometry to have a specific sector count.", - "type" : "integer", + "format_description" : "none|writethrough|writeback|unsafe|directsync", "optional" : 1, - "format_description" : "count" + "type" : "string" }, - "iops_wr" : { - "description" : "Maximum write I/O speed in operations per second.", - "type" : "integer", + "cyls" : { + "description" : "Force the drive's physical geometry to have a specific cylinder count.", + "format_description" : "count", "optional" : 1, - "format_description" : "iops" + "type" : "integer" }, "detect_zeroes" : { "description" : "Controls whether to detect and try to optimize writes of zeroes.", - "type" : "boolean", - "optional" : 1 - }, - "iops_max" : { - "format_description" : "iops", - "type" : "integer", - "optional" : 1, - "description" : "Maximum unthrottled r/w I/O pool speed in operations per second." - }, - "snapshot" : { - "optional" : 1, - "type" : "boolean", - "description" : "Whether the drive should be included when making snapshots.", - "format_description" : "on|off" - }, - "bps_wr" : { "optional" : 1, - "type" : "integer", - "description" : "Maximum write speed speed in bytes per second.", - "format_description" : "bps" - }, - "mbps_max" : { - "description" : "Maximum unthrottled r/w pool speed in megabytes per second.", - "type" : "number", - "optional" : 1, - "format_description" : "mbps" + "type" : "boolean" }, - "iops_rd" : { - "format_description" : "iops", - "type" : "integer", + "discard" : { + "description" : "Controls whether to pass discard/trim requests to the underlying storage.", + "enum" : [ + "ignore", + "on" + ], + "format_description" : "ignore|on", "optional" : 1, - "description" : "Maximum read I/O speed in operations per second." - }, - "size" : { - "format" : "disk-size", - "description" : "Disk size. This is purely informational and has no effect.", - "type" : "string", - "optional" : 1 + "type" : "string" }, - "iops_rd_max" : { - "format_description" : "iops", - "optional" : 1, - "type" : "integer", - "description" : "Maximum unthrottled read I/O pool speed in operations per second." + "file" : { + "default_key" : 1, + "description" : "The drive's backing volume.", + "format" : "pve-volume-id-or-qm-path", + "format_description" : "volume", + "type" : "string" }, "format" : { - "type" : "string", - "optional" : 1, + "description" : "The drive's backing file's data format.", "enum" : [ "raw", "cow", @@ -5695,326 +5764,246 @@ var pveapi = [ "vmdk", "cloop" ], - "description" : "The drive's backing file's data format.", - "format_description" : "drive format" - }, - "mbps_wr_max" : { - "format_description" : "mbps", - "type" : "number", - "optional" : 1, - "description" : "Maximum unthrottled write pool speed in megabytes per second." - }, - "bps" : { - "description" : "Maximum r/w speed speed in bytes per second.", + "format_description" : "drive format", "optional" : 1, - "type" : "integer", - "format_description" : "bps" + "type" : "string" }, "heads" : { - "format_description" : "count", "description" : "Force the drive's physical geometry to have a specific head count.", + "format_description" : "count", "optional" : 1, "type" : "integer" }, - "serial" : { - "type" : "string", - "optional" : 1, - "description" : "The drive's reported serial number, url-encoded, up to 20 bytes long.", - "format_description" : "serial", - "maxLength" : 60, - "format" : "urlencoded" - }, - "discard" : { - "enum" : [ - "ignore", - "on" - ], - "description" : "Controls whether to pass discard/trim requests to the underlying storage.", - "optional" : 1, - "type" : "string", - "format_description" : "ignore|on" - }, - "mbps_rd_max" : { - "description" : "Maximum unthrottled read pool speed in megabytes per second.", - "type" : "number", + "iops" : { + "description" : "Maximum r/w I/O speed in operations per second.", + "format_description" : "iops", "optional" : 1, - "format_description" : "mbps" + "type" : "integer" }, - "mbps_rd" : { - "type" : "number", + "iops_max" : { + "description" : "Maximum unthrottled r/w I/O pool speed in operations per second.", + "format_description" : "iops", "optional" : 1, - "description" : "Maximum read speed speed in megabytes per second.", - "format_description" : "mbps" + "type" : "integer" }, - "mbps_wr" : { - "format_description" : "mbps", + "iops_rd" : { + "description" : "Maximum read I/O speed in operations per second.", + "format_description" : "iops", "optional" : 1, - "type" : "number", - "description" : "Maximum write speed speed in megabytes per second." - }, - "file" : { - "format" : "pve-volume-id-or-qm-path", - "format_description" : "volume", - "default_key" : 1, - "description" : "The drive's backing volume.", - "type" : "string" + "type" : "integer" }, - "iops" : { - "type" : "integer", + "iops_rd_max" : { + "description" : "Maximum unthrottled read I/O pool speed in operations per second.", + "format_description" : "iops", "optional" : 1, - "description" : "Maximum r/w I/O speed in operations per second.", - "format_description" : "iops" - }, - "werror" : { - "format_description" : "enospc|ignore|report|stop", - "description" : "Write error action.", - "enum" : [ - "enospc", - "ignore", - "report", - "stop" - ], - "type" : "string", - "optional" : 1 + "type" : "integer" }, - "aio" : { - "format_description" : "native|threads", - "enum" : [ - "native", - "threads" - ], - "description" : "AIO type to use.", + "iops_wr" : { + "description" : "Maximum write I/O speed in operations per second.", + "format_description" : "iops", "optional" : 1, - "type" : "string" + "type" : "integer" }, "iops_wr_max" : { "description" : "Maximum unthrottled write I/O pool speed in operations per second.", - "type" : "integer", + "format_description" : "iops", "optional" : 1, - "format_description" : "iops" + "type" : "integer" }, - "backup" : { - "format_description" : "on|off", - "type" : "boolean", + "mbps" : { + "description" : "Maximum r/w speed speed in megabytes per second.", + "format_description" : "mbps", "optional" : 1, - "description" : "Whether the drive should be included when making backups." + "type" : "number" }, - "bps_rd" : { - "type" : "integer", - "optional" : 1, - "description" : "Maximum read speed speed in bytes per second.", - "format_description" : "bps" + "mbps_max" : { + "description" : "Maximum unthrottled r/w pool speed in megabytes per second.", + "format_description" : "mbps", + "optional" : 1, + "type" : "number" }, - "queues" : { - "minimum" : 2, - "format_description" : "nbqueues", - "type" : "integer", + "mbps_rd" : { + "description" : "Maximum read speed speed in megabytes per second.", + "format_description" : "mbps", "optional" : 1, - "description" : "Number of queues." + "type" : "number" }, - "cyls" : { - "format_description" : "count", - "description" : "Force the drive's physical geometry to have a specific cylinder count.", + "mbps_rd_max" : { + "description" : "Maximum unthrottled read pool speed in megabytes per second.", + "format_description" : "mbps", "optional" : 1, - "type" : "integer" + "type" : "number" }, - "mbps" : { + "mbps_wr" : { + "description" : "Maximum write speed speed in megabytes per second.", "format_description" : "mbps", - "description" : "Maximum r/w speed speed in megabytes per second.", - "type" : "number", - "optional" : 1 + "optional" : 1, + "type" : "number" }, - "volume" : { - "alias" : "file" + "mbps_wr_max" : { + "description" : "Maximum unthrottled write pool speed in megabytes per second.", + "format_description" : "mbps", + "optional" : 1, + "type" : "number" }, - "trans" : { - "format_description" : "none|lba|auto", + "media" : { + "default" : "disk", + "description" : "The drive's media type.", + "enum" : [ + "cdrom", + "disk" + ], + "format_description" : "cdrom|disk", "optional" : 1, - "type" : "string", - "description" : "Force disk geometry bios translation mode.", + "type" : "string" + }, + "rerror" : { + "description" : "Read error action.", "enum" : [ - "none", - "lba", - "auto" - ] - } - }, - "type" : "string", - "optional" : 1, - "description" : "Use volume as SCSI hard disk or CD-ROM (n is 0 to 13)." - }, - "virtio[n]" : { - "type" : "string", - "optional" : 1, - "description" : "Use volume as VIRTIO hard disk (n is 0 to 15).", - "format" : { - "cyls" : { - "description" : "Force the drive's physical geometry to have a specific cylinder count.", + "ignore", + "report", + "stop" + ], + "format_description" : "ignore|report|stop", "optional" : 1, - "type" : "integer", - "format_description" : "count" + "type" : "string" }, - "mbps" : { - "description" : "Maximum r/w speed speed in megabytes per second.", - "type" : "number", + "secs" : { + "description" : "Force the drive's physical geometry to have a specific sector count.", + "format_description" : "count", "optional" : 1, - "format_description" : "mbps" + "type" : "integer" }, - "bps_rd" : { - "description" : "Maximum read speed speed in bytes per second.", + "serial" : { + "description" : "The drive's reported serial number, url-encoded, up to 20 bytes long.", + "format" : "urlencoded", + "format_description" : "serial", + "maxLength" : 60, "optional" : 1, - "type" : "integer", - "format_description" : "bps" + "type" : "string" }, - "trans" : { - "format_description" : "none|lba|auto", + "size" : { + "description" : "Disk size. This is purely informational and has no effect.", + "format" : "disk-size", + "optional" : 1, + "type" : "string" + }, + "snapshot" : { + "description" : "Whether the drive should be included when making snapshots.", + "format_description" : "on|off", "optional" : 1, - "type" : "string", + "type" : "boolean" + }, + "trans" : { + "description" : "Force disk geometry bios translation mode.", "enum" : [ "none", "lba", "auto" ], - "description" : "Force disk geometry bios translation mode." + "format_description" : "none|lba|auto", + "optional" : 1, + "type" : "string" }, "volume" : { "alias" : "file" }, - "file" : { - "default_key" : 1, - "format" : "pve-volume-id-or-qm-path", - "format_description" : "volume", - "type" : "string", - "description" : "The drive's backing volume." - }, - "iops" : { - "format_description" : "iops", - "description" : "Maximum r/w I/O speed in operations per second.", - "type" : "integer", - "optional" : 1 - }, - "mbps_rd" : { - "type" : "number", - "optional" : 1, - "description" : "Maximum read speed speed in megabytes per second.", - "format_description" : "mbps" - }, - "mbps_wr" : { - "type" : "number", - "optional" : 1, - "description" : "Maximum write speed speed in megabytes per second.", - "format_description" : "mbps" - }, - "iops_wr_max" : { - "format_description" : "iops", - "description" : "Maximum unthrottled write I/O pool speed in operations per second.", - "type" : "integer", - "optional" : 1 - }, - "backup" : { + "werror" : { + "description" : "Write error action.", + "enum" : [ + "enospc", + "ignore", + "report", + "stop" + ], + "format_description" : "enospc|ignore|report|stop", "optional" : 1, - "type" : "boolean", - "description" : "Whether the drive should be included when making backups.", - "format_description" : "on|off" - }, + "type" : "string" + } + }, + "optional" : 1, + "type" : "string" + }, + "scsi[n]" : { + "description" : "Use volume as SCSI hard disk or CD-ROM (n is 0 to 13).", + "format" : { "aio" : { - "type" : "string", - "optional" : 1, "description" : "AIO type to use.", "enum" : [ "native", "threads" ], - "format_description" : "native|threads" - }, - "werror" : { - "type" : "string", + "format_description" : "native|threads", "optional" : 1, - "enum" : [ - "enospc", - "ignore", - "report", - "stop" - ], - "description" : "Write error action.", - "format_description" : "enospc|ignore|report|stop" + "type" : "string" }, - "iops_rd" : { - "description" : "Maximum read I/O speed in operations per second.", + "backup" : { + "description" : "Whether the drive should be included when making backups.", + "format_description" : "on|off", "optional" : 1, - "type" : "integer", - "format_description" : "iops" + "type" : "boolean" }, - "size" : { - "type" : "string", + "bps" : { + "description" : "Maximum r/w speed speed in bytes per second.", + "format_description" : "bps", "optional" : 1, - "description" : "Disk size. This is purely informational and has no effect.", - "format" : "disk-size" + "type" : "integer" }, - "mbps_max" : { - "description" : "Maximum unthrottled r/w pool speed in megabytes per second.", - "type" : "number", + "bps_rd" : { + "description" : "Maximum read speed speed in bytes per second.", + "format_description" : "bps", "optional" : 1, - "format_description" : "mbps" + "type" : "integer" }, "bps_wr" : { + "description" : "Maximum write speed speed in bytes per second.", "format_description" : "bps", - "type" : "integer", "optional" : 1, - "description" : "Maximum write speed speed in bytes per second." + "type" : "integer" }, - "discard" : { + "cache" : { + "description" : "The drive's cache mode", "enum" : [ - "ignore", - "on" + "none", + "writethrough", + "writeback", + "unsafe", + "directsync" ], - "description" : "Controls whether to pass discard/trim requests to the underlying storage.", - "optional" : 1, - "type" : "string", - "format_description" : "ignore|on" - }, - "mbps_rd_max" : { - "type" : "number", + "format_description" : "none|writethrough|writeback|unsafe|directsync", "optional" : 1, - "description" : "Maximum unthrottled read pool speed in megabytes per second.", - "format_description" : "mbps" + "type" : "string" }, - "heads" : { + "cyls" : { + "description" : "Force the drive's physical geometry to have a specific cylinder count.", "format_description" : "count", - "type" : "integer", - "optional" : 1, - "description" : "Force the drive's physical geometry to have a specific head count." - }, - "serial" : { - "format_description" : "serial", - "format" : "urlencoded", - "maxLength" : 60, - "description" : "The drive's reported serial number, url-encoded, up to 20 bytes long.", "optional" : 1, - "type" : "string" + "type" : "integer" }, - "iops_rd_max" : { - "type" : "integer", + "detect_zeroes" : { + "description" : "Controls whether to detect and try to optimize writes of zeroes.", "optional" : 1, - "description" : "Maximum unthrottled read I/O pool speed in operations per second.", - "format_description" : "iops" + "type" : "boolean" }, - "mbps_wr_max" : { - "description" : "Maximum unthrottled write pool speed in megabytes per second.", - "type" : "number", + "discard" : { + "description" : "Controls whether to pass discard/trim requests to the underlying storage.", + "enum" : [ + "ignore", + "on" + ], + "format_description" : "ignore|on", "optional" : 1, - "format_description" : "mbps" + "type" : "string" }, - "bps" : { - "format_description" : "bps", - "type" : "integer", - "optional" : 1, - "description" : "Maximum r/w speed speed in bytes per second." + "file" : { + "default_key" : 1, + "description" : "The drive's backing volume.", + "format" : "pve-volume-id-or-qm-path", + "format_description" : "volume", + "type" : "string" }, "format" : { - "format_description" : "drive format", - "type" : "string", - "optional" : 1, + "description" : "The drive's backing file's data format.", "enum" : [ "raw", "cow", @@ -6024,336 +6013,385 @@ var pveapi = [ "vmdk", "cloop" ], - "description" : "The drive's backing file's data format." + "format_description" : "drive format", + "optional" : 1, + "type" : "string" }, - "secs" : { + "heads" : { + "description" : "Force the drive's physical geometry to have a specific head count.", "format_description" : "count", - "description" : "Force the drive's physical geometry to have a specific sector count.", "optional" : 1, "type" : "integer" }, - "iops_wr" : { + "iops" : { + "description" : "Maximum r/w I/O speed in operations per second.", "format_description" : "iops", - "description" : "Maximum write I/O speed in operations per second.", - "type" : "integer", - "optional" : 1 + "optional" : 1, + "type" : "integer" }, - "detect_zeroes" : { + "iops_max" : { + "description" : "Maximum unthrottled r/w I/O pool speed in operations per second.", + "format_description" : "iops", "optional" : 1, - "type" : "boolean", - "description" : "Controls whether to detect and try to optimize writes of zeroes." + "type" : "integer" }, - "rerror" : { - "description" : "Read error action.", - "enum" : [ - "ignore", - "report", - "stop" - ], + "iops_rd" : { + "description" : "Maximum read I/O speed in operations per second.", + "format_description" : "iops", "optional" : 1, - "type" : "string", - "format_description" : "ignore|report|stop" + "type" : "integer" }, - "cache" : { - "description" : "The drive's cache mode", - "enum" : [ - "none", - "writethrough", - "writeback", - "unsafe", - "directsync" - ], - "type" : "string", + "iops_rd_max" : { + "description" : "Maximum unthrottled read I/O pool speed in operations per second.", + "format_description" : "iops", + "optional" : 1, + "type" : "integer" + }, + "iops_wr" : { + "description" : "Maximum write I/O speed in operations per second.", + "format_description" : "iops", "optional" : 1, - "format_description" : "none|writethrough|writeback|unsafe|directsync" + "type" : "integer" + }, + "iops_wr_max" : { + "description" : "Maximum unthrottled write I/O pool speed in operations per second.", + "format_description" : "iops", + "optional" : 1, + "type" : "integer" }, "iothread" : { - "format_description" : "off|on", "description" : "Whether to use iothreads for this drive", + "format_description" : "off|on", "optional" : 1, "type" : "boolean" }, + "mbps" : { + "description" : "Maximum r/w speed speed in megabytes per second.", + "format_description" : "mbps", + "optional" : 1, + "type" : "number" + }, + "mbps_max" : { + "description" : "Maximum unthrottled r/w pool speed in megabytes per second.", + "format_description" : "mbps", + "optional" : 1, + "type" : "number" + }, + "mbps_rd" : { + "description" : "Maximum read speed speed in megabytes per second.", + "format_description" : "mbps", + "optional" : 1, + "type" : "number" + }, + "mbps_rd_max" : { + "description" : "Maximum unthrottled read pool speed in megabytes per second.", + "format_description" : "mbps", + "optional" : 1, + "type" : "number" + }, + "mbps_wr" : { + "description" : "Maximum write speed speed in megabytes per second.", + "format_description" : "mbps", + "optional" : 1, + "type" : "number" + }, + "mbps_wr_max" : { + "description" : "Maximum unthrottled write pool speed in megabytes per second.", + "format_description" : "mbps", + "optional" : 1, + "type" : "number" + }, "media" : { + "default" : "disk", + "description" : "The drive's media type.", "enum" : [ "cdrom", "disk" ], - "description" : "The drive's media type.", - "type" : "string", + "format_description" : "cdrom|disk", "optional" : 1, - "default" : "disk", - "format_description" : "cdrom|disk" + "type" : "string" + }, + "queues" : { + "description" : "Number of queues.", + "format_description" : "nbqueues", + "minimum" : 2, + "optional" : 1, + "type" : "integer" + }, + "secs" : { + "description" : "Force the drive's physical geometry to have a specific sector count.", + "format_description" : "count", + "optional" : 1, + "type" : "integer" + }, + "serial" : { + "description" : "The drive's reported serial number, url-encoded, up to 20 bytes long.", + "format" : "urlencoded", + "format_description" : "serial", + "maxLength" : 60, + "optional" : 1, + "type" : "string" + }, + "size" : { + "description" : "Disk size. This is purely informational and has no effect.", + "format" : "disk-size", + "optional" : 1, + "type" : "string" }, "snapshot" : { "description" : "Whether the drive should be included when making snapshots.", + "format_description" : "on|off", "optional" : 1, - "type" : "boolean", - "format_description" : "on|off" + "type" : "boolean" }, - "iops_max" : { - "format_description" : "iops", - "type" : "integer", + "trans" : { + "description" : "Force disk geometry bios translation mode.", + "enum" : [ + "none", + "lba", + "auto" + ], + "format_description" : "none|lba|auto", + "optional" : 1, + "type" : "string" + }, + "volume" : { + "alias" : "file" + }, + "werror" : { + "description" : "Write error action.", + "enum" : [ + "enospc", + "ignore", + "report", + "stop" + ], + "format_description" : "enospc|ignore|report|stop", "optional" : 1, - "description" : "Maximum unthrottled r/w I/O pool speed in operations per second." + "type" : "string" } - } - }, - "vga" : { + }, "optional" : 1, - "type" : "string", + "type" : "string" + }, + "scsihw" : { + "default" : "lsi", + "description" : "scsi controller model", "enum" : [ - "std", - "cirrus", - "vmware", - "qxl", - "serial0", - "serial1", - "serial2", - "serial3", - "qxl2", - "qxl3", - "qxl4" + "lsi", + "lsi53c810", + "virtio-scsi-pci", + "virtio-scsi-single", + "megasas", + "pvscsi" ], - "description" : "Select the VGA type. If you want to use high resolution modes (>= 1280x1024x16) then you should use the options 'std' or 'vmware'. Default is 'std' for win8/win7/w2k8, and 'cirrus' for other OS types. The 'qxl' option enables the SPICE display sever. For win* OS you can select how many independent displays you want, Linux guests can add displays them self. You can also run without any graphic card, using a serial device as terminal." + "optional" : 1, + "type" : "string" }, - "balloon" : { + "serial[n]" : { + "description" : "Create a serial device inside the VM (n is 0 to 3), and pass through a host serial device (i.e. /dev/ttyS0), or create a unix socket on the host side (use 'qm terminal' to open a terminal connection).\n\nNOTE: If you pass through a host serial device, it is no longer possible to migrate such machines - use with special care.\n\nExperimental: user reported problems with this option.\n", "optional" : 1, - "type" : "integer", - "description" : "Amount of target RAM for the VM in MB. Using zero disables the ballon driver.", - "minimum" : 0 + "pattern" : "(/dev/.+|socket)", + "type" : "string" }, - "smp" : { - "description" : "The number of CPUs. Please use option -sockets instead.", - "default" : 1, + "shares" : { + "default" : 1000, + "description" : "Amount of memory shares for auto-ballooning. The larger the number is, the more memory this VM gets. Number is relative to weights of all other running VMs. Using zero disables auto-ballooning", + "maximum" : 50000, + "minimum" : 0, "optional" : 1, - "type" : "integer", - "minimum" : 1 + "type" : "integer" }, - "machine" : { - "description" : "Specific the Qemu machine type.", - "pattern" : "(pc|pc(-i440fx)?-\\d+\\.\\d+(\\.pxe)?|q35|pc-q35-\\d+\\.\\d+(\\.pxe)?)", + "skiplock" : { + "description" : "Ignore locks - only root is allowed to use this option.", "optional" : 1, - "type" : "string", - "maxLength" : 40 + "type" : "boolean" }, - "delete" : { - "format" : "pve-configid-list", + "smbios1" : { + "description" : "Specify SMBIOS type 1 fields.", + "format" : "pve-qm-smbios1", + "maxLength" : 256, "optional" : 1, - "type" : "string", - "description" : "A list of settings you want to delete." + "type" : "string" }, - "cores" : { + "smp" : { + "default" : 1, + "description" : "The number of CPUs. Please use option -sockets instead.", "minimum" : 1, - "description" : "The number of cores per socket.", - "type" : "integer", "optional" : 1, - "default" : 1 + "type" : "integer" }, - "name" : { - "description" : "Set a name for the VM. Only used on the configuration web interface.", - "type" : "string", + "sockets" : { + "default" : 1, + "description" : "The number of CPU sockets.", + "minimum" : 1, "optional" : 1, - "format" : "dns-name" + "type" : "integer" }, - "agent" : { - "default" : 0, + "startdate" : { + "default" : "now", + "description" : "Set the initial date of the real time clock. Valid format for date are: 'now' or '2006-06-17T16:01:21' or '2006-06-17'.", "optional" : 1, - "type" : "boolean", - "description" : "Enable/disable Qemu GuestAgent." - }, - "digest" : { - "maxLength" : 40, - "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", + "pattern" : "(now|\\d{4}-\\d{1,2}-\\d{1,2}(T\\d{1,2}:\\d{1,2}:\\d{1,2})?)", "type" : "string", - "optional" : 1 + "typetext" : "(now | YYYY-MM-DD | YYYY-MM-DDTHH:MM:SS)" }, "startup" : { - "optional" : 1, - "type" : "string", "description" : "Startup and shutdown behavior. Order is a non-negative number defining the general startup order. Shutdown in done with reverse ordering. Additionally you can set the 'up' or 'down' delay in seconds, which specifies a delay to wait before the next VM is started or stopped.", - "typetext" : "[[order=]\\d+] [,up=\\d+] [,down=\\d+] ", - "format" : "pve-startup-order" - }, - "onboot" : { - "type" : "boolean", + "format" : "pve-startup-order", "optional" : 1, - "default" : 0, - "description" : "Specifies whether a VM will be started during system bootup." - }, - "freeze" : { - "description" : "Freeze CPU at startup (use 'c' monitor command to start execution).", - "type" : "boolean", - "optional" : 1 + "type" : "string", + "typetext" : "[[order=]\\d+] [,up=\\d+] [,down=\\d+] " }, - "sockets" : { - "type" : "integer", - "optional" : 1, + "tablet" : { "default" : 1, - "description" : "The number of CPU sockets.", - "minimum" : 1 - }, - "vcpus" : { - "description" : "Number of hotplugged vcpus.", - "default" : 0, + "description" : "Enable/disable the USB tablet device. This device is usually needed to allow absolute mouse positioning with VNC. Else the mouse runs out of sync with normal VNC clients. If you're running lots of console-only guests on one host, you may consider disabling this to save some context switches. This is turned off by default if you use spice (-vga=qxl).", "optional" : 1, - "type" : "integer", - "minimum" : 1 + "type" : "boolean" }, - "serial[n]" : { - "type" : "string", + "tdf" : { + "default" : 0, + "description" : "Enable/disable time drift fix.", "optional" : 1, - "pattern" : "(/dev/.+|socket)", - "description" : "Create a serial device inside the VM (n is 0 to 3), and pass through a host serial device (i.e. /dev/ttyS0), or create a unix socket on the host side (use 'qm terminal' to open a terminal connection).\n\nNOTE: If you pass through a host serial device, it is no longer possible to migrate such machines - use with special care.\n\nExperimental: user reported problems with this option.\n" + "type" : "boolean" }, - "description" : { - "type" : "string", + "template" : { + "default" : 0, + "description" : "Enable/disable Template.", "optional" : 1, - "description" : "Description for the VM. Only used on the configuration web interface. This is saved as comment inside the configuration file." + "type" : "boolean" }, - "acpi" : { - "description" : "Enable/disable ACPI.", + "unused[n]" : { + "description" : "Reference to unused volumes.", + "format" : "pve-volume-id", "optional" : 1, - "type" : "boolean", - "default" : 1 + "type" : "string" }, - "migrate_downtime" : { - "description" : "Set maximum tolerated downtime (in seconds) for migrations.", - "type" : "number", + "usb[n]" : { + "description" : "Configure an USB device (n is 0 to 4). This can be used to\npass-through usb devices to the guest. HOSTUSBDEVICE syntax is:\n\n'bus-port(.port)*' (decimal numbers) or\n'vendor_id:product_id' (hexadeciaml numbers) or\n'spice'\n\nYou can use the 'lsusb -t' command to list existing usb devices.\n\nNOTE: This option allows direct access to host hardware. So it is no longer possible to migrate such machines - use with special care.\n\nThe value 'spice' can be used to add a usb redirection devices for spice.\n\nThe 'usb3' option determines whether the device is a USB3 device or not (this does currently not work reliably with spice redirection and is then ignored).\n\n", + "format" : { + "host" : { + "default_key" : 1, + "description" : "The Host USB device or port or the value spice", + "format" : "pve-qm-usb-device", + "format_description" : "HOSTUSBDEVICE|spice", + "type" : "string" + }, + "usb3" : { + "description" : "Specifies whether if given host option is a USB3 device or port", + "format_description" : "yes|no", + "optional" : 1, + "type" : "boolean" + } + }, "optional" : 1, - "default" : 0.1, - "minimum" : 0 - }, - "parallel[n]" : { - "description" : "Map host parallel devices (n is 0 to 2).\n\nNOTE: This option allows direct access to host hardware. So it is no longer possible to migrate such machines - use with special care.\n\nExperimental: user reported problems with this option.\n", - "pattern" : "/dev/parport\\d+|/dev/usb/lp\\d+", - "type" : "string", - "optional" : 1 + "type" : "string" }, - "hotplug" : { - "format" : "pve-hotplug-features", - "default" : "network,disk,usb", - "type" : "string", + "vcpus" : { + "default" : 0, + "description" : "Number of hotplugged vcpus.", + "minimum" : 1, "optional" : 1, - "description" : "Selectively enable hotplug features. This is a comma separated list of hotplug features: 'network', 'disk', 'cpu', 'memory' and 'usb'. Use '0' to disable hotplug completely. Value '1' is an alias for the default 'network,disk,usb'." + "type" : "integer" }, - "watchdog" : { + "vga" : { + "description" : "Select the VGA type. If you want to use high resolution modes (>= 1280x1024x16) then you should use the options 'std' or 'vmware'. Default is 'std' for win8/win7/w2k8, and 'cirrus' for other OS types. The 'qxl' option enables the SPICE display sever. For win* OS you can select how many independent displays you want, Linux guests can add displays them self. You can also run without any graphic card, using a serial device as terminal.", + "enum" : [ + "std", + "cirrus", + "vmware", + "qxl", + "serial0", + "serial1", + "serial2", + "serial3", + "qxl2", + "qxl3", + "qxl4" + ], "optional" : 1, - "type" : "string", - "description" : "Create a virtual hardware watchdog device. Once enabled (by a guest action), the watchdog must be periodically polled by an agent inside the guest or else the watchdog will reset the guest (or execute the respective action specified)", - "format" : "pve-qm-watchdog" + "type" : "string" }, - "ide[n]" : { - "optional" : 1, - "type" : "string", - "description" : "Use volume as IDE hard disk or CD-ROM (n is 0 to 3).", + "virtio[n]" : { + "description" : "Use volume as VIRTIO hard disk (n is 0 to 15).", "format" : { - "volume" : { - "alias" : "file" - }, - "trans" : { - "format_description" : "none|lba|auto", + "aio" : { + "description" : "AIO type to use.", "enum" : [ - "none", - "lba", - "auto" + "native", + "threads" ], - "description" : "Force disk geometry bios translation mode.", + "format_description" : "native|threads", "optional" : 1, "type" : "string" }, - "bps_rd" : { - "format_description" : "bps", - "description" : "Maximum read speed speed in bytes per second.", - "type" : "integer", - "optional" : 1 - }, - "cyls" : { - "format_description" : "count", - "description" : "Force the drive's physical geometry to have a specific cylinder count.", - "type" : "integer", - "optional" : 1 + "backup" : { + "description" : "Whether the drive should be included when making backups.", + "format_description" : "on|off", + "optional" : 1, + "type" : "boolean" }, - "mbps" : { - "format_description" : "mbps", - "description" : "Maximum r/w speed speed in megabytes per second.", - "type" : "number", - "optional" : 1 + "bps" : { + "description" : "Maximum r/w speed speed in bytes per second.", + "format_description" : "bps", + "optional" : 1, + "type" : "integer" }, - "werror" : { - "format_description" : "enospc|ignore|report|stop", + "bps_rd" : { + "description" : "Maximum read speed speed in bytes per second.", + "format_description" : "bps", "optional" : 1, - "type" : "string", - "enum" : [ - "enospc", - "ignore", - "report", - "stop" - ], - "description" : "Write error action." + "type" : "integer" }, - "aio" : { + "bps_wr" : { + "description" : "Maximum write speed speed in bytes per second.", + "format_description" : "bps", "optional" : 1, - "type" : "string", - "description" : "AIO type to use.", + "type" : "integer" + }, + "cache" : { + "description" : "The drive's cache mode", "enum" : [ - "native", - "threads" + "none", + "writethrough", + "writeback", + "unsafe", + "directsync" ], - "format_description" : "native|threads" - }, - "iops_wr_max" : { - "description" : "Maximum unthrottled write I/O pool speed in operations per second.", + "format_description" : "none|writethrough|writeback|unsafe|directsync", "optional" : 1, - "type" : "integer", - "format_description" : "iops" + "type" : "string" }, - "backup" : { - "format_description" : "on|off", - "type" : "boolean", + "cyls" : { + "description" : "Force the drive's physical geometry to have a specific cylinder count.", + "format_description" : "count", "optional" : 1, - "description" : "Whether the drive should be included when making backups." - }, - "mbps_rd" : { - "format_description" : "mbps", - "description" : "Maximum read speed speed in megabytes per second.", - "type" : "number", - "optional" : 1 + "type" : "integer" }, - "mbps_wr" : { - "format_description" : "mbps", - "description" : "Maximum write speed speed in megabytes per second.", - "type" : "number", - "optional" : 1 + "detect_zeroes" : { + "description" : "Controls whether to detect and try to optimize writes of zeroes.", + "optional" : 1, + "type" : "boolean" }, - "model" : { - "type" : "string", + "discard" : { + "description" : "Controls whether to pass discard/trim requests to the underlying storage.", + "enum" : [ + "ignore", + "on" + ], + "format_description" : "ignore|on", "optional" : 1, - "description" : "The drive's reported model name, url-encoded, up to 40 bytes long.", - "format_description" : "model", - "format" : "urlencoded", - "maxLength" : 120 + "type" : "string" }, "file" : { - "type" : "string", - "description" : "The drive's backing volume.", "default_key" : 1, + "description" : "The drive's backing volume.", "format" : "pve-volume-id-or-qm-path", - "format_description" : "volume" - }, - "iops" : { - "description" : "Maximum r/w I/O speed in operations per second.", - "optional" : 1, - "type" : "integer", - "format_description" : "iops" - }, - "mbps_wr_max" : { - "description" : "Maximum unthrottled write pool speed in megabytes per second.", - "optional" : 1, - "type" : "number", - "format_description" : "mbps" + "format_description" : "volume", + "type" : "string" }, "format" : { - "format_description" : "drive format", "description" : "The drive's backing file's data format.", "enum" : [ "raw", @@ -6364,455 +6402,471 @@ var pveapi = [ "vmdk", "cloop" ], + "format_description" : "drive format", "optional" : 1, "type" : "string" }, - "bps" : { - "type" : "integer", + "heads" : { + "description" : "Force the drive's physical geometry to have a specific head count.", + "format_description" : "count", "optional" : 1, - "description" : "Maximum r/w speed speed in bytes per second.", - "format_description" : "bps" + "type" : "integer" }, - "iops_rd_max" : { + "iops" : { + "description" : "Maximum r/w I/O speed in operations per second.", "format_description" : "iops", - "type" : "integer", "optional" : 1, - "description" : "Maximum unthrottled read I/O pool speed in operations per second." + "type" : "integer" }, - "heads" : { - "format_description" : "count", - "description" : "Force the drive's physical geometry to have a specific head count.", + "iops_max" : { + "description" : "Maximum unthrottled r/w I/O pool speed in operations per second.", + "format_description" : "iops", "optional" : 1, "type" : "integer" }, - "serial" : { - "format_description" : "serial", - "format" : "urlencoded", - "maxLength" : 60, - "type" : "string", + "iops_rd" : { + "description" : "Maximum read I/O speed in operations per second.", + "format_description" : "iops", "optional" : 1, - "description" : "The drive's reported serial number, url-encoded, up to 20 bytes long." + "type" : "integer" }, - "discard" : { - "description" : "Controls whether to pass discard/trim requests to the underlying storage.", - "enum" : [ - "ignore", - "on" - ], + "iops_rd_max" : { + "description" : "Maximum unthrottled read I/O pool speed in operations per second.", + "format_description" : "iops", "optional" : 1, - "type" : "string", - "format_description" : "ignore|on" + "type" : "integer" }, - "mbps_rd_max" : { - "format_description" : "mbps", + "iops_wr" : { + "description" : "Maximum write I/O speed in operations per second.", + "format_description" : "iops", "optional" : 1, - "type" : "number", - "description" : "Maximum unthrottled read pool speed in megabytes per second." + "type" : "integer" }, - "bps_wr" : { - "format_description" : "bps", - "description" : "Maximum write speed speed in bytes per second.", + "iops_wr_max" : { + "description" : "Maximum unthrottled write I/O pool speed in operations per second.", + "format_description" : "iops", "optional" : 1, "type" : "integer" }, - "mbps_max" : { + "iothread" : { + "description" : "Whether to use iothreads for this drive", + "format_description" : "off|on", + "optional" : 1, + "type" : "boolean" + }, + "mbps" : { + "description" : "Maximum r/w speed speed in megabytes per second.", "format_description" : "mbps", + "optional" : 1, + "type" : "number" + }, + "mbps_max" : { "description" : "Maximum unthrottled r/w pool speed in megabytes per second.", - "type" : "number", - "optional" : 1 + "format_description" : "mbps", + "optional" : 1, + "type" : "number" }, - "iops_rd" : { - "description" : "Maximum read I/O speed in operations per second.", + "mbps_rd" : { + "description" : "Maximum read speed speed in megabytes per second.", + "format_description" : "mbps", "optional" : 1, - "type" : "integer", - "format_description" : "iops" + "type" : "number" }, - "size" : { - "description" : "Disk size. This is purely informational and has no effect.", - "type" : "string", + "mbps_rd_max" : { + "description" : "Maximum unthrottled read pool speed in megabytes per second.", + "format_description" : "mbps", "optional" : 1, - "format" : "disk-size" + "type" : "number" }, - "iops_max" : { - "type" : "integer", + "mbps_wr" : { + "description" : "Maximum write speed speed in megabytes per second.", + "format_description" : "mbps", "optional" : 1, - "description" : "Maximum unthrottled r/w I/O pool speed in operations per second.", - "format_description" : "iops" + "type" : "number" }, - "snapshot" : { - "description" : "Whether the drive should be included when making snapshots.", - "type" : "boolean", + "mbps_wr_max" : { + "description" : "Maximum unthrottled write pool speed in megabytes per second.", + "format_description" : "mbps", "optional" : 1, - "format_description" : "on|off" + "type" : "number" }, "media" : { - "format_description" : "cdrom|disk", - "type" : "string", - "optional" : 1, "default" : "disk", + "description" : "The drive's media type.", "enum" : [ "cdrom", "disk" ], - "description" : "The drive's media type." + "format_description" : "cdrom|disk", + "optional" : 1, + "type" : "string" }, "rerror" : { + "description" : "Read error action.", "enum" : [ "ignore", "report", "stop" ], - "description" : "Read error action.", - "type" : "string", + "format_description" : "ignore|report|stop", "optional" : 1, - "format_description" : "ignore|report|stop" + "type" : "string" }, - "cache" : { - "format_description" : "none|writethrough|writeback|unsafe|directsync", - "description" : "The drive's cache mode", - "enum" : [ - "none", - "writethrough", - "writeback", - "unsafe", - "directsync" - ], + "secs" : { + "description" : "Force the drive's physical geometry to have a specific sector count.", + "format_description" : "count", + "optional" : 1, + "type" : "integer" + }, + "serial" : { + "description" : "The drive's reported serial number, url-encoded, up to 20 bytes long.", + "format" : "urlencoded", + "format_description" : "serial", + "maxLength" : 60, "optional" : 1, "type" : "string" }, - "iops_wr" : { - "type" : "integer", + "size" : { + "description" : "Disk size. This is purely informational and has no effect.", + "format" : "disk-size", "optional" : 1, - "description" : "Maximum write I/O speed in operations per second.", - "format_description" : "iops" + "type" : "string" }, - "secs" : { - "description" : "Force the drive's physical geometry to have a specific sector count.", + "snapshot" : { + "description" : "Whether the drive should be included when making snapshots.", + "format_description" : "on|off", "optional" : 1, - "type" : "integer", - "format_description" : "count" + "type" : "boolean" }, - "detect_zeroes" : { + "trans" : { + "description" : "Force disk geometry bios translation mode.", + "enum" : [ + "none", + "lba", + "auto" + ], + "format_description" : "none|lba|auto", + "optional" : 1, + "type" : "string" + }, + "volume" : { + "alias" : "file" + }, + "werror" : { + "description" : "Write error action.", + "enum" : [ + "enospc", + "ignore", + "report", + "stop" + ], + "format_description" : "enospc|ignore|report|stop", "optional" : 1, - "type" : "boolean", - "description" : "Controls whether to detect and try to optimize writes of zeroes." + "type" : "string" } - } - }, - "lock" : { - "type" : "string", - "optional" : 1, - "enum" : [ - "migrate", - "backup", - "snapshot", - "rollback" - ], - "description" : "Lock/unlock the VM." - }, - "hostpci[n]" : { - "format" : "pve-qm-hostpci", - "type" : "string", - "optional" : 1, - "description" : "Map host pci devices. HOSTPCIDEVICE syntax is:\n\n'bus:dev.func' (hexadecimal numbers)\n\nYou can us the 'lspci' command to list existing pci devices.\n\nThe 'rombar' option determines whether or not the device's ROM will be visible in the guest's memory map (default is 'on').\n\nNOTE: This option allows direct access to host hardware. So it is no longer possible to migrate such machines - use with special care.\n\nExperimental: user reported problems with this option.\n" - }, - "keyboard" : { - "description" : "Keybord layout for vnc server. Default is read from the datacenter configuration file.", - "enum" : [ - "da", - "sv", - "en-gb", - "lt", - "is", - "mk", - "pl", - "hu", - "fr-be", - "pt-br", - "de-ch", - "nl", - "no", - "tr", - "sl", - "de", - "fr-ca", - "ja", - "es", - "it", - "pt", - "fr", - "en-us", - "fi", - "fr-ch" - ], - "default" : "en-us", - "type" : "string", - "optional" : 1 - }, - "bootdisk" : { - "type" : "string", - "optional" : 1, - "pattern" : "(ide|sata|scsi|virtio)\\d+", - "description" : "Enable booting from specified disk.", - "format" : "pve-qm-bootdisk" - }, - "revert" : { - "description" : "Revert a pending change.", - "optional" : 1, - "type" : "string", - "format" : "pve-configid-list" - }, - "reboot" : { - "description" : "Allow reboot. If set to '0' the VM exit on reboot.", - "default" : 1, - "type" : "boolean", - "optional" : 1 - }, - "cpuunits" : { - "description" : "CPU weight for a VM. Argument is used in the kernel fair scheduler. The larger the number is, the more CPU time this VM gets. Number is relative to weights of all the other running VMs.\n\nNOTE: You can disable fair-scheduler configuration by setting this to 0.", - "maximum" : 500000, - "default" : 1000, - "optional" : 1, - "type" : "integer", - "minimum" : 0 - }, - "numa" : { - "description" : "Enable/disable NUMA.", - "default" : 0, - "optional" : 1, - "type" : "boolean" - }, - "smbios1" : { - "description" : "Specify SMBIOS type 1 fields.", + }, "optional" : 1, - "type" : "string", - "format" : "pve-qm-smbios1", - "maxLength" : 256 + "type" : "string" }, "vmid" : { "description" : "The (unique) ID of the VM.", - "type" : "integer", "format" : "pve-vmid", - "minimum" : 1 - } - }, - "additionalProperties" : 0 - }, - "name" : "update_vm_async", - "protected" : 1 - }, - "GET" : { - "returns" : { - "type" : "object", - "properties" : { - "digest" : { - "description" : "SHA1 digest of configuration file. This can be used to prevent concurrent modifications.", - "type" : "string" - } - } - }, - "method" : "GET", - "name" : "vm_config", - "parameters" : { - "properties" : { - "node" : { - "description" : "The cluster node name.", - "type" : "string", - "format" : "pve-node" + "minimum" : 1, + "type" : "integer" }, - "current" : { - "description" : "Get current values (instead of pending values).", + "watchdog" : { + "description" : "Create a virtual hardware watchdog device. Once enabled (by a guest action), the watchdog must be periodically polled by an agent inside the guest or else the watchdog will reset the guest (or execute the respective action specified)", + "format" : "pve-qm-watchdog", "optional" : 1, - "type" : "boolean", - "default" : 0 - }, - "vmid" : { - "format" : "pve-vmid", - "minimum" : 1, - "type" : "integer", - "description" : "The (unique) ID of the VM." + "type" : "string" } - }, - "additionalProperties" : 0 + } }, "permissions" : { "check" : [ "perm", "/vms/{vmid}", [ - "VM.Audit" - ] + "VM.Config.Disk", + "VM.Config.CDROM", + "VM.Config.CPU", + "VM.Config.Memory", + "VM.Config.Network", + "VM.Config.HWType", + "VM.Config.Options" + ], + "any", + 1 ] }, + "protected" : 1, "proxyto" : "node", - "description" : "Get current virtual machine configuration. This does not include pending configuration changes (see 'pending' API)." + "returns" : { + "optional" : 1, + "type" : "string" + } }, "PUT" : { + "description" : "Set virtual machine options (synchrounous API) - You should consider using the POST method instead for any actions involving hotplug or storage allocation.", + "method" : "PUT", + "name" : "update_vm", "parameters" : { "additionalProperties" : 0, "properties" : { - "numa" : { - "description" : "Enable/disable NUMA.", - "type" : "boolean", - "optional" : 1, - "default" : 0 - }, - "cpuunits" : { - "type" : "integer", + "acpi" : { + "default" : 1, + "description" : "Enable/disable ACPI.", "optional" : 1, - "maximum" : 500000, - "default" : 1000, - "description" : "CPU weight for a VM. Argument is used in the kernel fair scheduler. The larger the number is, the more CPU time this VM gets. Number is relative to weights of all the other running VMs.\n\nNOTE: You can disable fair-scheduler configuration by setting this to 0.", - "minimum" : 0 - }, - "vmid" : { - "type" : "integer", - "description" : "The (unique) ID of the VM.", - "format" : "pve-vmid", - "minimum" : 1 + "type" : "boolean" }, - "smbios1" : { - "format" : "pve-qm-smbios1", - "maxLength" : 256, - "type" : "string", + "agent" : { + "default" : 0, + "description" : "Enable/disable Qemu GuestAgent.", "optional" : 1, - "description" : "Specify SMBIOS type 1 fields." - }, - "bootdisk" : { - "format" : "pve-qm-bootdisk", - "description" : "Enable booting from specified disk.", - "pattern" : "(ide|sata|scsi|virtio)\\d+", - "type" : "string", - "optional" : 1 + "type" : "boolean" }, - "revert" : { - "format" : "pve-configid-list", - "description" : "Revert a pending change.", + "args" : { + "description" : "Arbitrary arguments passed to kvm, for example:\n\nargs: -no-reboot -no-hpet\n\nNOTE: this option is for experts only.\n", "optional" : 1, "type" : "string" }, - "reboot" : { - "description" : "Allow reboot. If set to '0' the VM exit on reboot.", - "default" : 1, + "autostart" : { + "default" : 0, + "description" : "Automatic restart after crash (currently ignored).", "optional" : 1, "type" : "boolean" }, - "lock" : { + "balloon" : { + "description" : "Amount of target RAM for the VM in MB. Using zero disables the ballon driver.", + "minimum" : 0, + "optional" : 1, + "type" : "integer" + }, + "bios" : { + "default" : "seabios", + "description" : "Select BIOS implementation.", "enum" : [ - "migrate", - "backup", - "snapshot", - "rollback" + "seabios", + "ovmf" ], - "description" : "Lock/unlock the VM.", "optional" : 1, "type" : "string" }, - "hostpci[n]" : { - "description" : "Map host pci devices. HOSTPCIDEVICE syntax is:\n\n'bus:dev.func' (hexadecimal numbers)\n\nYou can us the 'lspci' command to list existing pci devices.\n\nThe 'rombar' option determines whether or not the device's ROM will be visible in the guest's memory map (default is 'on').\n\nNOTE: This option allows direct access to host hardware. So it is no longer possible to migrate such machines - use with special care.\n\nExperimental: user reported problems with this option.\n", - "type" : "string", + "boot" : { + "default" : "cdn", + "description" : "Boot on floppy (a), hard disk (c), CD-ROM (d), or network (n).", "optional" : 1, - "format" : "pve-qm-hostpci" + "pattern" : "[acdn]{1,4}", + "type" : "string" }, - "keyboard" : { - "enum" : [ - "da", - "sv", - "en-gb", - "lt", - "is", - "mk", - "pl", - "hu", - "fr-be", - "pt-br", - "de-ch", - "nl", - "no", - "tr", - "sl", - "de", - "fr-ca", - "ja", - "es", - "it", - "pt", - "fr", - "en-us", - "fi", - "fr-ch" - ], - "description" : "Keybord layout for vnc server. Default is read from the datacenter configuration file.", + "bootdisk" : { + "description" : "Enable booting from specified disk.", + "format" : "pve-qm-bootdisk", + "optional" : 1, + "pattern" : "(ide|sata|scsi|virtio)\\d+", + "type" : "string" + }, + "cdrom" : { + "description" : "This is an alias for option -ide2", + "format" : "pve-qm-drive", "optional" : 1, "type" : "string", - "default" : "en-us" + "typetext" : "volume" + }, + "cores" : { + "default" : 1, + "description" : "The number of cores per socket.", + "minimum" : 1, + "optional" : 1, + "type" : "integer" + }, + "cpu" : { + "description" : "Emulated CPU type.", + "format" : { + "cputype" : { + "default" : "kvm64", + "default_key" : 1, + "description" : "Emulated CPU type.", + "enum" : [ + "486", + "athlon", + "pentium", + "pentium2", + "pentium3", + "coreduo", + "core2duo", + "kvm32", + "kvm64", + "qemu32", + "qemu64", + "phenom", + "Conroe", + "Penryn", + "Nehalem", + "Westmere", + "SandyBridge", + "IvyBridge", + "Haswell", + "Haswell-noTSX", + "Broadwell", + "Broadwell-noTSX", + "Opteron_G1", + "Opteron_G2", + "Opteron_G3", + "Opteron_G4", + "Opteron_G5", + "host" + ], + "format_description" : "cputype", + "type" : "string" + }, + "hidden" : { + "default" : 0, + "description" : "Do not identify as a KVM virtual machine.", + "optional" : 1, + "type" : "boolean" + } + }, + "optional" : 1, + "type" : "string" + }, + "cpulimit" : { + "default" : 0, + "description" : "Limit of CPU usage.\n\nNOTE: If the computer has 2 CPUs, it has total of '2' CPU time. Value '0' indicates no CPU limit.", + "maximum" : 128, + "minimum" : 0, + "optional" : 1, + "type" : "number" + }, + "cpuunits" : { + "default" : 1000, + "description" : "CPU weight for a VM. Argument is used in the kernel fair scheduler. The larger the number is, the more CPU time this VM gets. Number is relative to weights of all the other running VMs.\n\nNOTE: You can disable fair-scheduler configuration by setting this to 0.", + "maximum" : 500000, + "minimum" : 0, + "optional" : 1, + "type" : "integer" + }, + "delete" : { + "description" : "A list of settings you want to delete.", + "format" : "pve-configid-list", + "optional" : 1, + "type" : "string" + }, + "description" : { + "description" : "Description for the VM. Only used on the configuration web interface. This is saved as comment inside the configuration file.", + "optional" : 1, + "type" : "string" + }, + "digest" : { + "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", + "maxLength" : 40, + "optional" : 1, + "type" : "string" + }, + "force" : { + "description" : "Force physical removal. Without this, we simple remove the disk from the config file and create an additional configuration entry called 'unused[n]', which contains the volume ID. Unlink of unused[n] always cause physical removal.", + "optional" : 1, + "requires" : "delete", + "type" : "boolean" + }, + "freeze" : { + "description" : "Freeze CPU at startup (use 'c' monitor command to start execution).", + "optional" : 1, + "type" : "boolean" + }, + "hostpci[n]" : { + "description" : "Map host pci devices. HOSTPCIDEVICE syntax is:\n\n'bus:dev.func' (hexadecimal numbers)\n\nYou can us the 'lspci' command to list existing pci devices.\n\nThe 'rombar' option determines whether or not the device's ROM will be visible in the guest's memory map (default is 'on').\n\nNOTE: This option allows direct access to host hardware. So it is no longer possible to migrate such machines - use with special care.\n\nExperimental: user reported problems with this option.\n", + "format" : "pve-qm-hostpci", + "optional" : 1, + "type" : "string" }, "hotplug" : { - "format" : "pve-hotplug-features", - "description" : "Selectively enable hotplug features. This is a comma separated list of hotplug features: 'network', 'disk', 'cpu', 'memory' and 'usb'. Use '0' to disable hotplug completely. Value '1' is an alias for the default 'network,disk,usb'.", "default" : "network,disk,usb", + "description" : "Selectively enable hotplug features. This is a comma separated list of hotplug features: 'network', 'disk', 'cpu', 'memory' and 'usb'. Use '0' to disable hotplug completely. Value '1' is an alias for the default 'network,disk,usb'.", + "format" : "pve-hotplug-features", "optional" : 1, "type" : "string" }, "ide[n]" : { - "type" : "string", - "optional" : 1, "description" : "Use volume as IDE hard disk or CD-ROM (n is 0 to 3).", "format" : { - "mbps_max" : { - "format_description" : "mbps", - "description" : "Maximum unthrottled r/w pool speed in megabytes per second.", + "aio" : { + "description" : "AIO type to use.", + "enum" : [ + "native", + "threads" + ], + "format_description" : "native|threads", "optional" : 1, - "type" : "number" + "type" : "string" }, - "size" : { - "format" : "disk-size", + "backup" : { + "description" : "Whether the drive should be included when making backups.", + "format_description" : "on|off", + "optional" : 1, + "type" : "boolean" + }, + "bps" : { + "description" : "Maximum r/w speed speed in bytes per second.", + "format_description" : "bps", "optional" : 1, - "type" : "string", - "description" : "Disk size. This is purely informational and has no effect." + "type" : "integer" }, - "iops_rd" : { - "format_description" : "iops", - "type" : "integer", + "bps_rd" : { + "description" : "Maximum read speed speed in bytes per second.", + "format_description" : "bps", "optional" : 1, - "description" : "Maximum read I/O speed in operations per second." + "type" : "integer" }, "bps_wr" : { - "format_description" : "bps", "description" : "Maximum write speed speed in bytes per second.", - "type" : "integer", - "optional" : 1 + "format_description" : "bps", + "optional" : 1, + "type" : "integer" }, - "mbps_rd_max" : { + "cache" : { + "description" : "The drive's cache mode", + "enum" : [ + "none", + "writethrough", + "writeback", + "unsafe", + "directsync" + ], + "format_description" : "none|writethrough|writeback|unsafe|directsync", "optional" : 1, - "type" : "number", - "description" : "Maximum unthrottled read pool speed in megabytes per second.", - "format_description" : "mbps" + "type" : "string" + }, + "cyls" : { + "description" : "Force the drive's physical geometry to have a specific cylinder count.", + "format_description" : "count", + "optional" : 1, + "type" : "integer" + }, + "detect_zeroes" : { + "description" : "Controls whether to detect and try to optimize writes of zeroes.", + "optional" : 1, + "type" : "boolean" }, "discard" : { - "format_description" : "ignore|on", "description" : "Controls whether to pass discard/trim requests to the underlying storage.", "enum" : [ "ignore", "on" ], - "type" : "string", - "optional" : 1 - }, - "bps" : { - "type" : "integer", + "format_description" : "ignore|on", "optional" : 1, - "description" : "Maximum r/w speed speed in bytes per second.", - "format_description" : "bps" + "type" : "string" }, - "mbps_wr_max" : { - "format_description" : "mbps", - "type" : "number", - "optional" : 1, - "description" : "Maximum unthrottled write pool speed in megabytes per second." + "file" : { + "default_key" : 1, + "description" : "The drive's backing volume.", + "format" : "pve-volume-id-or-qm-path", + "format_description" : "volume", + "type" : "string" }, "format" : { - "format_description" : "drive format", + "description" : "The drive's backing file's data format.", "enum" : [ "raw", "cow", @@ -6822,381 +6876,444 @@ var pveapi = [ "vmdk", "cloop" ], - "description" : "The drive's backing file's data format.", - "type" : "string", - "optional" : 1 - }, - "iops_rd_max" : { - "description" : "Maximum unthrottled read I/O pool speed in operations per second.", - "type" : "integer", - "optional" : 1, - "format_description" : "iops" - }, - "serial" : { - "description" : "The drive's reported serial number, url-encoded, up to 20 bytes long.", + "format_description" : "drive format", "optional" : 1, - "type" : "string", - "format" : "urlencoded", - "maxLength" : 60, - "format_description" : "serial" + "type" : "string" }, "heads" : { + "description" : "Force the drive's physical geometry to have a specific head count.", "format_description" : "count", "optional" : 1, - "type" : "integer", - "description" : "Force the drive's physical geometry to have a specific head count." + "type" : "integer" }, - "cache" : { - "format_description" : "none|writethrough|writeback|unsafe|directsync", - "enum" : [ - "none", - "writethrough", - "writeback", - "unsafe", - "directsync" - ], - "description" : "The drive's cache mode", - "type" : "string", - "optional" : 1 - }, - "rerror" : { - "format_description" : "ignore|report|stop", - "description" : "Read error action.", - "enum" : [ - "ignore", - "report", - "stop" - ], + "iops" : { + "description" : "Maximum r/w I/O speed in operations per second.", + "format_description" : "iops", "optional" : 1, - "type" : "string" + "type" : "integer" }, - "detect_zeroes" : { + "iops_max" : { + "description" : "Maximum unthrottled r/w I/O pool speed in operations per second.", + "format_description" : "iops", "optional" : 1, - "type" : "boolean", - "description" : "Controls whether to detect and try to optimize writes of zeroes." + "type" : "integer" }, - "iops_wr" : { + "iops_rd" : { + "description" : "Maximum read I/O speed in operations per second.", + "format_description" : "iops", "optional" : 1, - "type" : "integer", - "description" : "Maximum write I/O speed in operations per second.", - "format_description" : "iops" + "type" : "integer" }, - "secs" : { - "description" : "Force the drive's physical geometry to have a specific sector count.", - "type" : "integer", + "iops_rd_max" : { + "description" : "Maximum unthrottled read I/O pool speed in operations per second.", + "format_description" : "iops", "optional" : 1, - "format_description" : "count" + "type" : "integer" }, - "media" : { - "format_description" : "cdrom|disk", - "enum" : [ - "cdrom", - "disk" - ], - "description" : "The drive's media type.", + "iops_wr" : { + "description" : "Maximum write I/O speed in operations per second.", + "format_description" : "iops", "optional" : 1, - "type" : "string", - "default" : "disk" + "type" : "integer" }, - "iops_max" : { - "type" : "integer", + "iops_wr_max" : { + "description" : "Maximum unthrottled write I/O pool speed in operations per second.", + "format_description" : "iops", "optional" : 1, - "description" : "Maximum unthrottled r/w I/O pool speed in operations per second.", - "format_description" : "iops" - }, - "snapshot" : { - "format_description" : "on|off", - "description" : "Whether the drive should be included when making snapshots.", - "type" : "boolean", - "optional" : 1 + "type" : "integer" }, "mbps" : { + "description" : "Maximum r/w speed speed in megabytes per second.", "format_description" : "mbps", - "type" : "number", "optional" : 1, - "description" : "Maximum r/w speed speed in megabytes per second." + "type" : "number" }, - "cyls" : { + "mbps_max" : { + "description" : "Maximum unthrottled r/w pool speed in megabytes per second.", + "format_description" : "mbps", "optional" : 1, - "type" : "integer", - "description" : "Force the drive's physical geometry to have a specific cylinder count.", - "format_description" : "count" + "type" : "number" }, - "bps_rd" : { - "type" : "integer", + "mbps_rd" : { + "description" : "Maximum read speed speed in megabytes per second.", + "format_description" : "mbps", "optional" : 1, - "description" : "Maximum read speed speed in bytes per second.", - "format_description" : "bps" + "type" : "number" }, - "volume" : { - "alias" : "file" + "mbps_rd_max" : { + "description" : "Maximum unthrottled read pool speed in megabytes per second.", + "format_description" : "mbps", + "optional" : 1, + "type" : "number" }, - "trans" : { + "mbps_wr" : { + "description" : "Maximum write speed speed in megabytes per second.", + "format_description" : "mbps", "optional" : 1, - "type" : "string", - "description" : "Force disk geometry bios translation mode.", + "type" : "number" + }, + "mbps_wr_max" : { + "description" : "Maximum unthrottled write pool speed in megabytes per second.", + "format_description" : "mbps", + "optional" : 1, + "type" : "number" + }, + "media" : { + "default" : "disk", + "description" : "The drive's media type.", "enum" : [ - "none", - "lba", - "auto" + "cdrom", + "disk" ], - "format_description" : "none|lba|auto" + "format_description" : "cdrom|disk", + "optional" : 1, + "type" : "string" }, "model" : { + "description" : "The drive's reported model name, url-encoded, up to 40 bytes long.", "format" : "urlencoded", - "maxLength" : 120, "format_description" : "model", - "type" : "string", + "maxLength" : 120, "optional" : 1, - "description" : "The drive's reported model name, url-encoded, up to 40 bytes long." + "type" : "string" }, - "iops" : { - "format_description" : "iops", + "rerror" : { + "description" : "Read error action.", + "enum" : [ + "ignore", + "report", + "stop" + ], + "format_description" : "ignore|report|stop", "optional" : 1, - "type" : "integer", - "description" : "Maximum r/w I/O speed in operations per second." + "type" : "string" }, - "file" : { - "description" : "The drive's backing volume.", - "type" : "string", - "format" : "pve-volume-id-or-qm-path", - "format_description" : "volume", - "default_key" : 1 + "secs" : { + "description" : "Force the drive's physical geometry to have a specific sector count.", + "format_description" : "count", + "optional" : 1, + "type" : "integer" }, - "mbps_wr" : { - "format_description" : "mbps", + "serial" : { + "description" : "The drive's reported serial number, url-encoded, up to 20 bytes long.", + "format" : "urlencoded", + "format_description" : "serial", + "maxLength" : 60, "optional" : 1, - "type" : "number", - "description" : "Maximum write speed speed in megabytes per second." + "type" : "string" }, - "mbps_rd" : { - "description" : "Maximum read speed speed in megabytes per second.", - "type" : "number", + "size" : { + "description" : "Disk size. This is purely informational and has no effect.", + "format" : "disk-size", "optional" : 1, - "format_description" : "mbps" + "type" : "string" }, - "backup" : { + "snapshot" : { + "description" : "Whether the drive should be included when making snapshots.", "format_description" : "on|off", "optional" : 1, - "type" : "boolean", - "description" : "Whether the drive should be included when making backups." + "type" : "boolean" }, - "iops_wr_max" : { - "format_description" : "iops", - "type" : "integer", + "trans" : { + "description" : "Force disk geometry bios translation mode.", + "enum" : [ + "none", + "lba", + "auto" + ], + "format_description" : "none|lba|auto", "optional" : 1, - "description" : "Maximum unthrottled write I/O pool speed in operations per second." + "type" : "string" + }, + "volume" : { + "alias" : "file" }, "werror" : { + "description" : "Write error action.", "enum" : [ "enospc", "ignore", "report", "stop" ], - "description" : "Write error action.", - "type" : "string", + "format_description" : "enospc|ignore|report|stop", "optional" : 1, - "format_description" : "enospc|ignore|report|stop" - }, - "aio" : { - "format_description" : "native|threads", - "enum" : [ - "native", - "threads" - ], - "description" : "AIO type to use.", - "type" : "string", - "optional" : 1 + "type" : "string" } - } + }, + "optional" : 1, + "type" : "string" }, - "watchdog" : { - "description" : "Create a virtual hardware watchdog device. Once enabled (by a guest action), the watchdog must be periodically polled by an agent inside the guest or else the watchdog will reset the guest (or execute the respective action specified)", + "keyboard" : { + "default" : "en-us", + "description" : "Keybord layout for vnc server. Default is read from the datacenter configuration file.", + "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" + ], "optional" : 1, - "type" : "string", - "format" : "pve-qm-watchdog" + "type" : "string" }, - "acpi" : { + "kvm" : { "default" : 1, + "description" : "Enable/disable KVM hardware virtualization.", "optional" : 1, - "type" : "boolean", - "description" : "Enable/disable ACPI." + "type" : "boolean" }, - "migrate_downtime" : { - "minimum" : 0, - "type" : "number", + "localtime" : { + "description" : "Set the real time clock to local time. This is enabled by default if ostype indicates a Microsoft OS.", "optional" : 1, - "default" : 0.1, - "description" : "Set maximum tolerated downtime (in seconds) for migrations." - }, - "parallel[n]" : { - "description" : "Map host parallel devices (n is 0 to 2).\n\nNOTE: This option allows direct access to host hardware. So it is no longer possible to migrate such machines - use with special care.\n\nExperimental: user reported problems with this option.\n", - "pattern" : "/dev/parport\\d+|/dev/usb/lp\\d+", - "type" : "string", - "optional" : 1 - }, - "description" : { - "description" : "Description for the VM. Only used on the configuration web interface. This is saved as comment inside the configuration file.", - "type" : "string", - "optional" : 1 + "type" : "boolean" }, - "vcpus" : { - "default" : 0, + "lock" : { + "description" : "Lock/unlock the VM.", + "enum" : [ + "migrate", + "backup", + "snapshot", + "rollback" + ], "optional" : 1, - "type" : "integer", - "description" : "Number of hotplugged vcpus.", - "minimum" : 1 + "type" : "string" }, - "serial[n]" : { + "machine" : { + "description" : "Specific the Qemu machine type.", + "maxLength" : 40, "optional" : 1, - "type" : "string", - "description" : "Create a serial device inside the VM (n is 0 to 3), and pass through a host serial device (i.e. /dev/ttyS0), or create a unix socket on the host side (use 'qm terminal' to open a terminal connection).\n\nNOTE: If you pass through a host serial device, it is no longer possible to migrate such machines - use with special care.\n\nExperimental: user reported problems with this option.\n", - "pattern" : "(/dev/.+|socket)" + "pattern" : "(pc|pc(-i440fx)?-\\d+\\.\\d+(\\.pxe)?|q35|pc-q35-\\d+\\.\\d+(\\.pxe)?)", + "type" : "string" }, - "digest" : { - "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", - "type" : "string", + "memory" : { + "default" : 512, + "description" : "Amount of RAM for the VM in MB. This is the maximum available memory when you use the balloon device.", + "minimum" : 16, "optional" : 1, - "maxLength" : 40 + "type" : "integer" }, - "startup" : { - "type" : "string", + "migrate_downtime" : { + "default" : 0.1, + "description" : "Set maximum tolerated downtime (in seconds) for migrations.", + "minimum" : 0, "optional" : 1, - "description" : "Startup and shutdown behavior. Order is a non-negative number defining the general startup order. Shutdown in done with reverse ordering. Additionally you can set the 'up' or 'down' delay in seconds, which specifies a delay to wait before the next VM is started or stopped.", - "typetext" : "[[order=]\\d+] [,up=\\d+] [,down=\\d+] ", - "format" : "pve-startup-order" + "type" : "number" }, - "agent" : { - "type" : "boolean", - "optional" : 1, + "migrate_speed" : { "default" : 0, - "description" : "Enable/disable Qemu GuestAgent." + "description" : "Set maximum speed (in MB/s) for migrations. Value 0 is no limit.", + "minimum" : 0, + "optional" : 1, + "type" : "integer" }, - "sockets" : { - "minimum" : 1, - "default" : 1, + "name" : { + "description" : "Set a name for the VM. Only used on the configuration web interface.", + "format" : "dns-name", "optional" : 1, - "type" : "integer", - "description" : "The number of CPU sockets." + "type" : "string" }, - "onboot" : { - "description" : "Specifies whether a VM will be started during system bootup.", - "type" : "boolean", + "net[n]" : { + "description" : "Specify network devices.\n\nMODEL is one of: e1000 e1000-82540em e1000-82544gc e1000-82545em i82551 i82557b i82559er ne2k_isa ne2k_pci pcnet rtl8139 virtio vmxnet3\n\nXX:XX:XX:XX:XX:XX should be an unique MAC address. This is\nautomatically generated if not specified.\n\nThe bridge parameter can be used to automatically add the interface to a bridge device. The Proxmox VE standard bridge is called 'vmbr0'.\n\nOption 'rate' is used to limit traffic bandwidth from and to this interface. It is specified as floating point number, unit is 'Megabytes per second'.\n\nIf you specify no bridge, we create a kvm 'user' (NATed) network device, which provides DHCP and DNS services. The following addresses are used:\n\n10.0.2.2 Gateway\n10.0.2.3 DNS Server\n10.0.2.4 SMB Server\n\nThe DHCP server assign addresses to the guest starting from 10.0.2.15.\n\n", + "format" : "pve-qm-net", "optional" : 1, - "default" : 0 + "type" : "string" }, - "freeze" : { - "description" : "Freeze CPU at startup (use 'c' monitor command to start execution).", + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, + "numa" : { + "default" : 0, + "description" : "Enable/disable NUMA.", "optional" : 1, "type" : "boolean" }, - "cores" : { - "default" : 1, - "type" : "integer", + "numa[n]" : { + "description" : "numa topology", + "format" : { + "cpus" : { + "description" : "CPUs accessing this numa node.", + "format_description" : "id[-id];...", + "pattern" : "(?^:\\d+(?:-\\d+)?(?:;\\d+(?:-\\d+)?)*)", + "type" : "string" + }, + "hostnodes" : { + "description" : "host numa nodes to use", + "format_description" : "id[-id];...", + "optional" : 1, + "pattern" : "(?^:\\d+(?:-\\d+)?(?:;\\d+(?:-\\d+)?)*)", + "type" : "string" + }, + "memory" : { + "description" : "Amount of memory this numa node provides.", + "format_description" : "mb", + "optional" : 1, + "type" : "number" + }, + "policy" : { + "description" : "numa allocation policy.", + "enum" : [ + "preferred", + "bind", + "interleave" + ], + "format_description" : "preferred|bind|interleave", + "optional" : 1, + "type" : "string" + } + }, "optional" : 1, - "description" : "The number of cores per socket.", - "minimum" : 1 + "type" : "string" }, - "delete" : { - "description" : "A list of settings you want to delete.", + "onboot" : { + "default" : 0, + "description" : "Specifies whether a VM will be started during system bootup.", "optional" : 1, - "type" : "string", - "format" : "pve-configid-list" + "type" : "boolean" }, - "name" : { - "format" : "dns-name", - "description" : "Set a name for the VM. Only used on the configuration web interface.", + "ostype" : { + "description" : "Used to enable special optimization/features for specific\noperating systems:\n\nother => unspecified OS\nwxp => Microsoft Windows XP\nw2k => Microsoft Windows 2000\nw2k3 => Microsoft Windows 2003\nw2k8 => Microsoft Windows 2008\nwvista => Microsoft Windows Vista\nwin7 => Microsoft Windows 7\nwin8 => Microsoft Windows 8/2012\nl24 => Linux 2.4 Kernel\nl26 => Linux 2.6/3.X Kernel\nsolaris => solaris/opensolaris/openindiania kernel\n\nother|l24|l26|solaris ... no special behaviour\nwxp|w2k|w2k3|w2k8|wvista|win7|win8 ... use --localtime switch\n", + "enum" : [ + "other", + "wxp", + "w2k", + "w2k3", + "w2k8", + "wvista", + "win7", + "win8", + "l24", + "l26", + "solaris" + ], "optional" : 1, "type" : "string" }, - "smp" : { - "description" : "The number of CPUs. Please use option -sockets instead.", - "default" : 1, + "parallel[n]" : { + "description" : "Map host parallel devices (n is 0 to 2).\n\nNOTE: This option allows direct access to host hardware. So it is no longer possible to migrate such machines - use with special care.\n\nExperimental: user reported problems with this option.\n", "optional" : 1, - "type" : "integer", - "minimum" : 1 + "pattern" : "/dev/parport\\d+|/dev/usb/lp\\d+", + "type" : "string" }, - "machine" : { - "maxLength" : 40, - "type" : "string", + "protection" : { + "default" : 0, + "description" : "Sets the protection flag of the VM. This will prevent the remove operation.", "optional" : 1, - "description" : "Specific the Qemu machine type.", - "pattern" : "(pc|pc(-i440fx)?-\\d+\\.\\d+(\\.pxe)?|q35|pc-q35-\\d+\\.\\d+(\\.pxe)?)" + "type" : "boolean" }, - "net[n]" : { - "description" : "Specify network devices.\n\nMODEL is one of: e1000 e1000-82540em e1000-82544gc e1000-82545em i82551 i82557b i82559er ne2k_isa ne2k_pci pcnet rtl8139 virtio vmxnet3\n\nXX:XX:XX:XX:XX:XX should be an unique MAC address. This is\nautomatically generated if not specified.\n\nThe bridge parameter can be used to automatically add the interface to a bridge device. The Proxmox VE standard bridge is called 'vmbr0'.\n\nOption 'rate' is used to limit traffic bandwidth from and to this interface. It is specified as floating point number, unit is 'Megabytes per second'.\n\nIf you specify no bridge, we create a kvm 'user' (NATed) network device, which provides DHCP and DNS services. The following addresses are used:\n\n10.0.2.2 Gateway\n10.0.2.3 DNS Server\n10.0.2.4 SMB Server\n\nThe DHCP server assign addresses to the guest starting from 10.0.2.15.\n\n", + "reboot" : { + "default" : 1, + "description" : "Allow reboot. If set to '0' the VM exit on reboot.", "optional" : 1, - "type" : "string", - "format" : "pve-qm-net" + "type" : "boolean" }, - "vga" : { - "type" : "string", + "revert" : { + "description" : "Revert a pending change.", + "format" : "pve-configid-list", "optional" : 1, - "description" : "Select the VGA type. If you want to use high resolution modes (>= 1280x1024x16) then you should use the options 'std' or 'vmware'. Default is 'std' for win8/win7/w2k8, and 'cirrus' for other OS types. The 'qxl' option enables the SPICE display sever. For win* OS you can select how many independent displays you want, Linux guests can add displays them self. You can also run without any graphic card, using a serial device as terminal.", - "enum" : [ - "std", - "cirrus", - "vmware", - "qxl", - "serial0", - "serial1", - "serial2", - "serial3", - "qxl2", - "qxl3", - "qxl4" - ] + "type" : "string" }, - "virtio[n]" : { - "type" : "string", - "optional" : 1, - "description" : "Use volume as VIRTIO hard disk (n is 0 to 15).", + "sata[n]" : { + "description" : "Use volume as SATA hard disk or CD-ROM (n is 0 to 5).", "format" : { - "bps_wr" : { + "aio" : { + "description" : "AIO type to use.", + "enum" : [ + "native", + "threads" + ], + "format_description" : "native|threads", + "optional" : 1, + "type" : "string" + }, + "backup" : { + "description" : "Whether the drive should be included when making backups.", + "format_description" : "on|off", + "optional" : 1, + "type" : "boolean" + }, + "bps" : { + "description" : "Maximum r/w speed speed in bytes per second.", "format_description" : "bps", - "description" : "Maximum write speed speed in bytes per second.", "optional" : 1, "type" : "integer" }, - "mbps_max" : { - "type" : "number", + "bps_rd" : { + "description" : "Maximum read speed speed in bytes per second.", + "format_description" : "bps", "optional" : 1, - "description" : "Maximum unthrottled r/w pool speed in megabytes per second.", - "format_description" : "mbps" + "type" : "integer" }, - "iops_rd" : { - "format_description" : "iops", + "bps_wr" : { + "description" : "Maximum write speed speed in bytes per second.", + "format_description" : "bps", "optional" : 1, - "type" : "integer", - "description" : "Maximum read I/O speed in operations per second." + "type" : "integer" }, - "size" : { + "cache" : { + "description" : "The drive's cache mode", + "enum" : [ + "none", + "writethrough", + "writeback", + "unsafe", + "directsync" + ], + "format_description" : "none|writethrough|writeback|unsafe|directsync", "optional" : 1, - "type" : "string", - "description" : "Disk size. This is purely informational and has no effect.", - "format" : "disk-size" + "type" : "string" }, - "mbps_wr_max" : { + "cyls" : { + "description" : "Force the drive's physical geometry to have a specific cylinder count.", + "format_description" : "count", "optional" : 1, - "type" : "number", - "description" : "Maximum unthrottled write pool speed in megabytes per second.", - "format_description" : "mbps" + "type" : "integer" }, - "bps" : { - "format_description" : "bps", - "description" : "Maximum r/w speed speed in bytes per second.", + "detect_zeroes" : { + "description" : "Controls whether to detect and try to optimize writes of zeroes.", "optional" : 1, - "type" : "integer" + "type" : "boolean" }, - "iops_rd_max" : { - "description" : "Maximum unthrottled read I/O pool speed in operations per second.", - "type" : "integer", + "discard" : { + "description" : "Controls whether to pass discard/trim requests to the underlying storage.", + "enum" : [ + "ignore", + "on" + ], + "format_description" : "ignore|on", "optional" : 1, - "format_description" : "iops" + "type" : "string" + }, + "file" : { + "default_key" : 1, + "description" : "The drive's backing volume.", + "format" : "pve-volume-id-or-qm-path", + "format_description" : "volume", + "type" : "string" }, "format" : { - "format_description" : "drive format", "description" : "The drive's backing file's data format.", "enum" : [ "raw", @@ -7207,129 +7324,135 @@ var pveapi = [ "vmdk", "cloop" ], + "format_description" : "drive format", "optional" : 1, "type" : "string" }, "heads" : { - "optional" : 1, - "type" : "integer", "description" : "Force the drive's physical geometry to have a specific head count.", - "format_description" : "count" + "format_description" : "count", + "optional" : 1, + "type" : "integer" }, - "serial" : { + "iops" : { + "description" : "Maximum r/w I/O speed in operations per second.", + "format_description" : "iops", "optional" : 1, - "type" : "string", - "description" : "The drive's reported serial number, url-encoded, up to 20 bytes long.", - "format_description" : "serial", - "format" : "urlencoded", - "maxLength" : 60 + "type" : "integer" }, - "discard" : { - "type" : "string", + "iops_max" : { + "description" : "Maximum unthrottled r/w I/O pool speed in operations per second.", + "format_description" : "iops", "optional" : 1, - "enum" : [ - "ignore", - "on" - ], - "description" : "Controls whether to pass discard/trim requests to the underlying storage.", - "format_description" : "ignore|on" + "type" : "integer" }, - "mbps_rd_max" : { - "type" : "number", + "iops_rd" : { + "description" : "Maximum read I/O speed in operations per second.", + "format_description" : "iops", "optional" : 1, - "description" : "Maximum unthrottled read pool speed in megabytes per second.", - "format_description" : "mbps" + "type" : "integer" }, - "media" : { - "format_description" : "cdrom|disk", - "description" : "The drive's media type.", - "enum" : [ - "cdrom", - "disk" - ], - "default" : "disk", + "iops_rd_max" : { + "description" : "Maximum unthrottled read I/O pool speed in operations per second.", + "format_description" : "iops", "optional" : 1, - "type" : "string" + "type" : "integer" }, - "iothread" : { - "format_description" : "off|on", - "description" : "Whether to use iothreads for this drive", - "type" : "boolean", - "optional" : 1 + "iops_wr" : { + "description" : "Maximum write I/O speed in operations per second.", + "format_description" : "iops", + "optional" : 1, + "type" : "integer" }, - "rerror" : { - "format_description" : "ignore|report|stop", + "iops_wr_max" : { + "description" : "Maximum unthrottled write I/O pool speed in operations per second.", + "format_description" : "iops", + "optional" : 1, + "type" : "integer" + }, + "mbps" : { + "description" : "Maximum r/w speed speed in megabytes per second.", + "format_description" : "mbps", + "optional" : 1, + "type" : "number" + }, + "mbps_max" : { + "description" : "Maximum unthrottled r/w pool speed in megabytes per second.", + "format_description" : "mbps", + "optional" : 1, + "type" : "number" + }, + "mbps_rd" : { + "description" : "Maximum read speed speed in megabytes per second.", + "format_description" : "mbps", + "optional" : 1, + "type" : "number" + }, + "mbps_rd_max" : { + "description" : "Maximum unthrottled read pool speed in megabytes per second.", + "format_description" : "mbps", + "optional" : 1, + "type" : "number" + }, + "mbps_wr" : { + "description" : "Maximum write speed speed in megabytes per second.", + "format_description" : "mbps", + "optional" : 1, + "type" : "number" + }, + "mbps_wr_max" : { + "description" : "Maximum unthrottled write pool speed in megabytes per second.", + "format_description" : "mbps", + "optional" : 1, + "type" : "number" + }, + "media" : { + "default" : "disk", + "description" : "The drive's media type.", + "enum" : [ + "cdrom", + "disk" + ], + "format_description" : "cdrom|disk", "optional" : 1, - "type" : "string", + "type" : "string" + }, + "rerror" : { "description" : "Read error action.", "enum" : [ "ignore", "report", "stop" - ] - }, - "cache" : { - "format_description" : "none|writethrough|writeback|unsafe|directsync", + ], + "format_description" : "ignore|report|stop", "optional" : 1, - "type" : "string", - "description" : "The drive's cache mode", - "enum" : [ - "none", - "writethrough", - "writeback", - "unsafe", - "directsync" - ] + "type" : "string" }, "secs" : { + "description" : "Force the drive's physical geometry to have a specific sector count.", "format_description" : "count", - "type" : "integer", "optional" : 1, - "description" : "Force the drive's physical geometry to have a specific sector count." + "type" : "integer" }, - "iops_wr" : { - "format_description" : "iops", - "type" : "integer", + "serial" : { + "description" : "The drive's reported serial number, url-encoded, up to 20 bytes long.", + "format" : "urlencoded", + "format_description" : "serial", + "maxLength" : 60, "optional" : 1, - "description" : "Maximum write I/O speed in operations per second." - }, - "detect_zeroes" : { - "description" : "Controls whether to detect and try to optimize writes of zeroes.", - "type" : "boolean", - "optional" : 1 + "type" : "string" }, - "iops_max" : { + "size" : { + "description" : "Disk size. This is purely informational and has no effect.", + "format" : "disk-size", "optional" : 1, - "type" : "integer", - "description" : "Maximum unthrottled r/w I/O pool speed in operations per second.", - "format_description" : "iops" + "type" : "string" }, "snapshot" : { - "format_description" : "on|off", "description" : "Whether the drive should be included when making snapshots.", - "type" : "boolean", - "optional" : 1 - }, - "bps_rd" : { - "format_description" : "bps", - "optional" : 1, - "type" : "integer", - "description" : "Maximum read speed speed in bytes per second." - }, - "cyls" : { - "type" : "integer", - "optional" : 1, - "description" : "Force the drive's physical geometry to have a specific cylinder count.", - "format_description" : "count" - }, - "mbps" : { - "format_description" : "mbps", + "format_description" : "on|off", "optional" : 1, - "type" : "number", - "description" : "Maximum r/w speed speed in megabytes per second." - }, - "volume" : { - "alias" : "file" + "type" : "boolean" }, "trans" : { "description" : "Force disk geometry bios translation mode.", @@ -7338,115 +7461,109 @@ var pveapi = [ "lba", "auto" ], + "format_description" : "none|lba|auto", "optional" : 1, - "type" : "string", - "format_description" : "none|lba|auto" - }, - "mbps_rd" : { - "type" : "number", - "optional" : 1, - "description" : "Maximum read speed speed in megabytes per second.", - "format_description" : "mbps" - }, - "mbps_wr" : { - "type" : "number", - "optional" : 1, - "description" : "Maximum write speed speed in megabytes per second.", - "format_description" : "mbps" - }, - "file" : { - "description" : "The drive's backing volume.", - "type" : "string", - "format" : "pve-volume-id-or-qm-path", - "format_description" : "volume", - "default_key" : 1 + "type" : "string" }, - "iops" : { - "format_description" : "iops", - "type" : "integer", - "optional" : 1, - "description" : "Maximum r/w I/O speed in operations per second." + "volume" : { + "alias" : "file" }, "werror" : { - "optional" : 1, - "type" : "string", + "description" : "Write error action.", "enum" : [ "enospc", "ignore", "report", "stop" ], - "description" : "Write error action.", - "format_description" : "enospc|ignore|report|stop" - }, - "aio" : { - "format_description" : "native|threads", + "format_description" : "enospc|ignore|report|stop", "optional" : 1, - "type" : "string", + "type" : "string" + } + }, + "optional" : 1, + "type" : "string" + }, + "scsi[n]" : { + "description" : "Use volume as SCSI hard disk or CD-ROM (n is 0 to 13).", + "format" : { + "aio" : { "description" : "AIO type to use.", "enum" : [ "native", "threads" - ] - }, - "iops_wr_max" : { - "type" : "integer", + ], + "format_description" : "native|threads", "optional" : 1, - "description" : "Maximum unthrottled write I/O pool speed in operations per second.", - "format_description" : "iops" + "type" : "string" }, "backup" : { - "type" : "boolean", - "optional" : 1, "description" : "Whether the drive should be included when making backups.", - "format_description" : "on|off" - } - } - }, - "balloon" : { - "description" : "Amount of target RAM for the VM in MB. Using zero disables the ballon driver.", - "type" : "integer", - "optional" : 1, - "minimum" : 0 - }, - "scsi[n]" : { - "optional" : 1, - "type" : "string", - "description" : "Use volume as SCSI hard disk or CD-ROM (n is 0 to 13).", - "format" : { - "heads" : { + "format_description" : "on|off", "optional" : 1, - "type" : "integer", - "description" : "Force the drive's physical geometry to have a specific head count.", - "format_description" : "count" + "type" : "boolean" }, - "serial" : { + "bps" : { + "description" : "Maximum r/w speed speed in bytes per second.", + "format_description" : "bps", "optional" : 1, - "type" : "string", - "description" : "The drive's reported serial number, url-encoded, up to 20 bytes long.", - "format_description" : "serial", - "maxLength" : 60, - "format" : "urlencoded" + "type" : "integer" }, - "iops_rd_max" : { - "description" : "Maximum unthrottled read I/O pool speed in operations per second.", + "bps_rd" : { + "description" : "Maximum read speed speed in bytes per second.", + "format_description" : "bps", "optional" : 1, - "type" : "integer", - "format_description" : "iops" + "type" : "integer" }, - "bps" : { + "bps_wr" : { + "description" : "Maximum write speed speed in bytes per second.", + "format_description" : "bps", "optional" : 1, - "type" : "integer", - "description" : "Maximum r/w speed speed in bytes per second.", - "format_description" : "bps" + "type" : "integer" }, - "mbps_wr_max" : { - "type" : "number", + "cache" : { + "description" : "The drive's cache mode", + "enum" : [ + "none", + "writethrough", + "writeback", + "unsafe", + "directsync" + ], + "format_description" : "none|writethrough|writeback|unsafe|directsync", "optional" : 1, - "description" : "Maximum unthrottled write pool speed in megabytes per second.", - "format_description" : "mbps" + "type" : "string" + }, + "cyls" : { + "description" : "Force the drive's physical geometry to have a specific cylinder count.", + "format_description" : "count", + "optional" : 1, + "type" : "integer" + }, + "detect_zeroes" : { + "description" : "Controls whether to detect and try to optimize writes of zeroes.", + "optional" : 1, + "type" : "boolean" + }, + "discard" : { + "description" : "Controls whether to pass discard/trim requests to the underlying storage.", + "enum" : [ + "ignore", + "on" + ], + "format_description" : "ignore|on", + "optional" : 1, + "type" : "string" + }, + "file" : { + "default_key" : 1, + "description" : "The drive's backing volume.", + "format" : "pve-volume-id-or-qm-path", + "format_description" : "volume", + "type" : "string" }, "format" : { + "description" : "The drive's backing file's data format.", "enum" : [ "raw", "cow", @@ -7456,237 +7573,170 @@ var pveapi = [ "vmdk", "cloop" ], - "description" : "The drive's backing file's data format.", - "type" : "string", + "format_description" : "drive format", "optional" : 1, - "format_description" : "drive format" + "type" : "string" }, - "discard" : { - "format_description" : "ignore|on", - "type" : "string", + "heads" : { + "description" : "Force the drive's physical geometry to have a specific head count.", + "format_description" : "count", "optional" : 1, - "description" : "Controls whether to pass discard/trim requests to the underlying storage.", - "enum" : [ - "ignore", - "on" - ] + "type" : "integer" }, - "mbps_rd_max" : { - "format_description" : "mbps", + "iops" : { + "description" : "Maximum r/w I/O speed in operations per second.", + "format_description" : "iops", "optional" : 1, - "type" : "number", - "description" : "Maximum unthrottled read pool speed in megabytes per second." - }, - "bps_wr" : { - "format_description" : "bps", - "description" : "Maximum write speed speed in bytes per second.", - "type" : "integer", - "optional" : 1 + "type" : "integer" }, - "iops_rd" : { + "iops_max" : { + "description" : "Maximum unthrottled r/w I/O pool speed in operations per second.", "format_description" : "iops", - "type" : "integer", "optional" : 1, - "description" : "Maximum read I/O speed in operations per second." + "type" : "integer" }, - "size" : { - "description" : "Disk size. This is purely informational and has no effect.", + "iops_rd" : { + "description" : "Maximum read I/O speed in operations per second.", + "format_description" : "iops", "optional" : 1, - "type" : "string", - "format" : "disk-size" + "type" : "integer" }, - "mbps_max" : { - "format_description" : "mbps", - "type" : "number", + "iops_rd_max" : { + "description" : "Maximum unthrottled read I/O pool speed in operations per second.", + "format_description" : "iops", "optional" : 1, - "description" : "Maximum unthrottled r/w pool speed in megabytes per second." + "type" : "integer" }, - "snapshot" : { + "iops_wr" : { + "description" : "Maximum write I/O speed in operations per second.", + "format_description" : "iops", "optional" : 1, - "type" : "boolean", - "description" : "Whether the drive should be included when making snapshots.", - "format_description" : "on|off" + "type" : "integer" }, - "iops_max" : { + "iops_wr_max" : { + "description" : "Maximum unthrottled write I/O pool speed in operations per second.", "format_description" : "iops", - "description" : "Maximum unthrottled r/w I/O pool speed in operations per second.", - "type" : "integer", - "optional" : 1 + "optional" : 1, + "type" : "integer" }, "iothread" : { + "description" : "Whether to use iothreads for this drive", "format_description" : "off|on", - "type" : "boolean", "optional" : 1, - "description" : "Whether to use iothreads for this drive" + "type" : "boolean" }, - "media" : { - "format_description" : "cdrom|disk", - "enum" : [ - "cdrom", - "disk" - ], - "description" : "The drive's media type.", - "type" : "string", + "mbps" : { + "description" : "Maximum r/w speed speed in megabytes per second.", + "format_description" : "mbps", "optional" : 1, - "default" : "disk" + "type" : "number" }, - "secs" : { - "description" : "Force the drive's physical geometry to have a specific sector count.", - "type" : "integer", + "mbps_max" : { + "description" : "Maximum unthrottled r/w pool speed in megabytes per second.", + "format_description" : "mbps", "optional" : 1, - "format_description" : "count" + "type" : "number" }, - "iops_wr" : { - "format_description" : "iops", - "description" : "Maximum write I/O speed in operations per second.", + "mbps_rd" : { + "description" : "Maximum read speed speed in megabytes per second.", + "format_description" : "mbps", "optional" : 1, - "type" : "integer" + "type" : "number" }, - "detect_zeroes" : { + "mbps_rd_max" : { + "description" : "Maximum unthrottled read pool speed in megabytes per second.", + "format_description" : "mbps", "optional" : 1, - "type" : "boolean", - "description" : "Controls whether to detect and try to optimize writes of zeroes." + "type" : "number" }, - "cache" : { - "type" : "string", + "mbps_wr" : { + "description" : "Maximum write speed speed in megabytes per second.", + "format_description" : "mbps", "optional" : 1, - "description" : "The drive's cache mode", - "enum" : [ - "none", - "writethrough", - "writeback", - "unsafe", - "directsync" - ], - "format_description" : "none|writethrough|writeback|unsafe|directsync" + "type" : "number" }, - "trans" : { + "mbps_wr_max" : { + "description" : "Maximum unthrottled write pool speed in megabytes per second.", + "format_description" : "mbps", "optional" : 1, - "type" : "string", - "description" : "Force disk geometry bios translation mode.", + "type" : "number" + }, + "media" : { + "default" : "disk", + "description" : "The drive's media type.", "enum" : [ - "none", - "lba", - "auto" + "cdrom", + "disk" ], - "format_description" : "none|lba|auto" - }, - "volume" : { - "alias" : "file" - }, - "bps_rd" : { - "format_description" : "bps", + "format_description" : "cdrom|disk", "optional" : 1, - "type" : "integer", - "description" : "Maximum read speed speed in bytes per second." + "type" : "string" }, "queues" : { + "description" : "Number of queues.", "format_description" : "nbqueues", "minimum" : 2, - "description" : "Number of queues.", "optional" : 1, "type" : "integer" }, - "cyls" : { - "description" : "Force the drive's physical geometry to have a specific cylinder count.", - "type" : "integer", + "secs" : { + "description" : "Force the drive's physical geometry to have a specific sector count.", + "format_description" : "count", "optional" : 1, - "format_description" : "count" + "type" : "integer" }, - "mbps" : { - "description" : "Maximum r/w speed speed in megabytes per second.", - "type" : "number", + "serial" : { + "description" : "The drive's reported serial number, url-encoded, up to 20 bytes long.", + "format" : "urlencoded", + "format_description" : "serial", + "maxLength" : 60, "optional" : 1, - "format_description" : "mbps" + "type" : "string" }, - "aio" : { + "size" : { + "description" : "Disk size. This is purely informational and has no effect.", + "format" : "disk-size", + "optional" : 1, + "type" : "string" + }, + "snapshot" : { + "description" : "Whether the drive should be included when making snapshots.", + "format_description" : "on|off", "optional" : 1, - "type" : "string", + "type" : "boolean" + }, + "trans" : { + "description" : "Force disk geometry bios translation mode.", "enum" : [ - "native", - "threads" + "none", + "lba", + "auto" ], - "description" : "AIO type to use.", - "format_description" : "native|threads" + "format_description" : "none|lba|auto", + "optional" : 1, + "type" : "string" + }, + "volume" : { + "alias" : "file" }, "werror" : { - "format_description" : "enospc|ignore|report|stop", - "type" : "string", - "optional" : 1, "description" : "Write error action.", "enum" : [ "enospc", "ignore", "report", "stop" - ] - }, - "iops_wr_max" : { - "format_description" : "iops", - "description" : "Maximum unthrottled write I/O pool speed in operations per second.", - "type" : "integer", - "optional" : 1 - }, - "backup" : { - "format_description" : "on|off", - "description" : "Whether the drive should be included when making backups.", - "type" : "boolean", - "optional" : 1 - }, - "mbps_rd" : { - "format_description" : "mbps", - "optional" : 1, - "type" : "number", - "description" : "Maximum read speed speed in megabytes per second." - }, - "mbps_wr" : { - "format_description" : "mbps", - "type" : "number", + ], + "format_description" : "enospc|ignore|report|stop", "optional" : 1, - "description" : "Maximum write speed speed in megabytes per second." - }, - "file" : { - "format_description" : "volume", - "format" : "pve-volume-id-or-qm-path", - "default_key" : 1, - "description" : "The drive's backing volume.", "type" : "string" - }, - "iops" : { - "optional" : 1, - "type" : "integer", - "description" : "Maximum r/w I/O speed in operations per second.", - "format_description" : "iops" } - } - }, - "protection" : { - "default" : 0, - "optional" : 1, - "type" : "boolean", - "description" : "Sets the protection flag of the VM. This will prevent the remove operation." - }, - "usb[n]" : { - "type" : "string", + }, "optional" : 1, - "description" : "Configure an USB device (n is 0 to 4). This can be used to\npass-through usb devices to the guest. HOSTUSBDEVICE syntax is:\n\n'bus-port(.port)*' (decimal numbers) or\n'vendor_id:product_id' (hexadeciaml numbers) or\n'spice'\n\nYou can use the 'lsusb -t' command to list existing usb devices.\n\nNOTE: This option allows direct access to host hardware. So it is no longer possible to migrate such machines - use with special care.\n\nThe value 'spice' can be used to add a usb redirection devices for spice.\n\nThe 'usb3' option determines whether the device is a USB3 device or not (this does currently not work reliably with spice redirection and is then ignored).\n\n", - "format" : { - "host" : { - "description" : "The Host USB device or port or the value spice", - "type" : "string", - "format_description" : "HOSTUSBDEVICE|spice", - "format" : "pve-qm-usb-device", - "default_key" : 1 - }, - "usb3" : { - "description" : "Specifies whether if given host option is a USB3 device or port", - "optional" : 1, - "type" : "boolean", - "format_description" : "yes|no" - } - } + "type" : "string" }, "scsihw" : { + "default" : "lsi", "description" : "scsi controller model", "enum" : [ "lsi", @@ -7696,330 +7746,172 @@ var pveapi = [ "megasas", "pvscsi" ], - "default" : "lsi", "optional" : 1, "type" : "string" }, - "cdrom" : { + "serial[n]" : { + "description" : "Create a serial device inside the VM (n is 0 to 3), and pass through a host serial device (i.e. /dev/ttyS0), or create a unix socket on the host side (use 'qm terminal' to open a terminal connection).\n\nNOTE: If you pass through a host serial device, it is no longer possible to migrate such machines - use with special care.\n\nExperimental: user reported problems with this option.\n", "optional" : 1, - "type" : "string", - "description" : "This is an alias for option -ide2", - "typetext" : "volume", - "format" : "pve-qm-drive" + "pattern" : "(/dev/.+|socket)", + "type" : "string" }, - "cpu" : { - "description" : "Emulated CPU type.", + "shares" : { + "default" : 1000, + "description" : "Amount of memory shares for auto-ballooning. The larger the number is, the more memory this VM gets. Number is relative to weights of all other running VMs. Using zero disables auto-ballooning", + "maximum" : 50000, + "minimum" : 0, "optional" : 1, - "type" : "string", - "format" : { - "cputype" : { - "default" : "kvm64", - "type" : "string", - "description" : "Emulated CPU type.", - "enum" : [ - "486", - "athlon", - "pentium", - "pentium2", - "pentium3", - "coreduo", - "core2duo", - "kvm32", - "kvm64", - "qemu32", - "qemu64", - "phenom", - "Conroe", - "Penryn", - "Nehalem", - "Westmere", - "SandyBridge", - "IvyBridge", - "Haswell", - "Haswell-noTSX", - "Broadwell", - "Broadwell-noTSX", - "Opteron_G1", - "Opteron_G2", - "Opteron_G3", - "Opteron_G4", - "Opteron_G5", - "host" - ], - "default_key" : 1, - "format_description" : "cputype" - }, - "hidden" : { - "description" : "Do not identify as a KVM virtual machine.", - "optional" : 1, - "type" : "boolean", - "default" : 0 - } - } + "type" : "integer" }, "skiplock" : { "description" : "Ignore locks - only root is allowed to use this option.", - "type" : "boolean", - "optional" : 1 + "optional" : 1, + "type" : "boolean" }, - "memory" : { - "minimum" : 16, - "type" : "integer", + "smbios1" : { + "description" : "Specify SMBIOS type 1 fields.", + "format" : "pve-qm-smbios1", + "maxLength" : 256, "optional" : 1, - "default" : 512, - "description" : "Amount of RAM for the VM in MB. This is the maximum available memory when you use the balloon device." + "type" : "string" }, - "args" : { - "description" : "Arbitrary arguments passed to kvm, for example:\n\nargs: -no-reboot -no-hpet\n\nNOTE: this option is for experts only.\n", + "smp" : { + "default" : 1, + "description" : "The number of CPUs. Please use option -sockets instead.", + "minimum" : 1, "optional" : 1, - "type" : "string" + "type" : "integer" }, - "template" : { + "sockets" : { + "default" : 1, + "description" : "The number of CPU sockets.", + "minimum" : 1, "optional" : 1, - "type" : "boolean", - "default" : 0, - "description" : "Enable/disable Template." + "type" : "integer" }, - "bios" : { - "enum" : [ - "seabios", - "ovmf" - ], - "description" : "Select BIOS implementation.", + "startdate" : { + "default" : "now", + "description" : "Set the initial date of the real time clock. Valid format for date are: 'now' or '2006-06-17T16:01:21' or '2006-06-17'.", + "optional" : 1, + "pattern" : "(now|\\d{4}-\\d{1,2}-\\d{1,2}(T\\d{1,2}:\\d{1,2}:\\d{1,2})?)", "type" : "string", + "typetext" : "(now | YYYY-MM-DD | YYYY-MM-DDTHH:MM:SS)" + }, + "startup" : { + "description" : "Startup and shutdown behavior. Order is a non-negative number defining the general startup order. Shutdown in done with reverse ordering. Additionally you can set the 'up' or 'down' delay in seconds, which specifies a delay to wait before the next VM is started or stopped.", + "format" : "pve-startup-order", "optional" : 1, - "default" : "seabios" + "type" : "string", + "typetext" : "[[order=]\\d+] [,up=\\d+] [,down=\\d+] " }, - "shares" : { - "default" : 1000, - "maximum" : 50000, + "tablet" : { + "default" : 1, + "description" : "Enable/disable the USB tablet device. This device is usually needed to allow absolute mouse positioning with VNC. Else the mouse runs out of sync with normal VNC clients. If you're running lots of console-only guests on one host, you may consider disabling this to save some context switches. This is turned off by default if you use spice (-vga=qxl).", "optional" : 1, - "type" : "integer", - "description" : "Amount of memory shares for auto-ballooning. The larger the number is, the more memory this VM gets. Number is relative to weights of all other running VMs. Using zero disables auto-ballooning", - "minimum" : 0 + "type" : "boolean" }, - "ostype" : { - "enum" : [ - "other", - "wxp", - "w2k", - "w2k3", - "w2k8", - "wvista", - "win7", - "win8", - "l24", - "l26", - "solaris" - ], - "description" : "Used to enable special optimization/features for specific\noperating systems:\n\nother => unspecified OS\nwxp => Microsoft Windows XP\nw2k => Microsoft Windows 2000\nw2k3 => Microsoft Windows 2003\nw2k8 => Microsoft Windows 2008\nwvista => Microsoft Windows Vista\nwin7 => Microsoft Windows 7\nwin8 => Microsoft Windows 8/2012\nl24 => Linux 2.4 Kernel\nl26 => Linux 2.6/3.X Kernel\nsolaris => solaris/opensolaris/openindiania kernel\n\nother|l24|l26|solaris ... no special behaviour\nwxp|w2k|w2k3|w2k8|wvista|win7|win8 ... use --localtime switch\n", + "tdf" : { + "default" : 0, + "description" : "Enable/disable time drift fix.", "optional" : 1, - "type" : "string" + "type" : "boolean" }, - "unused[n]" : { - "type" : "string", + "template" : { + "default" : 0, + "description" : "Enable/disable Template.", "optional" : 1, - "description" : "Reference to unused volumes.", - "format" : "pve-volume-id" + "type" : "boolean" }, - "boot" : { - "description" : "Boot on floppy (a), hard disk (c), CD-ROM (d), or network (n).", - "pattern" : "[acdn]{1,4}", - "default" : "cdn", + "unused[n]" : { + "description" : "Reference to unused volumes.", + "format" : "pve-volume-id", "optional" : 1, "type" : "string" }, - "numa[n]" : { - "description" : "numa topology", - "type" : "string", - "optional" : 1, + "usb[n]" : { + "description" : "Configure an USB device (n is 0 to 4). This can be used to\npass-through usb devices to the guest. HOSTUSBDEVICE syntax is:\n\n'bus-port(.port)*' (decimal numbers) or\n'vendor_id:product_id' (hexadeciaml numbers) or\n'spice'\n\nYou can use the 'lsusb -t' command to list existing usb devices.\n\nNOTE: This option allows direct access to host hardware. So it is no longer possible to migrate such machines - use with special care.\n\nThe value 'spice' can be used to add a usb redirection devices for spice.\n\nThe 'usb3' option determines whether the device is a USB3 device or not (this does currently not work reliably with spice redirection and is then ignored).\n\n", "format" : { - "hostnodes" : { - "format_description" : "id[-id];...", - "type" : "string", - "optional" : 1, - "pattern" : "(?^:\\d+(?:-\\d+)?(?:;\\d+(?:-\\d+)?)*)", - "description" : "host numa nodes to use" - }, - "cpus" : { - "format_description" : "id[-id];...", - "type" : "string", - "description" : "CPUs accessing this numa node.", - "pattern" : "(?^:\\d+(?:-\\d+)?(?:;\\d+(?:-\\d+)?)*)" - }, - "policy" : { - "type" : "string", - "optional" : 1, - "enum" : [ - "preferred", - "bind", - "interleave" - ], - "description" : "numa allocation policy.", - "format_description" : "preferred|bind|interleave" + "host" : { + "default_key" : 1, + "description" : "The Host USB device or port or the value spice", + "format" : "pve-qm-usb-device", + "format_description" : "HOSTUSBDEVICE|spice", + "type" : "string" }, - "memory" : { - "format_description" : "mb", - "description" : "Amount of memory this numa node provides.", + "usb3" : { + "description" : "Specifies whether if given host option is a USB3 device or port", + "format_description" : "yes|no", "optional" : 1, - "type" : "number" + "type" : "boolean" } - } - }, - "autostart" : { - "default" : 0, - "type" : "boolean", + }, "optional" : 1, - "description" : "Automatic restart after crash (currently ignored)." + "type" : "string" }, - "tdf" : { - "optional" : 1, - "type" : "boolean", + "vcpus" : { "default" : 0, - "description" : "Enable/disable time drift fix." - }, - "tablet" : { - "description" : "Enable/disable the USB tablet device. This device is usually needed to allow absolute mouse positioning with VNC. Else the mouse runs out of sync with normal VNC clients. If you're running lots of console-only guests on one host, you may consider disabling this to save some context switches. This is turned off by default if you use spice (-vga=qxl).", - "default" : 1, - "type" : "boolean", - "optional" : 1 - }, - "cpulimit" : { - "description" : "Limit of CPU usage.\n\nNOTE: If the computer has 2 CPUs, it has total of '2' CPU time. Value '0' indicates no CPU limit.", - "type" : "number", + "description" : "Number of hotplugged vcpus.", + "minimum" : 1, "optional" : 1, - "default" : 0, - "maximum" : 128, - "minimum" : 0 + "type" : "integer" }, - "kvm" : { - "default" : 1, - "type" : "boolean", + "vga" : { + "description" : "Select the VGA type. If you want to use high resolution modes (>= 1280x1024x16) then you should use the options 'std' or 'vmware'. Default is 'std' for win8/win7/w2k8, and 'cirrus' for other OS types. The 'qxl' option enables the SPICE display sever. For win* OS you can select how many independent displays you want, Linux guests can add displays them self. You can also run without any graphic card, using a serial device as terminal.", + "enum" : [ + "std", + "cirrus", + "vmware", + "qxl", + "serial0", + "serial1", + "serial2", + "serial3", + "qxl2", + "qxl3", + "qxl4" + ], "optional" : 1, - "description" : "Enable/disable KVM hardware virtualization." + "type" : "string" }, - "sata[n]" : { + "virtio[n]" : { + "description" : "Use volume as VIRTIO hard disk (n is 0 to 15).", "format" : { - "file" : { - "type" : "string", - "description" : "The drive's backing volume.", - "default_key" : 1, - "format" : "pve-volume-id-or-qm-path", - "format_description" : "volume" - }, - "iops" : { - "description" : "Maximum r/w I/O speed in operations per second.", - "type" : "integer", - "optional" : 1, - "format_description" : "iops" - }, - "mbps_rd" : { - "format_description" : "mbps", - "type" : "number", - "optional" : 1, - "description" : "Maximum read speed speed in megabytes per second." - }, - "mbps_wr" : { - "description" : "Maximum write speed speed in megabytes per second.", - "optional" : 1, - "type" : "number", - "format_description" : "mbps" - }, - "iops_wr_max" : { - "type" : "integer", - "optional" : 1, - "description" : "Maximum unthrottled write I/O pool speed in operations per second.", - "format_description" : "iops" - }, - "backup" : { - "format_description" : "on|off", - "description" : "Whether the drive should be included when making backups.", - "type" : "boolean", - "optional" : 1 - }, "aio" : { - "format_description" : "native|threads", - "optional" : 1, - "type" : "string", "description" : "AIO type to use.", "enum" : [ "native", "threads" - ] - }, - "werror" : { - "type" : "string", - "optional" : 1, - "description" : "Write error action.", - "enum" : [ - "enospc", - "ignore", - "report", - "stop" ], - "format_description" : "enospc|ignore|report|stop" + "format_description" : "native|threads", + "optional" : 1, + "type" : "string" }, - "cyls" : { - "type" : "integer", + "backup" : { + "description" : "Whether the drive should be included when making backups.", + "format_description" : "on|off", "optional" : 1, - "description" : "Force the drive's physical geometry to have a specific cylinder count.", - "format_description" : "count" + "type" : "boolean" }, - "mbps" : { - "format_description" : "mbps", + "bps" : { + "description" : "Maximum r/w speed speed in bytes per second.", + "format_description" : "bps", "optional" : 1, - "type" : "number", - "description" : "Maximum r/w speed speed in megabytes per second." + "type" : "integer" }, "bps_rd" : { "description" : "Maximum read speed speed in bytes per second.", - "type" : "integer", - "optional" : 1, - "format_description" : "bps" - }, - "trans" : { - "format_description" : "none|lba|auto", - "enum" : [ - "none", - "lba", - "auto" - ], - "description" : "Force disk geometry bios translation mode.", - "type" : "string", - "optional" : 1 - }, - "volume" : { - "alias" : "file" - }, - "iops_wr" : { - "format_description" : "iops", - "description" : "Maximum write I/O speed in operations per second.", + "format_description" : "bps", "optional" : 1, "type" : "integer" }, - "secs" : { - "format_description" : "count", - "description" : "Force the drive's physical geometry to have a specific sector count.", + "bps_wr" : { + "description" : "Maximum write speed speed in bytes per second.", + "format_description" : "bps", "optional" : 1, "type" : "integer" }, - "detect_zeroes" : { - "description" : "Controls whether to detect and try to optimize writes of zeroes.", - "type" : "boolean", - "optional" : 1 - }, - "rerror" : { - "format_description" : "ignore|report|stop", - "optional" : 1, - "type" : "string", - "enum" : [ - "ignore", - "report", - "stop" - ], - "description" : "Read error action." - }, "cache" : { + "description" : "The drive's cache mode", "enum" : [ "none", "writethrough", @@ -8027,162 +7919,229 @@ var pveapi = [ "unsafe", "directsync" ], - "description" : "The drive's cache mode", + "format_description" : "none|writethrough|writeback|unsafe|directsync", "optional" : 1, - "type" : "string", - "format_description" : "none|writethrough|writeback|unsafe|directsync" + "type" : "string" }, - "media" : { - "description" : "The drive's media type.", + "cyls" : { + "description" : "Force the drive's physical geometry to have a specific cylinder count.", + "format_description" : "count", + "optional" : 1, + "type" : "integer" + }, + "detect_zeroes" : { + "description" : "Controls whether to detect and try to optimize writes of zeroes.", + "optional" : 1, + "type" : "boolean" + }, + "discard" : { + "description" : "Controls whether to pass discard/trim requests to the underlying storage.", "enum" : [ - "cdrom", - "disk" + "ignore", + "on" ], - "default" : "disk", + "format_description" : "ignore|on", "optional" : 1, - "type" : "string", - "format_description" : "cdrom|disk" + "type" : "string" }, - "snapshot" : { - "description" : "Whether the drive should be included when making snapshots.", - "type" : "boolean", + "file" : { + "default_key" : 1, + "description" : "The drive's backing volume.", + "format" : "pve-volume-id-or-qm-path", + "format_description" : "volume", + "type" : "string" + }, + "format" : { + "description" : "The drive's backing file's data format.", + "enum" : [ + "raw", + "cow", + "qcow", + "qed", + "qcow2", + "vmdk", + "cloop" + ], + "format_description" : "drive format", "optional" : 1, - "format_description" : "on|off" + "type" : "string" }, - "iops_max" : { - "type" : "integer", + "heads" : { + "description" : "Force the drive's physical geometry to have a specific head count.", + "format_description" : "count", + "optional" : 1, + "type" : "integer" + }, + "iops" : { + "description" : "Maximum r/w I/O speed in operations per second.", + "format_description" : "iops", "optional" : 1, + "type" : "integer" + }, + "iops_max" : { "description" : "Maximum unthrottled r/w I/O pool speed in operations per second.", - "format_description" : "iops" + "format_description" : "iops", + "optional" : 1, + "type" : "integer" }, "iops_rd" : { + "description" : "Maximum read I/O speed in operations per second.", "format_description" : "iops", - "type" : "integer", "optional" : 1, - "description" : "Maximum read I/O speed in operations per second." + "type" : "integer" }, - "size" : { - "description" : "Disk size. This is purely informational and has no effect.", - "type" : "string", + "iops_rd_max" : { + "description" : "Maximum unthrottled read I/O pool speed in operations per second.", + "format_description" : "iops", + "optional" : 1, + "type" : "integer" + }, + "iops_wr" : { + "description" : "Maximum write I/O speed in operations per second.", + "format_description" : "iops", + "optional" : 1, + "type" : "integer" + }, + "iops_wr_max" : { + "description" : "Maximum unthrottled write I/O pool speed in operations per second.", + "format_description" : "iops", + "optional" : 1, + "type" : "integer" + }, + "iothread" : { + "description" : "Whether to use iothreads for this drive", + "format_description" : "off|on", + "optional" : 1, + "type" : "boolean" + }, + "mbps" : { + "description" : "Maximum r/w speed speed in megabytes per second.", + "format_description" : "mbps", "optional" : 1, - "format" : "disk-size" + "type" : "number" }, "mbps_max" : { "description" : "Maximum unthrottled r/w pool speed in megabytes per second.", - "type" : "number", + "format_description" : "mbps", "optional" : 1, - "format_description" : "mbps" + "type" : "number" }, - "bps_wr" : { - "description" : "Maximum write speed speed in bytes per second.", + "mbps_rd" : { + "description" : "Maximum read speed speed in megabytes per second.", + "format_description" : "mbps", "optional" : 1, - "type" : "integer", - "format_description" : "bps" + "type" : "number" }, - "discard" : { - "description" : "Controls whether to pass discard/trim requests to the underlying storage.", + "mbps_rd_max" : { + "description" : "Maximum unthrottled read pool speed in megabytes per second.", + "format_description" : "mbps", + "optional" : 1, + "type" : "number" + }, + "mbps_wr" : { + "description" : "Maximum write speed speed in megabytes per second.", + "format_description" : "mbps", + "optional" : 1, + "type" : "number" + }, + "mbps_wr_max" : { + "description" : "Maximum unthrottled write pool speed in megabytes per second.", + "format_description" : "mbps", + "optional" : 1, + "type" : "number" + }, + "media" : { + "default" : "disk", + "description" : "The drive's media type.", "enum" : [ - "ignore", - "on" + "cdrom", + "disk" ], - "type" : "string", + "format_description" : "cdrom|disk", "optional" : 1, - "format_description" : "ignore|on" + "type" : "string" }, - "mbps_rd_max" : { - "description" : "Maximum unthrottled read pool speed in megabytes per second.", + "rerror" : { + "description" : "Read error action.", + "enum" : [ + "ignore", + "report", + "stop" + ], + "format_description" : "ignore|report|stop", "optional" : 1, - "type" : "number", - "format_description" : "mbps" + "type" : "string" }, - "heads" : { - "type" : "integer", + "secs" : { + "description" : "Force the drive's physical geometry to have a specific sector count.", + "format_description" : "count", "optional" : 1, - "description" : "Force the drive's physical geometry to have a specific head count.", - "format_description" : "count" + "type" : "integer" }, "serial" : { "description" : "The drive's reported serial number, url-encoded, up to 20 bytes long.", - "optional" : 1, - "type" : "string", "format" : "urlencoded", + "format_description" : "serial", "maxLength" : 60, - "format_description" : "serial" + "optional" : 1, + "type" : "string" }, - "format" : { - "format_description" : "drive format", - "description" : "The drive's backing file's data format.", - "enum" : [ - "raw", - "cow", - "qcow", - "qed", - "qcow2", - "vmdk", - "cloop" - ], - "type" : "string", - "optional" : 1 + "size" : { + "description" : "Disk size. This is purely informational and has no effect.", + "format" : "disk-size", + "optional" : 1, + "type" : "string" }, - "bps" : { + "snapshot" : { + "description" : "Whether the drive should be included when making snapshots.", + "format_description" : "on|off", "optional" : 1, - "type" : "integer", - "description" : "Maximum r/w speed speed in bytes per second.", - "format_description" : "bps" + "type" : "boolean" }, - "iops_rd_max" : { - "description" : "Maximum unthrottled read I/O pool speed in operations per second.", + "trans" : { + "description" : "Force disk geometry bios translation mode.", + "enum" : [ + "none", + "lba", + "auto" + ], + "format_description" : "none|lba|auto", "optional" : 1, - "type" : "integer", - "format_description" : "iops" + "type" : "string" }, - "mbps_wr_max" : { + "volume" : { + "alias" : "file" + }, + "werror" : { + "description" : "Write error action.", + "enum" : [ + "enospc", + "ignore", + "report", + "stop" + ], + "format_description" : "enospc|ignore|report|stop", "optional" : 1, - "type" : "number", - "description" : "Maximum unthrottled write pool speed in megabytes per second.", - "format_description" : "mbps" + "type" : "string" } }, "optional" : 1, - "type" : "string", - "description" : "Use volume as SATA hard disk or CD-ROM (n is 0 to 5)." - }, - "localtime" : { - "description" : "Set the real time clock to local time. This is enabled by default if ostype indicates a Microsoft OS.", - "type" : "boolean", - "optional" : 1 + "type" : "string" }, - "migrate_speed" : { - "description" : "Set maximum speed (in MB/s) for migrations. Value 0 is no limit.", - "default" : 0, - "optional" : 1, - "type" : "integer", - "minimum" : 0 + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" }, - "startdate" : { - "typetext" : "(now | YYYY-MM-DD | YYYY-MM-DDTHH:MM:SS)", - "type" : "string", + "watchdog" : { + "description" : "Create a virtual hardware watchdog device. Once enabled (by a guest action), the watchdog must be periodically polled by an agent inside the guest or else the watchdog will reset the guest (or execute the respective action specified)", + "format" : "pve-qm-watchdog", "optional" : 1, - "default" : "now", - "pattern" : "(now|\\d{4}-\\d{1,2}-\\d{1,2}(T\\d{1,2}:\\d{1,2}:\\d{1,2})?)", - "description" : "Set the initial date of the real time clock. Valid format for date are: 'now' or '2006-06-17T16:01:21' or '2006-06-17'." - }, - "force" : { - "requires" : "delete", - "description" : "Force physical removal. Without this, we simple remove the disk from the config file and create an additional configuration entry called 'unused[n]', which contains the volume ID. Unlink of unused[n] always cause physical removal.", - "type" : "boolean", - "optional" : 1 - }, - "node" : { - "type" : "string", - "description" : "The cluster node name.", - "format" : "pve-node" + "type" : "string" } } }, - "name" : "update_vm", - "protected" : 1, - "method" : "PUT", "permissions" : { "check" : [ "perm", @@ -8200,63 +8159,38 @@ var pveapi = [ 1 ] }, + "protected" : 1, "proxyto" : "node", - "description" : "Set virtual machine options (synchrounous API) - You should consider using the POST method instead for any actions involving hotplug or storage allocation.", "returns" : { "type" : "null" } } }, + "leaf" : 1, + "path" : "/nodes/{node}/qemu/{vmid}/config", "text" : "config" }, { "info" : { "GET" : { - "returns" : { - "type" : "array", - "items" : { - "properties" : { - "key" : { - "description" : "Configuration option name.", - "type" : "string" - }, - "value" : { - "description" : "Current value.", - "optional" : 1, - "type" : "string" - }, - "delete" : { - "description" : "Indicates a pending delete request if present and not 0. The value 2 indicates a force-delete request.", - "type" : "integer", - "optional" : 1, - "maximum" : 2, - "minimum" : 0 - }, - "pending" : { - "type" : "string", - "optional" : 1, - "description" : "Pending value." - } - }, - "type" : "object" - } - }, + "description" : "Get virtual machine configuration, including pending changes.", "method" : "GET", + "name" : "vm_pending", "parameters" : { + "additionalProperties" : 0, "properties" : { "node" : { - "format" : "pve-node", "description" : "The cluster node name.", + "format" : "pve-node", "type" : "string" }, "vmid" : { - "minimum" : 1, + "description" : "The (unique) ID of the VM.", "format" : "pve-vmid", - "type" : "integer", - "description" : "The (unique) ID of the VM." + "minimum" : 1, + "type" : "integer" } - }, - "additionalProperties" : 0 + } }, "permissions" : { "check" : [ @@ -8267,121 +8201,146 @@ var pveapi = [ ] ] }, - "name" : "vm_pending", "proxyto" : "node", - "description" : "Get virtual machine configuration, including pending changes." + "returns" : { + "items" : { + "properties" : { + "delete" : { + "description" : "Indicates a pending delete request if present and not 0. The value 2 indicates a force-delete request.", + "maximum" : 2, + "minimum" : 0, + "optional" : 1, + "type" : "integer" + }, + "key" : { + "description" : "Configuration option name.", + "type" : "string" + }, + "pending" : { + "description" : "Pending value.", + "optional" : 1, + "type" : "string" + }, + "value" : { + "description" : "Current value.", + "optional" : 1, + "type" : "string" + } + }, + "type" : "object" + }, + "type" : "array" + } } }, - "text" : "pending", "leaf" : 1, - "path" : "/nodes/{node}/qemu/{vmid}/pending" + "path" : "/nodes/{node}/qemu/{vmid}/pending", + "text" : "pending" }, { - "text" : "unlink", "info" : { "PUT" : { - "returns" : { - "type" : "null" - }, "description" : "Unlink/delete disk images.", - "proxyto" : "node", - "permissions" : { - "check" : [ - "perm", - "/vms/{vmid}", - [ - "VM.Config.Disk" - ] - ] - }, "method" : "PUT", - "protected" : 1, "name" : "unlink", "parameters" : { + "additionalProperties" : 0, "properties" : { - "node" : { - "type" : "string", - "description" : "The cluster node name.", - "format" : "pve-node" - }, "force" : { - "type" : "boolean", + "description" : "Force physical removal. Without this, we simple remove the disk from the config file and create an additional configuration entry called 'unused[n]', which contains the volume ID. Unlink of unused[n] always cause physical removal.", "optional" : 1, - "description" : "Force physical removal. Without this, we simple remove the disk from the config file and create an additional configuration entry called 'unused[n]', which contains the volume ID. Unlink of unused[n] always cause physical removal." + "type" : "boolean" }, "idlist" : { "description" : "A list of disk IDs you want to delete.", - "type" : "string", - "format" : "pve-configid-list" + "format" : "pve-configid-list", + "type" : "string" + }, + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" }, "vmid" : { - "type" : "integer", "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", "minimum" : 1, - "format" : "pve-vmid" + "type" : "integer" } - }, - "additionalProperties" : 0 + } + }, + "permissions" : { + "check" : [ + "perm", + "/vms/{vmid}", + [ + "VM.Config.Disk" + ] + ] + }, + "protected" : 1, + "proxyto" : "node", + "returns" : { + "type" : "null" } } }, + "leaf" : 1, "path" : "/nodes/{node}/qemu/{vmid}/unlink", - "leaf" : 1 + "text" : "unlink" }, { - "leaf" : 1, - "path" : "/nodes/{node}/qemu/{vmid}/vncproxy", "info" : { "POST" : { - "protected" : 1, "description" : "Creates a TCP VNC proxy connections.", - "permissions" : { - "check" : [ - "perm", - "/vms/{vmid}", - [ - "VM.Console" - ] - ] - }, + "method" : "POST", + "name" : "vncproxy", "parameters" : { + "additionalProperties" : 0, "properties" : { + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, "vmid" : { "description" : "The (unique) ID of the VM.", - "type" : "integer", + "format" : "pve-vmid", "minimum" : 1, - "format" : "pve-vmid" - }, - "node" : { - "type" : "string", - "description" : "The cluster node name.", - "format" : "pve-node" + "type" : "integer" }, "websocket" : { "description" : "starts websockify instead of vncproxy", - "type" : "boolean", - "optional" : 1 + "optional" : 1, + "type" : "boolean" } - }, - "additionalProperties" : 0 + } }, - "name" : "vncproxy", - "method" : "POST", + "permissions" : { + "check" : [ + "perm", + "/vms/{vmid}", + [ + "VM.Console" + ] + ] + }, + "protected" : 1, "returns" : { "additionalProperties" : 0, "properties" : { "cert" : { "type" : "string" }, - "upid" : { - "type" : "string" - }, "port" : { "type" : "integer" }, "ticket" : { "type" : "string" }, + "upid" : { + "type" : "string" + }, "user" : { "type" : "string" } @@ -8389,51 +8348,53 @@ var pveapi = [ } } }, + "leaf" : 1, + "path" : "/nodes/{node}/qemu/{vmid}/vncproxy", "text" : "vncproxy" }, { "info" : { "GET" : { - "permissions" : { - "check" : [ - "perm", - "/vms/{vmid}", - [ - "VM.Console" - ] - ], - "description" : "You also need to pass a valid ticket (vncticket)." - }, + "description" : "Opens a weksocket for VNC traffic.", + "method" : "GET", + "name" : "vncwebsocket", "parameters" : { + "additionalProperties" : 0, "properties" : { - "port" : { - "minimum" : 5900, - "description" : "Port number returned by previous vncproxy call.", - "type" : "integer", - "maximum" : 5999 - }, "node" : { - "format" : "pve-node", "description" : "The cluster node name.", + "format" : "pve-node", "type" : "string" }, - "vncticket" : { - "maxLength" : 512, - "description" : "Ticket from previous call to vncproxy.", - "type" : "string" + "port" : { + "description" : "Port number returned by previous vncproxy call.", + "maximum" : 5999, + "minimum" : 5900, + "type" : "integer" }, "vmid" : { + "description" : "The (unique) ID of the VM.", "format" : "pve-vmid", "minimum" : 1, - "type" : "integer", - "description" : "The (unique) ID of the VM." + "type" : "integer" + }, + "vncticket" : { + "description" : "Ticket from previous call to vncproxy.", + "maxLength" : 512, + "type" : "string" } - }, - "additionalProperties" : 0 + } + }, + "permissions" : { + "check" : [ + "perm", + "/vms/{vmid}", + [ + "VM.Console" + ] + ], + "description" : "You also need to pass a valid ticket (vncticket)." }, - "name" : "vncwebsocket", - "description" : "Opens a weksocket for VNC traffic.", - "method" : "GET", "returns" : { "properties" : { "port" : { @@ -8444,42 +8405,38 @@ var pveapi = [ } } }, - "text" : "vncwebsocket", "leaf" : 1, - "path" : "/nodes/{node}/qemu/{vmid}/vncwebsocket" + "path" : "/nodes/{node}/qemu/{vmid}/vncwebsocket", + "text" : "vncwebsocket" }, { - "leaf" : 1, - "path" : "/nodes/{node}/qemu/{vmid}/spiceproxy", "info" : { "POST" : { - "protected" : 1, + "description" : "Returns a SPICE configuration to connect to the VM.", + "method" : "POST", "name" : "spiceproxy", "parameters" : { + "additionalProperties" : 0, "properties" : { + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, "proxy" : { + "description" : "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 resonable setting is to use same node you use to connect to the API (This is window.location.hostname for the JS GUI).", "format" : "address", - "type" : "string", "optional" : 1, - "description" : "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 resonable setting is to use same node you use to connect to the API (This is window.location.hostname for the JS GUI)." + "type" : "string" }, "vmid" : { + "description" : "The (unique) ID of the VM.", "format" : "pve-vmid", "minimum" : 1, - "type" : "integer", - "description" : "The (unique) ID of the VM." - }, - "node" : { - "format" : "pve-node", - "type" : "string", - "description" : "The cluster node name." + "type" : "integer" } - }, - "additionalProperties" : 0 + } }, - "method" : "POST", - "description" : "Returns a SPICE configuration to connect to the VM.", - "proxyto" : "node", "permissions" : { "check" : [ "perm", @@ -8489,99 +8446,59 @@ var pveapi = [ ] ] }, + "protected" : 1, + "proxyto" : "node", "returns" : { + "additionalProperties" : 1, + "description" : "Returned values can be directly passed to the 'remote-viewer' application.", "properties" : { - "proxy" : { + "host" : { "type" : "string" }, - "tls-port" : { - "type" : "integer" - }, "password" : { "type" : "string" }, - "type" : { + "proxy" : { "type" : "string" }, - "host" : { + "tls-port" : { + "type" : "integer" + }, + "type" : { "type" : "string" } - }, - "description" : "Returned values can be directly passed to the 'remote-viewer' application.", - "additionalProperties" : 1 + } } } }, + "leaf" : 1, + "path" : "/nodes/{node}/qemu/{vmid}/spiceproxy", "text" : "spiceproxy" }, { - "info" : { - "GET" : { - "method" : "GET", - "returns" : { - "links" : [ - { - "href" : "{subdir}", - "rel" : "child" - } - ], - "items" : { - "properties" : { - "subdir" : { - "type" : "string" - } - }, - "type" : "object" - }, - "type" : "array" - }, - "description" : "Directory index", - "proxyto" : "node", - "permissions" : { - "user" : "all" - }, - "parameters" : { - "properties" : { - "vmid" : { - "minimum" : 1, - "format" : "pve-vmid", - "type" : "integer", - "description" : "The (unique) ID of the VM." - }, - "node" : { - "description" : "The cluster node name.", - "type" : "string", - "format" : "pve-node" - } - }, - "additionalProperties" : 0 - }, - "name" : "vmcmdidx" - } - }, "children" : [ { "info" : { "GET" : { + "description" : "Get virtual machine status.", + "method" : "GET", + "name" : "vm_status", "parameters" : { + "additionalProperties" : 0, "properties" : { + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, "vmid" : { + "description" : "The (unique) ID of the VM.", "format" : "pve-vmid", "minimum" : 1, - "description" : "The (unique) ID of the VM.", "type" : "integer" - }, - "node" : { - "type" : "string", - "description" : "The cluster node name.", - "format" : "pve-node" } - }, - "additionalProperties" : 0 + } }, - "name" : "vm_status", - "protected" : 1, - "method" : "GET", "permissions" : { "check" : [ "perm", @@ -8591,71 +8508,63 @@ var pveapi = [ ] ] }, + "protected" : 1, "proxyto" : "node", - "description" : "Get virtual machine status.", "returns" : { "type" : "object" } } }, - "text" : "current", "leaf" : 1, - "path" : "/nodes/{node}/qemu/{vmid}/status/current" + "path" : "/nodes/{node}/qemu/{vmid}/status/current", + "text" : "current" }, { - "path" : "/nodes/{node}/qemu/{vmid}/status/start", - "leaf" : 1, - "text" : "start", "info" : { "POST" : { + "description" : "Start virtual machine.", "method" : "POST", - "protected" : 1, + "name" : "vm_start", "parameters" : { + "additionalProperties" : 0, "properties" : { - "stateuri" : { - "description" : "Some command save/restore state from this location.", - "type" : "string", + "machine" : { + "description" : "Specific the Qemu machine type.", + "maxLength" : 40, + "optional" : 1, + "pattern" : "(pc|pc(-i440fx)?-\\d+\\.\\d+(\\.pxe)?|q35|pc-q35-\\d+\\.\\d+(\\.pxe)?)", + "type" : "string" + }, + "migratedfrom" : { + "description" : "The cluster node name.", + "format" : "pve-node", "optional" : 1, - "maxLength" : 128 + "type" : "string" }, "node" : { - "type" : "string", "description" : "The cluster node name.", - "format" : "pve-node" + "format" : "pve-node", + "type" : "string" }, - "machine" : { - "pattern" : "(pc|pc(-i440fx)?-\\d+\\.\\d+(\\.pxe)?|q35|pc-q35-\\d+\\.\\d+(\\.pxe)?)", - "description" : "Specific the Qemu machine type.", - "type" : "string", + "skiplock" : { + "description" : "Ignore locks - only root is allowed to use this option.", "optional" : 1, - "maxLength" : 40 + "type" : "boolean" }, - "skiplock" : { - "type" : "boolean", + "stateuri" : { + "description" : "Some command save/restore state from this location.", + "maxLength" : 128, "optional" : 1, - "description" : "Ignore locks - only root is allowed to use this option." + "type" : "string" }, "vmid" : { - "minimum" : 1, - "format" : "pve-vmid", "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, "type" : "integer" - }, - "migratedfrom" : { - "description" : "The cluster node name.", - "type" : "string", - "optional" : 1, - "format" : "pve-node" } - }, - "additionalProperties" : 0 - }, - "name" : "vm_start", - "returns" : { - "type" : "string" + } }, - "proxyto" : "node", - "description" : "Start virtual machine.", "permissions" : { "check" : [ "perm", @@ -8664,83 +8573,63 @@ var pveapi = [ "VM.PowerMgmt" ] ] + }, + "protected" : 1, + "proxyto" : "node", + "returns" : { + "type" : "string" } } - } + }, + "leaf" : 1, + "path" : "/nodes/{node}/qemu/{vmid}/status/start", + "text" : "start" }, { - "text" : "stop", "info" : { "POST" : { "description" : "Stop virtual machine. The qemu process will exit immediately. Thisis akin to pulling the power plug of a running computer and may damage the VM data", - "proxyto" : "node", - "permissions" : { - "check" : [ - "perm", - "/vms/{vmid}", - [ - "VM.PowerMgmt" - ] - ] - }, - "returns" : { - "type" : "string" - }, - "protected" : 1, + "method" : "POST", + "name" : "vm_stop", "parameters" : { + "additionalProperties" : 0, "properties" : { - "timeout" : { - "minimum" : 0, + "keepActive" : { + "default" : 0, + "description" : "Do not decativate storage volumes.", "optional" : 1, - "type" : "integer", - "description" : "Wait maximal timeout seconds." + "type" : "boolean" }, "migratedfrom" : { "description" : "The cluster node name.", - "type" : "string", + "format" : "pve-node", "optional" : 1, - "format" : "pve-node" + "type" : "string" }, - "vmid" : { - "minimum" : 1, - "format" : "pve-vmid", - "description" : "The (unique) ID of the VM.", - "type" : "integer" + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" }, "skiplock" : { "description" : "Ignore locks - only root is allowed to use this option.", "optional" : 1, "type" : "boolean" }, - "keepActive" : { - "description" : "Do not decativate storage volumes.", - "type" : "boolean", + "timeout" : { + "description" : "Wait maximal timeout seconds.", + "minimum" : 0, "optional" : 1, - "default" : 0 + "type" : "integer" }, - "node" : { - "format" : "pve-node", - "type" : "string", - "description" : "The cluster node name." + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" } - }, - "additionalProperties" : 0 + } }, - "name" : "vm_stop", - "method" : "POST" - } - }, - "path" : "/nodes/{node}/qemu/{vmid}/status/stop", - "leaf" : 1 - }, - { - "path" : "/nodes/{node}/qemu/{vmid}/status/reset", - "leaf" : 1, - "text" : "reset", - "info" : { - "POST" : { - "proxyto" : "node", - "description" : "Reset virtual machine.", "permissions" : { "check" : [ "perm", @@ -8750,40 +8639,44 @@ var pveapi = [ ] ] }, + "protected" : 1, + "proxyto" : "node", "returns" : { "type" : "string" - }, - "protected" : 1, + } + } + }, + "leaf" : 1, + "path" : "/nodes/{node}/qemu/{vmid}/status/stop", + "text" : "stop" + }, + { + "info" : { + "POST" : { + "description" : "Reset virtual machine.", + "method" : "POST", + "name" : "vm_reset", "parameters" : { "additionalProperties" : 0, "properties" : { "node" : { - "type" : "string", "description" : "The cluster node name.", - "format" : "pve-node" + "format" : "pve-node", + "type" : "string" }, "skiplock" : { - "type" : "boolean", + "description" : "Ignore locks - only root is allowed to use this option.", "optional" : 1, - "description" : "Ignore locks - only root is allowed to use this option." + "type" : "boolean" }, "vmid" : { + "description" : "The (unique) ID of the VM.", "format" : "pve-vmid", "minimum" : 1, - "type" : "integer", - "description" : "The (unique) ID of the VM." + "type" : "integer" } } }, - "name" : "vm_reset", - "method" : "POST" - } - } - }, - { - "text" : "shutdown", - "info" : { - "POST" : { "permissions" : { "check" : [ "perm", @@ -8793,88 +8686,108 @@ var pveapi = [ ] ] }, - "description" : "Shutdown virtual machine. This is similar to pressing the power button on a physical machine.This will send an ACPI event for the guest OS, which should then proceed to a clean shutdown.", + "protected" : 1, "proxyto" : "node", "returns" : { "type" : "string" - }, + } + } + }, + "leaf" : 1, + "path" : "/nodes/{node}/qemu/{vmid}/status/reset", + "text" : "reset" + }, + { + "info" : { + "POST" : { + "description" : "Shutdown virtual machine. This is similar to pressing the power button on a physical machine.This will send an ACPI event for the guest OS, which should then proceed to a clean shutdown.", + "method" : "POST", "name" : "vm_shutdown", "parameters" : { "additionalProperties" : 0, "properties" : { - "node" : { - "format" : "pve-node", - "description" : "The cluster node name.", - "type" : "string" - }, "forceStop" : { "default" : 0, + "description" : "Make sure the VM stops.", "optional" : 1, - "type" : "boolean", - "description" : "Make sure the VM stops." + "type" : "boolean" }, "keepActive" : { - "type" : "boolean", - "optional" : 1, "default" : 0, - "description" : "Do not decativate storage volumes." + "description" : "Do not decativate storage volumes.", + "optional" : 1, + "type" : "boolean" + }, + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, + "skiplock" : { + "description" : "Ignore locks - only root is allowed to use this option.", + "optional" : 1, + "type" : "boolean" }, "timeout" : { - "minimum" : 0, "description" : "Wait maximal timeout seconds.", + "minimum" : 0, "optional" : 1, "type" : "integer" }, "vmid" : { - "minimum" : 1, - "format" : "pve-vmid", "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, "type" : "integer" - }, - "skiplock" : { - "description" : "Ignore locks - only root is allowed to use this option.", - "optional" : 1, - "type" : "boolean" } } }, + "permissions" : { + "check" : [ + "perm", + "/vms/{vmid}", + [ + "VM.PowerMgmt" + ] + ] + }, "protected" : 1, - "method" : "POST" + "proxyto" : "node", + "returns" : { + "type" : "string" + } } }, + "leaf" : 1, "path" : "/nodes/{node}/qemu/{vmid}/status/shutdown", - "leaf" : 1 + "text" : "shutdown" }, { - "text" : "suspend", "info" : { "POST" : { + "description" : "Suspend virtual machine.", "method" : "POST", + "name" : "vm_suspend", "parameters" : { + "additionalProperties" : 0, "properties" : { "node" : { - "type" : "string", "description" : "The cluster node name.", - "format" : "pve-node" - }, - "vmid" : { - "minimum" : 1, - "format" : "pve-vmid", - "description" : "The (unique) ID of the VM.", - "type" : "integer" + "format" : "pve-node", + "type" : "string" }, "skiplock" : { "description" : "Ignore locks - only root is allowed to use this option.", - "type" : "boolean", - "optional" : 1 - } - }, - "additionalProperties" : 0 - }, - "name" : "vm_suspend", - "protected" : 1, - "returns" : { - "type" : "string" + "optional" : 1, + "type" : "boolean" + }, + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" + } + } }, "permissions" : { "check" : [ @@ -8885,48 +8798,48 @@ var pveapi = [ ] ] }, - "description" : "Suspend virtual machine.", - "proxyto" : "node" + "protected" : 1, + "proxyto" : "node", + "returns" : { + "type" : "string" + } } }, + "leaf" : 1, "path" : "/nodes/{node}/qemu/{vmid}/status/suspend", - "leaf" : 1 + "text" : "suspend" }, { - "leaf" : 1, - "path" : "/nodes/{node}/qemu/{vmid}/status/resume", "info" : { "POST" : { - "protected" : 1, + "description" : "Resume virtual machine.", + "method" : "POST", "name" : "vm_resume", "parameters" : { "additionalProperties" : 0, "properties" : { + "nocheck" : { + "optional" : 1, + "type" : "boolean" + }, "node" : { + "description" : "The cluster node name.", "format" : "pve-node", - "type" : "string", - "description" : "The cluster node name." + "type" : "string" }, "skiplock" : { "description" : "Ignore locks - only root is allowed to use this option.", - "type" : "boolean", - "optional" : 1 + "optional" : 1, + "type" : "boolean" }, "vmid" : { - "type" : "integer", "description" : "The (unique) ID of the VM.", "format" : "pve-vmid", - "minimum" : 1 - }, - "nocheck" : { - "type" : "boolean", - "optional" : 1 + "minimum" : 1, + "type" : "integer" } } }, - "method" : "POST", - "description" : "Resume virtual machine.", - "proxyto" : "node", "permissions" : { "check" : [ "perm", @@ -8936,229 +8849,269 @@ var pveapi = [ ] ] }, + "protected" : 1, + "proxyto" : "node", "returns" : { "type" : "string" } } }, + "leaf" : 1, + "path" : "/nodes/{node}/qemu/{vmid}/status/resume", "text" : "resume" } ], - "text" : "status", - "leaf" : 0, - "path" : "/nodes/{node}/qemu/{vmid}/status" - }, - { - "text" : "sendkey", "info" : { - "PUT" : { - "proxyto" : "node", - "description" : "Send key event to virtual machine.", - "permissions" : { - "check" : [ - "perm", - "/vms/{vmid}", - [ - "VM.Console" - ] - ] - }, - "returns" : { - "type" : "null" - }, - "protected" : 1, + "GET" : { + "description" : "Directory index", + "method" : "GET", + "name" : "vmcmdidx", "parameters" : { + "additionalProperties" : 0, "properties" : { - "key" : { - "description" : "The key (qemu monitor encoding).", + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", "type" : "string" }, - "skiplock" : { - "optional" : 1, - "type" : "boolean", - "description" : "Ignore locks - only root is allowed to use this option." - }, "vmid" : { - "minimum" : 1, - "format" : "pve-vmid", "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, "type" : "integer" - }, - "node" : { - "format" : "pve-node", - "description" : "The cluster node name.", - "type" : "string" } - }, - "additionalProperties" : 0 + } }, - "name" : "vm_sendkey", - "method" : "PUT" + "permissions" : { + "user" : "all" + }, + "proxyto" : "node", + "returns" : { + "items" : { + "properties" : { + "subdir" : { + "type" : "string" + } + }, + "type" : "object" + }, + "links" : [ + { + "href" : "{subdir}", + "rel" : "child" + } + ], + "type" : "array" + } } }, - "path" : "/nodes/{node}/qemu/{vmid}/sendkey", - "leaf" : 1 + "leaf" : 0, + "path" : "/nodes/{node}/qemu/{vmid}/status", + "text" : "status" }, { "info" : { - "GET" : { - "returns" : { - "type" : "object", + "PUT" : { + "description" : "Send key event to virtual machine.", + "method" : "PUT", + "name" : "vm_sendkey", + "parameters" : { + "additionalProperties" : 0, "properties" : { - "hasFeature" : { + "key" : { + "description" : "The key (qemu monitor encoding).", + "type" : "string" + }, + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, + "skiplock" : { + "description" : "Ignore locks - only root is allowed to use this option.", + "optional" : 1, "type" : "boolean" }, - "nodes" : { - "type" : "array", - "items" : { - "type" : "string" - } + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" } } }, - "description" : "Check if feature for virtual machine is available.", - "proxyto" : "node", "permissions" : { "check" : [ "perm", "/vms/{vmid}", [ - "VM.Audit" + "VM.Console" ] ] }, - "method" : "GET", "protected" : 1, + "proxyto" : "node", + "returns" : { + "type" : "null" + } + } + }, + "leaf" : 1, + "path" : "/nodes/{node}/qemu/{vmid}/sendkey", + "text" : "sendkey" + }, + { + "info" : { + "GET" : { + "description" : "Check if feature for virtual machine is available.", + "method" : "GET", "name" : "vm_feature", "parameters" : { + "additionalProperties" : 0, "properties" : { - "vmid" : { - "minimum" : 1, - "format" : "pve-vmid", - "type" : "integer", - "description" : "The (unique) ID of the VM." - }, "feature" : { + "description" : "Feature to check.", "enum" : [ "snapshot", "clone", "copy" ], - "description" : "Feature to check.", + "type" : "string" + }, + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", "type" : "string" }, "snapname" : { - "maxLength" : 40, - "format" : "pve-configid", "description" : "The name of the snapshot.", + "format" : "pve-configid", + "maxLength" : 40, "optional" : 1, "type" : "string" }, - "node" : { - "type" : "string", - "description" : "The cluster node name.", - "format" : "pve-node" + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" + } + } + }, + "permissions" : { + "check" : [ + "perm", + "/vms/{vmid}", + [ + "VM.Audit" + ] + ] + }, + "protected" : 1, + "proxyto" : "node", + "returns" : { + "properties" : { + "hasFeature" : { + "type" : "boolean" + }, + "nodes" : { + "items" : { + "type" : "string" + }, + "type" : "array" } }, - "additionalProperties" : 0 + "type" : "object" } } }, - "text" : "feature", "leaf" : 1, - "path" : "/nodes/{node}/qemu/{vmid}/feature" + "path" : "/nodes/{node}/qemu/{vmid}/feature", + "text" : "feature" }, { - "leaf" : 1, - "path" : "/nodes/{node}/qemu/{vmid}/clone", "info" : { "POST" : { + "description" : "Create a copy of virtual machine/template.", "method" : "POST", - "protected" : 1, "name" : "clone_vm", "parameters" : { "additionalProperties" : 0, "properties" : { - "newid" : { - "minimum" : 1, - "format" : "pve-vmid", - "description" : "VMID for the clone.", - "type" : "integer" - }, - "storage" : { - "format" : "pve-storage-id", - "description" : "Target storage for full clone.", - "requires" : "full", + "description" : { + "description" : "Description for the new VM.", "optional" : 1, "type" : "string" }, - "target" : { - "format" : "pve-node", - "description" : "Target node. Only allowed if the original VM is on shared storage.", - "type" : "string", - "optional" : 1 - }, - "snapname" : { - "format" : "pve-configid", - "maxLength" : 40, - "description" : "The name of the snapshot.", - "type" : "string", - "optional" : 1 - }, - "node" : { - "format" : "pve-node", - "description" : "The cluster node name.", + "format" : { + "description" : "Target format for file storage.", + "enum" : [ + "raw", + "qcow2", + "vmdk" + ], + "optional" : 1, + "requires" : "full", "type" : "string" }, - "name" : { + "full" : { + "default" : 0, + "description" : "Create a full copy of all disk. This is always done when you clone a normal VM. For VM templates, we try to create a linked clone by default.", "optional" : 1, - "type" : "string", + "type" : "boolean" + }, + "name" : { "description" : "Set a name for the new VM.", - "format" : "dns-name" + "format" : "dns-name", + "optional" : 1, + "type" : "string" + }, + "newid" : { + "description" : "VMID for the clone.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" + }, + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" }, "pool" : { "description" : "Add the new VM to the specified pool.", - "type" : "string", + "format" : "pve-poolid", "optional" : 1, - "format" : "pve-poolid" - }, - "vmid" : { - "type" : "integer", - "description" : "The (unique) ID of the VM.", - "minimum" : 1, - "format" : "pve-vmid" + "type" : "string" }, - "format" : { - "enum" : [ - "raw", - "qcow2", - "vmdk" - ], - "description" : "Target format for file storage.", - "requires" : "full", + "snapname" : { + "description" : "The name of the snapshot.", + "format" : "pve-configid", + "maxLength" : 40, "optional" : 1, "type" : "string" }, - "full" : { + "storage" : { + "description" : "Target storage for full clone.", + "format" : "pve-storage-id", "optional" : 1, - "type" : "boolean", - "default" : 0, - "description" : "Create a full copy of all disk. This is always done when you clone a normal VM. For VM templates, we try to create a linked clone by default." + "requires" : "full", + "type" : "string" }, - "description" : { - "description" : "Description for the new VM.", + "target" : { + "description" : "Target node. Only allowed if the original VM is on shared storage.", + "format" : "pve-node", "optional" : 1, "type" : "string" + }, + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" } } }, - "returns" : { - "type" : "string" - }, - "description" : "Create a copy of virtual machine/template.", - "proxyto" : "node", "permissions" : { - "description" : "You need 'VM.Clone' permissions on /vms/{vmid}, and 'VM.Allocate' permissions on /vms/{newid} (or on the VM pool /pool/{pool}). You also need 'Datastore.AllocateSpace' on any used storage.", "check" : [ "and", [ @@ -9187,70 +9140,42 @@ var pveapi = [ "pool" ] ] - ] + ], + "description" : "You need 'VM.Clone' permissions on /vms/{vmid}, and 'VM.Allocate' permissions on /vms/{newid} (or on the VM pool /pool/{pool}). You also need 'Datastore.AllocateSpace' on any used storage." + }, + "protected" : 1, + "proxyto" : "node", + "returns" : { + "type" : "string" } } }, + "leaf" : 1, + "path" : "/nodes/{node}/qemu/{vmid}/clone", "text" : "clone" }, { - "text" : "move_disk", "info" : { "POST" : { - "proxyto" : "node", "description" : "Move volume to different storage.", - "permissions" : { - "check" : [ - "and", - [ - "perm", - "/vms/{vmid}", - [ - "VM.Config.Disk" - ] - ], - [ - "perm", - "/storage/{storage}", - [ - "Datastore.AllocateSpace" - ] - ] - ], - "description" : "You need 'VM.Config.Disk' permissions on /vms/{vmid}, and 'Datastore.AllocateSpace' permissions on the storage." - }, - "returns" : { - "type" : "string", - "description" : "the task ID." - }, - "protected" : 1, + "method" : "POST", + "name" : "move_vm_disk", "parameters" : { "additionalProperties" : 0, "properties" : { - "node" : { - "format" : "pve-node", - "description" : "The cluster node name.", - "type" : "string" - }, "delete" : { + "default" : 0, "description" : "Delete the original disk after successful copy. By default the original disk is kept as unused disk.", - "type" : "boolean", "optional" : 1, - "default" : 0 - }, - "storage" : { - "type" : "string", - "description" : "Target storage.", - "format" : "pve-storage-id" + "type" : "boolean" }, - "vmid" : { - "description" : "The (unique) ID of the VM.", - "type" : "integer", - "format" : "pve-vmid", - "minimum" : 1 + "digest" : { + "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", + "maxLength" : 40, + "optional" : 1, + "type" : "string" }, "disk" : { - "type" : "string", "description" : "The disk you want to move.", "enum" : [ "ide0", @@ -9293,13 +9218,8 @@ var pveapi = [ "sata3", "sata4", "sata5" - ] - }, - "digest" : { - "maxLength" : 40, - "optional" : 1, - "type" : "string", - "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications." + ], + "type" : "string" }, "format" : { "description" : "Target Format.", @@ -9310,106 +9230,141 @@ var pveapi = [ ], "optional" : 1, "type" : "string" + }, + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, + "storage" : { + "description" : "Target storage.", + "format" : "pve-storage-id", + "type" : "string" + }, + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" } } }, - "name" : "move_vm_disk", - "method" : "POST" + "permissions" : { + "check" : [ + "and", + [ + "perm", + "/vms/{vmid}", + [ + "VM.Config.Disk" + ] + ], + [ + "perm", + "/storage/{storage}", + [ + "Datastore.AllocateSpace" + ] + ] + ], + "description" : "You need 'VM.Config.Disk' permissions on /vms/{vmid}, and 'Datastore.AllocateSpace' permissions on the storage." + }, + "protected" : 1, + "proxyto" : "node", + "returns" : { + "description" : "the task ID.", + "type" : "string" + } } }, + "leaf" : 1, "path" : "/nodes/{node}/qemu/{vmid}/move_disk", - "leaf" : 1 + "text" : "move_disk" }, { - "leaf" : 1, - "path" : "/nodes/{node}/qemu/{vmid}/migrate", "info" : { "POST" : { - "permissions" : { - "check" : [ - "perm", - "/vms/{vmid}", - [ - "VM.Migrate" - ] - ] - }, - "proxyto" : "node", "description" : "Migrate virtual machine. Creates a new migration task.", - "returns" : { - "type" : "string", - "description" : "the task ID." - }, + "method" : "POST", "name" : "migrate_vm", "parameters" : { + "additionalProperties" : 0, "properties" : { + "force" : { + "description" : "Allow to migrate VMs which use local devices. Only root may use this option.", + "optional" : 1, + "type" : "boolean" + }, "node" : { + "description" : "The cluster node name.", "format" : "pve-node", - "type" : "string", - "description" : "The cluster node name." + "type" : "string" }, "online" : { + "description" : "Use online/live migration.", "optional" : 1, - "type" : "boolean", - "description" : "Use online/live migration." + "type" : "boolean" }, - "force" : { - "type" : "boolean", - "optional" : 1, - "description" : "Allow to migrate VMs which use local devices. Only root may use this option." + "target" : { + "description" : "Target node.", + "format" : "pve-node", + "type" : "string" }, "vmid" : { - "type" : "integer", "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", "minimum" : 1, - "format" : "pve-vmid" - }, - "target" : { - "type" : "string", - "description" : "Target node.", - "format" : "pve-node" + "type" : "integer" } - }, - "additionalProperties" : 0 + } + }, + "permissions" : { + "check" : [ + "perm", + "/vms/{vmid}", + [ + "VM.Migrate" + ] + ] }, "protected" : 1, - "method" : "POST" + "proxyto" : "node", + "returns" : { + "description" : "the task ID.", + "type" : "string" + } } }, + "leaf" : 1, + "path" : "/nodes/{node}/qemu/{vmid}/migrate", "text" : "migrate" }, { - "path" : "/nodes/{node}/qemu/{vmid}/monitor", - "leaf" : 1, - "text" : "monitor", "info" : { "POST" : { + "description" : "Execute Qemu monitor commands.", "method" : "POST", + "name" : "monitor", "parameters" : { "additionalProperties" : 0, "properties" : { + "command" : { + "description" : "The monitor command.", + "type" : "string" + }, "node" : { + "description" : "The cluster node name.", "format" : "pve-node", - "type" : "string", - "description" : "The cluster node name." - }, - "command" : { - "type" : "string", - "description" : "The monitor command." + "type" : "string" }, "vmid" : { + "description" : "The (unique) ID of the VM.", "format" : "pve-vmid", "minimum" : 1, - "type" : "integer", - "description" : "The (unique) ID of the VM." + "type" : "integer" } } }, - "name" : "monitor", - "protected" : 1, - "returns" : { - "type" : "string" - }, "permissions" : { "check" : [ "perm", @@ -9419,31 +9374,33 @@ var pveapi = [ ] ] }, - "description" : "Execute Qemu monitor commands.", - "proxyto" : "node" + "protected" : 1, + "proxyto" : "node", + "returns" : { + "type" : "string" + } } - } + }, + "leaf" : 1, + "path" : "/nodes/{node}/qemu/{vmid}/monitor", + "text" : "monitor" }, { - "leaf" : 1, - "path" : "/nodes/{node}/qemu/{vmid}/resize", "info" : { "PUT" : { - "protected" : 1, + "description" : "Extend volume size.", + "method" : "PUT", + "name" : "resize_vm", "parameters" : { + "additionalProperties" : 0, "properties" : { - "node" : { - "format" : "pve-node", - "type" : "string", - "description" : "The cluster node name." - }, - "size" : { - "description" : "The new size. With the '+' sign the value is added to the actual size of the volume and without it, the value is taken as an absolute one. Shrinking disk size is not supported.", - "pattern" : "\\+?\\d+(\\.\\d+)?[KMGT]?", + "digest" : { + "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", + "maxLength" : 40, + "optional" : 1, "type" : "string" }, "disk" : { - "type" : "string", "description" : "The disk you want to resize.", "enum" : [ "ide0", @@ -9486,284 +9443,84 @@ var pveapi = [ "sata3", "sata4", "sata5" - ] + ], + "type" : "string" }, - "digest" : { - "maxLength" : 40, - "optional" : 1, - "type" : "string", - "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications." + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" }, - "vmid" : { - "type" : "integer", - "description" : "The (unique) ID of the VM.", - "minimum" : 1, - "format" : "pve-vmid" + "size" : { + "description" : "The new size. With the '+' sign the value is added to the actual size of the volume and without it, the value is taken as an absolute one. Shrinking disk size is not supported.", + "pattern" : "\\+?\\d+(\\.\\d+)?[KMGT]?", + "type" : "string" }, "skiplock" : { "description" : "Ignore locks - only root is allowed to use this option.", "optional" : 1, "type" : "boolean" - } - }, - "additionalProperties" : 0 - }, - "name" : "resize_vm", - "method" : "PUT", - "description" : "Extend volume size.", - "proxyto" : "node", - "permissions" : { - "check" : [ - "perm", - "/vms/{vmid}", - [ - "VM.Config.Disk" - ] - ] - }, - "returns" : { - "type" : "null" - } - } - }, - "text" : "resize" - }, - { - "leaf" : 0, - "path" : "/nodes/{node}/qemu/{vmid}/snapshot", - "info" : { - "POST" : { - "protected" : 1, - "name" : "snapshot", - "parameters" : { - "additionalProperties" : 0, - "properties" : { - "vmstate" : { - "description" : "Save the vmstate", - "optional" : 1, - "type" : "boolean" }, "vmid" : { - "type" : "integer", "description" : "The (unique) ID of the VM.", "format" : "pve-vmid", - "minimum" : 1 - }, - "snapname" : { - "type" : "string", - "description" : "The name of the snapshot.", - "format" : "pve-configid", - "maxLength" : 40 - }, - "node" : { - "format" : "pve-node", - "description" : "The cluster node name.", - "type" : "string" - }, - "description" : { - "description" : "A textual description or comment.", - "optional" : 1, - "type" : "string" + "minimum" : 1, + "type" : "integer" } } }, - "method" : "POST", - "proxyto" : "node", - "description" : "Snapshot a VM.", "permissions" : { "check" : [ "perm", "/vms/{vmid}", [ - "VM.Snapshot" + "VM.Config.Disk" ] ] }, - "returns" : { - "type" : "string", - "description" : "the task ID." - } - }, - "GET" : { - "method" : "GET", - "name" : "snapshot_list", - "parameters" : { - "properties" : { - "vmid" : { - "type" : "integer", - "description" : "The (unique) ID of the VM.", - "format" : "pve-vmid", - "minimum" : 1 - }, - "node" : { - "type" : "string", - "description" : "The cluster node name.", - "format" : "pve-node" - } - }, - "additionalProperties" : 0 - }, "protected" : 1, - "returns" : { - "items" : { - "properties" : {}, - "type" : "object" - }, - "links" : [ - { - "href" : "{name}", - "rel" : "child" - } - ], - "type" : "array" - }, - "permissions" : { - "check" : [ - "perm", - "/vms/{vmid}", - [ - "VM.Audit" - ] - ] - }, "proxyto" : "node", - "description" : "List all snapshots." + "returns" : { + "type" : "null" + } } }, + "leaf" : 1, + "path" : "/nodes/{node}/qemu/{vmid}/resize", + "text" : "resize" + }, + { "children" : [ { - "leaf" : 0, - "path" : "/nodes/{node}/qemu/{vmid}/snapshot/{snapname}", - "info" : { - "GET" : { - "method" : "GET", - "returns" : { - "type" : "array", - "items" : { - "properties" : {}, - "type" : "object" - }, - "links" : [ - { - "href" : "{cmd}", - "rel" : "child" - } - ] - }, - "name" : "snapshot_cmd_idx", - "permissions" : { - "user" : "all" - }, - "parameters" : { - "properties" : { - "vmid" : { - "minimum" : 1, - "format" : "pve-vmid", - "type" : "integer", - "description" : "The (unique) ID of the VM." - }, - "node" : { - "format" : "pve-node", - "type" : "string", - "description" : "The cluster node name." - }, - "snapname" : { - "format" : "pve-configid", - "maxLength" : 40, - "description" : "The name of the snapshot.", - "type" : "string" - } - }, - "additionalProperties" : 0 - }, - "description" : "" - }, - "DELETE" : { - "proxyto" : "node", - "description" : "Delete a VM snapshot.", - "permissions" : { - "check" : [ - "perm", - "/vms/{vmid}", - [ - "VM.Snapshot" - ] - ] - }, - "returns" : { - "type" : "string", - "description" : "the task ID." - }, - "protected" : 1, - "parameters" : { - "properties" : { - "vmid" : { - "description" : "The (unique) ID of the VM.", - "type" : "integer", - "format" : "pve-vmid", - "minimum" : 1 - }, - "node" : { - "description" : "The cluster node name.", - "type" : "string", - "format" : "pve-node" - }, - "snapname" : { - "maxLength" : 40, - "format" : "pve-configid", - "description" : "The name of the snapshot.", - "type" : "string" - }, - "force" : { - "description" : "For removal from config file, even if removing disk snapshots fails.", - "optional" : 1, - "type" : "boolean" - } - }, - "additionalProperties" : 0 - }, - "name" : "delsnapshot", - "method" : "DELETE" - } - }, - "text" : "{snapname}", "children" : [ { - "text" : "config", "info" : { - "PUT" : { - "protected" : 1, + "GET" : { + "description" : "Get snapshot configuration", + "method" : "GET", + "name" : "get_snapshot_config", "parameters" : { + "additionalProperties" : 0, "properties" : { - "description" : { - "type" : "string", - "optional" : 1, - "description" : "A textual description or comment." - }, "node" : { + "description" : "The cluster node name.", "format" : "pve-node", - "type" : "string", - "description" : "The cluster node name." + "type" : "string" }, "snapname" : { - "maxLength" : 40, + "description" : "The name of the snapshot.", "format" : "pve-configid", - "type" : "string", - "description" : "The name of the snapshot." + "maxLength" : 40, + "type" : "string" }, "vmid" : { + "description" : "The (unique) ID of the VM.", "format" : "pve-vmid", "minimum" : 1, - "type" : "integer", - "description" : "The (unique) ID of the VM." + "type" : "integer" } - }, - "additionalProperties" : 0 + } }, - "name" : "update_snapshot_config", - "method" : "PUT", - "proxyto" : "node", - "description" : "Update snapshot metadata.", "permissions" : { "check" : [ "perm", @@ -9773,40 +9530,42 @@ var pveapi = [ ] ] }, + "proxyto" : "node", "returns" : { - "type" : "null" + "type" : "object" } }, - "GET" : { - "method" : "GET", - "returns" : { - "type" : "object" - }, - "proxyto" : "node", - "description" : "Get snapshot configuration", + "PUT" : { + "description" : "Update snapshot metadata.", + "method" : "PUT", + "name" : "update_snapshot_config", "parameters" : { + "additionalProperties" : 0, "properties" : { + "description" : { + "description" : "A textual description or comment.", + "optional" : 1, + "type" : "string" + }, "node" : { - "type" : "string", "description" : "The cluster node name.", - "format" : "pve-node" + "format" : "pve-node", + "type" : "string" }, "snapname" : { "description" : "The name of the snapshot.", - "type" : "string", + "format" : "pve-configid", "maxLength" : 40, - "format" : "pve-configid" + "type" : "string" }, "vmid" : { "description" : "The (unique) ID of the VM.", - "type" : "integer", + "format" : "pve-vmid", "minimum" : 1, - "format" : "pve-vmid" + "type" : "integer" } - }, - "additionalProperties" : 0 + } }, - "name" : "get_snapshot_config", "permissions" : { "check" : [ "perm", @@ -9815,46 +9574,46 @@ var pveapi = [ "VM.Snapshot" ] ] + }, + "protected" : 1, + "proxyto" : "node", + "returns" : { + "type" : "null" } } }, + "leaf" : 1, "path" : "/nodes/{node}/qemu/{vmid}/snapshot/{snapname}/config", - "leaf" : 1 + "text" : "config" }, { - "leaf" : 1, - "path" : "/nodes/{node}/qemu/{vmid}/snapshot/{snapname}/rollback", "info" : { "POST" : { + "description" : "Rollback VM state to specified snapshot.", "method" : "POST", + "name" : "rollback", "parameters" : { "additionalProperties" : 0, "properties" : { + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, "snapname" : { + "description" : "The name of the snapshot.", "format" : "pve-configid", "maxLength" : 40, - "type" : "string", - "description" : "The name of the snapshot." - }, - "node" : { - "format" : "pve-node", - "description" : "The cluster node name.", "type" : "string" }, "vmid" : { "description" : "The (unique) ID of the VM.", - "type" : "integer", + "format" : "pve-vmid", "minimum" : 1, - "format" : "pve-vmid" + "type" : "integer" } } }, - "name" : "rollback", - "protected" : 1, - "returns" : { - "type" : "string", - "description" : "the task ID." - }, "permissions" : { "check" : [ "perm", @@ -9864,30 +9623,228 @@ var pveapi = [ ] ] }, + "protected" : 1, "proxyto" : "node", - "description" : "Rollback VM state to specified snapshot." + "returns" : { + "description" : "the task ID.", + "type" : "string" + } } }, + "leaf" : 1, + "path" : "/nodes/{node}/qemu/{vmid}/snapshot/{snapname}/rollback", "text" : "rollback" } - ] + ], + "info" : { + "DELETE" : { + "description" : "Delete a VM snapshot.", + "method" : "DELETE", + "name" : "delsnapshot", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "force" : { + "description" : "For removal from config file, even if removing disk snapshots fails.", + "optional" : 1, + "type" : "boolean" + }, + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, + "snapname" : { + "description" : "The name of the snapshot.", + "format" : "pve-configid", + "maxLength" : 40, + "type" : "string" + }, + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" + } + } + }, + "permissions" : { + "check" : [ + "perm", + "/vms/{vmid}", + [ + "VM.Snapshot" + ] + ] + }, + "protected" : 1, + "proxyto" : "node", + "returns" : { + "description" : "the task ID.", + "type" : "string" + } + }, + "GET" : { + "description" : "", + "method" : "GET", + "name" : "snapshot_cmd_idx", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, + "snapname" : { + "description" : "The name of the snapshot.", + "format" : "pve-configid", + "maxLength" : 40, + "type" : "string" + }, + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" + } + } + }, + "permissions" : { + "user" : "all" + }, + "returns" : { + "items" : { + "properties" : {}, + "type" : "object" + }, + "links" : [ + { + "href" : "{cmd}", + "rel" : "child" + } + ], + "type" : "array" + } + } + }, + "leaf" : 0, + "path" : "/nodes/{node}/qemu/{vmid}/snapshot/{snapname}", + "text" : "{snapname}" } ], + "info" : { + "GET" : { + "description" : "List all snapshots.", + "method" : "GET", + "name" : "snapshot_list", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" + } + } + }, + "permissions" : { + "check" : [ + "perm", + "/vms/{vmid}", + [ + "VM.Audit" + ] + ] + }, + "protected" : 1, + "proxyto" : "node", + "returns" : { + "items" : { + "properties" : {}, + "type" : "object" + }, + "links" : [ + { + "href" : "{name}", + "rel" : "child" + } + ], + "type" : "array" + } + }, + "POST" : { + "description" : "Snapshot a VM.", + "method" : "POST", + "name" : "snapshot", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "description" : { + "description" : "A textual description or comment.", + "optional" : 1, + "type" : "string" + }, + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, + "snapname" : { + "description" : "The name of the snapshot.", + "format" : "pve-configid", + "maxLength" : 40, + "type" : "string" + }, + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" + }, + "vmstate" : { + "description" : "Save the vmstate", + "optional" : 1, + "type" : "boolean" + } + } + }, + "permissions" : { + "check" : [ + "perm", + "/vms/{vmid}", + [ + "VM.Snapshot" + ] + ] + }, + "protected" : 1, + "proxyto" : "node", + "returns" : { + "description" : "the task ID.", + "type" : "string" + } + } + }, + "leaf" : 0, + "path" : "/nodes/{node}/qemu/{vmid}/snapshot", "text" : "snapshot" }, { - "text" : "template", "info" : { "POST" : { + "description" : "Create a Template.", + "method" : "POST", "name" : "template", "parameters" : { "additionalProperties" : 0, "properties" : { - "node" : { - "format" : "pve-node", - "type" : "string", - "description" : "The cluster node name." - }, "disk" : { "description" : "If you want to convert only 1 disk to base image.", "enum" : [ @@ -9935,16 +9892,19 @@ var pveapi = [ "optional" : 1, "type" : "string" }, - "vmid" : { - "description" : "The (unique) ID of the VM.", - "type" : "integer", + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, + "vmid" : { + "description" : "The (unique) ID of the VM.", "format" : "pve-vmid", - "minimum" : 1 + "minimum" : 1, + "type" : "integer" } } }, - "protected" : 1, - "method" : "POST", "permissions" : { "check" : [ "perm", @@ -9955,63 +9915,44 @@ var pveapi = [ ], "description" : "You need 'VM.Allocate' permissions on /vms/{vmid}" }, + "protected" : 1, "proxyto" : "node", - "description" : "Create a Template.", "returns" : { "type" : "null" } } }, + "leaf" : 1, "path" : "/nodes/{node}/qemu/{vmid}/template", - "leaf" : 1 + "text" : "template" } ], "info" : { - "GET" : { - "returns" : { - "items" : { - "type" : "object", - "properties" : { - "subdir" : { - "type" : "string" - } - } - }, - "links" : [ - { - "href" : "{subdir}", - "rel" : "child" - } - ], - "type" : "array" - }, - "method" : "GET", - "permissions" : { - "user" : "all" - }, - "name" : "vmdiridx", + "DELETE" : { + "description" : "Destroy the vm (also delete all used/owned volumes).", + "method" : "DELETE", + "name" : "destroy_vm", "parameters" : { + "additionalProperties" : 0, "properties" : { "node" : { + "description" : "The cluster node name.", "format" : "pve-node", - "type" : "string", - "description" : "The cluster node name." + "type" : "string" + }, + "skiplock" : { + "description" : "Ignore locks - only root is allowed to use this option.", + "optional" : 1, + "type" : "boolean" }, "vmid" : { - "minimum" : 1, + "description" : "The (unique) ID of the VM.", "format" : "pve-vmid", - "type" : "integer", - "description" : "The (unique) ID of the VM." + "minimum" : 1, + "type" : "integer" } - }, - "additionalProperties" : 0 + } }, - "description" : "Directory index", - "proxyto" : "node" - }, - "DELETE" : { - "proxyto" : "node", - "description" : "Destroy the vm (also delete all used/owned volumes).", "permissions" : { "check" : [ "perm", @@ -10021,528 +9962,659 @@ var pveapi = [ ] ] }, + "protected" : 1, + "proxyto" : "node", "returns" : { "type" : "string" - }, - "protected" : 1, + } + }, + "GET" : { + "description" : "Directory index", + "method" : "GET", + "name" : "vmdiridx", "parameters" : { + "additionalProperties" : 0, "properties" : { - "vmid" : { - "minimum" : 1, - "format" : "pve-vmid", - "type" : "integer", - "description" : "The (unique) ID of the VM." - }, - "skiplock" : { - "optional" : 1, - "type" : "boolean", - "description" : "Ignore locks - only root is allowed to use this option." - }, "node" : { - "type" : "string", "description" : "The cluster node name.", - "format" : "pve-node" + "format" : "pve-node", + "type" : "string" + }, + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" } - }, - "additionalProperties" : 0 + } }, - "name" : "destroy_vm", - "method" : "DELETE" + "permissions" : { + "user" : "all" + }, + "proxyto" : "node", + "returns" : { + "items" : { + "properties" : { + "subdir" : { + "type" : "string" + } + }, + "type" : "object" + }, + "links" : [ + { + "href" : "{subdir}", + "rel" : "child" + } + ], + "type" : "array" + } } - } + }, + "leaf" : 0, + "path" : "/nodes/{node}/qemu/{vmid}", + "text" : "{vmid}" } ], - "text" : "qemu", "info" : { - "POST" : { - "method" : "POST", + "GET" : { + "description" : "Virtual machine index (per node).", + "method" : "GET", + "name" : "vmlist", "parameters" : { + "additionalProperties" : 0, "properties" : { - "serial[n]" : { - "type" : "string", - "optional" : 1, - "description" : "Create a serial device inside the VM (n is 0 to 3), and pass through a host serial device (i.e. /dev/ttyS0), or create a unix socket on the host side (use 'qm terminal' to open a terminal connection).\n\nNOTE: If you pass through a host serial device, it is no longer possible to migrate such machines - use with special care.\n\nExperimental: user reported problems with this option.\n", - "pattern" : "(/dev/.+|socket)" - }, - "vcpus" : { - "minimum" : 1, - "default" : 0, - "type" : "integer", + "full" : { + "description" : "Determine the full status of active VMs.", "optional" : 1, - "description" : "Number of hotplugged vcpus." + "type" : "boolean" }, - "description" : { - "description" : "Description for the VM. Only used on the configuration web interface. This is saved as comment inside the configuration file.", - "optional" : 1, + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", "type" : "string" - }, - "parallel[n]" : { - "pattern" : "/dev/parport\\d+|/dev/usb/lp\\d+", - "description" : "Map host parallel devices (n is 0 to 2).\n\nNOTE: This option allows direct access to host hardware. So it is no longer possible to migrate such machines - use with special care.\n\nExperimental: user reported problems with this option.\n", - "type" : "string", - "optional" : 1 - }, + } + } + }, + "permissions" : { + "description" : "Only list VMs where you have VM.Audit permissons on /vms/.", + "user" : "all" + }, + "protected" : 1, + "proxyto" : "node", + "returns" : { + "items" : { + "properties" : {}, + "type" : "object" + }, + "links" : [ + { + "href" : "{vmid}", + "rel" : "child" + } + ], + "type" : "array" + } + }, + "POST" : { + "description" : "Create or restore a virtual machine.", + "method" : "POST", + "name" : "create_vm", + "parameters" : { + "additionalProperties" : 0, + "properties" : { "acpi" : { - "description" : "Enable/disable ACPI.", "default" : 1, + "description" : "Enable/disable ACPI.", "optional" : 1, "type" : "boolean" }, - "migrate_downtime" : { - "minimum" : 0, - "default" : 0.1, - "optional" : 1, - "type" : "number", - "description" : "Set maximum tolerated downtime (in seconds) for migrations." - }, - "name" : { - "description" : "Set a name for the VM. Only used on the configuration web interface.", - "type" : "string", - "optional" : 1, - "format" : "dns-name" - }, - "pool" : { - "format" : "pve-poolid", - "description" : "Add the VM to the specified pool.", - "type" : "string", - "optional" : 1 - }, - "cores" : { - "minimum" : 1, - "default" : 1, - "optional" : 1, - "type" : "integer", - "description" : "The number of cores per socket." - }, - "sockets" : { - "description" : "The number of CPU sockets.", - "default" : 1, + "agent" : { + "default" : 0, + "description" : "Enable/disable Qemu GuestAgent.", "optional" : 1, - "type" : "integer", - "minimum" : 1 + "type" : "boolean" }, - "storage" : { - "type" : "string", + "archive" : { + "description" : "The backup file.", + "maxLength" : 255, "optional" : 1, - "description" : "Default storage.", - "format" : "pve-storage-id" + "type" : "string" }, - "freeze" : { + "args" : { + "description" : "Arbitrary arguments passed to kvm, for example:\n\nargs: -no-reboot -no-hpet\n\nNOTE: this option is for experts only.\n", "optional" : 1, - "type" : "boolean", - "description" : "Freeze CPU at startup (use 'c' monitor command to start execution)." + "type" : "string" }, - "onboot" : { - "optional" : 1, - "type" : "boolean", + "autostart" : { "default" : 0, - "description" : "Specifies whether a VM will be started during system bootup." + "description" : "Automatic restart after crash (currently ignored).", + "optional" : 1, + "type" : "boolean" }, - "startup" : { - "typetext" : "[[order=]\\d+] [,up=\\d+] [,down=\\d+] ", - "format" : "pve-startup-order", - "type" : "string", + "balloon" : { + "description" : "Amount of target RAM for the VM in MB. Using zero disables the ballon driver.", + "minimum" : 0, "optional" : 1, - "description" : "Startup and shutdown behavior. Order is a non-negative number defining the general startup order. Shutdown in done with reverse ordering. Additionally you can set the 'up' or 'down' delay in seconds, which specifies a delay to wait before the next VM is started or stopped." + "type" : "integer" }, - "agent" : { - "default" : 0, - "type" : "boolean", + "bios" : { + "default" : "seabios", + "description" : "Select BIOS implementation.", + "enum" : [ + "seabios", + "ovmf" + ], "optional" : 1, - "description" : "Enable/disable Qemu GuestAgent." + "type" : "string" }, - "reboot" : { - "description" : "Allow reboot. If set to '0' the VM exit on reboot.", - "type" : "boolean", + "boot" : { + "default" : "cdn", + "description" : "Boot on floppy (a), hard disk (c), CD-ROM (d), or network (n).", "optional" : 1, - "default" : 1 + "pattern" : "[acdn]{1,4}", + "type" : "string" }, "bootdisk" : { "description" : "Enable booting from specified disk.", + "format" : "pve-qm-bootdisk", + "optional" : 1, "pattern" : "(ide|sata|scsi|virtio)\\d+", - "type" : "string", + "type" : "string" + }, + "cdrom" : { + "description" : "This is an alias for option -ide2", + "format" : "pve-qm-drive", "optional" : 1, - "format" : "pve-qm-bootdisk" + "type" : "string", + "typetext" : "volume" }, - "vmid" : { - "format" : "pve-vmid", + "cores" : { + "default" : 1, + "description" : "The number of cores per socket.", "minimum" : 1, - "description" : "The (unique) ID of the VM.", + "optional" : 1, "type" : "integer" }, - "smbios1" : { - "description" : "Specify SMBIOS type 1 fields.", - "type" : "string", + "cpu" : { + "description" : "Emulated CPU type.", + "format" : { + "cputype" : { + "default" : "kvm64", + "default_key" : 1, + "description" : "Emulated CPU type.", + "enum" : [ + "486", + "athlon", + "pentium", + "pentium2", + "pentium3", + "coreduo", + "core2duo", + "kvm32", + "kvm64", + "qemu32", + "qemu64", + "phenom", + "Conroe", + "Penryn", + "Nehalem", + "Westmere", + "SandyBridge", + "IvyBridge", + "Haswell", + "Haswell-noTSX", + "Broadwell", + "Broadwell-noTSX", + "Opteron_G1", + "Opteron_G2", + "Opteron_G3", + "Opteron_G4", + "Opteron_G5", + "host" + ], + "format_description" : "cputype", + "type" : "string" + }, + "hidden" : { + "default" : 0, + "description" : "Do not identify as a KVM virtual machine.", + "optional" : 1, + "type" : "boolean" + } + }, "optional" : 1, - "maxLength" : 256, - "format" : "pve-qm-smbios1" + "type" : "string" }, - "numa" : { - "description" : "Enable/disable NUMA.", + "cpulimit" : { "default" : 0, + "description" : "Limit of CPU usage.\n\nNOTE: If the computer has 2 CPUs, it has total of '2' CPU time. Value '0' indicates no CPU limit.", + "maximum" : 128, + "minimum" : 0, "optional" : 1, - "type" : "boolean" + "type" : "number" }, "cpuunits" : { - "minimum" : 0, "default" : 1000, + "description" : "CPU weight for a VM. Argument is used in the kernel fair scheduler. The larger the number is, the more CPU time this VM gets. Number is relative to weights of all the other running VMs.\n\nNOTE: You can disable fair-scheduler configuration by setting this to 0.", "maximum" : 500000, - "type" : "integer", + "minimum" : 0, + "optional" : 1, + "type" : "integer" + }, + "description" : { + "description" : "Description for the VM. Only used on the configuration web interface. This is saved as comment inside the configuration file.", "optional" : 1, - "description" : "CPU weight for a VM. Argument is used in the kernel fair scheduler. The larger the number is, the more CPU time this VM gets. Number is relative to weights of all the other running VMs.\n\nNOTE: You can disable fair-scheduler configuration by setting this to 0." + "type" : "string" + }, + "force" : { + "description" : "Allow to overwrite existing VM.", + "optional" : 1, + "requires" : "archive", + "type" : "boolean" + }, + "freeze" : { + "description" : "Freeze CPU at startup (use 'c' monitor command to start execution).", + "optional" : 1, + "type" : "boolean" + }, + "hostpci[n]" : { + "description" : "Map host pci devices. HOSTPCIDEVICE syntax is:\n\n'bus:dev.func' (hexadecimal numbers)\n\nYou can us the 'lspci' command to list existing pci devices.\n\nThe 'rombar' option determines whether or not the device's ROM will be visible in the guest's memory map (default is 'on').\n\nNOTE: This option allows direct access to host hardware. So it is no longer possible to migrate such machines - use with special care.\n\nExperimental: user reported problems with this option.\n", + "format" : "pve-qm-hostpci", + "optional" : 1, + "type" : "string" + }, + "hotplug" : { + "default" : "network,disk,usb", + "description" : "Selectively enable hotplug features. This is a comma separated list of hotplug features: 'network', 'disk', 'cpu', 'memory' and 'usb'. Use '0' to disable hotplug completely. Value '1' is an alias for the default 'network,disk,usb'.", + "format" : "pve-hotplug-features", + "optional" : 1, + "type" : "string" }, "ide[n]" : { + "description" : "Use volume as IDE hard disk or CD-ROM (n is 0 to 3).", "format" : { - "bps_rd" : { + "aio" : { + "description" : "AIO type to use.", + "enum" : [ + "native", + "threads" + ], + "format_description" : "native|threads", + "optional" : 1, + "type" : "string" + }, + "backup" : { + "description" : "Whether the drive should be included when making backups.", + "format_description" : "on|off", + "optional" : 1, + "type" : "boolean" + }, + "bps" : { + "description" : "Maximum r/w speed speed in bytes per second.", "format_description" : "bps", - "type" : "integer", "optional" : 1, - "description" : "Maximum read speed speed in bytes per second." + "type" : "integer" }, - "cyls" : { - "description" : "Force the drive's physical geometry to have a specific cylinder count.", + "bps_rd" : { + "description" : "Maximum read speed speed in bytes per second.", + "format_description" : "bps", "optional" : 1, - "type" : "integer", - "format_description" : "count" + "type" : "integer" }, - "mbps" : { - "description" : "Maximum r/w speed speed in megabytes per second.", - "type" : "number", + "bps_wr" : { + "description" : "Maximum write speed speed in bytes per second.", + "format_description" : "bps", "optional" : 1, - "format_description" : "mbps" + "type" : "integer" }, - "trans" : { + "cache" : { + "description" : "The drive's cache mode", "enum" : [ "none", - "lba", - "auto" + "writethrough", + "writeback", + "unsafe", + "directsync" ], - "description" : "Force disk geometry bios translation mode.", - "type" : "string", + "format_description" : "none|writethrough|writeback|unsafe|directsync", "optional" : 1, - "format_description" : "none|lba|auto" + "type" : "string" }, - "volume" : { - "alias" : "file" + "cyls" : { + "description" : "Force the drive's physical geometry to have a specific cylinder count.", + "format_description" : "count", + "optional" : 1, + "type" : "integer" }, - "mbps_rd" : { - "description" : "Maximum read speed speed in megabytes per second.", - "type" : "number", + "detect_zeroes" : { + "description" : "Controls whether to detect and try to optimize writes of zeroes.", "optional" : 1, - "format_description" : "mbps" + "type" : "boolean" }, - "mbps_wr" : { - "format_description" : "mbps", - "type" : "number", + "discard" : { + "description" : "Controls whether to pass discard/trim requests to the underlying storage.", + "enum" : [ + "ignore", + "on" + ], + "format_description" : "ignore|on", "optional" : 1, - "description" : "Maximum write speed speed in megabytes per second." + "type" : "string" }, "file" : { + "default_key" : 1, "description" : "The drive's backing volume.", - "type" : "string", "format" : "pve-volume-id-or-qm-path", "format_description" : "volume", - "default_key" : 1 - }, - "iops" : { - "format_description" : "iops", - "description" : "Maximum r/w I/O speed in operations per second.", - "type" : "integer", - "optional" : 1 - }, - "model" : { - "maxLength" : 120, - "format" : "urlencoded", - "format_description" : "model", - "description" : "The drive's reported model name, url-encoded, up to 40 bytes long.", - "optional" : 1, "type" : "string" }, - "aio" : { - "format_description" : "native|threads", + "format" : { + "description" : "The drive's backing file's data format.", "enum" : [ - "native", - "threads" + "raw", + "cow", + "qcow", + "qed", + "qcow2", + "vmdk", + "cloop" ], - "description" : "AIO type to use.", + "format_description" : "drive format", "optional" : 1, "type" : "string" }, - "werror" : { - "format_description" : "enospc|ignore|report|stop", - "type" : "string", + "heads" : { + "description" : "Force the drive's physical geometry to have a specific head count.", + "format_description" : "count", "optional" : 1, - "enum" : [ - "enospc", - "ignore", - "report", - "stop" - ], - "description" : "Write error action." + "type" : "integer" }, - "iops_wr_max" : { + "iops" : { + "description" : "Maximum r/w I/O speed in operations per second.", "format_description" : "iops", - "type" : "integer", "optional" : 1, - "description" : "Maximum unthrottled write I/O pool speed in operations per second." + "type" : "integer" }, - "backup" : { - "type" : "boolean", + "iops_max" : { + "description" : "Maximum unthrottled r/w I/O pool speed in operations per second.", + "format_description" : "iops", "optional" : 1, - "description" : "Whether the drive should be included when making backups.", - "format_description" : "on|off" - }, - "bps_wr" : { - "format_description" : "bps", - "description" : "Maximum write speed speed in bytes per second.", - "type" : "integer", - "optional" : 1 + "type" : "integer" }, "iops_rd" : { - "format_description" : "iops", "description" : "Maximum read I/O speed in operations per second.", - "type" : "integer", - "optional" : 1 + "format_description" : "iops", + "optional" : 1, + "type" : "integer" }, - "size" : { - "format" : "disk-size", - "description" : "Disk size. This is purely informational and has no effect.", + "iops_rd_max" : { + "description" : "Maximum unthrottled read I/O pool speed in operations per second.", + "format_description" : "iops", "optional" : 1, - "type" : "string" + "type" : "integer" }, - "mbps_max" : { - "format_description" : "mbps", - "type" : "number", + "iops_wr" : { + "description" : "Maximum write I/O speed in operations per second.", + "format_description" : "iops", "optional" : 1, - "description" : "Maximum unthrottled r/w pool speed in megabytes per second." + "type" : "integer" }, - "heads" : { - "description" : "Force the drive's physical geometry to have a specific head count.", + "iops_wr_max" : { + "description" : "Maximum unthrottled write I/O pool speed in operations per second.", + "format_description" : "iops", "optional" : 1, - "type" : "integer", - "format_description" : "count" + "type" : "integer" }, - "serial" : { + "mbps" : { + "description" : "Maximum r/w speed speed in megabytes per second.", + "format_description" : "mbps", "optional" : 1, - "type" : "string", - "description" : "The drive's reported serial number, url-encoded, up to 20 bytes long.", - "format" : "urlencoded", - "maxLength" : 60, - "format_description" : "serial" + "type" : "number" }, - "mbps_wr_max" : { + "mbps_max" : { + "description" : "Maximum unthrottled r/w pool speed in megabytes per second.", "format_description" : "mbps", - "type" : "number", "optional" : 1, - "description" : "Maximum unthrottled write pool speed in megabytes per second." + "type" : "number" }, - "format" : { + "mbps_rd" : { + "description" : "Maximum read speed speed in megabytes per second.", + "format_description" : "mbps", "optional" : 1, - "type" : "string", - "description" : "The drive's backing file's data format.", - "enum" : [ - "raw", - "cow", - "qcow", - "qed", - "qcow2", - "vmdk", - "cloop" - ], - "format_description" : "drive format" - }, - "iops_rd_max" : { - "optional" : 1, - "type" : "integer", - "description" : "Maximum unthrottled read I/O pool speed in operations per second.", - "format_description" : "iops" + "type" : "number" }, - "bps" : { - "description" : "Maximum r/w speed speed in bytes per second.", - "type" : "integer", + "mbps_rd_max" : { + "description" : "Maximum unthrottled read pool speed in megabytes per second.", + "format_description" : "mbps", "optional" : 1, - "format_description" : "bps" + "type" : "number" }, - "discard" : { - "format_description" : "ignore|on", - "type" : "string", + "mbps_wr" : { + "description" : "Maximum write speed speed in megabytes per second.", + "format_description" : "mbps", "optional" : 1, - "description" : "Controls whether to pass discard/trim requests to the underlying storage.", - "enum" : [ - "ignore", - "on" - ] + "type" : "number" }, - "mbps_rd_max" : { - "description" : "Maximum unthrottled read pool speed in megabytes per second.", - "type" : "number", + "mbps_wr_max" : { + "description" : "Maximum unthrottled write pool speed in megabytes per second.", + "format_description" : "mbps", "optional" : 1, - "format_description" : "mbps" + "type" : "number" }, "media" : { + "default" : "disk", + "description" : "The drive's media type.", "enum" : [ "cdrom", "disk" ], - "description" : "The drive's media type.", - "optional" : 1, - "type" : "string", - "default" : "disk", - "format_description" : "cdrom|disk" - }, - "secs" : { - "optional" : 1, - "type" : "integer", - "description" : "Force the drive's physical geometry to have a specific sector count.", - "format_description" : "count" - }, - "iops_wr" : { - "type" : "integer", + "format_description" : "cdrom|disk", "optional" : 1, - "description" : "Maximum write I/O speed in operations per second.", - "format_description" : "iops" + "type" : "string" }, - "detect_zeroes" : { + "model" : { + "description" : "The drive's reported model name, url-encoded, up to 40 bytes long.", + "format" : "urlencoded", + "format_description" : "model", + "maxLength" : 120, "optional" : 1, - "type" : "boolean", - "description" : "Controls whether to detect and try to optimize writes of zeroes." + "type" : "string" }, "rerror" : { - "format_description" : "ignore|report|stop", - "type" : "string", - "optional" : 1, "description" : "Read error action.", "enum" : [ "ignore", "report", "stop" - ] + ], + "format_description" : "ignore|report|stop", + "optional" : 1, + "type" : "string" }, - "cache" : { - "format_description" : "none|writethrough|writeback|unsafe|directsync", + "secs" : { + "description" : "Force the drive's physical geometry to have a specific sector count.", + "format_description" : "count", "optional" : 1, - "type" : "string", - "description" : "The drive's cache mode", - "enum" : [ - "none", - "writethrough", - "writeback", - "unsafe", - "directsync" - ] + "type" : "integer" + }, + "serial" : { + "description" : "The drive's reported serial number, url-encoded, up to 20 bytes long.", + "format" : "urlencoded", + "format_description" : "serial", + "maxLength" : 60, + "optional" : 1, + "type" : "string" + }, + "size" : { + "description" : "Disk size. This is purely informational and has no effect.", + "format" : "disk-size", + "optional" : 1, + "type" : "string" }, "snapshot" : { + "description" : "Whether the drive should be included when making snapshots.", "format_description" : "on|off", "optional" : 1, - "type" : "boolean", - "description" : "Whether the drive should be included when making snapshots." + "type" : "boolean" }, - "iops_max" : { + "trans" : { + "description" : "Force disk geometry bios translation mode.", + "enum" : [ + "none", + "lba", + "auto" + ], + "format_description" : "none|lba|auto", "optional" : 1, - "type" : "integer", - "description" : "Maximum unthrottled r/w I/O pool speed in operations per second.", - "format_description" : "iops" + "type" : "string" + }, + "volume" : { + "alias" : "file" + }, + "werror" : { + "description" : "Write error action.", + "enum" : [ + "enospc", + "ignore", + "report", + "stop" + ], + "format_description" : "enospc|ignore|report|stop", + "optional" : 1, + "type" : "string" } }, - "description" : "Use volume as IDE hard disk or CD-ROM (n is 0 to 3).", - "optional" : 1, - "type" : "string" - }, - "archive" : { - "maxLength" : 255, - "description" : "The backup file.", "optional" : 1, "type" : "string" }, - "watchdog" : { - "description" : "Create a virtual hardware watchdog device. Once enabled (by a guest action), the watchdog must be periodically polled by an agent inside the guest or else the watchdog will reset the guest (or execute the respective action specified)", - "type" : "string", - "optional" : 1, - "format" : "pve-qm-watchdog" - }, - "hotplug" : { - "type" : "string", - "optional" : 1, - "default" : "network,disk,usb", - "description" : "Selectively enable hotplug features. This is a comma separated list of hotplug features: 'network', 'disk', 'cpu', 'memory' and 'usb'. Use '0' to disable hotplug completely. Value '1' is an alias for the default 'network,disk,usb'.", - "format" : "pve-hotplug-features" - }, "keyboard" : { + "default" : "en-us", "description" : "Keybord layout for vnc server. Default is read from the datacenter configuration file.", "enum" : [ + "de", + "de-ch", "da", - "sv", "en-gb", - "lt", + "en-us", + "es", + "fi", + "fr", + "fr-be", + "fr-ca", + "fr-ch", + "hu", "is", + "it", + "ja", + "lt", "mk", - "pl", - "hu", - "fr-be", - "pt-br", - "de-ch", "nl", "no", - "tr", - "sl", - "de", - "fr-ca", - "ja", - "es", - "it", + "pl", "pt", - "fr", - "en-us", - "fi", - "fr-ch" + "pt-br", + "sv", + "sl", + "tr" ], - "default" : "en-us", - "type" : "string", - "optional" : 1 + "optional" : 1, + "type" : "string" }, - "hostpci[n]" : { - "format" : "pve-qm-hostpci", + "kvm" : { + "default" : 1, + "description" : "Enable/disable KVM hardware virtualization.", "optional" : 1, - "type" : "string", - "description" : "Map host pci devices. HOSTPCIDEVICE syntax is:\n\n'bus:dev.func' (hexadecimal numbers)\n\nYou can us the 'lspci' command to list existing pci devices.\n\nThe 'rombar' option determines whether or not the device's ROM will be visible in the guest's memory map (default is 'on').\n\nNOTE: This option allows direct access to host hardware. So it is no longer possible to migrate such machines - use with special care.\n\nExperimental: user reported problems with this option.\n" + "type" : "boolean" }, - "lock" : { + "localtime" : { + "description" : "Set the real time clock to local time. This is enabled by default if ostype indicates a Microsoft OS.", "optional" : 1, - "type" : "string", + "type" : "boolean" + }, + "lock" : { + "description" : "Lock/unlock the VM.", "enum" : [ "migrate", "backup", "snapshot", "rollback" ], - "description" : "Lock/unlock the VM." + "optional" : 1, + "type" : "string" }, - "autostart" : { - "description" : "Automatic restart after crash (currently ignored).", + "machine" : { + "description" : "Specific the Qemu machine type.", + "maxLength" : 40, + "optional" : 1, + "pattern" : "(pc|pc(-i440fx)?-\\d+\\.\\d+(\\.pxe)?|q35|pc-q35-\\d+\\.\\d+(\\.pxe)?)", + "type" : "string" + }, + "memory" : { + "default" : 512, + "description" : "Amount of RAM for the VM in MB. This is the maximum available memory when you use the balloon device.", + "minimum" : 16, + "optional" : 1, + "type" : "integer" + }, + "migrate_downtime" : { + "default" : 0.1, + "description" : "Set maximum tolerated downtime (in seconds) for migrations.", + "minimum" : 0, + "optional" : 1, + "type" : "number" + }, + "migrate_speed" : { "default" : 0, + "description" : "Set maximum speed (in MB/s) for migrations. Value 0 is no limit.", + "minimum" : 0, "optional" : 1, - "type" : "boolean" + "type" : "integer" }, - "tdf" : { - "description" : "Enable/disable time drift fix.", + "name" : { + "description" : "Set a name for the VM. Only used on the configuration web interface.", + "format" : "dns-name", + "optional" : 1, + "type" : "string" + }, + "net[n]" : { + "description" : "Specify network devices.\n\nMODEL is one of: e1000 e1000-82540em e1000-82544gc e1000-82545em i82551 i82557b i82559er ne2k_isa ne2k_pci pcnet rtl8139 virtio vmxnet3\n\nXX:XX:XX:XX:XX:XX should be an unique MAC address. This is\nautomatically generated if not specified.\n\nThe bridge parameter can be used to automatically add the interface to a bridge device. The Proxmox VE standard bridge is called 'vmbr0'.\n\nOption 'rate' is used to limit traffic bandwidth from and to this interface. It is specified as floating point number, unit is 'Megabytes per second'.\n\nIf you specify no bridge, we create a kvm 'user' (NATed) network device, which provides DHCP and DNS services. The following addresses are used:\n\n10.0.2.2 Gateway\n10.0.2.3 DNS Server\n10.0.2.4 SMB Server\n\nThe DHCP server assign addresses to the guest starting from 10.0.2.15.\n\n", + "format" : "pve-qm-net", + "optional" : 1, + "type" : "string" + }, + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, + "numa" : { "default" : 0, - "type" : "boolean", - "optional" : 1 + "description" : "Enable/disable NUMA.", + "optional" : 1, + "type" : "boolean" }, "numa[n]" : { + "description" : "numa topology", "format" : { + "cpus" : { + "description" : "CPUs accessing this numa node.", + "format_description" : "id[-id];...", + "pattern" : "(?^:\\d+(?:-\\d+)?(?:;\\d+(?:-\\d+)?)*)", + "type" : "string" + }, "hostnodes" : { "description" : "host numa nodes to use", - "pattern" : "(?^:\\d+(?:-\\d+)?(?:;\\d+(?:-\\d+)?)*)", + "format_description" : "id[-id];...", "optional" : 1, - "type" : "string", - "format_description" : "id[-id];..." + "pattern" : "(?^:\\d+(?:-\\d+)?(?:;\\d+(?:-\\d+)?)*)", + "type" : "string" }, - "cpus" : { - "format_description" : "id[-id];...", - "type" : "string", - "description" : "CPUs accessing this numa node.", - "pattern" : "(?^:\\d+(?:-\\d+)?(?:;\\d+(?:-\\d+)?)*)" + "memory" : { + "description" : "Amount of memory this numa node provides.", + "format_description" : "mb", + "optional" : 1, + "type" : "number" }, "policy" : { "description" : "numa allocation policy.", @@ -10551,37 +10623,21 @@ var pveapi = [ "bind", "interleave" ], - "type" : "string", - "optional" : 1, - "format_description" : "preferred|bind|interleave" - }, - "memory" : { - "format_description" : "mb", - "type" : "number", + "format_description" : "preferred|bind|interleave", "optional" : 1, - "description" : "Amount of memory this numa node provides." + "type" : "string" } }, "optional" : 1, - "type" : "string", - "description" : "numa topology" + "type" : "string" }, - "boot" : { - "default" : "cdn", + "onboot" : { + "default" : 0, + "description" : "Specifies whether a VM will be started during system bootup.", "optional" : 1, - "type" : "string", - "pattern" : "[acdn]{1,4}", - "description" : "Boot on floppy (a), hard disk (c), CD-ROM (d), or network (n)." - }, - "unused[n]" : { - "format" : "pve-volume-id", - "description" : "Reference to unused volumes.", - "type" : "string", - "optional" : 1 + "type" : "boolean" }, "ostype" : { - "type" : "string", - "optional" : 1, "description" : "Used to enable special optimization/features for specific\noperating systems:\n\nother => unspecified OS\nwxp => Microsoft Windows XP\nw2k => Microsoft Windows 2000\nw2k3 => Microsoft Windows 2003\nw2k8 => Microsoft Windows 2008\nwvista => Microsoft Windows Vista\nwin7 => Microsoft Windows 7\nwin8 => Microsoft Windows 8/2012\nl24 => Linux 2.4 Kernel\nl26 => Linux 2.6/3.X Kernel\nsolaris => solaris/opensolaris/openindiania kernel\n\nother|l24|l26|solaris ... no special behaviour\nwxp|w2k|w2k3|w2k8|wvista|win7|win8 ... use --localtime switch\n", "enum" : [ "other", @@ -10595,158 +10651,72 @@ var pveapi = [ "l24", "l26", "solaris" - ] - }, - "unique" : { - "requires" : "archive", - "description" : "Assign a unique random ethernet address.", + ], "optional" : 1, - "type" : "boolean" + "type" : "string" }, - "migrate_speed" : { - "description" : "Set maximum speed (in MB/s) for migrations. Value 0 is no limit.", - "default" : 0, + "parallel[n]" : { + "description" : "Map host parallel devices (n is 0 to 2).\n\nNOTE: This option allows direct access to host hardware. So it is no longer possible to migrate such machines - use with special care.\n\nExperimental: user reported problems with this option.\n", "optional" : 1, - "type" : "integer", - "minimum" : 0 + "pattern" : "/dev/parport\\d+|/dev/usb/lp\\d+", + "type" : "string" }, - "startdate" : { - "pattern" : "(now|\\d{4}-\\d{1,2}-\\d{1,2}(T\\d{1,2}:\\d{1,2}:\\d{1,2})?)", - "description" : "Set the initial date of the real time clock. Valid format for date are: 'now' or '2006-06-17T16:01:21' or '2006-06-17'.", - "default" : "now", + "pool" : { + "description" : "Add the VM to the specified pool.", + "format" : "pve-poolid", "optional" : 1, - "type" : "string", - "typetext" : "(now | YYYY-MM-DD | YYYY-MM-DDTHH:MM:SS)" + "type" : "string" }, - "localtime" : { + "protection" : { + "default" : 0, + "description" : "Sets the protection flag of the VM. This will prevent the remove operation.", "optional" : 1, - "type" : "boolean", - "description" : "Set the real time clock to local time. This is enabled by default if ostype indicates a Microsoft OS." + "type" : "boolean" }, - "kvm" : { - "description" : "Enable/disable KVM hardware virtualization.", + "reboot" : { "default" : 1, - "type" : "boolean", - "optional" : 1 + "description" : "Allow reboot. If set to '0' the VM exit on reboot.", + "optional" : 1, + "type" : "boolean" }, "sata[n]" : { + "description" : "Use volume as SATA hard disk or CD-ROM (n is 0 to 5).", "format" : { - "mbps_rd" : { - "format_description" : "mbps", - "description" : "Maximum read speed speed in megabytes per second.", - "optional" : 1, - "type" : "number" - }, - "mbps_wr" : { - "type" : "number", - "optional" : 1, - "description" : "Maximum write speed speed in megabytes per second.", - "format_description" : "mbps" - }, - "file" : { - "description" : "The drive's backing volume.", - "type" : "string", - "format" : "pve-volume-id-or-qm-path", - "format_description" : "volume", - "default_key" : 1 - }, - "iops" : { - "type" : "integer", - "optional" : 1, - "description" : "Maximum r/w I/O speed in operations per second.", - "format_description" : "iops" - }, - "werror" : { - "description" : "Write error action.", - "enum" : [ - "enospc", - "ignore", - "report", - "stop" - ], - "type" : "string", - "optional" : 1, - "format_description" : "enospc|ignore|report|stop" - }, "aio" : { + "description" : "AIO type to use.", "enum" : [ "native", "threads" ], - "description" : "AIO type to use.", - "type" : "string", - "optional" : 1, - "format_description" : "native|threads" - }, - "iops_wr_max" : { - "format_description" : "iops", + "format_description" : "native|threads", "optional" : 1, - "type" : "integer", - "description" : "Maximum unthrottled write I/O pool speed in operations per second." + "type" : "string" }, "backup" : { - "type" : "boolean", - "optional" : 1, "description" : "Whether the drive should be included when making backups.", - "format_description" : "on|off" - }, - "bps_rd" : { - "type" : "integer", - "optional" : 1, - "description" : "Maximum read speed speed in bytes per second.", - "format_description" : "bps" - }, - "cyls" : { - "optional" : 1, - "type" : "integer", - "description" : "Force the drive's physical geometry to have a specific cylinder count.", - "format_description" : "count" - }, - "mbps" : { + "format_description" : "on|off", "optional" : 1, - "type" : "number", - "description" : "Maximum r/w speed speed in megabytes per second.", - "format_description" : "mbps" - }, - "volume" : { - "alias" : "file" + "type" : "boolean" }, - "trans" : { - "format_description" : "none|lba|auto", - "type" : "string", + "bps" : { + "description" : "Maximum r/w speed speed in bytes per second.", + "format_description" : "bps", "optional" : 1, - "enum" : [ - "none", - "lba", - "auto" - ], - "description" : "Force disk geometry bios translation mode." + "type" : "integer" }, - "media" : { - "format_description" : "cdrom|disk", - "type" : "string", + "bps_rd" : { + "description" : "Maximum read speed speed in bytes per second.", + "format_description" : "bps", "optional" : 1, - "default" : "disk", - "enum" : [ - "cdrom", - "disk" - ], - "description" : "The drive's media type." + "type" : "integer" }, - "rerror" : { - "description" : "Read error action.", - "enum" : [ - "ignore", - "report", - "stop" - ], + "bps_wr" : { + "description" : "Maximum write speed speed in bytes per second.", + "format_description" : "bps", "optional" : 1, - "type" : "string", - "format_description" : "ignore|report|stop" + "type" : "integer" }, "cache" : { - "type" : "string", - "optional" : 1, "description" : "The drive's cache mode", "enum" : [ "none", @@ -10755,17 +10725,13 @@ var pveapi = [ "unsafe", "directsync" ], - "format_description" : "none|writethrough|writeback|unsafe|directsync" + "format_description" : "none|writethrough|writeback|unsafe|directsync", + "optional" : 1, + "type" : "string" }, - "secs" : { + "cyls" : { + "description" : "Force the drive's physical geometry to have a specific cylinder count.", "format_description" : "count", - "description" : "Force the drive's physical geometry to have a specific sector count.", - "type" : "integer", - "optional" : 1 - }, - "iops_wr" : { - "format_description" : "iops", - "description" : "Maximum write I/O speed in operations per second.", "optional" : 1, "type" : "integer" }, @@ -10774,61 +10740,25 @@ var pveapi = [ "optional" : 1, "type" : "boolean" }, - "iops_max" : { - "format_description" : "iops", - "description" : "Maximum unthrottled r/w I/O pool speed in operations per second.", - "type" : "integer", - "optional" : 1 - }, - "snapshot" : { - "format_description" : "on|off", - "description" : "Whether the drive should be included when making snapshots.", - "optional" : 1, - "type" : "boolean" - }, - "bps_wr" : { - "format_description" : "bps", - "type" : "integer", - "optional" : 1, - "description" : "Maximum write speed speed in bytes per second." - }, - "mbps_max" : { - "format_description" : "mbps", - "description" : "Maximum unthrottled r/w pool speed in megabytes per second.", - "type" : "number", - "optional" : 1 - }, - "iops_rd" : { - "format_description" : "iops", - "optional" : 1, - "type" : "integer", - "description" : "Maximum read I/O speed in operations per second." - }, - "size" : { - "format" : "disk-size", - "type" : "string", - "optional" : 1, - "description" : "Disk size. This is purely informational and has no effect." - }, - "iops_rd_max" : { - "format_description" : "iops", - "optional" : 1, - "type" : "integer", - "description" : "Maximum unthrottled read I/O pool speed in operations per second." - }, - "mbps_wr_max" : { - "format_description" : "mbps", + "discard" : { + "description" : "Controls whether to pass discard/trim requests to the underlying storage.", + "enum" : [ + "ignore", + "on" + ], + "format_description" : "ignore|on", "optional" : 1, - "type" : "number", - "description" : "Maximum unthrottled write pool speed in megabytes per second." + "type" : "string" }, - "bps" : { - "format_description" : "bps", - "description" : "Maximum r/w speed speed in bytes per second.", - "optional" : 1, - "type" : "integer" + "file" : { + "default_key" : 1, + "description" : "The drive's backing volume.", + "format" : "pve-volume-id-or-qm-path", + "format_description" : "volume", + "type" : "string" }, "format" : { + "description" : "The drive's backing file's data format.", "enum" : [ "raw", "cow", @@ -10838,264 +10768,151 @@ var pveapi = [ "vmdk", "cloop" ], - "description" : "The drive's backing file's data format.", - "type" : "string", + "format_description" : "drive format", "optional" : 1, - "format_description" : "drive format" + "type" : "string" }, "heads" : { - "optional" : 1, - "type" : "integer", "description" : "Force the drive's physical geometry to have a specific head count.", - "format_description" : "count" + "format_description" : "count", + "optional" : 1, + "type" : "integer" }, - "serial" : { - "format_description" : "serial", - "format" : "urlencoded", - "maxLength" : 60, - "description" : "The drive's reported serial number, url-encoded, up to 20 bytes long.", - "type" : "string", - "optional" : 1 + "iops" : { + "description" : "Maximum r/w I/O speed in operations per second.", + "format_description" : "iops", + "optional" : 1, + "type" : "integer" }, - "discard" : { - "description" : "Controls whether to pass discard/trim requests to the underlying storage.", - "enum" : [ - "ignore", - "on" - ], - "type" : "string", + "iops_max" : { + "description" : "Maximum unthrottled r/w I/O pool speed in operations per second.", + "format_description" : "iops", "optional" : 1, - "format_description" : "ignore|on" + "type" : "integer" }, - "mbps_rd_max" : { - "format_description" : "mbps", + "iops_rd" : { + "description" : "Maximum read I/O speed in operations per second.", + "format_description" : "iops", "optional" : 1, - "type" : "number", - "description" : "Maximum unthrottled read pool speed in megabytes per second." - } - }, - "description" : "Use volume as SATA hard disk or CD-ROM (n is 0 to 5).", - "type" : "string", - "optional" : 1 - }, - "node" : { - "type" : "string", - "description" : "The cluster node name.", - "format" : "pve-node" - }, - "force" : { - "requires" : "archive", - "description" : "Allow to overwrite existing VM.", - "type" : "boolean", - "optional" : 1 - }, - "cpulimit" : { - "minimum" : 0, - "default" : 0, - "maximum" : 128, - "type" : "number", - "optional" : 1, - "description" : "Limit of CPU usage.\n\nNOTE: If the computer has 2 CPUs, it has total of '2' CPU time. Value '0' indicates no CPU limit." - }, - "tablet" : { - "description" : "Enable/disable the USB tablet device. This device is usually needed to allow absolute mouse positioning with VNC. Else the mouse runs out of sync with normal VNC clients. If you're running lots of console-only guests on one host, you may consider disabling this to save some context switches. This is turned off by default if you use spice (-vga=qxl).", - "optional" : 1, - "type" : "boolean", - "default" : 1 - }, - "vga" : { - "type" : "string", - "optional" : 1, - "description" : "Select the VGA type. If you want to use high resolution modes (>= 1280x1024x16) then you should use the options 'std' or 'vmware'. Default is 'std' for win8/win7/w2k8, and 'cirrus' for other OS types. The 'qxl' option enables the SPICE display sever. For win* OS you can select how many independent displays you want, Linux guests can add displays them self. You can also run without any graphic card, using a serial device as terminal.", - "enum" : [ - "std", - "cirrus", - "vmware", - "qxl", - "serial0", - "serial1", - "serial2", - "serial3", - "qxl2", - "qxl3", - "qxl4" - ] - }, - "virtio[n]" : { - "description" : "Use volume as VIRTIO hard disk (n is 0 to 15).", - "optional" : 1, - "type" : "string", - "format" : { - "snapshot" : { - "description" : "Whether the drive should be included when making snapshots.", - "type" : "boolean", - "optional" : 1, - "format_description" : "on|off" + "type" : "integer" }, - "iops_max" : { + "iops_rd_max" : { + "description" : "Maximum unthrottled read I/O pool speed in operations per second.", "format_description" : "iops", "optional" : 1, - "type" : "integer", - "description" : "Maximum unthrottled r/w I/O pool speed in operations per second." - }, - "iothread" : { - "format_description" : "off|on", - "type" : "boolean", - "optional" : 1, - "description" : "Whether to use iothreads for this drive" + "type" : "integer" }, - "media" : { - "format_description" : "cdrom|disk", - "default" : "disk", + "iops_wr" : { + "description" : "Maximum write I/O speed in operations per second.", + "format_description" : "iops", "optional" : 1, - "type" : "string", - "description" : "The drive's media type.", - "enum" : [ - "cdrom", - "disk" - ] + "type" : "integer" }, - "secs" : { - "format_description" : "count", - "description" : "Force the drive's physical geometry to have a specific sector count.", + "iops_wr_max" : { + "description" : "Maximum unthrottled write I/O pool speed in operations per second.", + "format_description" : "iops", "optional" : 1, "type" : "integer" }, - "iops_wr" : { - "type" : "integer", + "mbps" : { + "description" : "Maximum r/w speed speed in megabytes per second.", + "format_description" : "mbps", "optional" : 1, - "description" : "Maximum write I/O speed in operations per second.", - "format_description" : "iops" + "type" : "number" }, - "detect_zeroes" : { + "mbps_max" : { + "description" : "Maximum unthrottled r/w pool speed in megabytes per second.", + "format_description" : "mbps", "optional" : 1, - "type" : "boolean", - "description" : "Controls whether to detect and try to optimize writes of zeroes." + "type" : "number" }, - "rerror" : { + "mbps_rd" : { + "description" : "Maximum read speed speed in megabytes per second.", + "format_description" : "mbps", "optional" : 1, - "type" : "string", - "enum" : [ - "ignore", - "report", - "stop" - ], - "description" : "Read error action.", - "format_description" : "ignore|report|stop" + "type" : "number" }, - "cache" : { - "format_description" : "none|writethrough|writeback|unsafe|directsync", - "enum" : [ - "none", - "writethrough", - "writeback", - "unsafe", - "directsync" - ], - "description" : "The drive's cache mode", + "mbps_rd_max" : { + "description" : "Maximum unthrottled read pool speed in megabytes per second.", + "format_description" : "mbps", "optional" : 1, - "type" : "string" + "type" : "number" }, - "heads" : { - "type" : "integer", + "mbps_wr" : { + "description" : "Maximum write speed speed in megabytes per second.", + "format_description" : "mbps", "optional" : 1, - "description" : "Force the drive's physical geometry to have a specific head count.", - "format_description" : "count" - }, - "serial" : { - "format_description" : "serial", - "maxLength" : 60, - "format" : "urlencoded", - "description" : "The drive's reported serial number, url-encoded, up to 20 bytes long.", - "type" : "string", - "optional" : 1 + "type" : "number" }, "mbps_wr_max" : { - "format_description" : "mbps", "description" : "Maximum unthrottled write pool speed in megabytes per second.", - "type" : "number", - "optional" : 1 - }, - "iops_rd_max" : { - "description" : "Maximum unthrottled read I/O pool speed in operations per second.", - "type" : "integer", + "format_description" : "mbps", "optional" : 1, - "format_description" : "iops" + "type" : "number" }, - "format" : { + "media" : { + "default" : "disk", + "description" : "The drive's media type.", "enum" : [ - "raw", - "cow", - "qcow", - "qed", - "qcow2", - "vmdk", - "cloop" + "cdrom", + "disk" ], - "description" : "The drive's backing file's data format.", - "optional" : 1, - "type" : "string", - "format_description" : "drive format" - }, - "bps" : { - "format_description" : "bps", + "format_description" : "cdrom|disk", "optional" : 1, - "type" : "integer", - "description" : "Maximum r/w speed speed in bytes per second." + "type" : "string" }, - "discard" : { - "format_description" : "ignore|on", + "rerror" : { + "description" : "Read error action.", "enum" : [ "ignore", - "on" + "report", + "stop" ], - "description" : "Controls whether to pass discard/trim requests to the underlying storage.", - "type" : "string", - "optional" : 1 - }, - "mbps_rd_max" : { + "format_description" : "ignore|report|stop", "optional" : 1, - "type" : "number", - "description" : "Maximum unthrottled read pool speed in megabytes per second.", - "format_description" : "mbps" + "type" : "string" }, - "bps_wr" : { - "description" : "Maximum write speed speed in bytes per second.", - "type" : "integer", + "secs" : { + "description" : "Force the drive's physical geometry to have a specific sector count.", + "format_description" : "count", "optional" : 1, - "format_description" : "bps" + "type" : "integer" }, - "iops_rd" : { - "format_description" : "iops", - "description" : "Maximum read I/O speed in operations per second.", - "type" : "integer", - "optional" : 1 + "serial" : { + "description" : "The drive's reported serial number, url-encoded, up to 20 bytes long.", + "format" : "urlencoded", + "format_description" : "serial", + "maxLength" : 60, + "optional" : 1, + "type" : "string" }, "size" : { "description" : "Disk size. This is purely informational and has no effect.", + "format" : "disk-size", "optional" : 1, - "type" : "string", - "format" : "disk-size" + "type" : "string" }, - "mbps_max" : { - "description" : "Maximum unthrottled r/w pool speed in megabytes per second.", + "snapshot" : { + "description" : "Whether the drive should be included when making snapshots.", + "format_description" : "on|off", "optional" : 1, - "type" : "number", - "format_description" : "mbps" + "type" : "boolean" }, - "aio" : { - "type" : "string", - "optional" : 1, + "trans" : { + "description" : "Force disk geometry bios translation mode.", "enum" : [ - "native", - "threads" + "none", + "lba", + "auto" ], - "description" : "AIO type to use.", - "format_description" : "native|threads" + "format_description" : "none|lba|auto", + "optional" : 1, + "type" : "string" + }, + "volume" : { + "alias" : "file" }, "werror" : { - "optional" : 1, - "type" : "string", "description" : "Write error action.", "enum" : [ "enospc", @@ -11103,200 +10920,94 @@ var pveapi = [ "report", "stop" ], - "format_description" : "enospc|ignore|report|stop" - }, - "iops_wr_max" : { - "format_description" : "iops", - "description" : "Maximum unthrottled write I/O pool speed in operations per second.", + "format_description" : "enospc|ignore|report|stop", "optional" : 1, - "type" : "integer" + "type" : "string" + } + }, + "optional" : 1, + "type" : "string" + }, + "scsi[n]" : { + "description" : "Use volume as SCSI hard disk or CD-ROM (n is 0 to 13).", + "format" : { + "aio" : { + "description" : "AIO type to use.", + "enum" : [ + "native", + "threads" + ], + "format_description" : "native|threads", + "optional" : 1, + "type" : "string" }, "backup" : { + "description" : "Whether the drive should be included when making backups.", "format_description" : "on|off", - "type" : "boolean", "optional" : 1, - "description" : "Whether the drive should be included when making backups." - }, - "mbps_rd" : { - "format_description" : "mbps", - "description" : "Maximum read speed speed in megabytes per second.", - "type" : "number", - "optional" : 1 + "type" : "boolean" }, - "mbps_wr" : { - "format_description" : "mbps", - "type" : "number", + "bps" : { + "description" : "Maximum r/w speed speed in bytes per second.", + "format_description" : "bps", "optional" : 1, - "description" : "Maximum write speed speed in megabytes per second." - }, - "file" : { - "type" : "string", - "description" : "The drive's backing volume.", - "default_key" : 1, - "format_description" : "volume", - "format" : "pve-volume-id-or-qm-path" + "type" : "integer" }, - "iops" : { - "format_description" : "iops", - "type" : "integer", + "bps_rd" : { + "description" : "Maximum read speed speed in bytes per second.", + "format_description" : "bps", "optional" : 1, - "description" : "Maximum r/w I/O speed in operations per second." + "type" : "integer" }, - "trans" : { - "type" : "string", - "optional" : 1, - "description" : "Force disk geometry bios translation mode.", - "enum" : [ - "none", - "lba", - "auto" - ], - "format_description" : "none|lba|auto" - }, - "volume" : { - "alias" : "file" - }, - "bps_rd" : { - "description" : "Maximum read speed speed in bytes per second.", - "type" : "integer", - "optional" : 1, - "format_description" : "bps" - }, - "cyls" : { - "type" : "integer", - "optional" : 1, - "description" : "Force the drive's physical geometry to have a specific cylinder count.", - "format_description" : "count" - }, - "mbps" : { - "description" : "Maximum r/w speed speed in megabytes per second.", + "bps_wr" : { + "description" : "Maximum write speed speed in bytes per second.", + "format_description" : "bps", "optional" : 1, - "type" : "number", - "format_description" : "mbps" - } - } - }, - "balloon" : { - "optional" : 1, - "type" : "integer", - "description" : "Amount of target RAM for the VM in MB. Using zero disables the ballon driver.", - "minimum" : 0 - }, - "scsi[n]" : { - "format" : { - "volume" : { - "alias" : "file" + "type" : "integer" }, - "trans" : { - "type" : "string", - "optional" : 1, + "cache" : { + "description" : "The drive's cache mode", "enum" : [ "none", - "lba", - "auto" + "writethrough", + "writeback", + "unsafe", + "directsync" ], - "description" : "Force disk geometry bios translation mode.", - "format_description" : "none|lba|auto" - }, - "queues" : { - "minimum" : 2, - "format_description" : "nbqueues", - "optional" : 1, - "type" : "integer", - "description" : "Number of queues." - }, - "bps_rd" : { - "format_description" : "bps", - "type" : "integer", - "optional" : 1, - "description" : "Maximum read speed speed in bytes per second." - }, - "mbps" : { - "format_description" : "mbps", - "description" : "Maximum r/w speed speed in megabytes per second.", + "format_description" : "none|writethrough|writeback|unsafe|directsync", "optional" : 1, - "type" : "number" + "type" : "string" }, "cyls" : { "description" : "Force the drive's physical geometry to have a specific cylinder count.", + "format_description" : "count", "optional" : 1, - "type" : "integer", - "format_description" : "count" + "type" : "integer" }, - "werror" : { - "enum" : [ - "enospc", - "ignore", - "report", - "stop" - ], - "description" : "Write error action.", + "detect_zeroes" : { + "description" : "Controls whether to detect and try to optimize writes of zeroes.", "optional" : 1, - "type" : "string", - "format_description" : "enospc|ignore|report|stop" + "type" : "boolean" }, - "aio" : { - "format_description" : "native|threads", - "optional" : 1, - "type" : "string", + "discard" : { + "description" : "Controls whether to pass discard/trim requests to the underlying storage.", "enum" : [ - "native", - "threads" + "ignore", + "on" ], - "description" : "AIO type to use." - }, - "backup" : { - "format_description" : "on|off", - "optional" : 1, - "type" : "boolean", - "description" : "Whether the drive should be included when making backups." - }, - "iops_wr_max" : { - "format_description" : "iops", - "type" : "integer", - "optional" : 1, - "description" : "Maximum unthrottled write I/O pool speed in operations per second." - }, - "mbps_wr" : { - "format_description" : "mbps", - "description" : "Maximum write speed speed in megabytes per second.", - "type" : "number", - "optional" : 1 - }, - "mbps_rd" : { - "format_description" : "mbps", - "type" : "number", - "optional" : 1, - "description" : "Maximum read speed speed in megabytes per second." - }, - "iops" : { - "format_description" : "iops", - "description" : "Maximum r/w I/O speed in operations per second.", + "format_description" : "ignore|on", "optional" : 1, - "type" : "integer" + "type" : "string" }, "file" : { - "format" : "pve-volume-id-or-qm-path", - "format_description" : "volume", "default_key" : 1, "description" : "The drive's backing volume.", + "format" : "pve-volume-id-or-qm-path", + "format_description" : "volume", "type" : "string" }, - "bps" : { - "type" : "integer", - "optional" : 1, - "description" : "Maximum r/w speed speed in bytes per second.", - "format_description" : "bps" - }, - "mbps_wr_max" : { - "optional" : 1, - "type" : "number", - "description" : "Maximum unthrottled write pool speed in megabytes per second.", - "format_description" : "mbps" - }, "format" : { - "optional" : 1, - "type" : "string", + "description" : "The drive's backing file's data format.", "enum" : [ "raw", "cow", @@ -11306,735 +11017,1020 @@ var pveapi = [ "vmdk", "cloop" ], - "description" : "The drive's backing file's data format.", - "format_description" : "drive format" + "format_description" : "drive format", + "optional" : 1, + "type" : "string" }, - "iops_rd_max" : { + "heads" : { + "description" : "Force the drive's physical geometry to have a specific head count.", + "format_description" : "count", + "optional" : 1, + "type" : "integer" + }, + "iops" : { + "description" : "Maximum r/w I/O speed in operations per second.", "format_description" : "iops", - "type" : "integer", "optional" : 1, - "description" : "Maximum unthrottled read I/O pool speed in operations per second." + "type" : "integer" }, - "serial" : { - "description" : "The drive's reported serial number, url-encoded, up to 20 bytes long.", + "iops_max" : { + "description" : "Maximum unthrottled r/w I/O pool speed in operations per second.", + "format_description" : "iops", "optional" : 1, - "type" : "string", - "format_description" : "serial", - "format" : "urlencoded", - "maxLength" : 60 + "type" : "integer" }, - "heads" : { - "description" : "Force the drive's physical geometry to have a specific head count.", - "type" : "integer", + "iops_rd" : { + "description" : "Maximum read I/O speed in operations per second.", + "format_description" : "iops", "optional" : 1, - "format_description" : "count" + "type" : "integer" }, - "mbps_rd_max" : { - "format_description" : "mbps", - "description" : "Maximum unthrottled read pool speed in megabytes per second.", - "type" : "number", - "optional" : 1 + "iops_rd_max" : { + "description" : "Maximum unthrottled read I/O pool speed in operations per second.", + "format_description" : "iops", + "optional" : 1, + "type" : "integer" }, - "discard" : { - "enum" : [ - "ignore", - "on" - ], - "description" : "Controls whether to pass discard/trim requests to the underlying storage.", - "type" : "string", + "iops_wr" : { + "description" : "Maximum write I/O speed in operations per second.", + "format_description" : "iops", "optional" : 1, - "format_description" : "ignore|on" + "type" : "integer" }, - "bps_wr" : { - "format_description" : "bps", - "description" : "Maximum write speed speed in bytes per second.", + "iops_wr_max" : { + "description" : "Maximum unthrottled write I/O pool speed in operations per second.", + "format_description" : "iops", "optional" : 1, "type" : "integer" }, + "iothread" : { + "description" : "Whether to use iothreads for this drive", + "format_description" : "off|on", + "optional" : 1, + "type" : "boolean" + }, + "mbps" : { + "description" : "Maximum r/w speed speed in megabytes per second.", + "format_description" : "mbps", + "optional" : 1, + "type" : "number" + }, "mbps_max" : { "description" : "Maximum unthrottled r/w pool speed in megabytes per second.", - "type" : "number", + "format_description" : "mbps", "optional" : 1, - "format_description" : "mbps" + "type" : "number" }, - "size" : { - "format" : "disk-size", - "description" : "Disk size. This is purely informational and has no effect.", - "type" : "string", - "optional" : 1 + "mbps_rd" : { + "description" : "Maximum read speed speed in megabytes per second.", + "format_description" : "mbps", + "optional" : 1, + "type" : "number" }, - "iops_rd" : { - "format_description" : "iops", - "description" : "Maximum read I/O speed in operations per second.", + "mbps_rd_max" : { + "description" : "Maximum unthrottled read pool speed in megabytes per second.", + "format_description" : "mbps", "optional" : 1, - "type" : "integer" + "type" : "number" }, - "iops_max" : { - "format_description" : "iops", + "mbps_wr" : { + "description" : "Maximum write speed speed in megabytes per second.", + "format_description" : "mbps", "optional" : 1, - "type" : "integer", - "description" : "Maximum unthrottled r/w I/O pool speed in operations per second." + "type" : "number" }, - "snapshot" : { - "description" : "Whether the drive should be included when making snapshots.", + "mbps_wr_max" : { + "description" : "Maximum unthrottled write pool speed in megabytes per second.", + "format_description" : "mbps", "optional" : 1, - "type" : "boolean", - "format_description" : "on|off" + "type" : "number" }, "media" : { - "format_description" : "cdrom|disk", + "default" : "disk", "description" : "The drive's media type.", "enum" : [ "cdrom", "disk" ], - "default" : "disk", - "type" : "string", - "optional" : 1 - }, - "iothread" : { - "format_description" : "off|on", - "description" : "Whether to use iothreads for this drive", - "type" : "boolean", - "optional" : 1 - }, - "cache" : { - "description" : "The drive's cache mode", - "enum" : [ - "none", - "writethrough", - "writeback", - "unsafe", - "directsync" - ], + "format_description" : "cdrom|disk", "optional" : 1, - "type" : "string", - "format_description" : "none|writethrough|writeback|unsafe|directsync" - }, - "detect_zeroes" : { - "description" : "Controls whether to detect and try to optimize writes of zeroes.", - "type" : "boolean", - "optional" : 1 + "type" : "string" }, - "iops_wr" : { - "format_description" : "iops", - "description" : "Maximum write I/O speed in operations per second.", - "type" : "integer", - "optional" : 1 + "queues" : { + "description" : "Number of queues.", + "format_description" : "nbqueues", + "minimum" : 2, + "optional" : 1, + "type" : "integer" }, "secs" : { - "format_description" : "count", "description" : "Force the drive's physical geometry to have a specific sector count.", - "type" : "integer", - "optional" : 1 + "format_description" : "count", + "optional" : 1, + "type" : "integer" + }, + "serial" : { + "description" : "The drive's reported serial number, url-encoded, up to 20 bytes long.", + "format" : "urlencoded", + "format_description" : "serial", + "maxLength" : 60, + "optional" : 1, + "type" : "string" + }, + "size" : { + "description" : "Disk size. This is purely informational and has no effect.", + "format" : "disk-size", + "optional" : 1, + "type" : "string" + }, + "snapshot" : { + "description" : "Whether the drive should be included when making snapshots.", + "format_description" : "on|off", + "optional" : 1, + "type" : "boolean" + }, + "trans" : { + "description" : "Force disk geometry bios translation mode.", + "enum" : [ + "none", + "lba", + "auto" + ], + "format_description" : "none|lba|auto", + "optional" : 1, + "type" : "string" + }, + "volume" : { + "alias" : "file" + }, + "werror" : { + "description" : "Write error action.", + "enum" : [ + "enospc", + "ignore", + "report", + "stop" + ], + "format_description" : "enospc|ignore|report|stop", + "optional" : 1, + "type" : "string" } }, - "type" : "string", "optional" : 1, - "description" : "Use volume as SCSI hard disk or CD-ROM (n is 0 to 13)." + "type" : "string" }, - "net[n]" : { + "scsihw" : { + "default" : "lsi", + "description" : "scsi controller model", + "enum" : [ + "lsi", + "lsi53c810", + "virtio-scsi-pci", + "virtio-scsi-single", + "megasas", + "pvscsi" + ], "optional" : 1, - "type" : "string", - "description" : "Specify network devices.\n\nMODEL is one of: e1000 e1000-82540em e1000-82544gc e1000-82545em i82551 i82557b i82559er ne2k_isa ne2k_pci pcnet rtl8139 virtio vmxnet3\n\nXX:XX:XX:XX:XX:XX should be an unique MAC address. This is\nautomatically generated if not specified.\n\nThe bridge parameter can be used to automatically add the interface to a bridge device. The Proxmox VE standard bridge is called 'vmbr0'.\n\nOption 'rate' is used to limit traffic bandwidth from and to this interface. It is specified as floating point number, unit is 'Megabytes per second'.\n\nIf you specify no bridge, we create a kvm 'user' (NATed) network device, which provides DHCP and DNS services. The following addresses are used:\n\n10.0.2.2 Gateway\n10.0.2.3 DNS Server\n10.0.2.4 SMB Server\n\nThe DHCP server assign addresses to the guest starting from 10.0.2.15.\n\n", - "format" : "pve-qm-net" + "type" : "string" }, - "machine" : { - "maxLength" : 40, - "description" : "Specific the Qemu machine type.", - "pattern" : "(pc|pc(-i440fx)?-\\d+\\.\\d+(\\.pxe)?|q35|pc-q35-\\d+\\.\\d+(\\.pxe)?)", + "serial[n]" : { + "description" : "Create a serial device inside the VM (n is 0 to 3), and pass through a host serial device (i.e. /dev/ttyS0), or create a unix socket on the host side (use 'qm terminal' to open a terminal connection).\n\nNOTE: If you pass through a host serial device, it is no longer possible to migrate such machines - use with special care.\n\nExperimental: user reported problems with this option.\n", + "optional" : 1, + "pattern" : "(/dev/.+|socket)", + "type" : "string" + }, + "shares" : { + "default" : 1000, + "description" : "Amount of memory shares for auto-ballooning. The larger the number is, the more memory this VM gets. Number is relative to weights of all other running VMs. Using zero disables auto-ballooning", + "maximum" : 50000, + "minimum" : 0, + "optional" : 1, + "type" : "integer" + }, + "smbios1" : { + "description" : "Specify SMBIOS type 1 fields.", + "format" : "pve-qm-smbios1", + "maxLength" : 256, "optional" : 1, "type" : "string" }, "smp" : { + "default" : 1, "description" : "The number of CPUs. Please use option -sockets instead.", + "minimum" : 1, "optional" : 1, - "type" : "integer", + "type" : "integer" + }, + "sockets" : { "default" : 1, - "minimum" : 1 + "description" : "The number of CPU sockets.", + "minimum" : 1, + "optional" : 1, + "type" : "integer" }, - "bios" : { - "description" : "Select BIOS implementation.", - "enum" : [ - "seabios", - "ovmf" - ], - "default" : "seabios", + "startdate" : { + "default" : "now", + "description" : "Set the initial date of the real time clock. Valid format for date are: 'now' or '2006-06-17T16:01:21' or '2006-06-17'.", + "optional" : 1, + "pattern" : "(now|\\d{4}-\\d{1,2}-\\d{1,2}(T\\d{1,2}:\\d{1,2}:\\d{1,2})?)", + "type" : "string", + "typetext" : "(now | YYYY-MM-DD | YYYY-MM-DDTHH:MM:SS)" + }, + "startup" : { + "description" : "Startup and shutdown behavior. Order is a non-negative number defining the general startup order. Shutdown in done with reverse ordering. Additionally you can set the 'up' or 'down' delay in seconds, which specifies a delay to wait before the next VM is started or stopped.", + "format" : "pve-startup-order", + "optional" : 1, + "type" : "string", + "typetext" : "[[order=]\\d+] [,up=\\d+] [,down=\\d+] " + }, + "storage" : { + "description" : "Default storage.", + "format" : "pve-storage-id", "optional" : 1, "type" : "string" }, - "shares" : { - "description" : "Amount of memory shares for auto-ballooning. The larger the number is, the more memory this VM gets. Number is relative to weights of all other running VMs. Using zero disables auto-ballooning", - "type" : "integer", + "tablet" : { + "default" : 1, + "description" : "Enable/disable the USB tablet device. This device is usually needed to allow absolute mouse positioning with VNC. Else the mouse runs out of sync with normal VNC clients. If you're running lots of console-only guests on one host, you may consider disabling this to save some context switches. This is turned off by default if you use spice (-vga=qxl).", "optional" : 1, - "default" : 1000, - "maximum" : 50000, - "minimum" : 0 + "type" : "boolean" + }, + "tdf" : { + "default" : 0, + "description" : "Enable/disable time drift fix.", + "optional" : 1, + "type" : "boolean" }, "template" : { - "description" : "Enable/disable Template.", "default" : 0, + "description" : "Enable/disable Template.", "optional" : 1, "type" : "boolean" }, - "scsihw" : { - "enum" : [ - "lsi", - "lsi53c810", - "virtio-scsi-pci", - "virtio-scsi-single", - "megasas", - "pvscsi" - ], - "description" : "scsi controller model", - "type" : "string", + "unique" : { + "description" : "Assign a unique random ethernet address.", "optional" : 1, - "default" : "lsi" + "requires" : "archive", + "type" : "boolean" }, - "usb[n]" : { - "type" : "string", + "unused[n]" : { + "description" : "Reference to unused volumes.", + "format" : "pve-volume-id", "optional" : 1, + "type" : "string" + }, + "usb[n]" : { "description" : "Configure an USB device (n is 0 to 4). This can be used to\npass-through usb devices to the guest. HOSTUSBDEVICE syntax is:\n\n'bus-port(.port)*' (decimal numbers) or\n'vendor_id:product_id' (hexadeciaml numbers) or\n'spice'\n\nYou can use the 'lsusb -t' command to list existing usb devices.\n\nNOTE: This option allows direct access to host hardware. So it is no longer possible to migrate such machines - use with special care.\n\nThe value 'spice' can be used to add a usb redirection devices for spice.\n\nThe 'usb3' option determines whether the device is a USB3 device or not (this does currently not work reliably with spice redirection and is then ignored).\n\n", "format" : { "host" : { "default_key" : 1, - "format_description" : "HOSTUSBDEVICE|spice", + "description" : "The Host USB device or port or the value spice", "format" : "pve-qm-usb-device", - "type" : "string", - "description" : "The Host USB device or port or the value spice" + "format_description" : "HOSTUSBDEVICE|spice", + "type" : "string" }, "usb3" : { - "format_description" : "yes|no", "description" : "Specifies whether if given host option is a USB3 device or port", + "format_description" : "yes|no", "optional" : 1, "type" : "boolean" } - } - }, - "cpu" : { - "format" : { - "hidden" : { - "description" : "Do not identify as a KVM virtual machine.", - "type" : "boolean", - "optional" : 1, - "default" : 0 - }, - "cputype" : { - "description" : "Emulated CPU type.", - "enum" : [ - "486", - "athlon", - "pentium", - "pentium2", - "pentium3", - "coreduo", - "core2duo", - "kvm32", - "kvm64", - "qemu32", - "qemu64", - "phenom", - "Conroe", - "Penryn", - "Nehalem", - "Westmere", - "SandyBridge", - "IvyBridge", - "Haswell", - "Haswell-noTSX", - "Broadwell", - "Broadwell-noTSX", - "Opteron_G1", - "Opteron_G2", - "Opteron_G3", - "Opteron_G4", - "Opteron_G5", - "host" - ], - "default" : "kvm64", - "type" : "string", - "format_description" : "cputype", - "default_key" : 1 - } }, - "type" : "string", "optional" : 1, - "description" : "Emulated CPU type." - }, - "cdrom" : { - "format" : "pve-qm-drive", - "typetext" : "volume", - "description" : "This is an alias for option -ide2", - "type" : "string", - "optional" : 1 + "type" : "string" }, - "memory" : { - "description" : "Amount of RAM for the VM in MB. This is the maximum available memory when you use the balloon device.", - "default" : 512, + "vcpus" : { + "default" : 0, + "description" : "Number of hotplugged vcpus.", + "minimum" : 1, "optional" : 1, - "type" : "integer", - "minimum" : 16 + "type" : "integer" }, - "args" : { - "description" : "Arbitrary arguments passed to kvm, for example:\n\nargs: -no-reboot -no-hpet\n\nNOTE: this option is for experts only.\n", - "type" : "string", - "optional" : 1 + "vga" : { + "description" : "Select the VGA type. If you want to use high resolution modes (>= 1280x1024x16) then you should use the options 'std' or 'vmware'. Default is 'std' for win8/win7/w2k8, and 'cirrus' for other OS types. The 'qxl' option enables the SPICE display sever. For win* OS you can select how many independent displays you want, Linux guests can add displays them self. You can also run without any graphic card, using a serial device as terminal.", + "enum" : [ + "std", + "cirrus", + "vmware", + "qxl", + "serial0", + "serial1", + "serial2", + "serial3", + "qxl2", + "qxl3", + "qxl4" + ], + "optional" : 1, + "type" : "string" }, - "protection" : { - "description" : "Sets the protection flag of the VM. This will prevent the remove operation.", - "default" : 0, - "type" : "boolean", - "optional" : 1 - } - }, - "additionalProperties" : 0 - }, - "name" : "create_vm", - "protected" : 1, - "returns" : { - "type" : "string" - }, - "permissions" : { - "description" : "You need 'VM.Allocate' permissions on /vms/{vmid} or on the VM pool /pool/{pool}. For restore (option 'archive'), it is enough if the user has 'VM.Backup' permission and the VM already exists. If you create disks you need 'Datastore.AllocateSpace' on any used storage.", - "user" : "all" - }, - "description" : "Create or restore a virtual machine.", - "proxyto" : "node" - }, - "GET" : { - "protected" : 1, - "parameters" : { - "properties" : { - "node" : { - "format" : "pve-node", - "type" : "string", - "description" : "The cluster node name." + "virtio[n]" : { + "description" : "Use volume as VIRTIO hard disk (n is 0 to 15).", + "format" : { + "aio" : { + "description" : "AIO type to use.", + "enum" : [ + "native", + "threads" + ], + "format_description" : "native|threads", + "optional" : 1, + "type" : "string" + }, + "backup" : { + "description" : "Whether the drive should be included when making backups.", + "format_description" : "on|off", + "optional" : 1, + "type" : "boolean" + }, + "bps" : { + "description" : "Maximum r/w speed speed in bytes per second.", + "format_description" : "bps", + "optional" : 1, + "type" : "integer" + }, + "bps_rd" : { + "description" : "Maximum read speed speed in bytes per second.", + "format_description" : "bps", + "optional" : 1, + "type" : "integer" + }, + "bps_wr" : { + "description" : "Maximum write speed speed in bytes per second.", + "format_description" : "bps", + "optional" : 1, + "type" : "integer" + }, + "cache" : { + "description" : "The drive's cache mode", + "enum" : [ + "none", + "writethrough", + "writeback", + "unsafe", + "directsync" + ], + "format_description" : "none|writethrough|writeback|unsafe|directsync", + "optional" : 1, + "type" : "string" + }, + "cyls" : { + "description" : "Force the drive's physical geometry to have a specific cylinder count.", + "format_description" : "count", + "optional" : 1, + "type" : "integer" + }, + "detect_zeroes" : { + "description" : "Controls whether to detect and try to optimize writes of zeroes.", + "optional" : 1, + "type" : "boolean" + }, + "discard" : { + "description" : "Controls whether to pass discard/trim requests to the underlying storage.", + "enum" : [ + "ignore", + "on" + ], + "format_description" : "ignore|on", + "optional" : 1, + "type" : "string" + }, + "file" : { + "default_key" : 1, + "description" : "The drive's backing volume.", + "format" : "pve-volume-id-or-qm-path", + "format_description" : "volume", + "type" : "string" + }, + "format" : { + "description" : "The drive's backing file's data format.", + "enum" : [ + "raw", + "cow", + "qcow", + "qed", + "qcow2", + "vmdk", + "cloop" + ], + "format_description" : "drive format", + "optional" : 1, + "type" : "string" + }, + "heads" : { + "description" : "Force the drive's physical geometry to have a specific head count.", + "format_description" : "count", + "optional" : 1, + "type" : "integer" + }, + "iops" : { + "description" : "Maximum r/w I/O speed in operations per second.", + "format_description" : "iops", + "optional" : 1, + "type" : "integer" + }, + "iops_max" : { + "description" : "Maximum unthrottled r/w I/O pool speed in operations per second.", + "format_description" : "iops", + "optional" : 1, + "type" : "integer" + }, + "iops_rd" : { + "description" : "Maximum read I/O speed in operations per second.", + "format_description" : "iops", + "optional" : 1, + "type" : "integer" + }, + "iops_rd_max" : { + "description" : "Maximum unthrottled read I/O pool speed in operations per second.", + "format_description" : "iops", + "optional" : 1, + "type" : "integer" + }, + "iops_wr" : { + "description" : "Maximum write I/O speed in operations per second.", + "format_description" : "iops", + "optional" : 1, + "type" : "integer" + }, + "iops_wr_max" : { + "description" : "Maximum unthrottled write I/O pool speed in operations per second.", + "format_description" : "iops", + "optional" : 1, + "type" : "integer" + }, + "iothread" : { + "description" : "Whether to use iothreads for this drive", + "format_description" : "off|on", + "optional" : 1, + "type" : "boolean" + }, + "mbps" : { + "description" : "Maximum r/w speed speed in megabytes per second.", + "format_description" : "mbps", + "optional" : 1, + "type" : "number" + }, + "mbps_max" : { + "description" : "Maximum unthrottled r/w pool speed in megabytes per second.", + "format_description" : "mbps", + "optional" : 1, + "type" : "number" + }, + "mbps_rd" : { + "description" : "Maximum read speed speed in megabytes per second.", + "format_description" : "mbps", + "optional" : 1, + "type" : "number" + }, + "mbps_rd_max" : { + "description" : "Maximum unthrottled read pool speed in megabytes per second.", + "format_description" : "mbps", + "optional" : 1, + "type" : "number" + }, + "mbps_wr" : { + "description" : "Maximum write speed speed in megabytes per second.", + "format_description" : "mbps", + "optional" : 1, + "type" : "number" + }, + "mbps_wr_max" : { + "description" : "Maximum unthrottled write pool speed in megabytes per second.", + "format_description" : "mbps", + "optional" : 1, + "type" : "number" + }, + "media" : { + "default" : "disk", + "description" : "The drive's media type.", + "enum" : [ + "cdrom", + "disk" + ], + "format_description" : "cdrom|disk", + "optional" : 1, + "type" : "string" + }, + "rerror" : { + "description" : "Read error action.", + "enum" : [ + "ignore", + "report", + "stop" + ], + "format_description" : "ignore|report|stop", + "optional" : 1, + "type" : "string" + }, + "secs" : { + "description" : "Force the drive's physical geometry to have a specific sector count.", + "format_description" : "count", + "optional" : 1, + "type" : "integer" + }, + "serial" : { + "description" : "The drive's reported serial number, url-encoded, up to 20 bytes long.", + "format" : "urlencoded", + "format_description" : "serial", + "maxLength" : 60, + "optional" : 1, + "type" : "string" + }, + "size" : { + "description" : "Disk size. This is purely informational and has no effect.", + "format" : "disk-size", + "optional" : 1, + "type" : "string" + }, + "snapshot" : { + "description" : "Whether the drive should be included when making snapshots.", + "format_description" : "on|off", + "optional" : 1, + "type" : "boolean" + }, + "trans" : { + "description" : "Force disk geometry bios translation mode.", + "enum" : [ + "none", + "lba", + "auto" + ], + "format_description" : "none|lba|auto", + "optional" : 1, + "type" : "string" + }, + "volume" : { + "alias" : "file" + }, + "werror" : { + "description" : "Write error action.", + "enum" : [ + "enospc", + "ignore", + "report", + "stop" + ], + "format_description" : "enospc|ignore|report|stop", + "optional" : 1, + "type" : "string" + } + }, + "optional" : 1, + "type" : "string" }, - "full" : { + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" + }, + "watchdog" : { + "description" : "Create a virtual hardware watchdog device. Once enabled (by a guest action), the watchdog must be periodically polled by an agent inside the guest or else the watchdog will reset the guest (or execute the respective action specified)", + "format" : "pve-qm-watchdog", "optional" : 1, - "type" : "boolean", - "description" : "Determine the full status of active VMs." + "type" : "string" } - }, - "additionalProperties" : 0 + } }, - "name" : "vmlist", - "method" : "GET", - "description" : "Virtual machine index (per node).", - "proxyto" : "node", "permissions" : { - "user" : "all", - "description" : "Only list VMs where you have VM.Audit permissons on /vms/." + "description" : "You need 'VM.Allocate' permissions on /vms/{vmid} or on the VM pool /pool/{pool}. For restore (option 'archive'), it is enough if the user has 'VM.Backup' permission and the VM already exists. If you create disks you need 'Datastore.AllocateSpace' on any used storage.", + "user" : "all" }, + "protected" : 1, + "proxyto" : "node", "returns" : { - "type" : "array", - "links" : [ - { - "href" : "{vmid}", - "rel" : "child" - } - ], - "items" : { - "properties" : {}, - "type" : "object" - } + "type" : "string" } } }, + "leaf" : 0, "path" : "/nodes/{node}/qemu", - "leaf" : 0 + "text" : "qemu" }, { - "path" : "/nodes/{node}/lxc", - "leaf" : 0, - "text" : "lxc", "children" : [ { - "path" : "/nodes/{node}/lxc/{vmid}", - "leaf" : 0, "children" : [ { - "text" : "config", "info" : { + "GET" : { + "description" : "Get container configuration.", + "method" : "GET", + "name" : "vm_config", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" + } + } + }, + "permissions" : { + "check" : [ + "perm", + "/vms/{vmid}", + [ + "VM.Audit" + ] + ] + }, + "proxyto" : "node", + "returns" : { + "properties" : { + "digest" : { + "description" : "SHA1 digest of configuration file. This can be used to prevent concurrent modifications.", + "type" : "string" + } + }, + "type" : "object" + } + }, "PUT" : { - "protected" : 1, + "description" : "Set container options.", + "method" : "PUT", + "name" : "update_vm", "parameters" : { + "additionalProperties" : 0, "properties" : { - "cmode" : { + "arch" : { + "default" : "amd64", + "description" : "OS architecture type.", + "enum" : [ + "amd64", + "i386" + ], "optional" : 1, - "type" : "string", + "type" : "string" + }, + "cmode" : { "default" : "tty", + "description" : "Console mode. By default, the console command tries to open a connection to one of the available tty devices. By setting cmode to 'console' it tries to attach to /dev/console instead. If you set cmode to 'shell', it simply invokes a shell inside the container (no login).", "enum" : [ "shell", "console", "tty" ], - "description" : "Console mode. By default, the console command tries to open a connection to one of the available tty devices. By setting cmode to 'console' it tries to attach to /dev/console instead. If you set cmode to 'shell', it simply invokes a shell inside the container (no login)." + "optional" : 1, + "type" : "string" }, - "description" : { - "type" : "string", + "console" : { + "default" : 1, + "description" : "Attach a console device (/dev/console) to the container.", "optional" : 1, - "description" : "Container description. Only used on the configuration web interface." + "type" : "boolean" }, - "swap" : { + "cpulimit" : { + "default" : 0, + "description" : "Limit of CPU usage.\n\nNOTE: If the computer has 2 CPUs, it has a total of '2' CPU time. Value '0' indicates no CPU limit.", + "maximum" : 128, "minimum" : 0, - "description" : "Amount of SWAP for the VM in MB.", "optional" : 1, - "type" : "integer", - "default" : 512 + "type" : "number" }, - "ostype" : { - "description" : "OS type. This is used to setup configuration inside the container, and corresponds to lxc setup scripts in /usr/share/lxc/config/.common.conf. Value 'unmanaged' can be used to skip and OS specific setup.", - "enum" : [ - "debian", - "ubuntu", - "centos", - "fedora", - "opensuse", - "archlinux", - "alpine", - "unmanaged" - ], - "type" : "string", - "optional" : 1 + "cpuunits" : { + "default" : 1024, + "description" : "CPU weight for a VM. Argument is used in the kernel fair scheduler. The larger the number is, the more CPU time this VM gets. Number is relative to the weights of all the other running VMs.\n\nNOTE: You can disable fair-scheduler configuration by setting this to 0.", + "maximum" : 500000, + "minimum" : 0, + "optional" : 1, + "type" : "integer" }, - "unprivileged" : { - "description" : "Makes the container run as unprivileged user. (Should not be modified manually.)", - "type" : "boolean", + "delete" : { + "description" : "A list of settings you want to delete.", + "format" : "pve-configid-list", "optional" : 1, - "default" : 0 + "type" : "string" }, - "unused[n]" : { - "type" : "string", + "description" : { + "description" : "Container description. Only used on the configuration web interface.", "optional" : 1, - "description" : "Reference to unused volumes.", - "format" : "pve-volume-id" + "type" : "string" }, - "delete" : { - "format" : "pve-configid-list", + "digest" : { + "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", + "maxLength" : 40, "optional" : 1, - "type" : "string", - "description" : "A list of settings you want to delete." + "type" : "string" }, - "console" : { - "description" : "Attach a console device (/dev/console) to the container.", - "default" : 1, + "hostname" : { + "description" : "Set a host name for the container.", + "format" : "dns-name", + "maxLength" : 255, "optional" : 1, - "type" : "boolean" + "type" : "string" + }, + "lock" : { + "description" : "Lock/unlock the VM.", + "enum" : [ + "migrate", + "backup", + "snapshot", + "rollback" + ], + "optional" : 1, + "type" : "string" + }, + "memory" : { + "default" : 512, + "description" : "Amount of RAM for the VM in MB.", + "minimum" : 16, + "optional" : 1, + "type" : "integer" }, "mp[n]" : { + "description" : "Use volume as container mount point (experimental feature).", "format" : { - "ro" : { - "format_description" : "ro", - "description" : "Read-only mountpoint (not supported with bind mounts)", - "type" : "boolean", - "optional" : 1 - }, "acl" : { "description" : "Explicitly enable or disable ACL support.", - "type" : "boolean", - "optional" : 1, - "format_description" : "acl" - }, - "size" : { - "format_description" : "DiskSize", - "format" : "disk-size", + "format_description" : "acl", "optional" : 1, - "type" : "string", - "description" : "Volume size (read only value)." + "type" : "boolean" }, "backup" : { "description" : "Whether to include the mountpoint in backups.", + "format_description" : "[1|0]", "optional" : 1, - "type" : "boolean", - "format_description" : "[1|0]" - }, - "quota" : { - "type" : "boolean", - "optional" : 1, - "description" : "Enable user quotas inside the container (not supported with zfs subvolumes)", - "format_description" : "[0|1]" - }, - "volume" : { - "default_key" : 1, - "format_description" : "volume", - "format" : "pve-lxc-mp-string", - "type" : "string", - "description" : "Volume, device or directory to mount into the container." + "type" : "boolean" }, "mp" : { "description" : "Path to the mountpoint as seen from inside the container.", - "type" : "string", "format" : "pve-lxc-mp-string", - "format_description" : "Path" - } - }, - "type" : "string", - "optional" : 1, - "description" : "Use volume as container mount point (experimental feature)." - }, - "cpulimit" : { - "optional" : 1, - "type" : "number", - "maximum" : 128, - "default" : 0, - "description" : "Limit of CPU usage.\n\nNOTE: If the computer has 2 CPUs, it has a total of '2' CPU time. Value '0' indicates no CPU limit.", - "minimum" : 0 - }, - "node" : { - "type" : "string", - "description" : "The cluster node name.", - "format" : "pve-node" - }, - "startup" : { - "description" : "Startup and shutdown behavior. Order is a non-negative number defining the general startup order. Shutdown in done with reverse ordering. Additionally you can set the 'up' or 'down' delay in seconds, which specifies a delay to wait before the next VM is started or stopped.", - "type" : "string", - "optional" : 1, - "format" : "pve-startup-order", - "typetext" : "[[order=]\\d+] [,up=\\d+] [,down=\\d+] " - }, - "digest" : { - "type" : "string", + "format_description" : "Path", + "type" : "string" + }, + "quota" : { + "description" : "Enable user quotas inside the container (not supported with zfs subvolumes)", + "format_description" : "[0|1]", + "optional" : 1, + "type" : "boolean" + }, + "ro" : { + "description" : "Read-only mountpoint (not supported with bind mounts)", + "format_description" : "ro", + "optional" : 1, + "type" : "boolean" + }, + "size" : { + "description" : "Volume size (read only value).", + "format" : "disk-size", + "format_description" : "DiskSize", + "optional" : 1, + "type" : "string" + }, + "volume" : { + "default_key" : 1, + "description" : "Volume, device or directory to mount into the container.", + "format" : "pve-lxc-mp-string", + "format_description" : "volume", + "type" : "string" + } + }, "optional" : 1, - "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", - "maxLength" : 40 - }, - "onboot" : { - "description" : "Specifies whether a VM will be started during system bootup.", - "default" : 0, - "type" : "boolean", - "optional" : 1 + "type" : "string" }, - "tty" : { - "minimum" : 0, - "type" : "integer", + "nameserver" : { + "description" : "Sets DNS server IP address for a container. Create will automatically use the setting from the host if you neither set searchdomain nor nameserver.", + "format" : "address-list", "optional" : 1, - "default" : 2, - "maximum" : 6, - "description" : "Specify the number of tty available to the container" - }, - "arch" : { - "description" : "OS architecture type.", - "enum" : [ - "amd64", - "i386" - ], - "default" : "amd64", - "type" : "string", - "optional" : 1 + "type" : "string" }, "net[n]" : { + "description" : "Specifies network interfaces for the container.", "format" : { - "firewall" : { - "format_description" : "[1|0]", - "optional" : 1, - "type" : "boolean", - "description" : "Controls whether this interface's firewall rules should be used." - }, - "type" : { - "type" : "string", + "bridge" : { + "description" : "Bridge to attach the network device to.", + "format_description" : "vmbr", "optional" : 1, - "enum" : [ - "veth" - ], - "description" : "Network interface type." + "pattern" : "[-_.\\w\\d]+", + "type" : "string" }, - "ip" : { - "description" : "IPv4 address in CIDR format.", + "firewall" : { + "description" : "Controls whether this interface's firewall rules should be used.", + "format_description" : "[1|0]", "optional" : 1, - "type" : "string", - "format_description" : "IPv4Format/CIDR", - "format" : "pve-ipv4-config" + "type" : "boolean" }, - "trunks" : { - "type" : "string", + "gw" : { + "description" : "Default gateway for IPv4 traffic.", + "format" : "ipv4", + "format_description" : "GatewayIPv4", "optional" : 1, - "description" : "VLAN ids to pass through the interface", - "pattern" : "(?^:\\d+(?:;\\d+)*)", - "format_description" : "vlanid[;vlanid...]" + "type" : "string" }, "gw6" : { - "format_description" : "GatewayIPv6", - "format" : "ipv6", "description" : "Default gateway for IPv6 traffic.", + "format" : "ipv6", + "format_description" : "GatewayIPv6", "optional" : 1, "type" : "string" }, - "tag" : { - "format_description" : "VlanNo", - "minimum" : "2", - "description" : "VLAN tag for this interface.", + "hwaddr" : { + "description" : "Bridge to attach the network device to. (lxc.network.hwaddr)", + "format_description" : "MAC", + "optional" : 1, + "pattern" : "(?^i:(?:[a-f0-9]{2}:){5}[a-f0-9]{2})", + "type" : "string" + }, + "ip" : { + "description" : "IPv4 address in CIDR format.", + "format" : "pve-ipv4-config", + "format_description" : "IPv4Format/CIDR", "optional" : 1, - "type" : "integer", - "maximum" : "4094" + "type" : "string" }, "ip6" : { - "optional" : 1, - "type" : "string", "description" : "IPv6 address in CIDR format.", "format" : "pve-ipv6-config", - "format_description" : "IPv6Format/CIDR" - }, - "gw" : { - "format" : "ipv4", - "format_description" : "GatewayIPv4", + "format_description" : "IPv6Format/CIDR", "optional" : 1, - "type" : "string", - "description" : "Default gateway for IPv4 traffic." + "type" : "string" }, - "bridge" : { - "format_description" : "vmbr", + "mtu" : { + "description" : "Maximum transfer unit of the interface. (lxc.network.mtu)", + "format_description" : "Number", + "minimum" : 64, "optional" : 1, - "type" : "string", - "description" : "Bridge to attach the network device to.", - "pattern" : "[-_.\\w\\d]+" + "type" : "integer" }, "name" : { + "description" : "Name of the network device as seen from inside the container. (lxc.network.name)", "format_description" : "String", - "type" : "string", "pattern" : "[-_.\\w\\d]+", - "description" : "Name of the network device as seen from inside the container. (lxc.network.name)" + "type" : "string" }, - "hwaddr" : { - "description" : "Bridge to attach the network device to. (lxc.network.hwaddr)", - "pattern" : "(?^i:(?:[a-f0-9]{2}:){5}[a-f0-9]{2})", + "rate" : { + "description" : "Apply rate limiting to the interface", + "format_description" : "mbps", "optional" : 1, - "type" : "string", - "format_description" : "MAC" + "type" : "number" }, - "mtu" : { - "minimum" : 64, - "format_description" : "Number", - "description" : "Maximum transfer unit of the interface. (lxc.network.mtu)", + "tag" : { + "description" : "VLAN tag for this interface.", + "format_description" : "VlanNo", + "maximum" : "4094", + "minimum" : "2", "optional" : 1, "type" : "integer" }, - "rate" : { - "description" : "Apply rate limiting to the interface", - "type" : "number", + "trunks" : { + "description" : "VLAN ids to pass through the interface", + "format_description" : "vlanid[;vlanid...]", + "optional" : 1, + "pattern" : "(?^:\\d+(?:;\\d+)*)", + "type" : "string" + }, + "type" : { + "description" : "Network interface type.", + "enum" : [ + "veth" + ], "optional" : 1, - "format_description" : "mbps" + "type" : "string" } }, - "description" : "Specifies network interfaces for the container.", "optional" : 1, "type" : "string" }, - "searchdomain" : { - "type" : "string", - "optional" : 1, - "description" : "Sets DNS search domains for a container. Create will automatically use the setting from the host if you neither set searchdomain nor nameserver.", - "format" : "dns-name-list" + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" }, - "cpuunits" : { - "minimum" : 0, - "description" : "CPU weight for a VM. Argument is used in the kernel fair scheduler. The larger the number is, the more CPU time this VM gets. Number is relative to the weights of all the other running VMs.\n\nNOTE: You can disable fair-scheduler configuration by setting this to 0.", - "type" : "integer", + "onboot" : { + "default" : 0, + "description" : "Specifies whether a VM will be started during system bootup.", "optional" : 1, - "default" : 1024, - "maximum" : 500000 + "type" : "boolean" }, - "nameserver" : { - "description" : "Sets DNS server IP address for a container. Create will automatically use the setting from the host if you neither set searchdomain nor nameserver.", - "type" : "string", + "ostype" : { + "description" : "OS type. This is used to setup configuration inside the container, and corresponds to lxc setup scripts in /usr/share/lxc/config/.common.conf. Value 'unmanaged' can be used to skip and OS specific setup.", + "enum" : [ + "debian", + "ubuntu", + "centos", + "fedora", + "opensuse", + "archlinux", + "alpine", + "unmanaged" + ], "optional" : 1, - "format" : "address-list" - }, - "vmid" : { - "description" : "The (unique) ID of the VM.", - "type" : "integer", - "format" : "pve-vmid", - "minimum" : 1 + "type" : "string" }, - "hostname" : { - "maxLength" : 255, - "format" : "dns-name", - "type" : "string", + "protection" : { + "default" : 0, + "description" : "Sets the protection flag of the container. This will prevent the CT or CT's disk remove/update operation.", "optional" : 1, - "description" : "Set a host name for the container." + "type" : "boolean" }, "rootfs" : { "description" : "Use volume as container root.", - "optional" : 1, - "type" : "string", "format" : { "acl" : { + "description" : "Explicitly enable or disable ACL support.", "format_description" : "acl", - "type" : "boolean", - "optional" : 1, - "description" : "Explicitly enable or disable ACL support." - }, - "ro" : { - "format_description" : "ro", - "description" : "Read-only mountpoint (not supported with bind mounts)", "optional" : 1, "type" : "boolean" }, "backup" : { - "format_description" : "[1|0]", "description" : "Whether to include the mountpoint in backups.", + "format_description" : "[1|0]", "optional" : 1, "type" : "boolean" }, - "size" : { + "quota" : { + "description" : "Enable user quotas inside the container (not supported with zfs subvolumes)", + "format_description" : "[0|1]", + "optional" : 1, + "type" : "boolean" + }, + "ro" : { + "description" : "Read-only mountpoint (not supported with bind mounts)", + "format_description" : "ro", "optional" : 1, - "type" : "string", + "type" : "boolean" + }, + "size" : { "description" : "Volume size (read only value).", + "format" : "disk-size", "format_description" : "DiskSize", - "format" : "disk-size" - }, - "quota" : { - "description" : "Enable user quotas inside the container (not supported with zfs subvolumes)", "optional" : 1, - "type" : "boolean", - "format_description" : "[0|1]" + "type" : "string" }, "volume" : { - "format" : "pve-lxc-mp-string", - "format_description" : "volume", "default_key" : 1, "description" : "Volume, device or directory to mount into the container.", + "format" : "pve-lxc-mp-string", + "format_description" : "volume", "type" : "string" } - } + }, + "optional" : 1, + "type" : "string" + }, + "searchdomain" : { + "description" : "Sets DNS search domains for a container. Create will automatically use the setting from the host if you neither set searchdomain nor nameserver.", + "format" : "dns-name-list", + "optional" : 1, + "type" : "string" + }, + "startup" : { + "description" : "Startup and shutdown behavior. Order is a non-negative number defining the general startup order. Shutdown in done with reverse ordering. Additionally you can set the 'up' or 'down' delay in seconds, which specifies a delay to wait before the next VM is started or stopped.", + "format" : "pve-startup-order", + "optional" : 1, + "type" : "string", + "typetext" : "[[order=]\\d+] [,up=\\d+] [,down=\\d+] " + }, + "swap" : { + "default" : 512, + "description" : "Amount of SWAP for the VM in MB.", + "minimum" : 0, + "optional" : 1, + "type" : "integer" }, "template" : { + "default" : 0, "description" : "Enable/disable Template.", "optional" : 1, - "type" : "boolean", - "default" : 0 + "type" : "boolean" }, - "lock" : { - "description" : "Lock/unlock the VM.", - "enum" : [ - "migrate", - "backup", - "snapshot", - "rollback" - ], - "type" : "string", - "optional" : 1 + "tty" : { + "default" : 2, + "description" : "Specify the number of tty available to the container", + "maximum" : 6, + "minimum" : 0, + "optional" : 1, + "type" : "integer" }, - "protection" : { - "description" : "Sets the protection flag of the container. This will prevent the CT or CT's disk remove/update operation.", - "type" : "boolean", + "unprivileged" : { + "default" : 0, + "description" : "Makes the container run as unprivileged user. (Should not be modified manually.)", "optional" : 1, - "default" : 0 + "type" : "boolean" }, - "memory" : { - "description" : "Amount of RAM for the VM in MB.", - "default" : 512, - "type" : "integer", + "unused[n]" : { + "description" : "Reference to unused volumes.", + "format" : "pve-volume-id", "optional" : 1, - "minimum" : 16 + "type" : "string" + }, + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" } - }, - "additionalProperties" : 0 + } }, - "name" : "update_vm", - "method" : "PUT", - "proxyto" : "node", - "description" : "Set container options.", "permissions" : { "check" : [ "perm", @@ -12050,85 +12046,40 @@ var pveapi = [ 1 ] }, + "protected" : 1, + "proxyto" : "node", "returns" : { "type" : "null" } - }, - "GET" : { - "method" : "GET", - "returns" : { - "type" : "object", - "properties" : { - "digest" : { - "description" : "SHA1 digest of configuration file. This can be used to prevent concurrent modifications.", - "type" : "string" - } - } - }, - "parameters" : { - "additionalProperties" : 0, - "properties" : { - "node" : { - "format" : "pve-node", - "description" : "The cluster node name.", - "type" : "string" - }, - "vmid" : { - "description" : "The (unique) ID of the VM.", - "type" : "integer", - "minimum" : 1, - "format" : "pve-vmid" - } - } - }, - "permissions" : { - "check" : [ - "perm", - "/vms/{vmid}", - [ - "VM.Audit" - ] - ] - }, - "name" : "vm_config", - "description" : "Get container configuration.", - "proxyto" : "node" } }, + "leaf" : 1, "path" : "/nodes/{node}/lxc/{vmid}/config", - "leaf" : 1 + "text" : "config" }, { - "path" : "/nodes/{node}/lxc/{vmid}/status", - "leaf" : 0, - "text" : "status", "children" : [ { - "leaf" : 1, - "path" : "/nodes/{node}/lxc/{vmid}/status/current", "info" : { "GET" : { + "description" : "Get virtual machine status.", "method" : "GET", + "name" : "vm_status", "parameters" : { + "additionalProperties" : 0, "properties" : { "node" : { + "description" : "The cluster node name.", "format" : "pve-node", - "type" : "string", - "description" : "The cluster node name." + "type" : "string" }, "vmid" : { "description" : "The (unique) ID of the VM.", - "type" : "integer", + "format" : "pve-vmid", "minimum" : 1, - "format" : "pve-vmid" + "type" : "integer" } - }, - "additionalProperties" : 0 - }, - "name" : "vm_status", - "protected" : 1, - "returns" : { - "type" : "object" + } }, "permissions" : { "check" : [ @@ -12139,65 +12090,44 @@ var pveapi = [ ] ] }, + "protected" : 1, "proxyto" : "node", - "description" : "Get virtual machine status." + "returns" : { + "type" : "object" + } } }, + "leaf" : 1, + "path" : "/nodes/{node}/lxc/{vmid}/status/current", "text" : "current" }, { "info" : { "POST" : { - "proxyto" : "node", "description" : "Start the container.", - "permissions" : { - "check" : [ - "perm", - "/vms/{vmid}", - [ - "VM.PowerMgmt" - ] - ] - }, - "returns" : { - "type" : "string" - }, - "protected" : 1, + "method" : "POST", "name" : "vm_start", "parameters" : { "additionalProperties" : 0, "properties" : { "node" : { - "type" : "string", "description" : "The cluster node name.", - "format" : "pve-node" + "format" : "pve-node", + "type" : "string" }, "skiplock" : { + "description" : "Ignore locks - only root is allowed to use this option.", "optional" : 1, - "type" : "boolean", - "description" : "Ignore locks - only root is allowed to use this option." + "type" : "boolean" }, "vmid" : { "description" : "The (unique) ID of the VM.", - "type" : "integer", + "format" : "pve-vmid", "minimum" : 1, - "format" : "pve-vmid" + "type" : "integer" } } }, - "method" : "POST" - } - }, - "text" : "start", - "leaf" : 1, - "path" : "/nodes/{node}/lxc/{vmid}/status/start" - }, - { - "info" : { - "POST" : { - "returns" : { - "type" : "string" - }, "permissions" : { "check" : [ "perm", @@ -12207,77 +12137,99 @@ var pveapi = [ ] ] }, - "description" : "Stop the container. This will abruptly stop all processes running in the container.", + "protected" : 1, "proxyto" : "node", + "returns" : { + "type" : "string" + } + } + }, + "leaf" : 1, + "path" : "/nodes/{node}/lxc/{vmid}/status/start", + "text" : "start" + }, + { + "info" : { + "POST" : { + "description" : "Stop the container. This will abruptly stop all processes running in the container.", "method" : "POST", "name" : "vm_stop", "parameters" : { + "additionalProperties" : 0, "properties" : { + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, "skiplock" : { "description" : "Ignore locks - only root is allowed to use this option.", - "type" : "boolean", - "optional" : 1 + "optional" : 1, + "type" : "boolean" }, "vmid" : { + "description" : "The (unique) ID of the VM.", "format" : "pve-vmid", "minimum" : 1, - "description" : "The (unique) ID of the VM.", "type" : "integer" - }, - "node" : { - "format" : "pve-node", - "description" : "The cluster node name.", - "type" : "string" } - }, - "additionalProperties" : 0 + } + }, + "permissions" : { + "check" : [ + "perm", + "/vms/{vmid}", + [ + "VM.PowerMgmt" + ] + ] }, - "protected" : 1 + "protected" : 1, + "proxyto" : "node", + "returns" : { + "type" : "string" + } } }, - "text" : "stop", "leaf" : 1, - "path" : "/nodes/{node}/lxc/{vmid}/status/stop" + "path" : "/nodes/{node}/lxc/{vmid}/status/stop", + "text" : "stop" }, { - "leaf" : 1, - "path" : "/nodes/{node}/lxc/{vmid}/status/shutdown", "info" : { "POST" : { - "protected" : 1, + "description" : "Shutdown the container. This will trigger a clean shutdown of the container, see lxc-stop(1) for details.", + "method" : "POST", "name" : "vm_shutdown", "parameters" : { + "additionalProperties" : 0, "properties" : { - "node" : { - "format" : "pve-node", - "description" : "The cluster node name.", - "type" : "string" - }, "forceStop" : { + "default" : 0, "description" : "Make sure the Container stops.", "optional" : 1, - "type" : "boolean", - "default" : 0 + "type" : "boolean" + }, + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" }, "timeout" : { - "description" : "Wait maximal timeout seconds.", "default" : 60, - "type" : "integer", + "description" : "Wait maximal timeout seconds.", + "minimum" : 0, "optional" : 1, - "minimum" : 0 + "type" : "integer" }, "vmid" : { - "minimum" : 1, - "format" : "pve-vmid", "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, "type" : "integer" } - }, - "additionalProperties" : 0 + } }, - "method" : "POST", - "description" : "Shutdown the container. This will trigger a clean shutdown of the container, see lxc-stop(1) for details.", - "proxyto" : "node", "permissions" : { "check" : [ "perm", @@ -12287,65 +12239,39 @@ var pveapi = [ ] ] }, + "protected" : 1, + "proxyto" : "node", "returns" : { "type" : "string" } } }, + "leaf" : 1, + "path" : "/nodes/{node}/lxc/{vmid}/status/shutdown", "text" : "shutdown" }, { - "leaf" : 1, - "path" : "/nodes/{node}/lxc/{vmid}/status/suspend", "info" : { "POST" : { - "returns" : { - "type" : "string" - }, - "proxyto" : "node", "description" : "Suspend the container.", - "permissions" : { - "check" : [ - "perm", - "/vms/{vmid}", - [ - "VM.PowerMgmt" - ] - ] - }, "method" : "POST", - "protected" : 1, "name" : "vm_suspend", "parameters" : { "additionalProperties" : 0, "properties" : { + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, "vmid" : { - "type" : "integer", "description" : "The (unique) ID of the VM.", "format" : "pve-vmid", - "minimum" : 1 - }, - "node" : { - "description" : "The cluster node name.", - "type" : "string", - "format" : "pve-node" + "minimum" : 1, + "type" : "integer" } } - } - } - }, - "text" : "suspend" - }, - { - "leaf" : 1, - "path" : "/nodes/{node}/lxc/{vmid}/status/resume", - "info" : { - "POST" : { - "returns" : { - "type" : "string" }, - "description" : "Resume the container.", - "proxyto" : "node", "permissions" : { "check" : [ "perm", @@ -12355,57 +12281,86 @@ var pveapi = [ ] ] }, - "method" : "POST", "protected" : 1, + "proxyto" : "node", + "returns" : { + "type" : "string" + } + } + }, + "leaf" : 1, + "path" : "/nodes/{node}/lxc/{vmid}/status/suspend", + "text" : "suspend" + }, + { + "info" : { + "POST" : { + "description" : "Resume the container.", + "method" : "POST", + "name" : "vm_resume", "parameters" : { + "additionalProperties" : 0, "properties" : { "node" : { - "type" : "string", "description" : "The cluster node name.", - "format" : "pve-node" + "format" : "pve-node", + "type" : "string" }, "vmid" : { - "type" : "integer", "description" : "The (unique) ID of the VM.", "format" : "pve-vmid", - "minimum" : 1 + "minimum" : 1, + "type" : "integer" } - }, - "additionalProperties" : 0 + } + }, + "permissions" : { + "check" : [ + "perm", + "/vms/{vmid}", + [ + "VM.PowerMgmt" + ] + ] }, - "name" : "vm_resume" + "protected" : 1, + "proxyto" : "node", + "returns" : { + "type" : "string" + } } }, + "leaf" : 1, + "path" : "/nodes/{node}/lxc/{vmid}/status/resume", "text" : "resume" } ], "info" : { "GET" : { - "proxyto" : "node", "description" : "Directory index", + "method" : "GET", "name" : "vmcmdidx", - "permissions" : { - "user" : "all" - }, "parameters" : { "additionalProperties" : 0, "properties" : { "node" : { "description" : "The cluster node name.", - "type" : "string", - "format" : "pve-node" + "format" : "pve-node", + "type" : "string" }, "vmid" : { + "description" : "The (unique) ID of the VM.", "format" : "pve-vmid", "minimum" : 1, - "type" : "integer", - "description" : "The (unique) ID of the VM." + "type" : "integer" } } }, - "method" : "GET", + "permissions" : { + "user" : "all" + }, + "proxyto" : "node", "returns" : { - "type" : "array", "items" : { "properties" : { "subdir" : { @@ -12416,100 +12371,96 @@ var pveapi = [ }, "links" : [ { - "rel" : "child", - "href" : "{subdir}" + "href" : "{subdir}", + "rel" : "child" } - ] + ], + "type" : "array" } } - } + }, + "leaf" : 0, + "path" : "/nodes/{node}/lxc/{vmid}/status", + "text" : "status" }, { - "path" : "/nodes/{node}/lxc/{vmid}/snapshot", - "leaf" : 0, - "text" : "snapshot", "children" : [ { - "text" : "{snapname}", "children" : [ { "info" : { "POST" : { - "returns" : { - "type" : "string", - "description" : "the task ID." - }, - "proxyto" : "node", "description" : "Rollback LXC state to specified snapshot.", - "permissions" : { - "check" : [ - "perm", - "/vms/{vmid}", - [ - "VM.Snapshot" - ] - ] - }, "method" : "POST", - "protected" : 1, + "name" : "rollback", "parameters" : { + "additionalProperties" : 0, "properties" : { + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, "snapname" : { + "description" : "The name of the snapshot.", "format" : "pve-configid", "maxLength" : 40, - "description" : "The name of the snapshot.", "type" : "string" }, - "node" : { - "description" : "The cluster node name.", - "type" : "string", - "format" : "pve-node" - }, "vmid" : { - "minimum" : 1, + "description" : "The (unique) ID of the VM.", "format" : "pve-vmid", - "type" : "integer", - "description" : "The (unique) ID of the VM." + "minimum" : 1, + "type" : "integer" } - }, - "additionalProperties" : 0 + } + }, + "permissions" : { + "check" : [ + "perm", + "/vms/{vmid}", + [ + "VM.Snapshot" + ] + ] }, - "name" : "rollback" + "protected" : 1, + "proxyto" : "node", + "returns" : { + "description" : "the task ID.", + "type" : "string" + } } }, - "text" : "rollback", "leaf" : 1, - "path" : "/nodes/{node}/lxc/{vmid}/snapshot/{snapname}/rollback" + "path" : "/nodes/{node}/lxc/{vmid}/snapshot/{snapname}/rollback", + "text" : "rollback" }, { - "text" : "config", "info" : { "GET" : { - "returns" : { - "type" : "object" - }, - "method" : "GET", "description" : "Get snapshot configuration", - "proxyto" : "node", + "method" : "GET", + "name" : "get_snapshot_config", "parameters" : { "additionalProperties" : 0, "properties" : { - "vmid" : { - "type" : "integer", - "description" : "The (unique) ID of the VM.", - "minimum" : 1, - "format" : "pve-vmid" - }, "node" : { - "format" : "pve-node", "description" : "The cluster node name.", + "format" : "pve-node", "type" : "string" }, "snapname" : { + "description" : "The name of the snapshot.", "format" : "pve-configid", "maxLength" : 40, - "type" : "string", - "description" : "The name of the snapshot." + "type" : "string" + }, + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" } } }, @@ -12522,41 +12473,42 @@ var pveapi = [ ] ] }, - "name" : "get_snapshot_config" + "proxyto" : "node", + "returns" : { + "type" : "object" + } }, "PUT" : { - "protected" : 1, + "description" : "Update snapshot metadata.", + "method" : "PUT", "name" : "update_snapshot_config", "parameters" : { "additionalProperties" : 0, "properties" : { + "description" : { + "description" : "A textual description or comment.", + "optional" : 1, + "type" : "string" + }, "node" : { - "type" : "string", "description" : "The cluster node name.", - "format" : "pve-node" + "format" : "pve-node", + "type" : "string" }, "snapname" : { "description" : "The name of the snapshot.", - "type" : "string", "format" : "pve-configid", - "maxLength" : 40 - }, - "description" : { - "description" : "A textual description or comment.", - "type" : "string", - "optional" : 1 + "maxLength" : 40, + "type" : "string" }, "vmid" : { - "minimum" : 1, + "description" : "The (unique) ID of the VM.", "format" : "pve-vmid", - "type" : "integer", - "description" : "The (unique) ID of the VM." + "minimum" : 1, + "type" : "integer" } } }, - "method" : "PUT", - "description" : "Update snapshot metadata.", - "proxyto" : "node", "permissions" : { "check" : [ "perm", @@ -12566,60 +12518,50 @@ var pveapi = [ ] ] }, + "protected" : 1, + "proxyto" : "node", "returns" : { "type" : "null" } } }, + "leaf" : 1, "path" : "/nodes/{node}/lxc/{vmid}/snapshot/{snapname}/config", - "leaf" : 1 + "text" : "config" } ], "info" : { - "GET" : { + "DELETE" : { + "description" : "Delete a LXC snapshot.", + "method" : "DELETE", + "name" : "delsnapshot", "parameters" : { + "additionalProperties" : 0, "properties" : { - "vmid" : { - "description" : "The (unique) ID of the VM.", - "type" : "integer", - "minimum" : 1, - "format" : "pve-vmid" + "force" : { + "description" : "For removal from config file, even if removing disk snapshots fails.", + "optional" : 1, + "type" : "boolean" + }, + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" }, "snapname" : { - "type" : "string", "description" : "The name of the snapshot.", "format" : "pve-configid", - "maxLength" : 40 - }, - "node" : { - "format" : "pve-node", - "description" : "The cluster node name.", + "maxLength" : 40, "type" : "string" + }, + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" } - }, - "additionalProperties" : 0 - }, - "name" : "snapshot_cmd_idx", - "permissions" : { - "user" : "all" - }, - "description" : "", - "returns" : { - "items" : { - "properties" : {}, - "type" : "object" - }, - "links" : [ - { - "href" : "{cmd}", - "rel" : "child" - } - ], - "type" : "array" + } }, - "method" : "GET" - }, - "DELETE" : { "permissions" : { "check" : [ "perm", @@ -12629,50 +12571,83 @@ var pveapi = [ ] ] }, + "protected" : 1, "proxyto" : "node", - "description" : "Delete a LXC snapshot.", "returns" : { "description" : "the task ID.", "type" : "string" - }, - "name" : "delsnapshot", + } + }, + "GET" : { + "description" : "", + "method" : "GET", + "name" : "snapshot_cmd_idx", "parameters" : { "additionalProperties" : 0, "properties" : { - "vmid" : { - "type" : "integer", - "description" : "The (unique) ID of the VM.", - "minimum" : 1, - "format" : "pve-vmid" - }, "node" : { + "description" : "The cluster node name.", "format" : "pve-node", - "type" : "string", - "description" : "The cluster node name." - }, - "force" : { - "description" : "For removal from config file, even if removing disk snapshots fails.", - "type" : "boolean", - "optional" : 1 + "type" : "string" }, "snapname" : { - "maxLength" : 40, + "description" : "The name of the snapshot.", "format" : "pve-configid", - "type" : "string", - "description" : "The name of the snapshot." + "maxLength" : 40, + "type" : "string" + }, + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" } } }, - "protected" : 1, - "method" : "DELETE" + "permissions" : { + "user" : "all" + }, + "returns" : { + "items" : { + "properties" : {}, + "type" : "object" + }, + "links" : [ + { + "href" : "{cmd}", + "rel" : "child" + } + ], + "type" : "array" + } + } + }, + "leaf" : 0, + "path" : "/nodes/{node}/lxc/{vmid}/snapshot/{snapname}", + "text" : "{snapname}" + } + ], + "info" : { + "GET" : { + "description" : "List all snapshots.", + "method" : "GET", + "name" : "list", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" + } } }, - "path" : "/nodes/{node}/lxc/{vmid}/snapshot/{snapname}", - "leaf" : 0 - } - ], - "info" : { - "GET" : { "permissions" : { "check" : [ "perm", @@ -12682,72 +12657,53 @@ var pveapi = [ ] ] }, - "description" : "List all snapshots.", + "protected" : 1, "proxyto" : "node", "returns" : { + "items" : { + "properties" : {}, + "type" : "object" + }, "links" : [ { "href" : "{name}", "rel" : "child" } ], - "items" : { - "properties" : {}, - "type" : "object" - }, "type" : "array" - }, - "parameters" : { - "properties" : { - "node" : { - "format" : "pve-node", - "type" : "string", - "description" : "The cluster node name." - }, - "vmid" : { - "format" : "pve-vmid", - "minimum" : 1, - "description" : "The (unique) ID of the VM.", - "type" : "integer" - } - }, - "additionalProperties" : 0 - }, - "name" : "list", - "protected" : 1, - "method" : "GET" + } }, "POST" : { + "description" : "Snapshot a container.", + "method" : "POST", + "name" : "snapshot", "parameters" : { "additionalProperties" : 0, "properties" : { - "vmid" : { - "description" : "The (unique) ID of the VM.", - "type" : "integer", - "format" : "pve-vmid", - "minimum" : 1 - }, "description" : { - "type" : "string", + "description" : "A textual description or comment.", "optional" : 1, - "description" : "A textual description or comment." + "type" : "string" + }, + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" }, "snapname" : { "description" : "The name of the snapshot.", - "type" : "string", + "format" : "pve-configid", "maxLength" : 40, - "format" : "pve-configid" + "type" : "string" }, - "node" : { - "format" : "pve-node", - "type" : "string", - "description" : "The cluster node name." + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" } } }, - "name" : "snapshot", - "protected" : 1, - "method" : "POST", "permissions" : { "check" : [ "perm", @@ -12757,230 +12713,229 @@ var pveapi = [ ] ] }, - "description" : "Snapshot a container.", + "protected" : 1, "proxyto" : "node", "returns" : { "description" : "the task ID.", "type" : "string" } } - } + }, + "leaf" : 0, + "path" : "/nodes/{node}/lxc/{vmid}/snapshot", + "text" : "snapshot" }, { "children" : [ { - "text" : "rules", "children" : [ { - "path" : "/nodes/{node}/lxc/{vmid}/firewall/rules/{pos}", - "leaf" : 1, - "text" : "{pos}", "info" : { - "GET" : { - "returns" : { - "properties" : { - "pos" : { - "type" : "integer" - } - }, - "type" : "object" - }, - "method" : "GET", + "DELETE" : { + "description" : "Delete rule.", + "method" : "DELETE", + "name" : "delete_rule", "parameters" : { + "additionalProperties" : 0, "properties" : { - "vmid" : { - "type" : "integer", - "description" : "The (unique) ID of the VM.", - "format" : "pve-vmid", - "minimum" : 1 - }, - "pos" : { - "type" : "integer", + "digest" : { + "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", + "maxLength" : 40, "optional" : 1, - "description" : "Update rule at position .", - "minimum" : 0 + "type" : "string" }, "node" : { + "description" : "The cluster node name.", "format" : "pve-node", - "type" : "string", - "description" : "The cluster node name." + "type" : "string" + }, + "pos" : { + "description" : "Update rule at position .", + "minimum" : 0, + "optional" : 1, + "type" : "integer" + }, + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" } - }, - "additionalProperties" : 0 + } }, - "name" : "get_rule", "permissions" : { "check" : [ "perm", "/vms/{vmid}", [ - "VM.Audit" + "VM.Config.Network" ] ] }, + "protected" : 1, "proxyto" : null, - "description" : "Get single rule data." + "returns" : { + "type" : "null" + } }, - "PUT" : { + "GET" : { + "description" : "Get single rule data.", + "method" : "GET", + "name" : "get_rule", "parameters" : { + "additionalProperties" : 0, "properties" : { - "dest" : { - "type" : "string", - "optional" : 1, - "description" : "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.", - "format" : "pve-fw-addr-spec" - }, - "digest" : { - "maxLength" : 40, - "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", - "type" : "string", - "optional" : 1 - }, - "source" : { - "format" : "pve-fw-addr-spec", - "type" : "string", - "optional" : 1, - "description" : "Restrict packet source 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." - }, - "moveto" : { - "minimum" : 0, - "type" : "integer", - "optional" : 1, - "description" : "Move rule to new position . Other arguments are ignored." - }, "node" : { - "type" : "string", "description" : "The cluster node name.", - "format" : "pve-node" - }, - "comment" : { - "optional" : 1, - "type" : "string" - }, - "delete" : { - "type" : "string", - "optional" : 1, - "description" : "A list of settings you want to delete.", - "format" : "pve-configid-list" - }, - "dport" : { - "format" : "pve-fw-dport-spec", - "type" : "string", - "optional" : 1, - "description" : "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." - }, - "type" : { - "optional" : 1, - "type" : "string", - "enum" : [ - "in", - "out", - "group" - ] - }, - "sport" : { - "description" : "Restrict TCP/UDP source 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.", - "optional" : 1, - "type" : "string", - "format" : "pve-fw-sport-spec" - }, - "iface" : { - "format" : "pve-iface", - "maxLength" : 20, - "minLength" : 2, - "description" : "Network interface name. You have to use network configuration key names for VMs and containers ('net\\d+'). Host related rules can use arbitrary strings.", - "optional" : 1, + "format" : "pve-node", "type" : "string" }, "pos" : { - "optional" : 1, - "type" : "integer", "description" : "Update rule at position .", - "minimum" : 0 - }, - "proto" : { - "type" : "string", + "minimum" : 0, "optional" : 1, - "description" : "IP protocol. You can use protocol names ('tcp'/'udp') or simple numbers, as defined in '/etc/protocols'.", - "format" : "pve-fw-protocol-spec" + "type" : "integer" }, "vmid" : { + "description" : "The (unique) ID of the VM.", "format" : "pve-vmid", "minimum" : 1, - "description" : "The (unique) ID of the VM.", "type" : "integer" - }, - "macro" : { - "optional" : 1, - "type" : "string", - "maxLength" : 128 - }, - "enable" : { - "minimum" : 0, - "type" : "integer", - "optional" : 1 - }, - "action" : { - "type" : "string", - "optional" : 1, - "minLength" : 2, - "description" : "Rule action ('ACCEPT', 'DROP', 'REJECT') or security group name.", - "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", - "maxLength" : 20 } - }, - "additionalProperties" : 0 + } }, - "name" : "update_rule", - "protected" : 1, - "method" : "PUT", "permissions" : { "check" : [ "perm", "/vms/{vmid}", [ - "VM.Config.Network" + "VM.Audit" ] ] }, - "description" : "Modify rule data.", "proxyto" : null, "returns" : { - "type" : "null" + "properties" : { + "pos" : { + "type" : "integer" + } + }, + "type" : "object" } }, - "DELETE" : { - "name" : "delete_rule", + "PUT" : { + "description" : "Modify rule data.", + "method" : "PUT", + "name" : "update_rule", "parameters" : { "additionalProperties" : 0, "properties" : { + "action" : { + "description" : "Rule action ('ACCEPT', 'DROP', 'REJECT') or security group name.", + "maxLength" : 20, + "minLength" : 2, + "optional" : 1, + "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", + "type" : "string" + }, + "comment" : { + "optional" : 1, + "type" : "string" + }, + "delete" : { + "description" : "A list of settings you want to delete.", + "format" : "pve-configid-list", + "optional" : 1, + "type" : "string" + }, + "dest" : { + "description" : "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.", + "format" : "pve-fw-addr-spec", + "optional" : 1, + "type" : "string" + }, + "digest" : { + "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", + "maxLength" : 40, + "optional" : 1, + "type" : "string" + }, + "dport" : { + "description" : "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.", + "format" : "pve-fw-dport-spec", + "optional" : 1, + "type" : "string" + }, + "enable" : { + "minimum" : 0, + "optional" : 1, + "type" : "integer" + }, + "iface" : { + "description" : "Network interface name. You have to use network configuration key names for VMs and containers ('net\\d+'). Host related rules can use arbitrary strings.", + "format" : "pve-iface", + "maxLength" : 20, + "minLength" : 2, + "optional" : 1, + "type" : "string" + }, + "macro" : { + "maxLength" : 128, + "optional" : 1, + "type" : "string" + }, + "moveto" : { + "description" : "Move rule to new position . Other arguments are ignored.", + "minimum" : 0, + "optional" : 1, + "type" : "integer" + }, "node" : { "description" : "The cluster node name.", - "type" : "string", - "format" : "pve-node" + "format" : "pve-node", + "type" : "string" }, "pos" : { + "description" : "Update rule at position .", "minimum" : 0, - "type" : "integer", "optional" : 1, - "description" : "Update rule at position ." + "type" : "integer" }, - "vmid" : { - "minimum" : 1, - "format" : "pve-vmid", - "type" : "integer", - "description" : "The (unique) ID of the VM." + "proto" : { + "description" : "IP protocol. You can use protocol names ('tcp'/'udp') or simple numbers, as defined in '/etc/protocols'.", + "format" : "pve-fw-protocol-spec", + "optional" : 1, + "type" : "string" }, - "digest" : { - "maxLength" : 40, - "type" : "string", + "source" : { + "description" : "Restrict packet source 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.", + "format" : "pve-fw-addr-spec", + "optional" : 1, + "type" : "string" + }, + "sport" : { + "description" : "Restrict TCP/UDP source 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.", + "format" : "pve-fw-sport-spec", + "optional" : 1, + "type" : "string" + }, + "type" : { + "enum" : [ + "in", + "out", + "group" + ], "optional" : 1, - "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications." + "type" : "string" + }, + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" } } }, - "protected" : 1, - "method" : "DELETE", "permissions" : { "check" : [ "perm", @@ -12990,32 +12945,38 @@ var pveapi = [ ] ] }, + "protected" : 1, "proxyto" : null, - "description" : "Delete rule.", "returns" : { "type" : "null" } } - } + }, + "leaf" : 1, + "path" : "/nodes/{node}/lxc/{vmid}/firewall/rules/{pos}", + "text" : "{pos}" } ], "info" : { "GET" : { + "description" : "List rules.", + "method" : "GET", + "name" : "get_rules", "parameters" : { + "additionalProperties" : 0, "properties" : { "node" : { - "type" : "string", "description" : "The cluster node name.", - "format" : "pve-node" + "format" : "pve-node", + "type" : "string" }, "vmid" : { "description" : "The (unique) ID of the VM.", - "type" : "integer", + "format" : "pve-vmid", "minimum" : 1, - "format" : "pve-vmid" + "type" : "integer" } - }, - "additionalProperties" : 0 + } }, "permissions" : { "check" : [ @@ -13026,11 +12987,8 @@ var pveapi = [ ] ] }, - "name" : "get_rules", "proxyto" : null, - "description" : "List rules.", "returns" : { - "type" : "array", "items" : { "properties" : { "pos" : { @@ -13041,230 +12999,171 @@ var pveapi = [ }, "links" : [ { - "rel" : "child", - "href" : "{pos}" + "href" : "{pos}", + "rel" : "child" } - ] - }, - "method" : "GET" + ], + "type" : "array" + } }, "POST" : { - "protected" : 1, + "description" : "Create new rule.", + "method" : "POST", "name" : "create_rule", "parameters" : { + "additionalProperties" : 0, "properties" : { - "vmid" : { - "format" : "pve-vmid", - "minimum" : 1, - "description" : "The (unique) ID of the VM.", - "type" : "integer" - }, - "proto" : { - "optional" : 1, - "type" : "string", - "description" : "IP protocol. You can use protocol names ('tcp'/'udp') or simple numbers, as defined in '/etc/protocols'.", - "format" : "pve-fw-protocol-spec" - }, - "pos" : { - "minimum" : 0, - "description" : "Update rule at position .", - "optional" : 1, - "type" : "integer" - }, - "macro" : { - "type" : "string", - "optional" : 1, - "maxLength" : 128 - }, "action" : { + "description" : "Rule action ('ACCEPT', 'DROP', 'REJECT') or security group name.", "maxLength" : 20, - "type" : "string", + "minLength" : 2, "optional" : 0, "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", - "description" : "Rule action ('ACCEPT', 'DROP', 'REJECT') or security group name.", - "minLength" : 2 - }, - "type" : { - "enum" : [ - "in", - "out", - "group" - ], - "optional" : 0, "type" : "string" }, - "enable" : { - "type" : "integer", + "comment" : { "optional" : 1, - "minimum" : 0 + "type" : "string" }, - "dport" : { - "format" : "pve-fw-dport-spec", + "dest" : { + "description" : "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.", + "format" : "pve-fw-addr-spec", "optional" : 1, - "type" : "string", - "description" : "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." + "type" : "string" }, - "sport" : { - "format" : "pve-fw-sport-spec", - "type" : "string", + "digest" : { + "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", + "maxLength" : 40, "optional" : 1, - "description" : "Restrict TCP/UDP source 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." + "type" : "string" }, - "dest" : { + "dport" : { + "description" : "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.", + "format" : "pve-fw-dport-spec", "optional" : 1, - "type" : "string", - "description" : "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.", - "format" : "pve-fw-addr-spec" + "type" : "string" }, - "digest" : { - "maxLength" : 40, + "enable" : { + "minimum" : 0, "optional" : 1, - "type" : "string", - "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications." + "type" : "integer" }, - "source" : { - "format" : "pve-fw-addr-spec", - "description" : "Restrict packet source 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.", + "iface" : { + "description" : "Network interface name. You have to use network configuration key names for VMs and containers ('net\\d+'). Host related rules can use arbitrary strings.", + "format" : "pve-iface", + "maxLength" : 20, + "minLength" : 2, "optional" : 1, "type" : "string" }, - "comment" : { + "macro" : { + "maxLength" : 128, "optional" : 1, "type" : "string" }, "node" : { "description" : "The cluster node name.", - "type" : "string", - "format" : "pve-node" + "format" : "pve-node", + "type" : "string" }, - "iface" : { - "maxLength" : 20, - "format" : "pve-iface", - "description" : "Network interface name. You have to use network configuration key names for VMs and containers ('net\\d+'). Host related rules can use arbitrary strings.", - "minLength" : 2, + "pos" : { + "description" : "Update rule at position .", + "minimum" : 0, + "optional" : 1, + "type" : "integer" + }, + "proto" : { + "description" : "IP protocol. You can use protocol names ('tcp'/'udp') or simple numbers, as defined in '/etc/protocols'.", + "format" : "pve-fw-protocol-spec", "optional" : 1, "type" : "string" - } - }, - "additionalProperties" : 0 - }, - "method" : "POST", - "description" : "Create new rule.", - "proxyto" : null, - "permissions" : { - "check" : [ - "perm", - "/vms/{vmid}", - [ - "VM.Config.Network" - ] - ] - }, - "returns" : { - "type" : "null" - } - } - }, - "path" : "/nodes/{node}/lxc/{vmid}/firewall/rules", - "leaf" : 0 - }, - { - "children" : [ - { - "path" : "/nodes/{node}/lxc/{vmid}/firewall/aliases/{name}", - "leaf" : 1, - "text" : "{name}", - "info" : { - "GET" : { - "returns" : { - "type" : "object" }, - "method" : "GET", - "permissions" : { - "check" : [ - "perm", - "/vms/{vmid}", - [ - "VM.Audit" - ] - ] + "source" : { + "description" : "Restrict packet source 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.", + "format" : "pve-fw-addr-spec", + "optional" : 1, + "type" : "string" }, - "parameters" : { - "properties" : { - "vmid" : { - "description" : "The (unique) ID of the VM.", - "type" : "integer", - "format" : "pve-vmid", - "minimum" : 1 - }, - "node" : { - "format" : "pve-node", - "type" : "string", - "description" : "The cluster node name." - }, - "name" : { - "type" : "string", - "minLength" : 2, - "description" : "Alias name.", - "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", - "maxLength" : 64 - } - }, - "additionalProperties" : 0 + "sport" : { + "description" : "Restrict TCP/UDP source 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.", + "format" : "pve-fw-sport-spec", + "optional" : 1, + "type" : "string" }, - "name" : "read_alias", - "description" : "Read alias." - }, - "PUT" : { - "protected" : 1, - "description" : "Update IP or Network alias.", + "type" : { + "enum" : [ + "in", + "out", + "group" + ], + "optional" : 0, + "type" : "string" + }, + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" + } + } + }, + "permissions" : { + "check" : [ + "perm", + "/vms/{vmid}", + [ + "VM.Config.Network" + ] + ] + }, + "protected" : 1, + "proxyto" : null, + "returns" : { + "type" : "null" + } + } + }, + "leaf" : 0, + "path" : "/nodes/{node}/lxc/{vmid}/firewall/rules", + "text" : "rules" + }, + { + "children" : [ + { + "info" : { + "DELETE" : { + "description" : "Remove IP or Network alias.", + "method" : "DELETE", + "name" : "remove_alias", "parameters" : { + "additionalProperties" : 0, "properties" : { - "comment" : { - "type" : "string", - "optional" : 1 - }, - "rename" : { - "maxLength" : 64, - "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", - "description" : "Rename an existing alias.", - "minLength" : 2, + "digest" : { + "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", + "maxLength" : 40, "optional" : 1, "type" : "string" }, "name" : { + "description" : "Alias name.", "maxLength" : 64, - "type" : "string", "minLength" : 2, "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", - "description" : "Alias name." + "type" : "string" }, "node" : { + "description" : "The cluster node name.", "format" : "pve-node", - "type" : "string", - "description" : "The cluster node name." - }, - "digest" : { - "type" : "string", - "optional" : 1, - "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", - "maxLength" : 40 - }, - "cidr" : { - "type" : "string", - "description" : "Network/IP specification in CIDR format.", - "format" : "IPorCIDR" + "type" : "string" }, "vmid" : { - "minimum" : 1, + "description" : "The (unique) ID of the VM.", "format" : "pve-vmid", - "type" : "integer", - "description" : "The (unique) ID of the VM." + "minimum" : 1, + "type" : "integer" } - }, - "additionalProperties" : 0 + } }, - "name" : "update_alias", "permissions" : { "check" : [ "perm", @@ -13274,406 +13173,324 @@ var pveapi = [ ] ] }, + "protected" : 1, "returns" : { "type" : "null" - }, - "method" : "PUT" + } }, - "DELETE" : { - "returns" : { - "type" : "null" + "GET" : { + "description" : "Read alias.", + "method" : "GET", + "name" : "read_alias", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "name" : { + "description" : "Alias name.", + "maxLength" : 64, + "minLength" : 2, + "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", + "type" : "string" + }, + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" + } + } }, - "method" : "DELETE", "permissions" : { "check" : [ "perm", "/vms/{vmid}", [ - "VM.Config.Network" + "VM.Audit" ] ] }, + "returns" : { + "type" : "object" + } + }, + "PUT" : { + "description" : "Update IP or Network alias.", + "method" : "PUT", + "name" : "update_alias", "parameters" : { "additionalProperties" : 0, "properties" : { + "cidr" : { + "description" : "Network/IP specification in CIDR format.", + "format" : "IPorCIDR", + "type" : "string" + }, + "comment" : { + "optional" : 1, + "type" : "string" + }, + "digest" : { + "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", + "maxLength" : 40, + "optional" : 1, + "type" : "string" + }, "name" : { - "maxLength" : 64, - "type" : "string", "description" : "Alias name.", + "maxLength" : 64, + "minLength" : 2, "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", - "minLength" : 2 + "type" : "string" }, "node" : { "description" : "The cluster node name.", - "type" : "string", - "format" : "pve-node" + "format" : "pve-node", + "type" : "string" + }, + "rename" : { + "description" : "Rename an existing alias.", + "maxLength" : 64, + "minLength" : 2, + "optional" : 1, + "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", + "type" : "string" }, "vmid" : { - "type" : "integer", "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", "minimum" : 1, - "format" : "pve-vmid" - }, - "digest" : { - "maxLength" : 40, - "optional" : 1, - "type" : "string", - "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications." + "type" : "integer" } } }, - "name" : "remove_alias", - "protected" : 1, - "description" : "Remove IP or Network alias." - } - } - } - ], - "text" : "aliases", - "info" : { - "GET" : { - "method" : "GET", - "returns" : { - "items" : { - "type" : "object", - "properties" : { - "digest" : { - "maxLength" : 40, - "type" : "string", - "optional" : 0, - "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications." - }, - "cidr" : { - "type" : "string" - }, - "comment" : { - "type" : "string", - "optional" : 1 - }, - "name" : { - "type" : "string" - } - } - }, - "links" : [ - { - "href" : "{name}", - "rel" : "child" - } - ], - "type" : "array" - }, - "description" : "List aliases", - "permissions" : { - "check" : [ - "perm", - "/vms/{vmid}", - [ - "VM.Audit" - ] - ] - }, - "parameters" : { - "additionalProperties" : 0, - "properties" : { - "node" : { - "type" : "string", - "description" : "The cluster node name.", - "format" : "pve-node" - }, - "vmid" : { - "type" : "integer", - "description" : "The (unique) ID of the VM.", - "format" : "pve-vmid", - "minimum" : 1 - } - } - }, - "name" : "get_aliases" - }, - "POST" : { - "returns" : { - "type" : "null" - }, - "method" : "POST", - "permissions" : { - "check" : [ - "perm", - "/vms/{vmid}", - [ - "VM.Config.Network" - ] - ] - }, - "parameters" : { - "additionalProperties" : 0, - "properties" : { - "comment" : { - "optional" : 1, - "type" : "string" - }, - "name" : { - "type" : "string", - "description" : "Alias name.", - "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", - "minLength" : 2, - "maxLength" : 64 - }, - "node" : { - "description" : "The cluster node name.", - "type" : "string", - "format" : "pve-node" - }, - "vmid" : { - "description" : "The (unique) ID of the VM.", - "type" : "integer", - "format" : "pve-vmid", - "minimum" : 1 + "permissions" : { + "check" : [ + "perm", + "/vms/{vmid}", + [ + "VM.Config.Network" + ] + ] }, - "cidr" : { - "type" : "string", - "description" : "Network/IP specification in CIDR format.", - "format" : "IPorCIDR" + "protected" : 1, + "returns" : { + "type" : "null" } } }, - "name" : "create_alias", - "description" : "Create IP or Network Alias.", - "protected" : 1 - } - }, - "path" : "/nodes/{node}/lxc/{vmid}/firewall/aliases", - "leaf" : 0 - }, - { - "leaf" : 0, - "path" : "/nodes/{node}/lxc/{vmid}/firewall/ipset", - "info" : { - "GET" : { - "permissions" : { - "check" : [ - "perm", - "/vms/{vmid}", - [ - "VM.Audit" - ] - ] - }, - "name" : "ipset_index", + "leaf" : 1, + "path" : "/nodes/{node}/lxc/{vmid}/firewall/aliases/{name}", + "text" : "{name}" + } + ], + "info" : { + "GET" : { + "description" : "List aliases", + "method" : "GET", + "name" : "get_aliases", "parameters" : { "additionalProperties" : 0, "properties" : { "node" : { + "description" : "The cluster node name.", "format" : "pve-node", - "type" : "string", - "description" : "The cluster node name." + "type" : "string" }, "vmid" : { - "type" : "integer", "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", "minimum" : 1, - "format" : "pve-vmid" + "type" : "integer" } } }, - "description" : "List IPSets", - "method" : "GET", + "permissions" : { + "check" : [ + "perm", + "/vms/{vmid}", + [ + "VM.Audit" + ] + ] + }, "returns" : { - "type" : "array", - "links" : [ - { - "href" : "{name}", - "rel" : "child" - } - ], "items" : { - "type" : "object", "properties" : { - "comment" : { - "type" : "string", - "optional" : 1 + "cidr" : { + "type" : "string" }, - "name" : { - "maxLength" : 64, - "description" : "IP set name.", - "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", - "minLength" : 2, + "comment" : { + "optional" : 1, "type" : "string" }, "digest" : { - "type" : "string", - "optional" : 0, "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", - "maxLength" : 40 + "maxLength" : 40, + "optional" : 0, + "type" : "string" + }, + "name" : { + "type" : "string" } + }, + "type" : "object" + }, + "links" : [ + { + "href" : "{name}", + "rel" : "child" } - } + ], + "type" : "array" } }, "POST" : { + "description" : "Create IP or Network Alias.", "method" : "POST", - "returns" : { - "type" : "null" - }, - "protected" : 1, - "description" : "Create new IPSet", - "permissions" : { - "check" : [ - "perm", - "/vms/{vmid}", - [ - "VM.Config.Network" - ] - ] - }, + "name" : "create_alias", "parameters" : { "additionalProperties" : 0, "properties" : { - "vmid" : { - "description" : "The (unique) ID of the VM.", - "type" : "integer", - "format" : "pve-vmid", - "minimum" : 1 - }, - "digest" : { - "maxLength" : 40, - "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", - "optional" : 1, + "cidr" : { + "description" : "Network/IP specification in CIDR format.", + "format" : "IPorCIDR", "type" : "string" }, "comment" : { "optional" : 1, "type" : "string" }, - "rename" : { + "name" : { + "description" : "Alias name.", + "maxLength" : 64, "minLength" : 2, "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", - "description" : "Rename an existing IPSet. You can set 'rename' to the same value as 'name' to update the 'comment' of an existing IPSet.", - "type" : "string", - "optional" : 1, - "maxLength" : 64 + "type" : "string" }, "node" : { + "description" : "The cluster node name.", "format" : "pve-node", - "type" : "string", - "description" : "The cluster node name." + "type" : "string" }, - "name" : { - "minLength" : 2, - "description" : "IP set name.", - "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", - "type" : "string", - "maxLength" : 64 + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" } } }, - "name" : "create_ipset" + "permissions" : { + "check" : [ + "perm", + "/vms/{vmid}", + [ + "VM.Config.Network" + ] + ] + }, + "protected" : 1, + "returns" : { + "type" : "null" + } } }, - "text" : "ipset", + "leaf" : 0, + "path" : "/nodes/{node}/lxc/{vmid}/firewall/aliases", + "text" : "aliases" + }, + { "children" : [ { - "path" : "/nodes/{node}/lxc/{vmid}/firewall/ipset/{name}", - "leaf" : 0, "children" : [ { "info" : { "DELETE" : { - "returns" : { - "type" : "null" - }, + "description" : "Remove IP or Network from IPSet.", "method" : "DELETE", - "permissions" : { - "check" : [ - "perm", - "/vms/{vmid}", - [ - "VM.Config.Network" - ] - ] - }, + "name" : "remove_ip", "parameters" : { "additionalProperties" : 0, "properties" : { - "vmid" : { - "description" : "The (unique) ID of the VM.", - "type" : "integer", - "minimum" : 1, - "format" : "pve-vmid" + "cidr" : { + "description" : "Network/IP specification in CIDR format.", + "format" : "IPorCIDRorAlias", + "type" : "string" }, "digest" : { + "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", "maxLength" : 40, - "type" : "string", "optional" : 1, - "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications." - }, - "cidr" : { - "type" : "string", - "description" : "Network/IP specification in CIDR format.", - "format" : "IPorCIDRorAlias" + "type" : "string" }, "name" : { + "description" : "IP set name.", "maxLength" : 64, "minLength" : 2, - "description" : "IP set name.", "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", "type" : "string" }, "node" : { - "type" : "string", "description" : "The cluster node name.", - "format" : "pve-node" + "format" : "pve-node", + "type" : "string" + }, + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" } } }, - "name" : "remove_ip", + "permissions" : { + "check" : [ + "perm", + "/vms/{vmid}", + [ + "VM.Config.Network" + ] + ] + }, "protected" : 1, - "description" : "Remove IP or Network from IPSet." - }, - "PUT" : { "returns" : { "type" : "null" - }, - "method" : "PUT", + } + }, + "GET" : { + "description" : "Read IP or Network settings from IPSet.", + "method" : "GET", + "name" : "read_ip", "parameters" : { "additionalProperties" : 0, "properties" : { "cidr" : { - "format" : "IPorCIDRorAlias", "description" : "Network/IP specification in CIDR format.", + "format" : "IPorCIDRorAlias", "type" : "string" }, - "digest" : { - "optional" : 1, - "type" : "string", - "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", - "maxLength" : 40 - }, - "vmid" : { - "type" : "integer", - "description" : "The (unique) ID of the VM.", - "minimum" : 1, - "format" : "pve-vmid" - }, - "nomatch" : { - "optional" : 1, - "type" : "boolean" - }, - "node" : { - "type" : "string", - "description" : "The cluster node name.", - "format" : "pve-node" - }, "name" : { + "description" : "IP set name.", "maxLength" : 64, "minLength" : 2, - "description" : "IP set name.", "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", "type" : "string" }, - "comment" : { - "type" : "string", - "optional" : 1 + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" } } }, @@ -13682,94 +13499,150 @@ var pveapi = [ "perm", "/vms/{vmid}", [ - "VM.Config.Network" + "VM.Audit" ] ] }, - "name" : "update_ip", - "description" : "Update IP or Network settings", - "protected" : 1 - }, - "GET" : { - "method" : "GET", + "protected" : 1, "returns" : { "type" : "object" - }, - "name" : "read_ip", - "permissions" : { - "check" : [ - "perm", - "/vms/{vmid}", - [ - "VM.Audit" - ] - ] - }, + } + }, + "PUT" : { + "description" : "Update IP or Network settings", + "method" : "PUT", + "name" : "update_ip", "parameters" : { + "additionalProperties" : 0, "properties" : { "cidr" : { + "description" : "Network/IP specification in CIDR format.", "format" : "IPorCIDRorAlias", - "type" : "string", - "description" : "Network/IP specification in CIDR format." + "type" : "string" }, - "vmid" : { - "minimum" : 1, - "format" : "pve-vmid", - "type" : "integer", - "description" : "The (unique) ID of the VM." + "comment" : { + "optional" : 1, + "type" : "string" + }, + "digest" : { + "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", + "maxLength" : 40, + "optional" : 1, + "type" : "string" + }, + "name" : { + "description" : "IP set name.", + "maxLength" : 64, + "minLength" : 2, + "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", + "type" : "string" }, "node" : { - "format" : "pve-node", "description" : "The cluster node name.", + "format" : "pve-node", "type" : "string" }, - "name" : { - "maxLength" : 64, - "type" : "string", - "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", - "description" : "IP set name.", - "minLength" : 2 + "nomatch" : { + "optional" : 1, + "type" : "boolean" + }, + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" } - }, - "additionalProperties" : 0 + } + }, + "permissions" : { + "check" : [ + "perm", + "/vms/{vmid}", + [ + "VM.Config.Network" + ] + ] }, "protected" : 1, - "description" : "Read IP or Network settings from IPSet." + "returns" : { + "type" : "null" + } } }, - "text" : "{cidr}", "leaf" : 1, - "path" : "/nodes/{node}/lxc/{vmid}/firewall/ipset/{name}/{cidr}" + "path" : "/nodes/{node}/lxc/{vmid}/firewall/ipset/{name}/{cidr}", + "text" : "{cidr}" } ], - "text" : "{name}", "info" : { + "DELETE" : { + "description" : "Delete IPSet", + "method" : "DELETE", + "name" : "delete_ipset", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "name" : { + "description" : "IP set name.", + "maxLength" : 64, + "minLength" : 2, + "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", + "type" : "string" + }, + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" + } + } + }, + "permissions" : { + "check" : [ + "perm", + "/vms/{vmid}", + [ + "VM.Config.Network" + ] + ] + }, + "protected" : 1, + "returns" : { + "type" : "null" + } + }, "GET" : { "description" : "List IPSet content", + "method" : "GET", + "name" : "get_ipset", "parameters" : { "additionalProperties" : 0, "properties" : { "name" : { "description" : "IP set name.", - "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", + "maxLength" : 64, "minLength" : 2, - "type" : "string", - "maxLength" : 64 + "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", + "type" : "string" }, "node" : { - "format" : "pve-node", "description" : "The cluster node name.", + "format" : "pve-node", "type" : "string" }, "vmid" : { "description" : "The (unique) ID of the VM.", - "type" : "integer", + "format" : "pve-vmid", "minimum" : 1, - "format" : "pve-vmid" + "type" : "integer" } } }, - "name" : "get_ipset", "permissions" : { "check" : [ "perm", @@ -13780,148 +13653,273 @@ var pveapi = [ ] }, "returns" : { - "type" : "array", "items" : { - "type" : "object", "properties" : { "cidr" : { "type" : "string" }, + "comment" : { + "optional" : 1, + "type" : "string" + }, "digest" : { "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", + "maxLength" : 40, "optional" : 0, - "type" : "string", - "maxLength" : 40 - }, - "comment" : { - "optional" : 1, "type" : "string" }, "nomatch" : { - "type" : "boolean", - "optional" : 1 + "optional" : 1, + "type" : "boolean" } - } + }, + "type" : "object" }, "links" : [ { - "rel" : "child", - "href" : "{cidr}" - } - ] - }, - "method" : "GET" - }, - "DELETE" : { - "returns" : { - "type" : "null" - }, - "method" : "DELETE", - "name" : "delete_ipset", - "parameters" : { - "properties" : { - "vmid" : { - "format" : "pve-vmid", - "minimum" : 1, - "description" : "The (unique) ID of the VM.", - "type" : "integer" - }, - "node" : { - "type" : "string", - "description" : "The cluster node name.", - "format" : "pve-node" - }, - "name" : { - "minLength" : 2, - "description" : "IP set name.", - "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", - "type" : "string", - "maxLength" : 64 + "href" : "{cidr}", + "rel" : "child" } - }, - "additionalProperties" : 0 - }, - "permissions" : { - "check" : [ - "perm", - "/vms/{vmid}", - [ - "VM.Config.Network" - ] - ] - }, - "protected" : 1, - "description" : "Delete IPSet" + ], + "type" : "array" + } }, "POST" : { "description" : "Add IP or Network to IPSet.", - "protected" : 1, + "method" : "POST", "name" : "create_ip", - "permissions" : { - "check" : [ - "perm", - "/vms/{vmid}", - [ - "VM.Config.Network" - ] - ] - }, "parameters" : { + "additionalProperties" : 0, "properties" : { - "nomatch" : { - "type" : "boolean", - "optional" : 1 + "cidr" : { + "description" : "Network/IP specification in CIDR format.", + "format" : "IPorCIDRorAlias", + "type" : "string" + }, + "comment" : { + "optional" : 1, + "type" : "string" }, "name" : { - "maxLength" : 64, "description" : "IP set name.", - "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", + "maxLength" : 64, "minLength" : 2, + "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", "type" : "string" }, "node" : { - "type" : "string", "description" : "The cluster node name.", - "format" : "pve-node" - }, - "comment" : { - "optional" : 1, + "format" : "pve-node", "type" : "string" }, - "cidr" : { - "description" : "Network/IP specification in CIDR format.", - "type" : "string", - "format" : "IPorCIDRorAlias" + "nomatch" : { + "optional" : 1, + "type" : "boolean" }, "vmid" : { + "description" : "The (unique) ID of the VM.", "format" : "pve-vmid", "minimum" : 1, - "description" : "The (unique) ID of the VM.", "type" : "integer" } + } + }, + "permissions" : { + "check" : [ + "perm", + "/vms/{vmid}", + [ + "VM.Config.Network" + ] + ] + }, + "protected" : 1, + "returns" : { + "type" : "null" + } + } + }, + "leaf" : 0, + "path" : "/nodes/{node}/lxc/{vmid}/firewall/ipset/{name}", + "text" : "{name}" + } + ], + "info" : { + "GET" : { + "description" : "List IPSets", + "method" : "GET", + "name" : "ipset_index", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" + } + } + }, + "permissions" : { + "check" : [ + "perm", + "/vms/{vmid}", + [ + "VM.Audit" + ] + ] + }, + "returns" : { + "items" : { + "properties" : { + "comment" : { + "optional" : 1, + "type" : "string" + }, + "digest" : { + "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", + "maxLength" : 40, + "optional" : 0, + "type" : "string" }, - "additionalProperties" : 0 + "name" : { + "description" : "IP set name.", + "maxLength" : 64, + "minLength" : 2, + "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", + "type" : "string" + } + }, + "type" : "object" + }, + "links" : [ + { + "href" : "{name}", + "rel" : "child" + } + ], + "type" : "array" + } + }, + "POST" : { + "description" : "Create new IPSet", + "method" : "POST", + "name" : "create_ipset", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "comment" : { + "optional" : 1, + "type" : "string" + }, + "digest" : { + "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", + "maxLength" : 40, + "optional" : 1, + "type" : "string" }, - "returns" : { - "type" : "null" + "name" : { + "description" : "IP set name.", + "maxLength" : 64, + "minLength" : 2, + "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", + "type" : "string" + }, + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" }, - "method" : "POST" + "rename" : { + "description" : "Rename an existing IPSet. You can set 'rename' to the same value as 'name' to update the 'comment' of an existing IPSet.", + "maxLength" : 64, + "minLength" : 2, + "optional" : 1, + "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", + "type" : "string" + }, + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" + } } + }, + "permissions" : { + "check" : [ + "perm", + "/vms/{vmid}", + [ + "VM.Config.Network" + ] + ] + }, + "protected" : 1, + "returns" : { + "type" : "null" } } - ] + }, + "leaf" : 0, + "path" : "/nodes/{node}/lxc/{vmid}/firewall/ipset", + "text" : "ipset" }, { - "text" : "options", "info" : { "GET" : { + "description" : "Get VM firewall options.", "method" : "GET", + "name" : "get_options", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" + } + } + }, + "permissions" : { + "check" : [ + "perm", + "/vms/{vmid}", + [ + "VM.Audit" + ] + ] + }, + "proxyto" : "node", "returns" : { - "type" : "object", "properties" : { - "log_level_in" : { + "dhcp" : { + "description" : "Enable DHCP.", + "optional" : 1, + "type" : "boolean" + }, + "enable" : { + "description" : "Enable/disable firewall rules.", + "optional" : 1, + "type" : "boolean" + }, + "ipfilter" : { + "description" : "Enable default IP filters. This is equivalent to adding an empty ipfilter-net 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.", "optional" : 1, - "type" : "string", + "type" : "boolean" + }, + "log_level_in" : { "description" : "Log level for incoming traffic.", "enum" : [ "emerg", @@ -13933,27 +13931,35 @@ var pveapi = [ "info", "debug", "nolog" - ] + ], + "optional" : 1, + "type" : "string" }, - "policy_out" : { + "log_level_out" : { + "description" : "Log level for outgoing traffic.", "enum" : [ - "ACCEPT", - "REJECT", - "DROP" + "emerg", + "alert", + "crit", + "err", + "warning", + "notice", + "info", + "debug", + "nolog" ], - "description" : "Output policy.", "optional" : 1, "type" : "string" }, - "radv" : { - "description" : "Allow sending Router Advertisement.", - "type" : "boolean", - "optional" : 1 + "macfilter" : { + "description" : "Enable/disable MAC address filter.", + "optional" : 1, + "type" : "boolean" }, - "ipfilter" : { + "ndp" : { + "description" : "Enable NDP.", "optional" : 1, - "type" : "boolean", - "description" : "Enable default IP filters. This is equivalent to adding an empty ipfilter-net 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." + "type" : "boolean" }, "policy_in" : { "description" : "Input policy.", @@ -13962,88 +13968,64 @@ var pveapi = [ "REJECT", "DROP" ], - "type" : "string", - "optional" : 1 - }, - "macfilter" : { - "description" : "Enable/disable MAC address filter.", - "optional" : 1, - "type" : "boolean" - }, - "ndp" : { "optional" : 1, - "type" : "boolean", - "description" : "Enable NDP." - }, - "dhcp" : { - "description" : "Enable DHCP.", - "optional" : 1, - "type" : "boolean" + "type" : "string" }, - "log_level_out" : { + "policy_out" : { + "description" : "Output policy.", "enum" : [ - "emerg", - "alert", - "crit", - "err", - "warning", - "notice", - "info", - "debug", - "nolog" + "ACCEPT", + "REJECT", + "DROP" ], - "description" : "Log level for outgoing traffic.", "optional" : 1, "type" : "string" }, - "enable" : { - "description" : "Enable/disable firewall rules.", + "radv" : { + "description" : "Allow sending Router Advertisement.", "optional" : 1, "type" : "boolean" } - } - }, - "permissions" : { - "check" : [ - "perm", - "/vms/{vmid}", - [ - "VM.Audit" - ] - ] - }, - "parameters" : { - "properties" : { - "vmid" : { - "type" : "integer", - "description" : "The (unique) ID of the VM.", - "format" : "pve-vmid", - "minimum" : 1 - }, - "node" : { - "type" : "string", - "description" : "The cluster node name.", - "format" : "pve-node" - } }, - "additionalProperties" : 0 - }, - "name" : "get_options", - "description" : "Get VM firewall options.", - "proxyto" : "node" + "type" : "object" + } }, "PUT" : { - "protected" : 1, + "description" : "Set Firewall options.", + "method" : "PUT", "name" : "set_options", "parameters" : { + "additionalProperties" : 0, "properties" : { + "delete" : { + "description" : "A list of settings you want to delete.", + "format" : "pve-configid-list", + "optional" : 1, + "type" : "string" + }, + "dhcp" : { + "description" : "Enable DHCP.", + "optional" : 1, + "type" : "boolean" + }, + "digest" : { + "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", + "maxLength" : 40, + "optional" : 1, + "type" : "string" + }, "enable" : { "description" : "Enable/disable firewall rules.", "optional" : 1, "type" : "boolean" }, - "log_level_out" : { - "description" : "Log level for outgoing traffic.", + "ipfilter" : { + "description" : "Enable default IP filters. This is equivalent to adding an empty ipfilter-net 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.", + "optional" : 1, + "type" : "boolean" + }, + "log_level_in" : { + "description" : "Log level for incoming traffic.", "enum" : [ "emerg", "alert", @@ -14055,32 +14037,11 @@ var pveapi = [ "debug", "nolog" ], - "type" : "string", - "optional" : 1 - }, - "vmid" : { - "type" : "integer", - "description" : "The (unique) ID of the VM.", - "format" : "pve-vmid", - "minimum" : 1 - }, - "delete" : { - "type" : "string", "optional" : 1, - "description" : "A list of settings you want to delete.", - "format" : "pve-configid-list" - }, - "policy_out" : { - "enum" : [ - "ACCEPT", - "REJECT", - "DROP" - ], - "description" : "Output policy.", - "type" : "string", - "optional" : 1 + "type" : "string" }, - "log_level_in" : { + "log_level_out" : { + "description" : "Log level for outgoing traffic.", "enum" : [ "emerg", "alert", @@ -14092,62 +14053,57 @@ var pveapi = [ "debug", "nolog" ], - "description" : "Log level for incoming traffic.", - "type" : "string", - "optional" : 1 + "optional" : 1, + "type" : "string" }, - "ipfilter" : { - "description" : "Enable default IP filters. This is equivalent to adding an empty ipfilter-net 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.", + "macfilter" : { + "description" : "Enable/disable MAC address filter.", + "optional" : 1, + "type" : "boolean" + }, + "ndp" : { + "description" : "Enable NDP.", "optional" : 1, "type" : "boolean" }, "node" : { "description" : "The cluster node name.", - "type" : "string", - "format" : "pve-node" - }, - "radv" : { - "description" : "Allow sending Router Advertisement.", - "type" : "boolean", - "optional" : 1 + "format" : "pve-node", + "type" : "string" }, - "macfilter" : { - "type" : "boolean", + "policy_in" : { + "description" : "Input policy.", + "enum" : [ + "ACCEPT", + "REJECT", + "DROP" + ], "optional" : 1, - "description" : "Enable/disable MAC address filter." + "type" : "string" }, - "policy_in" : { + "policy_out" : { + "description" : "Output policy.", "enum" : [ "ACCEPT", "REJECT", "DROP" ], - "description" : "Input policy.", - "type" : "string", - "optional" : 1 - }, - "ndp" : { - "description" : "Enable NDP.", - "type" : "boolean", - "optional" : 1 - }, - "digest" : { - "maxLength" : 40, - "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", "optional" : 1, "type" : "string" }, - "dhcp" : { - "type" : "boolean", + "radv" : { + "description" : "Allow sending Router Advertisement.", "optional" : 1, - "description" : "Enable DHCP." + "type" : "boolean" + }, + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" } - }, - "additionalProperties" : 0 + } }, - "method" : "PUT", - "proxyto" : "node", - "description" : "Set Firewall options.", "permissions" : { "check" : [ "perm", @@ -14157,208 +14113,223 @@ var pveapi = [ ] ] }, + "protected" : 1, + "proxyto" : "node", "returns" : { "type" : "null" } } }, + "leaf" : 1, "path" : "/nodes/{node}/lxc/{vmid}/firewall/options", - "leaf" : 1 + "text" : "options" }, { "info" : { "GET" : { + "description" : "Read firewall log", "method" : "GET", "name" : "log", "parameters" : { "additionalProperties" : 0, "properties" : { + "limit" : { + "minimum" : 0, + "optional" : 1, + "type" : "integer" + }, "node" : { "description" : "The cluster node name.", - "type" : "string", - "format" : "pve-node" + "format" : "pve-node", + "type" : "string" }, - "limit" : { + "start" : { + "minimum" : 0, "optional" : 1, - "type" : "integer", - "minimum" : 0 + "type" : "integer" }, "vmid" : { + "description" : "The (unique) ID of the VM.", "format" : "pve-vmid", "minimum" : 1, - "description" : "The (unique) ID of the VM.", - "type" : "integer" - }, - "start" : { - "minimum" : 0, - "optional" : 1, "type" : "integer" } } }, + "permissions" : { + "check" : [ + "perm", + "/vms/{vmid}", + [ + "VM.Console" + ] + ] + }, "protected" : 1, + "proxyto" : "node", "returns" : { "items" : { "properties" : { - "t" : { - "description" : "Line text", - "type" : "string" - }, "n" : { "description" : "Line number", "type" : "integer" + }, + "t" : { + "description" : "Line text", + "type" : "string" } }, "type" : "object" }, "type" : "array" - }, - "permissions" : { - "check" : [ - "perm", - "/vms/{vmid}", - [ - "VM.Console" - ] - ] - }, - "proxyto" : "node", - "description" : "Read firewall log" + } } }, - "text" : "log", "leaf" : 1, - "path" : "/nodes/{node}/lxc/{vmid}/firewall/log" + "path" : "/nodes/{node}/lxc/{vmid}/firewall/log", + "text" : "log" }, { - "text" : "refs", "info" : { "GET" : { "description" : "Lists possible IPSet/Alias reference which are allowed in source/dest properties.", - "permissions" : { - "check" : [ - "perm", - "/vms/{vmid}", - [ - "VM.Audit" - ] - ] - }, + "method" : "GET", + "name" : "refs", "parameters" : { "additionalProperties" : 0, "properties" : { - "vmid" : { - "format" : "pve-vmid", - "minimum" : 1, - "description" : "The (unique) ID of the VM.", - "type" : "integer" + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" }, "type" : { - "type" : "string", - "optional" : 1, + "description" : "Only list references of specified type.", "enum" : [ "alias", "ipset" ], - "description" : "Only list references of specified type." + "optional" : 1, + "type" : "string" }, - "node" : { - "type" : "string", - "description" : "The cluster node name.", - "format" : "pve-node" + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" } } }, - "name" : "refs", - "method" : "GET", + "permissions" : { + "check" : [ + "perm", + "/vms/{vmid}", + [ + "VM.Audit" + ] + ] + }, "returns" : { - "type" : "array", "items" : { - "type" : "object", "properties" : { + "comment" : { + "optional" : 1, + "type" : "string" + }, + "name" : { + "type" : "string" + }, "type" : { - "type" : "string", "enum" : [ "alias", "ipset" - ] - }, - "name" : { + ], "type" : "string" - }, - "comment" : { - "type" : "string", - "optional" : 1 } - } - } + }, + "type" : "object" + }, + "type" : "array" } } }, + "leaf" : 1, "path" : "/nodes/{node}/lxc/{vmid}/firewall/refs", - "leaf" : 1 + "text" : "refs" } ], - "text" : "firewall", "info" : { "GET" : { "description" : "Directory index.", - "permissions" : { - "user" : "all" - }, + "method" : "GET", + "name" : "index", "parameters" : { + "additionalProperties" : 0, "properties" : { - "vmid" : { - "minimum" : 1, - "format" : "pve-vmid", - "type" : "integer", - "description" : "The (unique) ID of the VM." - }, "node" : { + "description" : "The cluster node name.", "format" : "pve-node", - "type" : "string", - "description" : "The cluster node name." + "type" : "string" + }, + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" } - }, - "additionalProperties" : 0 + } + }, + "permissions" : { + "user" : "all" }, - "name" : "index", - "method" : "GET", "returns" : { - "type" : "array", "items" : { - "type" : "object", - "properties" : {} + "properties" : {}, + "type" : "object" }, "links" : [ { - "rel" : "child", - "href" : "{name}" + "href" : "{name}", + "rel" : "child" } - ] + ], + "type" : "array" } } }, + "leaf" : 0, "path" : "/nodes/{node}/lxc/{vmid}/firewall", - "leaf" : 0 + "text" : "firewall" }, { - "text" : "rrd", "info" : { "GET" : { "description" : "Read VM RRD statistics (returns PNG)", - "protected" : 1, + "method" : "GET", "name" : "rrd", "parameters" : { "additionalProperties" : 0, "properties" : { + "cf" : { + "description" : "The RRD consolidation function", + "enum" : [ + "AVERAGE", + "MAX" + ], + "optional" : 1, + "type" : "string" + }, + "ds" : { + "description" : "The list of datasources you want to display.", + "format" : "pve-configid-list", + "type" : "string" + }, "node" : { "description" : "The cluster node name.", - "type" : "string", - "format" : "pve-node" + "format" : "pve-node", + "type" : "string" }, "timeframe" : { - "type" : "string", "description" : "Specify the time frame you are interested in.", "enum" : [ "hour", @@ -14366,26 +14337,13 @@ var pveapi = [ "week", "month", "year" - ] - }, - "ds" : { - "description" : "The list of datasources you want to display.", - "type" : "string", - "format" : "pve-configid-list" - }, - "cf" : { - "optional" : 1, - "type" : "string", - "enum" : [ - "AVERAGE", - "MAX" ], - "description" : "The RRD consolidation function" + "type" : "string" }, "vmid" : { + "description" : "The (unique) ID of the VM.", "format" : "pve-vmid", "minimum" : 1, - "description" : "The (unique) ID of the VM.", "type" : "integer" } } @@ -14399,7 +14357,7 @@ var pveapi = [ ] ] }, - "method" : "GET", + "protected" : 1, "returns" : { "properties" : { "filename" : { @@ -14410,23 +14368,34 @@ var pveapi = [ } } }, + "leaf" : 1, "path" : "/nodes/{node}/lxc/{vmid}/rrd", - "leaf" : 1 + "text" : "rrd" }, { - "text" : "rrddata", "info" : { "GET" : { + "description" : "Read VM RRD statistics", + "method" : "GET", + "name" : "rrddata", "parameters" : { "additionalProperties" : 0, "properties" : { + "cf" : { + "description" : "The RRD consolidation function", + "enum" : [ + "AVERAGE", + "MAX" + ], + "optional" : 1, + "type" : "string" + }, "node" : { + "description" : "The cluster node name.", "format" : "pve-node", - "type" : "string", - "description" : "The cluster node name." + "type" : "string" }, "timeframe" : { - "type" : "string", "description" : "Specify the time frame you are interested in.", "enum" : [ "hour", @@ -14434,22 +14403,14 @@ var pveapi = [ "week", "month", "year" - ] + ], + "type" : "string" }, "vmid" : { "description" : "The (unique) ID of the VM.", - "type" : "integer", + "format" : "pve-vmid", "minimum" : 1, - "format" : "pve-vmid" - }, - "cf" : { - "enum" : [ - "AVERAGE", - "MAX" - ], - "description" : "The RRD consolidation function", - "type" : "string", - "optional" : 1 + "type" : "integer" } } }, @@ -14462,48 +14423,46 @@ var pveapi = [ ] ] }, - "name" : "rrddata", - "description" : "Read VM RRD statistics", "protected" : 1, "returns" : { - "type" : "array", "items" : { "properties" : {}, "type" : "object" - } - }, - "method" : "GET" + }, + "type" : "array" + } } }, + "leaf" : 1, "path" : "/nodes/{node}/lxc/{vmid}/rrddata", - "leaf" : 1 + "text" : "rrddata" }, { - "text" : "vncproxy", "info" : { "POST" : { - "protected" : 1, "description" : "Creates a TCP VNC proxy connections.", + "method" : "POST", + "name" : "vncproxy", "parameters" : { + "additionalProperties" : 0, "properties" : { + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, "vmid" : { + "description" : "The (unique) ID of the VM.", "format" : "pve-vmid", "minimum" : 1, - "description" : "The (unique) ID of the VM.", "type" : "integer" }, "websocket" : { - "type" : "boolean", + "description" : "use websocket instead of standard VNC.", "optional" : 1, - "description" : "use websocket instead of standard VNC." - }, - "node" : { - "type" : "string", - "description" : "The cluster node name.", - "format" : "pve-node" + "type" : "boolean" } - }, - "additionalProperties" : 0 + } }, "permissions" : { "check" : [ @@ -14514,65 +14473,66 @@ var pveapi = [ ] ] }, - "name" : "vncproxy", - "method" : "POST", + "protected" : 1, "returns" : { "additionalProperties" : 0, "properties" : { "cert" : { "type" : "string" }, - "upid" : { - "type" : "string" + "port" : { + "type" : "integer" }, - "user" : { + "ticket" : { "type" : "string" }, - "ticket" : { + "upid" : { "type" : "string" }, - "port" : { - "type" : "integer" + "user" : { + "type" : "string" } } } } }, + "leaf" : 1, "path" : "/nodes/{node}/lxc/{vmid}/vncproxy", - "leaf" : 1 + "text" : "vncproxy" }, { - "text" : "vncwebsocket", "info" : { "GET" : { + "description" : "Opens a weksocket for VNC traffic.", + "method" : "GET", + "name" : "vncwebsocket", "parameters" : { + "additionalProperties" : 0, "properties" : { - "vncticket" : { - "type" : "string", - "description" : "Ticket from previous call to vncproxy.", - "maxLength" : 512 - }, - "port" : { - "minimum" : 5900, - "maximum" : 5999, - "type" : "integer", - "description" : "Port number returned by previous vncproxy call." - }, "node" : { - "format" : "pve-node", "description" : "The cluster node name.", + "format" : "pve-node", "type" : "string" }, + "port" : { + "description" : "Port number returned by previous vncproxy call.", + "maximum" : 5999, + "minimum" : 5900, + "type" : "integer" + }, "vmid" : { "description" : "The (unique) ID of the VM.", - "type" : "integer", "format" : "pve-vmid", - "minimum" : 1 + "minimum" : 1, + "type" : "integer" + }, + "vncticket" : { + "description" : "Ticket from previous call to vncproxy.", + "maxLength" : 512, + "type" : "string" } - }, - "additionalProperties" : 0 + } }, - "name" : "vncwebsocket", "permissions" : { "check" : [ "perm", @@ -14583,54 +14543,48 @@ var pveapi = [ ], "description" : "You also need to pass a valid ticket (vncticket)." }, - "description" : "Opens a weksocket for VNC traffic.", "returns" : { - "type" : "object", "properties" : { "port" : { "type" : "string" } - } - }, - "method" : "GET" + }, + "type" : "object" + } } }, + "leaf" : 1, "path" : "/nodes/{node}/lxc/{vmid}/vncwebsocket", - "leaf" : 1 + "text" : "vncwebsocket" }, { - "path" : "/nodes/{node}/lxc/{vmid}/spiceproxy", - "leaf" : 1, - "text" : "spiceproxy", "info" : { "POST" : { - "protected" : 1, + "description" : "Returns a SPICE configuration to connect to the CT.", + "method" : "POST", + "name" : "spiceproxy", "parameters" : { "additionalProperties" : 0, "properties" : { - "vmid" : { - "format" : "pve-vmid", - "minimum" : 1, - "type" : "integer", - "description" : "The (unique) ID of the VM." + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" }, "proxy" : { - "optional" : 1, - "type" : "string", "description" : "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 resonable setting is to use same node you use to connect to the API (This is window.location.hostname for the JS GUI).", - "format" : "address" - }, - "node" : { - "format" : "pve-node", - "description" : "The cluster node name.", + "format" : "address", + "optional" : 1, "type" : "string" + }, + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" } } }, - "name" : "spiceproxy", - "method" : "POST", - "description" : "Returns a SPICE configuration to connect to the CT.", - "proxyto" : "node", "permissions" : { "check" : [ "perm", @@ -14640,14 +14594,16 @@ var pveapi = [ ] ] }, + "protected" : 1, + "proxyto" : "node", "returns" : { - "description" : "Returned values can be directly passed to the 'remote-viewer' application.", "additionalProperties" : 1, + "description" : "Returned values can be directly passed to the 'remote-viewer' application.", "properties" : { - "type" : { + "host" : { "type" : "string" }, - "host" : { + "password" : { "type" : "string" }, "proxy" : { @@ -14656,56 +14612,53 @@ var pveapi = [ "tls-port" : { "type" : "integer" }, - "password" : { + "type" : { "type" : "string" } } } } - } + }, + "leaf" : 1, + "path" : "/nodes/{node}/lxc/{vmid}/spiceproxy", + "text" : "spiceproxy" }, { - "leaf" : 1, - "path" : "/nodes/{node}/lxc/{vmid}/migrate", "info" : { "POST" : { + "description" : "Migrate the container to another node. Creates a new migration task.", "method" : "POST", + "name" : "migrate_vm", "parameters" : { + "additionalProperties" : 0, "properties" : { - "target" : { + "force" : { + "description" : "Force migration despite local bind / device mounts. WARNING: identical bind / device mounts need to be available on the target node.", + "optional" : 1, + "type" : "boolean" + }, + "node" : { + "description" : "The cluster node name.", "format" : "pve-node", - "description" : "Target node.", "type" : "string" }, - "vmid" : { - "minimum" : 1, - "format" : "pve-vmid", - "description" : "The (unique) ID of the VM.", - "type" : "integer" - }, "online" : { "description" : "Use online/live migration.", - "type" : "boolean", - "optional" : 1 + "optional" : 1, + "type" : "boolean" }, - "node" : { + "target" : { + "description" : "Target node.", "format" : "pve-node", - "type" : "string", - "description" : "The cluster node name." + "type" : "string" }, - "force" : { - "optional" : 1, - "type" : "boolean", - "description" : "Force migration despite local bind / device mounts. WARNING: identical bind / device mounts need to be available on the target node." + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" } - }, - "additionalProperties" : 0 - }, - "name" : "migrate_vm", - "protected" : 1, - "returns" : { - "type" : "string", - "description" : "the task ID." + } }, "permissions" : { "check" : [ @@ -14716,48 +14669,54 @@ var pveapi = [ ] ] }, + "protected" : 1, "proxyto" : "node", - "description" : "Migrate the container to another node. Creates a new migration task." + "returns" : { + "description" : "the task ID.", + "type" : "string" + } } }, + "leaf" : 1, + "path" : "/nodes/{node}/lxc/{vmid}/migrate", "text" : "migrate" }, { "info" : { "GET" : { + "description" : "Check if feature for virtual machine is available.", + "method" : "GET", "name" : "vm_feature", "parameters" : { "additionalProperties" : 0, "properties" : { + "feature" : { + "description" : "Feature to check.", + "enum" : [ + "snapshot" + ], + "type" : "string" + }, "node" : { + "description" : "The cluster node name.", "format" : "pve-node", - "type" : "string", - "description" : "The cluster node name." + "type" : "string" }, "snapname" : { - "type" : "string", - "optional" : 1, "description" : "The name of the snapshot.", "format" : "pve-configid", - "maxLength" : 40 - }, - "feature" : { - "enum" : [ - "snapshot" - ], - "description" : "Feature to check.", + "maxLength" : 40, + "optional" : 1, "type" : "string" }, "vmid" : { "description" : "The (unique) ID of the VM.", - "type" : "integer", + "format" : "pve-vmid", "minimum" : 1, - "format" : "pve-vmid" + "type" : "integer" } } }, - "protected" : 1, - "method" : "GET", "permissions" : { "check" : [ "perm", @@ -14767,8 +14726,8 @@ var pveapi = [ ] ] }, + "protected" : 1, "proxyto" : "node", - "description" : "Check if feature for virtual machine is available.", "returns" : { "properties" : { "hasFeature" : { @@ -14779,131 +14738,128 @@ var pveapi = [ } } }, - "text" : "feature", "leaf" : 1, - "path" : "/nodes/{node}/lxc/{vmid}/feature" + "path" : "/nodes/{node}/lxc/{vmid}/feature", + "text" : "feature" }, { - "text" : "template", "info" : { "POST" : { + "description" : "Create a Template.", + "method" : "POST", "name" : "template", "parameters" : { "additionalProperties" : 0, "properties" : { - "vmid" : { - "minimum" : 1, - "format" : "pve-vmid", - "type" : "integer", - "description" : "The (unique) ID of the VM." + "experimental" : { + "default" : 0, + "description" : "The template feature is experimental, set this flag if you know what you are doing.", + "type" : "boolean" }, "node" : { - "format" : "pve-node", "description" : "The cluster node name.", + "format" : "pve-node", "type" : "string" }, - "experimental" : { - "default" : 0, - "type" : "boolean", - "description" : "The template feature is experimental, set this flag if you know what you are doing." + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" } } }, - "protected" : 1, - "method" : "POST", "permissions" : { - "description" : "You need 'VM.Allocate' permissions on /vms/{vmid}", "check" : [ "perm", "/vms/{vmid}", [ "VM.Allocate" ] - ] + ], + "description" : "You need 'VM.Allocate' permissions on /vms/{vmid}" }, - "description" : "Create a Template.", + "protected" : 1, "proxyto" : "node", "returns" : { "type" : "null" } } }, + "leaf" : 1, "path" : "/nodes/{node}/lxc/{vmid}/template", - "leaf" : 1 + "text" : "template" }, { - "path" : "/nodes/{node}/lxc/{vmid}/clone", - "leaf" : 1, - "text" : "clone", "info" : { "POST" : { + "description" : "Create a container clone/copy", + "method" : "POST", "name" : "clone_vm", "parameters" : { "additionalProperties" : 0, "properties" : { - "full" : { + "description" : { + "description" : "Description for the new CT.", "optional" : 1, - "type" : "boolean", - "default" : 0, - "description" : "Create a full copy of all disk. This is always done when you clone a normal CT. For CT templates, we try to create a linked clone by default." + "type" : "string" }, "experimental" : { - "type" : "boolean", "default" : 0, - "description" : "The clone feature is experimental, set this flag if you know what you are doing." + "description" : "The clone feature is experimental, set this flag if you know what you are doing.", + "type" : "boolean" }, - "description" : { - "description" : "Description for the new CT.", + "full" : { + "default" : 0, + "description" : "Create a full copy of all disk. This is always done when you clone a normal CT. For CT templates, we try to create a linked clone by default.", "optional" : 1, - "type" : "string" + "type" : "boolean" }, "hostname" : { + "description" : "Set a hostname for the new CT.", "format" : "dns-name", - "type" : "string", "optional" : 1, - "description" : "Set a hostname for the new CT." + "type" : "string" }, - "vmid" : { - "minimum" : 1, + "newid" : { + "description" : "VMID for the clone.", "format" : "pve-vmid", - "description" : "The (unique) ID of the VM.", + "minimum" : 1, "type" : "integer" }, "node" : { "description" : "The cluster node name.", - "type" : "string", - "format" : "pve-node" + "format" : "pve-node", + "type" : "string" + }, + "pool" : { + "description" : "Add the new CT to the specified pool.", + "format" : "pve-poolid", + "optional" : 1, + "type" : "string" }, "snapname" : { + "description" : "The name of the snapshot.", "format" : "pve-configid", "maxLength" : 40, - "type" : "string", - "optional" : 1, - "description" : "The name of the snapshot." - }, - "pool" : { "optional" : 1, - "type" : "string", - "description" : "Add the new CT to the specified pool.", - "format" : "pve-poolid" - }, - "newid" : { - "minimum" : 1, - "format" : "pve-vmid", - "type" : "integer", - "description" : "VMID for the clone." + "type" : "string" }, "storage" : { + "description" : "Target storage for full clone.", "format" : "pve-storage-id", "optional" : 1, - "type" : "string", "requires" : "full", - "description" : "Target storage for full clone." + "type" : "string" + }, + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" } } }, - "protected" : 1, - "method" : "POST", "permissions" : { "check" : [ "and", @@ -14936,35 +14892,31 @@ var pveapi = [ ], "description" : "You need 'VM.Clone' permissions on /vms/{vmid}, and 'VM.Allocate' permissions on /vms/{newid} (or on the VM pool /pool/{pool}). You also need 'Datastore.AllocateSpace' on any used storage." }, + "protected" : 1, "proxyto" : "node", - "description" : "Create a container clone/copy", "returns" : { "type" : "string" } } - } + }, + "leaf" : 1, + "path" : "/nodes/{node}/lxc/{vmid}/clone", + "text" : "clone" }, { - "text" : "resize", "info" : { "PUT" : { + "description" : "Resize a container mountpoint.", + "method" : "PUT", + "name" : "resize_vm", "parameters" : { + "additionalProperties" : 0, "properties" : { - "node" : { - "format" : "pve-node", - "type" : "string", - "description" : "The cluster node name." - }, - "size" : { - "type" : "string", - "description" : "The new size. With the '+' sign the value is added to the actual size of the volume and without it, the value is taken as an absolute one. Shrinking disk size is not supported.", - "pattern" : "\\+?\\d+(\\.\\d+)?[KMGT]?" - }, - "vmid" : { - "format" : "pve-vmid", - "minimum" : 1, - "description" : "The (unique) ID of the VM.", - "type" : "integer" + "digest" : { + "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", + "maxLength" : 40, + "optional" : 1, + "type" : "string" }, "disk" : { "description" : "The disk you want to resize.", @@ -14983,18 +14935,24 @@ var pveapi = [ ], "type" : "string" }, - "digest" : { - "optional" : 1, - "type" : "string", - "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", - "maxLength" : 40 + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, + "size" : { + "description" : "The new size. With the '+' sign the value is added to the actual size of the volume and without it, the value is taken as an absolute one. Shrinking disk size is not supported.", + "pattern" : "\\+?\\d+(\\.\\d+)?[KMGT]?", + "type" : "string" + }, + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" } - }, - "additionalProperties" : 0 + } }, - "name" : "resize_vm", - "protected" : 1, - "method" : "PUT", "permissions" : { "check" : [ "perm", @@ -15006,7 +14964,7 @@ var pveapi = [ 1 ] }, - "description" : "Resize a container mountpoint.", + "protected" : 1, "proxyto" : "node", "returns" : { "description" : "the task ID.", @@ -15014,15 +14972,32 @@ var pveapi = [ } } }, + "leaf" : 1, "path" : "/nodes/{node}/lxc/{vmid}/resize", - "leaf" : 1 + "text" : "resize" } ], - "text" : "{vmid}", "info" : { "DELETE" : { "description" : "Destroy the container (also delete all uses files).", - "proxyto" : "node", + "method" : "DELETE", + "name" : "destroy_vm", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" + } + } + }, "permissions" : { "check" : [ "perm", @@ -15032,313 +15007,356 @@ var pveapi = [ ] ] }, + "protected" : 1, + "proxyto" : "node", "returns" : { "type" : "string" - }, - "protected" : 1, - "name" : "destroy_vm", - "parameters" : { - "properties" : { - "vmid" : { - "format" : "pve-vmid", - "minimum" : 1, - "type" : "integer", - "description" : "The (unique) ID of the VM." - }, - "node" : { - "format" : "pve-node", - "type" : "string", - "description" : "The cluster node name." - } - }, - "additionalProperties" : 0 - }, - "method" : "DELETE" + } }, "GET" : { - "returns" : { - "type" : "array", - "links" : [ - { - "rel" : "child", - "href" : "{subdir}" - } - ], - "items" : { - "properties" : { - "subdir" : { - "type" : "string" - } - }, - "type" : "object" - } - }, - "method" : "GET", - "proxyto" : "node", "description" : "Directory index", + "method" : "GET", "name" : "vmdiridx", "parameters" : { "additionalProperties" : 0, "properties" : { "node" : { - "type" : "string", "description" : "The cluster node name.", - "format" : "pve-node" + "format" : "pve-node", + "type" : "string" }, "vmid" : { "description" : "The (unique) ID of the VM.", - "type" : "integer", "format" : "pve-vmid", - "minimum" : 1 + "minimum" : 1, + "type" : "integer" } } }, "permissions" : { "user" : "all" + }, + "proxyto" : "node", + "returns" : { + "items" : { + "properties" : { + "subdir" : { + "type" : "string" + } + }, + "type" : "object" + }, + "links" : [ + { + "href" : "{subdir}", + "rel" : "child" + } + ], + "type" : "array" } } - } + }, + "leaf" : 0, + "path" : "/nodes/{node}/lxc/{vmid}", + "text" : "{vmid}" } ], "info" : { + "GET" : { + "description" : "LXC container index (per node).", + "method" : "GET", + "name" : "vmlist", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + } + } + }, + "permissions" : { + "description" : "Only list CTs where you have VM.Audit permissons on /vms/.", + "user" : "all" + }, + "protected" : 1, + "proxyto" : "node", + "returns" : { + "items" : { + "properties" : {}, + "type" : "object" + }, + "links" : [ + { + "href" : "{vmid}", + "rel" : "child" + } + ], + "type" : "array" + } + }, "POST" : { + "description" : "Create or restore a container.", "method" : "POST", "name" : "create_vm", "parameters" : { "additionalProperties" : 0, "properties" : { - "storage" : { - "description" : "Default Storage.", - "default" : "local", - "type" : "string", - "optional" : 1, - "format" : "pve-storage-id" - }, - "onboot" : { - "type" : "boolean", + "arch" : { + "default" : "amd64", + "description" : "OS architecture type.", + "enum" : [ + "amd64", + "i386" + ], "optional" : 1, - "default" : 0, - "description" : "Specifies whether a VM will be started during system bootup." + "type" : "string" }, - "startup" : { - "description" : "Startup and shutdown behavior. Order is a non-negative number defining the general startup order. Shutdown in done with reverse ordering. Additionally you can set the 'up' or 'down' delay in seconds, which specifies a delay to wait before the next VM is started or stopped.", - "type" : "string", + "cmode" : { + "default" : "tty", + "description" : "Console mode. By default, the console command tries to open a connection to one of the available tty devices. By setting cmode to 'console' it tries to attach to /dev/console instead. If you set cmode to 'shell', it simply invokes a shell inside the container (no login).", + "enum" : [ + "shell", + "console", + "tty" + ], "optional" : 1, - "format" : "pve-startup-order", - "typetext" : "[[order=]\\d+] [,up=\\d+] [,down=\\d+] " + "type" : "string" }, "console" : { - "description" : "Attach a console device (/dev/console) to the container.", "default" : 1, + "description" : "Attach a console device (/dev/console) to the container.", "optional" : 1, "type" : "boolean" }, - "pool" : { + "cpulimit" : { + "default" : 0, + "description" : "Limit of CPU usage.\n\nNOTE: If the computer has 2 CPUs, it has a total of '2' CPU time. Value '0' indicates no CPU limit.", + "maximum" : 128, + "minimum" : 0, "optional" : 1, - "type" : "string", - "description" : "Add the VM to the specified pool.", - "format" : "pve-poolid" + "type" : "number" }, - "cmode" : { - "enum" : [ - "shell", - "console", - "tty" - ], - "description" : "Console mode. By default, the console command tries to open a connection to one of the available tty devices. By setting cmode to 'console' it tries to attach to /dev/console instead. If you set cmode to 'shell', it simply invokes a shell inside the container (no login).", - "type" : "string", + "cpuunits" : { + "default" : 1024, + "description" : "CPU weight for a VM. Argument is used in the kernel fair scheduler. The larger the number is, the more CPU time this VM gets. Number is relative to the weights of all the other running VMs.\n\nNOTE: You can disable fair-scheduler configuration by setting this to 0.", + "maximum" : 500000, + "minimum" : 0, "optional" : 1, - "default" : "tty" + "type" : "integer" }, "description" : { - "type" : "string", + "description" : "Container description. Only used on the configuration web interface.", "optional" : 1, - "description" : "Container description. Only used on the configuration web interface." + "type" : "string" }, - "lock" : { + "force" : { + "description" : "Allow to overwrite existing container.", "optional" : 1, - "type" : "string", + "type" : "boolean" + }, + "hostname" : { + "description" : "Set a host name for the container.", + "format" : "dns-name", + "maxLength" : 255, + "optional" : 1, + "type" : "string" + }, + "ignore-unpack-errors" : { + "description" : "Ignore errors when extracting the template.", + "optional" : 1, + "type" : "boolean" + }, + "lock" : { + "description" : "Lock/unlock the VM.", "enum" : [ "migrate", "backup", "snapshot", "rollback" ], - "description" : "Lock/unlock the VM." + "optional" : 1, + "type" : "string" }, - "rootfs" : { - "type" : "string", + "memory" : { + "default" : 512, + "description" : "Amount of RAM for the VM in MB.", + "minimum" : 16, "optional" : 1, - "description" : "Use volume as container root.", + "type" : "integer" + }, + "mp[n]" : { + "description" : "Use volume as container mount point (experimental feature).", "format" : { - "ro" : { - "type" : "boolean", - "optional" : 1, - "description" : "Read-only mountpoint (not supported with bind mounts)", - "format_description" : "ro" - }, "acl" : { "description" : "Explicitly enable or disable ACL support.", + "format_description" : "acl", "optional" : 1, - "type" : "boolean", - "format_description" : "acl" + "type" : "boolean" }, "backup" : { "description" : "Whether to include the mountpoint in backups.", - "type" : "boolean", + "format_description" : "[1|0]", + "optional" : 1, + "type" : "boolean" + }, + "mp" : { + "description" : "Path to the mountpoint as seen from inside the container.", + "format" : "pve-lxc-mp-string", + "format_description" : "Path", + "type" : "string" + }, + "quota" : { + "description" : "Enable user quotas inside the container (not supported with zfs subvolumes)", + "format_description" : "[0|1]", "optional" : 1, - "format_description" : "[1|0]" + "type" : "boolean" + }, + "ro" : { + "description" : "Read-only mountpoint (not supported with bind mounts)", + "format_description" : "ro", + "optional" : 1, + "type" : "boolean" }, "size" : { + "description" : "Volume size (read only value).", "format" : "disk-size", "format_description" : "DiskSize", - "description" : "Volume size (read only value).", "optional" : 1, "type" : "string" }, "volume" : { "default_key" : 1, + "description" : "Volume, device or directory to mount into the container.", "format" : "pve-lxc-mp-string", "format_description" : "volume", - "type" : "string", - "description" : "Volume, device or directory to mount into the container." - }, - "quota" : { - "format_description" : "[0|1]", - "optional" : 1, - "type" : "boolean", - "description" : "Enable user quotas inside the container (not supported with zfs subvolumes)" + "type" : "string" } - } - }, - "vmid" : { - "format" : "pve-vmid", - "minimum" : 1, - "description" : "The (unique) ID of the VM.", - "type" : "integer" - }, - "cpuunits" : { - "minimum" : 0, - "maximum" : 500000, - "default" : 1024, - "type" : "integer", - "optional" : 1, - "description" : "CPU weight for a VM. Argument is used in the kernel fair scheduler. The larger the number is, the more CPU time this VM gets. Number is relative to the weights of all the other running VMs.\n\nNOTE: You can disable fair-scheduler configuration by setting this to 0." - }, - "tty" : { - "minimum" : 0, - "description" : "Specify the number of tty available to the container", - "default" : 2, - "maximum" : 6, - "optional" : 1, - "type" : "integer" - }, - "arch" : { - "default" : "amd64", - "type" : "string", + }, "optional" : 1, - "description" : "OS architecture type.", - "enum" : [ - "amd64", - "i386" - ] - }, - "ostemplate" : { - "maxLength" : 255, - "description" : "The OS template or backup file.", "type" : "string" }, - "force" : { - "type" : "boolean", - "optional" : 1, - "description" : "Allow to overwrite existing container." - }, - "node" : { - "format" : "pve-node", - "type" : "string", - "description" : "The cluster node name." - }, - "cpulimit" : { - "minimum" : 0, - "type" : "number", + "nameserver" : { + "description" : "Sets DNS server IP address for a container. Create will automatically use the setting from the host if you neither set searchdomain nor nameserver.", + "format" : "address-list", "optional" : 1, - "default" : 0, - "maximum" : 128, - "description" : "Limit of CPU usage.\n\nNOTE: If the computer has 2 CPUs, it has a total of '2' CPU time. Value '0' indicates no CPU limit." + "type" : "string" }, - "mp[n]" : { + "net[n]" : { + "description" : "Specifies network interfaces for the container.", "format" : { - "backup" : { + "bridge" : { + "description" : "Bridge to attach the network device to.", + "format_description" : "vmbr", "optional" : 1, - "type" : "boolean", - "description" : "Whether to include the mountpoint in backups.", - "format_description" : "[1|0]" + "pattern" : "[-_.\\w\\d]+", + "type" : "string" }, - "size" : { - "format_description" : "DiskSize", - "format" : "disk-size", - "type" : "string", + "firewall" : { + "description" : "Controls whether this interface's firewall rules should be used.", + "format_description" : "[1|0]", "optional" : 1, - "description" : "Volume size (read only value)." + "type" : "boolean" }, - "acl" : { - "description" : "Explicitly enable or disable ACL support.", - "type" : "boolean", + "gw" : { + "description" : "Default gateway for IPv4 traffic.", + "format" : "ipv4", + "format_description" : "GatewayIPv4", "optional" : 1, - "format_description" : "acl" + "type" : "string" }, - "ro" : { - "format_description" : "ro", - "description" : "Read-only mountpoint (not supported with bind mounts)", - "type" : "boolean", - "optional" : 1 + "gw6" : { + "description" : "Default gateway for IPv6 traffic.", + "format" : "ipv6", + "format_description" : "GatewayIPv6", + "optional" : 1, + "type" : "string" }, - "volume" : { - "format_description" : "volume", - "format" : "pve-lxc-mp-string", - "default_key" : 1, - "description" : "Volume, device or directory to mount into the container.", + "hwaddr" : { + "description" : "Bridge to attach the network device to. (lxc.network.hwaddr)", + "format_description" : "MAC", + "optional" : 1, + "pattern" : "(?^i:(?:[a-f0-9]{2}:){5}[a-f0-9]{2})", "type" : "string" }, - "quota" : { + "ip" : { + "description" : "IPv4 address in CIDR format.", + "format" : "pve-ipv4-config", + "format_description" : "IPv4Format/CIDR", "optional" : 1, - "type" : "boolean", - "description" : "Enable user quotas inside the container (not supported with zfs subvolumes)", - "format_description" : "[0|1]" + "type" : "string" }, - "mp" : { - "type" : "string", - "description" : "Path to the mountpoint as seen from inside the container.", - "format_description" : "Path", - "format" : "pve-lxc-mp-string" + "ip6" : { + "description" : "IPv6 address in CIDR format.", + "format" : "pve-ipv6-config", + "format_description" : "IPv6Format/CIDR", + "optional" : 1, + "type" : "string" + }, + "mtu" : { + "description" : "Maximum transfer unit of the interface. (lxc.network.mtu)", + "format_description" : "Number", + "minimum" : 64, + "optional" : 1, + "type" : "integer" + }, + "name" : { + "description" : "Name of the network device as seen from inside the container. (lxc.network.name)", + "format_description" : "String", + "pattern" : "[-_.\\w\\d]+", + "type" : "string" + }, + "rate" : { + "description" : "Apply rate limiting to the interface", + "format_description" : "mbps", + "optional" : 1, + "type" : "number" + }, + "tag" : { + "description" : "VLAN tag for this interface.", + "format_description" : "VlanNo", + "maximum" : "4094", + "minimum" : "2", + "optional" : 1, + "type" : "integer" + }, + "trunks" : { + "description" : "VLAN ids to pass through the interface", + "format_description" : "vlanid[;vlanid...]", + "optional" : 1, + "pattern" : "(?^:\\d+(?:;\\d+)*)", + "type" : "string" + }, + "type" : { + "description" : "Network interface type.", + "enum" : [ + "veth" + ], + "optional" : 1, + "type" : "string" } }, - "description" : "Use volume as container mount point (experimental feature).", - "type" : "string", - "optional" : 1 - }, - "unprivileged" : { - "type" : "boolean", "optional" : 1, - "default" : 0, - "description" : "Makes the container run as unprivileged user. (Should not be modified manually.)" + "type" : "string" }, - "unused[n]" : { - "description" : "Reference to unused volumes.", - "type" : "string", - "optional" : 1, - "format" : "pve-volume-id" + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" }, - "swap" : { - "description" : "Amount of SWAP for the VM in MB.", - "default" : 512, + "onboot" : { + "default" : 0, + "description" : "Specifies whether a VM will be started during system bootup.", "optional" : 1, - "type" : "integer", - "minimum" : 0 + "type" : "boolean" + }, + "ostemplate" : { + "description" : "The OS template or backup file.", + "maxLength" : 255, + "type" : "string" }, "ostype" : { - "type" : "string", - "optional" : 1, "description" : "OS type. This is used to setup configuration inside the container, and corresponds to lxc setup scripts in /usr/share/lxc/config/.common.conf. Value 'unmanaged' can be used to skip and OS specific setup.", "enum" : [ "debian", @@ -15349,373 +15367,185 @@ var pveapi = [ "archlinux", "alpine", "unmanaged" - ] - }, - "memory" : { - "description" : "Amount of RAM for the VM in MB.", - "type" : "integer", - "optional" : 1, - "default" : 512, - "minimum" : 16 - }, - "ssh-public-keys" : { - "description" : "Setup public SSH keys (one key per line, OpenSSH format).", + ], "optional" : 1, "type" : "string" }, - "protection" : { - "type" : "boolean", - "optional" : 1, - "default" : 0, - "description" : "Sets the protection flag of the container. This will prevent the CT or CT's disk remove/update operation." - }, - "ignore-unpack-errors" : { - "type" : "boolean", - "optional" : 1, - "description" : "Ignore errors when extracting the template." - }, - "template" : { - "description" : "Enable/disable Template.", - "optional" : 1, - "type" : "boolean", - "default" : 0 - }, - "restore" : { - "optional" : 1, - "type" : "boolean", - "description" : "Mark this as restore task." - }, - "hostname" : { - "format" : "dns-name", - "maxLength" : 255, - "description" : "Set a host name for the container.", + "password" : { + "description" : "Sets root password inside container.", + "minLength" : 5, "optional" : 1, "type" : "string" }, - "password" : { + "pool" : { + "description" : "Add the VM to the specified pool.", + "format" : "pve-poolid", "optional" : 1, - "type" : "string", - "description" : "Sets root password inside container.", - "minLength" : 5 + "type" : "string" }, - "searchdomain" : { - "format" : "dns-name-list", + "protection" : { + "default" : 0, + "description" : "Sets the protection flag of the container. This will prevent the CT or CT's disk remove/update operation.", "optional" : 1, - "type" : "string", - "description" : "Sets DNS search domains for a container. Create will automatically use the setting from the host if you neither set searchdomain nor nameserver." + "type" : "boolean" }, - "nameserver" : { - "format" : "address-list", - "description" : "Sets DNS server IP address for a container. Create will automatically use the setting from the host if you neither set searchdomain nor nameserver.", - "type" : "string", - "optional" : 1 + "restore" : { + "description" : "Mark this as restore task.", + "optional" : 1, + "type" : "boolean" }, - "net[n]" : { + "rootfs" : { + "description" : "Use volume as container root.", "format" : { - "gw6" : { - "format" : "ipv6", - "format_description" : "GatewayIPv6", - "description" : "Default gateway for IPv6 traffic.", - "type" : "string", - "optional" : 1 - }, - "tag" : { - "description" : "VLAN tag for this interface.", - "type" : "integer", + "acl" : { + "description" : "Explicitly enable or disable ACL support.", + "format_description" : "acl", "optional" : 1, - "maximum" : "4094", - "format_description" : "VlanNo", - "minimum" : "2" + "type" : "boolean" }, - "firewall" : { + "backup" : { + "description" : "Whether to include the mountpoint in backups.", "format_description" : "[1|0]", - "description" : "Controls whether this interface's firewall rules should be used.", "optional" : 1, "type" : "boolean" }, - "type" : { - "type" : "string", - "optional" : 1, - "description" : "Network interface type.", - "enum" : [ - "veth" - ] - }, - "trunks" : { - "format_description" : "vlanid[;vlanid...]", - "type" : "string", - "optional" : 1, - "pattern" : "(?^:\\d+(?:;\\d+)*)", - "description" : "VLAN ids to pass through the interface" - }, - "ip" : { - "format" : "pve-ipv4-config", - "format_description" : "IPv4Format/CIDR", - "description" : "IPv4 address in CIDR format.", - "type" : "string", - "optional" : 1 - }, - "rate" : { - "description" : "Apply rate limiting to the interface", + "quota" : { + "description" : "Enable user quotas inside the container (not supported with zfs subvolumes)", + "format_description" : "[0|1]", "optional" : 1, - "type" : "number", - "format_description" : "mbps" + "type" : "boolean" }, - "ip6" : { - "type" : "string", + "ro" : { + "description" : "Read-only mountpoint (not supported with bind mounts)", + "format_description" : "ro", "optional" : 1, - "description" : "IPv6 address in CIDR format.", - "format" : "pve-ipv6-config", - "format_description" : "IPv6Format/CIDR" + "type" : "boolean" }, - "gw" : { - "format" : "ipv4", - "format_description" : "GatewayIPv4", - "description" : "Default gateway for IPv4 traffic.", + "size" : { + "description" : "Volume size (read only value).", + "format" : "disk-size", + "format_description" : "DiskSize", "optional" : 1, "type" : "string" }, - "bridge" : { - "format_description" : "vmbr", - "optional" : 1, - "type" : "string", - "description" : "Bridge to attach the network device to.", - "pattern" : "[-_.\\w\\d]+" - }, - "name" : { - "type" : "string", - "description" : "Name of the network device as seen from inside the container. (lxc.network.name)", - "pattern" : "[-_.\\w\\d]+", - "format_description" : "String" - }, - "mtu" : { - "description" : "Maximum transfer unit of the interface. (lxc.network.mtu)", - "type" : "integer", - "optional" : 1, - "format_description" : "Number", - "minimum" : 64 - }, - "hwaddr" : { - "format_description" : "MAC", - "description" : "Bridge to attach the network device to. (lxc.network.hwaddr)", - "pattern" : "(?^i:(?:[a-f0-9]{2}:){5}[a-f0-9]{2})", - "type" : "string", - "optional" : 1 + "volume" : { + "default_key" : 1, + "description" : "Volume, device or directory to mount into the container.", + "format" : "pve-lxc-mp-string", + "format_description" : "volume", + "type" : "string" } }, - "description" : "Specifies network interfaces for the container.", "optional" : 1, "type" : "string" - } - } - }, - "protected" : 1, - "returns" : { - "type" : "string" - }, - "permissions" : { - "description" : "You need 'VM.Allocate' permissions on /vms/{vmid} or on the VM pool /pool/{pool}. For restore, it is enough if the user has 'VM.Backup' permission and the VM already exists. You also need 'Datastore.AllocateSpace' permissions on the storage.", - "user" : "all" - }, - "proxyto" : "node", - "description" : "Create or restore a container." - }, - "GET" : { - "name" : "vmlist", - "parameters" : { - "additionalProperties" : 0, - "properties" : { - "node" : { - "type" : "string", - "description" : "The cluster node name.", - "format" : "pve-node" - } - } - }, - "protected" : 1, - "method" : "GET", - "permissions" : { - "description" : "Only list CTs where you have VM.Audit permissons on /vms/.", - "user" : "all" - }, - "proxyto" : "node", - "description" : "LXC container index (per node).", - "returns" : { - "items" : { - "type" : "object", - "properties" : {} - }, - "links" : [ - { - "rel" : "child", - "href" : "{vmid}" - } - ], - "type" : "array" - } - } - } - }, - { - "info" : { - "GET" : { - "description" : "Directory index.", - "parameters" : { - "properties" : { - "node" : { - "format" : "pve-node", + }, + "searchdomain" : { + "description" : "Sets DNS search domains for a container. Create will automatically use the setting from the host if you neither set searchdomain nor nameserver.", + "format" : "dns-name-list", + "optional" : 1, + "type" : "string" + }, + "ssh-public-keys" : { + "description" : "Setup public SSH keys (one key per line, OpenSSH format).", + "optional" : 1, + "type" : "string" + }, + "startup" : { + "description" : "Startup and shutdown behavior. Order is a non-negative number defining the general startup order. Shutdown in done with reverse ordering. Additionally you can set the 'up' or 'down' delay in seconds, which specifies a delay to wait before the next VM is started or stopped.", + "format" : "pve-startup-order", + "optional" : 1, "type" : "string", - "description" : "The cluster node name." - } - }, - "additionalProperties" : 0 - }, - "permissions" : { - "check" : [ - "perm", - "/", - [ - "Sys.Audit", - "Datastore.Audit" - ], - "any", - 1 - ] - }, - "name" : "index", - "method" : "GET", - "returns" : { - "type" : "array", - "items" : { - "properties" : {}, - "type" : "object" - }, - "links" : [ - { - "href" : "{name}", - "rel" : "child" - } - ] - } - } - }, - "children" : [ - { - "info" : { - "POST" : { - "name" : "createosd", - "parameters" : { - "additionalProperties" : 0, - "properties" : { - "node" : { - "format" : "pve-node", - "description" : "The cluster node name.", - "type" : "string" - }, - "fstype" : { - "enum" : [ - "xfs", - "ext4", - "btrfs" - ], - "description" : "File system type.", - "type" : "string", - "optional" : 1, - "default" : "xfs" - }, - "journal_dev" : { - "type" : "string", - "optional" : 1, - "description" : "Block device name for journal." - }, - "dev" : { - "description" : "Block device name.", - "type" : "string" - } - } + "typetext" : "[[order=]\\d+] [,up=\\d+] [,down=\\d+] " }, - "proxyto" : "node", - "description" : "Create OSD", - "protected" : 1, - "method" : "POST", - "returns" : { + "storage" : { + "default" : "local", + "description" : "Default Storage.", + "format" : "pve-storage-id", + "optional" : 1, "type" : "string" - } - }, - "GET" : { - "permissions" : { - "check" : [ - "perm", - "/", - [ - "Sys.Audit", - "Datastore.Audit" - ], - "any", - 1 - ] }, - "proxyto" : "node", - "description" : "Get Ceph osd list/tree.", - "returns" : { - "type" : "object" + "swap" : { + "default" : 512, + "description" : "Amount of SWAP for the VM in MB.", + "minimum" : 0, + "optional" : 1, + "type" : "integer" + }, + "template" : { + "default" : 0, + "description" : "Enable/disable Template.", + "optional" : 1, + "type" : "boolean" }, - "name" : "index", - "parameters" : { - "properties" : { - "node" : { - "format" : "pve-node", - "description" : "The cluster node name.", - "type" : "string" - } - }, - "additionalProperties" : 0 + "tty" : { + "default" : 2, + "description" : "Specify the number of tty available to the container", + "maximum" : 6, + "minimum" : 0, + "optional" : 1, + "type" : "integer" }, - "protected" : 1, - "method" : "GET" + "unprivileged" : { + "default" : 0, + "description" : "Makes the container run as unprivileged user. (Should not be modified manually.)", + "optional" : 1, + "type" : "boolean" + }, + "unused[n]" : { + "description" : "Reference to unused volumes.", + "format" : "pve-volume-id", + "optional" : 1, + "type" : "string" + }, + "vmid" : { + "description" : "The (unique) ID of the VM.", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" + } } }, + "permissions" : { + "description" : "You need 'VM.Allocate' permissions on /vms/{vmid} or on the VM pool /pool/{pool}. For restore, it is enough if the user has 'VM.Backup' permission and the VM already exists. You also need 'Datastore.AllocateSpace' permissions on the storage.", + "user" : "all" + }, + "protected" : 1, + "proxyto" : "node", + "returns" : { + "type" : "string" + } + } + }, + "leaf" : 0, + "path" : "/nodes/{node}/lxc", + "text" : "lxc" + }, + { + "children" : [ + { "children" : [ { - "leaf" : 0, - "path" : "/nodes/{node}/ceph/osd/{osdid}", - "info" : { - "DELETE" : { - "name" : "destroyosd", - "parameters" : { - "additionalProperties" : 0, - "properties" : { - "osdid" : { - "type" : "integer", - "description" : "OSD ID" - }, - "cleanup" : { - "description" : "If set, we remove partition table entries.", - "optional" : 1, - "type" : "boolean", - "default" : 0 - }, - "node" : { - "format" : "pve-node", - "type" : "string", - "description" : "The cluster node name." - } - } - }, - "protected" : 1, - "description" : "Destroy OSD", - "proxyto" : "node", - "method" : "DELETE", - "returns" : { - "type" : "string" - } - } - }, "children" : [ { - "text" : "in", "info" : { "POST" : { + "description" : "ceph osd in", + "method" : "POST", + "name" : "in", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, + "osdid" : { + "description" : "OSD ID", + "type" : "integer" + } + } + }, "permissions" : { "check" : [ "perm", @@ -15725,38 +15555,37 @@ var pveapi = [ ] ] }, - "description" : "ceph osd in", + "protected" : 1, "proxyto" : "node", "returns" : { "type" : "null" - }, - "name" : "in", - "parameters" : { - "properties" : { - "osdid" : { - "type" : "integer", - "description" : "OSD ID" - }, - "node" : { - "format" : "pve-node", - "description" : "The cluster node name.", - "type" : "string" - } - }, - "additionalProperties" : 0 - }, - "protected" : 1, - "method" : "POST" + } } }, + "leaf" : 1, "path" : "/nodes/{node}/ceph/osd/{osdid}/in", - "leaf" : 1 + "text" : "in" }, { - "leaf" : 1, - "path" : "/nodes/{node}/ceph/osd/{osdid}/out", "info" : { "POST" : { + "description" : "ceph osd out", + "method" : "POST", + "name" : "out", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, + "osdid" : { + "description" : "OSD ID", + "type" : "integer" + } + } + }, "permissions" : { "check" : [ "perm", @@ -15766,48 +15595,158 @@ var pveapi = [ ] ] }, + "protected" : 1, "proxyto" : "node", - "description" : "ceph osd out", "returns" : { "type" : "null" + } + } + }, + "leaf" : 1, + "path" : "/nodes/{node}/ceph/osd/{osdid}/out", + "text" : "out" + } + ], + "info" : { + "DELETE" : { + "description" : "Destroy OSD", + "method" : "DELETE", + "name" : "destroyosd", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "cleanup" : { + "default" : 0, + "description" : "If set, we remove partition table entries.", + "optional" : 1, + "type" : "boolean" }, - "parameters" : { - "properties" : { - "node" : { - "format" : "pve-node", - "type" : "string", - "description" : "The cluster node name." - }, - "osdid" : { - "type" : "integer", - "description" : "OSD ID" - } - }, - "additionalProperties" : 0 + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" }, - "name" : "out", - "protected" : 1, - "method" : "POST" + "osdid" : { + "description" : "OSD ID", + "type" : "integer" + } } }, - "text" : "out" + "protected" : 1, + "proxyto" : "node", + "returns" : { + "type" : "string" + } + } + }, + "leaf" : 0, + "path" : "/nodes/{node}/ceph/osd/{osdid}", + "text" : "{osdid}" + } + ], + "info" : { + "GET" : { + "description" : "Get Ceph osd list/tree.", + "method" : "GET", + "name" : "index", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + } + } + }, + "permissions" : { + "check" : [ + "perm", + "/", + [ + "Sys.Audit", + "Datastore.Audit" + ], + "any", + 1 + ] + }, + "protected" : 1, + "proxyto" : "node", + "returns" : { + "type" : "object" + } + }, + "POST" : { + "description" : "Create OSD", + "method" : "POST", + "name" : "createosd", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "dev" : { + "description" : "Block device name.", + "type" : "string" + }, + "fstype" : { + "default" : "xfs", + "description" : "File system type.", + "enum" : [ + "xfs", + "ext4", + "btrfs" + ], + "optional" : 1, + "type" : "string" + }, + "journal_dev" : { + "description" : "Block device name for journal.", + "optional" : 1, + "type" : "string" + }, + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + } } - ], - "text" : "{osdid}" + }, + "protected" : 1, + "proxyto" : "node", + "returns" : { + "type" : "string" + } } - ], - "text" : "osd", + }, "leaf" : 0, - "path" : "/nodes/{node}/ceph/osd" + "path" : "/nodes/{node}/ceph/osd", + "text" : "osd" }, { - "path" : "/nodes/{node}/ceph/disks", - "leaf" : 1, - "text" : "disks", "info" : { "GET" : { - "proxyto" : "node", "description" : "List local disks.", + "method" : "GET", + "name" : "disks", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, + "type" : { + "description" : "Only list specific types of disks.", + "enum" : [ + "unused", + "journal_disks" + ], + "optional" : 1, + "type" : "string" + } + } + }, "permissions" : { "check" : [ "perm", @@ -15820,89 +15759,66 @@ var pveapi = [ 1 ] }, + "protected" : 1, + "proxyto" : "node", "returns" : { - "type" : "array", "items" : { "properties" : { - "vendor" : { - "type" : "string", - "optional" : 1 + "dev" : { + "type" : "string" + }, + "gpt" : { + "type" : "boolean" + }, + "model" : { + "optional" : 1, + "type" : "string" }, "osdid" : { "type" : "integer" }, "serial" : { - "type" : "string", - "optional" : 1 - }, - "model" : { - "type" : "string", - "optional" : 1 - }, - "used" : { "optional" : 1, "type" : "string" }, "size" : { "type" : "integer" }, - "dev" : { + "used" : { + "optional" : 1, "type" : "string" }, - "gpt" : { - "type" : "boolean" + "vendor" : { + "optional" : 1, + "type" : "string" } }, "type" : "object" - } - }, - "protected" : 1, - "name" : "disks", - "parameters" : { - "additionalProperties" : 0, - "properties" : { - "node" : { - "type" : "string", - "description" : "The cluster node name.", - "format" : "pve-node" - }, - "type" : { - "optional" : 1, - "type" : "string", - "description" : "Only list specific types of disks.", - "enum" : [ - "unused", - "journal_disks" - ] - } - } - }, - "method" : "GET" + }, + "type" : "array" + } } - } + }, + "leaf" : 1, + "path" : "/nodes/{node}/ceph/disks", + "text" : "disks" }, { - "path" : "/nodes/{node}/ceph/config", - "leaf" : 1, - "text" : "config", "info" : { "GET" : { - "method" : "GET", - "returns" : { - "type" : "string" - }, "description" : "Get Ceph configuration.", + "method" : "GET", + "name" : "config", "parameters" : { "additionalProperties" : 0, "properties" : { "node" : { - "format" : "pve-node", "description" : "The cluster node name.", + "format" : "pve-node", "type" : "string" } } }, - "name" : "config", "permissions" : { "check" : [ "perm", @@ -15914,23 +15830,38 @@ var pveapi = [ "any", 1 ] + }, + "returns" : { + "type" : "string" } } - } + }, + "leaf" : 1, + "path" : "/nodes/{node}/ceph/config", + "text" : "config" }, { - "path" : "/nodes/{node}/ceph/mon", - "leaf" : 0, - "text" : "mon", "children" : [ { - "path" : "/nodes/{node}/ceph/mon/{monid}", - "leaf" : 1, - "text" : "{monid}", "info" : { "DELETE" : { - "proxyto" : "node", "description" : "Destroy Ceph monitor.", + "method" : "DELETE", + "name" : "destroymon", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "monid" : { + "description" : "Monitor ID", + "type" : "integer" + }, + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + } + } + }, "permissions" : { "check" : [ "perm", @@ -15940,52 +15871,54 @@ var pveapi = [ ] ] }, + "protected" : 1, + "proxyto" : "node", "returns" : { "type" : "string" - }, - "protected" : 1, - "parameters" : { - "additionalProperties" : 0, - "properties" : { - "node" : { - "type" : "string", - "description" : "The cluster node name.", - "format" : "pve-node" - }, - "monid" : { - "description" : "Monitor ID", - "type" : "integer" - } - } - }, - "name" : "destroymon", - "method" : "DELETE" + } } - } + }, + "leaf" : 1, + "path" : "/nodes/{node}/ceph/mon/{monid}", + "text" : "{monid}" } ], "info" : { "GET" : { + "description" : "Get Ceph monitor list.", "method" : "GET", + "name" : "listmon", "parameters" : { "additionalProperties" : 0, "properties" : { "node" : { - "type" : "string", "description" : "The cluster node name.", - "format" : "pve-node" + "format" : "pve-node", + "type" : "string" } } }, - "name" : "listmon", + "permissions" : { + "check" : [ + "perm", + "/", + [ + "Sys.Audit", + "Datastore.Audit" + ], + "any", + 1 + ] + }, "protected" : 1, + "proxyto" : "node", "returns" : { "items" : { "properties" : { - "name" : { + "addr" : { "type" : "string" }, - "addr" : { + "name" : { "type" : "string" } }, @@ -15998,23 +15931,22 @@ var pveapi = [ } ], "type" : "array" - }, - "permissions" : { - "check" : [ - "perm", - "/", - [ - "Sys.Audit", - "Datastore.Audit" - ], - "any", - 1 - ] - }, - "description" : "Get Ceph monitor list.", - "proxyto" : "node" + } }, "POST" : { + "description" : "Create Ceph Monitor", + "method" : "POST", + "name" : "createmon", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + } + } + }, "permissions" : { "check" : [ "perm", @@ -16024,35 +15956,56 @@ var pveapi = [ ] ] }, - "description" : "Create Ceph Monitor", + "protected" : 1, "proxyto" : "node", "returns" : { "type" : "string" - }, - "parameters" : { - "properties" : { - "node" : { - "format" : "pve-node", - "type" : "string", - "description" : "The cluster node name." - } - }, - "additionalProperties" : 0 - }, - "name" : "createmon", - "protected" : 1, - "method" : "POST" + } } - } + }, + "leaf" : 0, + "path" : "/nodes/{node}/ceph/mon", + "text" : "mon" }, { "info" : { "POST" : { - "returns" : { - "type" : "null" + "description" : "Create initial ceph default configuration and setup symlinks.", + "method" : "POST", + "name" : "init", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "network" : { + "description" : "Use specific network for all ceph related traffic", + "format" : "CIDR", + "maxLength" : 128, + "optional" : 1, + "type" : "string" + }, + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, + "pg_bits" : { + "default" : 6, + "description" : "Placement group bits, used to specify the default number of placement groups.\n\nNOTE: 'osd pool default pg num' does not work for default pools.", + "maximum" : 14, + "minimum" : 6, + "optional" : 1, + "type" : "integer" + }, + "size" : { + "default" : 2, + "description" : "Number of replicas per object", + "maximum" : 3, + "minimum" : 1, + "optional" : 1, + "type" : "integer" + } + } }, - "proxyto" : "node", - "description" : "Create initial ceph default configuration and setup symlinks.", "permissions" : { "check" : [ "perm", @@ -16062,75 +16015,38 @@ var pveapi = [ ] ] }, - "method" : "POST", "protected" : 1, - "name" : "init", - "parameters" : { - "properties" : { - "pg_bits" : { - "description" : "Placement group bits, used to specify the default number of placement groups.\n\nNOTE: 'osd pool default pg num' does not work for default pools.", - "default" : 6, - "maximum" : 14, - "optional" : 1, - "type" : "integer", - "minimum" : 6 - }, - "size" : { - "minimum" : 1, - "maximum" : 3, - "default" : 2, - "type" : "integer", - "optional" : 1, - "description" : "Number of replicas per object" - }, - "node" : { - "description" : "The cluster node name.", - "type" : "string", - "format" : "pve-node" - }, - "network" : { - "optional" : 1, - "type" : "string", - "description" : "Use specific network for all ceph related traffic", - "format" : "CIDR", - "maxLength" : 128 - } - }, - "additionalProperties" : 0 + "proxyto" : "node", + "returns" : { + "type" : "null" } } }, - "text" : "init", "leaf" : 1, - "path" : "/nodes/{node}/ceph/init" + "path" : "/nodes/{node}/ceph/init", + "text" : "init" }, { - "path" : "/nodes/{node}/ceph/stop", - "leaf" : 1, - "text" : "stop", "info" : { "POST" : { + "description" : "Stop ceph services.", "method" : "POST", "name" : "stop", "parameters" : { + "additionalProperties" : 0, "properties" : { "node" : { - "format" : "pve-node", "description" : "The cluster node name.", + "format" : "pve-node", "type" : "string" }, "service" : { - "type" : "string", - "optional" : 1, "description" : "Ceph service name.", - "pattern" : "(mon|mds|osd)\\.[A-Za-z0-9]{1,32}" + "optional" : 1, + "pattern" : "(mon|mds|osd)\\.[A-Za-z0-9]{1,32}", + "type" : "string" } - }, - "additionalProperties" : 0 - }, - "protected" : 1, - "returns" : { - "type" : "string" + } }, "permissions" : { "check" : [ @@ -16141,72 +16057,75 @@ var pveapi = [ ] ] }, - "description" : "Stop ceph services.", - "proxyto" : "node" + "protected" : 1, + "proxyto" : "node", + "returns" : { + "type" : "string" + } } - } + }, + "leaf" : 1, + "path" : "/nodes/{node}/ceph/stop", + "text" : "stop" }, { - "path" : "/nodes/{node}/ceph/start", - "leaf" : 1, - "text" : "start", "info" : { "POST" : { - "permissions" : { - "check" : [ - "perm", - "/", - [ - "Sys.Modify" - ] - ] - }, - "proxyto" : "node", "description" : "Start ceph services.", - "returns" : { - "type" : "string" - }, + "method" : "POST", "name" : "start", "parameters" : { "additionalProperties" : 0, "properties" : { "node" : { - "format" : "pve-node", "description" : "The cluster node name.", + "format" : "pve-node", "type" : "string" }, "service" : { "description" : "Ceph service name.", + "optional" : 1, "pattern" : "(mon|mds|osd)\\.[A-Za-z0-9]{1,32}", - "type" : "string", - "optional" : 1 + "type" : "string" } } }, + "permissions" : { + "check" : [ + "perm", + "/", + [ + "Sys.Modify" + ] + ] + }, "protected" : 1, - "method" : "POST" + "proxyto" : "node", + "returns" : { + "type" : "string" + } } - } + }, + "leaf" : 1, + "path" : "/nodes/{node}/ceph/start", + "text" : "start" }, { - "text" : "status", "info" : { "GET" : { - "protected" : 1, + "description" : "Get ceph status.", + "method" : "GET", + "name" : "status", "parameters" : { "additionalProperties" : 0, "properties" : { "node" : { - "format" : "pve-node", "description" : "The cluster node name.", + "format" : "pve-node", "type" : "string" } } }, - "name" : "status", - "method" : "GET", - "description" : "Get ceph status.", - "proxyto" : "node", "permissions" : { "check" : [ "perm", @@ -16219,32 +16138,75 @@ var pveapi = [ 1 ] }, + "protected" : 1, + "proxyto" : "node", "returns" : { "type" : "object" } } }, + "leaf" : 1, "path" : "/nodes/{node}/ceph/status", - "leaf" : 1 + "text" : "status" }, { + "children" : [ + { + "info" : { + "DELETE" : { + "description" : "Destroy pool", + "method" : "DELETE", + "name" : "destroypool", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "name" : { + "description" : "The name of the pool. It must be unique.", + "type" : "string" + }, + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + } + } + }, + "permissions" : { + "check" : [ + "perm", + "/", + [ + "Sys.Modify" + ] + ] + }, + "protected" : 1, + "proxyto" : "node", + "returns" : { + "type" : "null" + } + } + }, + "leaf" : 1, + "path" : "/nodes/{node}/ceph/pools/{name}", + "text" : "{name}" + } + ], "info" : { "GET" : { - "protected" : 1, + "description" : "List all pools.", + "method" : "GET", + "name" : "lspools", "parameters" : { "additionalProperties" : 0, "properties" : { "node" : { - "type" : "string", "description" : "The cluster node name.", - "format" : "pve-node" + "format" : "pve-node", + "type" : "string" } } }, - "name" : "lspools", - "method" : "GET", - "proxyto" : "node", - "description" : "List all pools.", "permissions" : { "check" : [ "perm", @@ -16257,147 +16219,118 @@ var pveapi = [ 1 ] }, + "protected" : 1, + "proxyto" : "node", "returns" : { - "links" : [ - { - "rel" : "child", - "href" : "{pool_name}" - } - ], "items" : { - "type" : "object", "properties" : { - "pool_name" : { - "type" : "string" - }, "pool" : { "type" : "integer" }, + "pool_name" : { + "type" : "string" + }, "size" : { "type" : "integer" } - } + }, + "type" : "object" }, + "links" : [ + { + "href" : "{pool_name}", + "rel" : "child" + } + ], "type" : "array" } }, "POST" : { - "returns" : { - "type" : "null" - }, - "proxyto" : "node", "description" : "Create POOL", - "permissions" : { - "check" : [ - "perm", - "/", - [ - "Sys.Modify" - ] - ] - }, "method" : "POST", - "protected" : 1, "name" : "createpool", "parameters" : { "additionalProperties" : 0, "properties" : { - "size" : { - "maximum" : 3, - "default" : 2, - "optional" : 1, - "type" : "integer", - "description" : "Number of replicas per object", - "minimum" : 1 - }, - "node" : { - "format" : "pve-node", - "type" : "string", - "description" : "The cluster node name." - }, - "name" : { - "description" : "The name of the pool. It must be unique.", - "type" : "string" - }, "crush_ruleset" : { - "minimum" : 0, - "optional" : 1, - "type" : "integer", "default" : 0, + "description" : "The ruleset to use for mapping object placement in the cluster.", "maximum" : 32768, - "description" : "The ruleset to use for mapping object placement in the cluster." - }, - "pg_num" : { - "optional" : 1, - "type" : "integer", - "maximum" : 32768, - "default" : 64, - "description" : "Number of placement groups.", - "minimum" : 8 - }, - "min_size" : { + "minimum" : 0, "optional" : 1, - "type" : "integer", - "maximum" : 3, - "default" : 1, - "description" : "Minimum number of replicas per object", - "minimum" : 1 - } - } - } - } - }, - "children" : [ - { - "path" : "/nodes/{node}/ceph/pools/{name}", - "leaf" : 1, - "text" : "{name}", - "info" : { - "DELETE" : { - "method" : "DELETE", - "protected" : 1, - "parameters" : { - "properties" : { - "node" : { - "format" : "pve-node", - "description" : "The cluster node name.", - "type" : "string" - }, - "name" : { - "type" : "string", - "description" : "The name of the pool. It must be unique." - } - }, - "additionalProperties" : 0 + "type" : "integer" }, - "name" : "destroypool", - "returns" : { - "type" : "null" + "min_size" : { + "default" : 1, + "description" : "Minimum number of replicas per object", + "maximum" : 3, + "minimum" : 1, + "optional" : 1, + "type" : "integer" }, - "proxyto" : "node", - "description" : "Destroy pool", - "permissions" : { - "check" : [ - "perm", - "/", - [ - "Sys.Modify" - ] - ] + "name" : { + "description" : "The name of the pool. It must be unique.", + "type" : "string" + }, + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, + "pg_num" : { + "default" : 64, + "description" : "Number of placement groups.", + "maximum" : 32768, + "minimum" : 8, + "optional" : 1, + "type" : "integer" + }, + "size" : { + "default" : 2, + "description" : "Number of replicas per object", + "maximum" : 3, + "minimum" : 1, + "optional" : 1, + "type" : "integer" } } + }, + "permissions" : { + "check" : [ + "perm", + "/", + [ + "Sys.Modify" + ] + ] + }, + "protected" : 1, + "proxyto" : "node", + "returns" : { + "type" : "null" } } - ], - "text" : "pools", + }, "leaf" : 0, - "path" : "/nodes/{node}/ceph/pools" + "path" : "/nodes/{node}/ceph/pools", + "text" : "pools" }, { - "leaf" : 1, - "path" : "/nodes/{node}/ceph/crush", "info" : { "GET" : { + "description" : "Get OSD crush map", + "method" : "GET", + "name" : "crush", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + } + } + }, "permissions" : { "check" : [ "perm", @@ -16410,49 +16343,43 @@ var pveapi = [ 1 ] }, - "description" : "Get OSD crush map", + "protected" : 1, "proxyto" : "node", "returns" : { "type" : "string" - }, - "parameters" : { - "properties" : { - "node" : { - "format" : "pve-node", - "description" : "The cluster node name.", - "type" : "string" - } - }, - "additionalProperties" : 0 - }, - "name" : "crush", - "protected" : 1, - "method" : "GET" + } } }, + "leaf" : 1, + "path" : "/nodes/{node}/ceph/crush", "text" : "crush" }, { "info" : { "GET" : { - "returns" : { - "type" : "array", - "items" : { - "properties" : { - "t" : { - "type" : "string", - "description" : "Line text" - }, - "n" : { - "type" : "integer", - "description" : "Line number" - } + "description" : "Read ceph log", + "method" : "GET", + "name" : "log", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "limit" : { + "minimum" : 0, + "optional" : 1, + "type" : "integer" }, - "type" : "object" + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, + "start" : { + "minimum" : 0, + "optional" : 1, + "type" : "integer" + } } }, - "description" : "Read ceph log", - "proxyto" : "node", "permissions" : { "check" : [ "perm", @@ -16462,377 +16389,291 @@ var pveapi = [ ] ] }, - "method" : "GET", "protected" : 1, - "name" : "log", - "parameters" : { - "properties" : { - "start" : { - "minimum" : 0, - "type" : "integer", - "optional" : 1 - }, - "node" : { - "description" : "The cluster node name.", - "type" : "string", - "format" : "pve-node" + "proxyto" : "node", + "returns" : { + "items" : { + "properties" : { + "n" : { + "description" : "Line number", + "type" : "integer" + }, + "t" : { + "description" : "Line text", + "type" : "string" + } }, - "limit" : { - "type" : "integer", - "optional" : 1, - "minimum" : 0 - } + "type" : "object" }, - "additionalProperties" : 0 + "type" : "array" } } }, - "text" : "log", "leaf" : 1, - "path" : "/nodes/{node}/ceph/log" + "path" : "/nodes/{node}/ceph/log", + "text" : "log" } ], - "text" : "ceph", + "info" : { + "GET" : { + "description" : "Directory index.", + "method" : "GET", + "name" : "index", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + } + } + }, + "permissions" : { + "check" : [ + "perm", + "/", + [ + "Sys.Audit", + "Datastore.Audit" + ], + "any", + 1 + ] + }, + "returns" : { + "items" : { + "properties" : {}, + "type" : "object" + }, + "links" : [ + { + "href" : "{name}", + "rel" : "child" + } + ], + "type" : "array" + } + } + }, "leaf" : 0, - "path" : "/nodes/{node}/ceph" + "path" : "/nodes/{node}/ceph", + "text" : "ceph" }, { - "text" : "vzdump", "info" : { "POST" : { - "permissions" : { - "user" : "all", - "description" : "The user needs 'VM.Backup' permissions on any VM, and 'Datastore.AllocateSpace' on the backup storage." - }, "description" : "Create backup.", - "proxyto" : "node", - "returns" : { - "type" : "string" - }, + "method" : "POST", "name" : "vzdump", "parameters" : { + "additionalProperties" : 0, "properties" : { - "exclude" : { - "format" : "pve-vmid-list", - "description" : "Exclude specified guest systems (assumes --all)", - "type" : "string", - "optional" : 1 - }, - "node" : { - "format" : "pve-node", - "type" : "string", - "optional" : 1, - "description" : "Only run if executed on this node." - }, - "size" : { - "description" : "Unused, will be removed in a future release.", - "type" : "integer", + "all" : { + "default" : 0, + "description" : "Backup all known guest systems on this host.", "optional" : 1, - "default" : 1024, - "minimum" : 500 + "type" : "boolean" }, - "pigz" : { - "type" : "integer", - "optional" : 1, + "bwlimit" : { "default" : 0, - "description" : "Use pigz instead of gzip when N>0. N=1 uses half of cores, N>1 uses N as thread count." - }, - "storage" : { - "format" : "pve-storage-id", - "description" : "Store resulting file to this storage.", - "type" : "string", - "optional" : 1 - }, - "stdexcludes" : { - "default" : 1, - "type" : "boolean", + "description" : "Limit I/O bandwidth (KBytes per second).", + "minimum" : 0, "optional" : 1, - "description" : "Exclude temporary files and logs." + "type" : "integer" }, - "exclude-path" : { - "format" : "string-alist", - "type" : "string", + "compress" : { + "default" : "0", + "description" : "Compress dump file.", + "enum" : [ + "0", + "1", + "gzip", + "lzo" + ], "optional" : 1, - "description" : "Exclude certain files/directories (shell globs)." + "type" : "string" }, - "quiet" : { - "description" : "Be quiet.", + "dumpdir" : { + "description" : "Store resulting files to specified directory.", "optional" : 1, - "type" : "boolean", - "default" : 0 + "type" : "string" }, - "stopwait" : { + "exclude" : { + "description" : "Exclude specified guest systems (assumes --all)", + "format" : "pve-vmid-list", "optional" : 1, - "type" : "integer", - "default" : 10, - "description" : "Maximal time to wait until a guest system is stopped (minutes).", - "minimum" : 0 + "type" : "string" }, - "remove" : { - "description" : "Remove old backup files if there are more than 'maxfiles' backup files.", - "type" : "boolean", + "exclude-path" : { + "description" : "Exclude certain files/directories (shell globs).", + "format" : "string-alist", "optional" : 1, - "default" : 1 + "type" : "string" }, - "stdout" : { - "description" : "Write tar to stdout, not to a file.", - "type" : "boolean", - "optional" : 1 + "ionice" : { + "default" : 7, + "description" : "Set CFQ ionice priority.", + "maximum" : 8, + "minimum" : 0, + "optional" : 1, + "type" : "integer" }, - "all" : { - "default" : 0, - "type" : "boolean", + "lockwait" : { + "default" : 180, + "description" : "Maximal time to wait for the global lock (minutes).", + "minimum" : 0, "optional" : 1, - "description" : "Backup all known guest systems on this host." + "type" : "integer" }, "mailnotification" : { + "default" : "always", "description" : "Specify when to send an email", "enum" : [ "always", "failure" ], - "default" : "always", - "type" : "string", - "optional" : 1 - }, - "lockwait" : { - "minimum" : 0, - "type" : "integer", - "optional" : 1, - "default" : 180, - "description" : "Maximal time to wait for the global lock (minutes)." - }, - "script" : { - "type" : "string", - "optional" : 1, - "description" : "Use specified hook script." - }, - "dumpdir" : { - "type" : "string", "optional" : 1, - "description" : "Store resulting files to specified directory." + "type" : "string" }, "mailto" : { - "optional" : 1, - "type" : "string", "description" : "Comma-separated list of email addresses that should receive email notifications.", - "format" : "string-list" - }, - "compress" : { - "default" : "0", - "type" : "string", + "format" : "string-list", "optional" : 1, - "description" : "Compress dump file.", - "enum" : [ - "0", - "1", - "gzip", - "lzo" - ] + "type" : "string" }, - "tmpdir" : { + "maxfiles" : { + "default" : 1, + "description" : "Maximal number of backup files per guest system.", + "minimum" : 1, "optional" : 1, - "type" : "string", - "description" : "Store temporary files to specified directory." + "type" : "integer" }, "mode" : { + "default" : "snapshot", "description" : "Backup mode.", "enum" : [ "snapshot", "suspend", "stop" ], - "default" : "snapshot", - "type" : "string", - "optional" : 1 + "optional" : 1, + "type" : "string" }, - "maxfiles" : { + "node" : { + "description" : "Only run if executed on this node.", + "format" : "pve-node", + "optional" : 1, + "type" : "string" + }, + "pigz" : { + "default" : 0, + "description" : "Use pigz instead of gzip when N>0. N=1 uses half of cores, N>1 uses N as thread count.", + "optional" : 1, + "type" : "integer" + }, + "quiet" : { + "default" : 0, + "description" : "Be quiet.", + "optional" : 1, + "type" : "boolean" + }, + "remove" : { "default" : 1, + "description" : "Remove old backup files if there are more than 'maxfiles' backup files.", "optional" : 1, - "type" : "integer", - "description" : "Maximal number of backup files per guest system.", - "minimum" : 1 + "type" : "boolean" }, - "stop" : { - "type" : "boolean", + "script" : { + "description" : "Use specified hook script.", + "optional" : 1, + "type" : "string" + }, + "size" : { + "default" : 1024, + "description" : "Unused, will be removed in a future release.", + "minimum" : 500, + "optional" : 1, + "type" : "integer" + }, + "stdexcludes" : { + "default" : 1, + "description" : "Exclude temporary files and logs.", + "optional" : 1, + "type" : "boolean" + }, + "stdout" : { + "description" : "Write tar to stdout, not to a file.", "optional" : 1, + "type" : "boolean" + }, + "stop" : { "default" : 0, - "description" : "Stop runnig backup jobs on this host." + "description" : "Stop runnig backup jobs on this host.", + "optional" : 1, + "type" : "boolean" }, - "ionice" : { + "stopwait" : { + "default" : 10, + "description" : "Maximal time to wait until a guest system is stopped (minutes).", "minimum" : 0, "optional" : 1, - "type" : "integer", - "default" : 7, - "maximum" : 8, - "description" : "Set CFQ ionice priority." + "type" : "integer" }, - "bwlimit" : { + "storage" : { + "description" : "Store resulting file to this storage.", + "format" : "pve-storage-id", "optional" : 1, - "type" : "integer", - "default" : 0, - "description" : "Limit I/O bandwidth (KBytes per second).", - "minimum" : 0 + "type" : "string" + }, + "tmpdir" : { + "description" : "Store temporary files to specified directory.", + "optional" : 1, + "type" : "string" }, "vmid" : { - "format" : "pve-vmid-list", "description" : "The ID of the guest system you want to backup.", + "format" : "pve-vmid-list", "optional" : 1, "type" : "string" } - }, - "additionalProperties" : 0 - }, - "protected" : 1, - "method" : "POST" - } - }, - "path" : "/nodes/{node}/vzdump", - "leaf" : 1 - }, - { - "info" : { - "GET" : { - "parameters" : { - "additionalProperties" : 0, - "properties" : { - "node" : { - "type" : "string", - "description" : "The cluster node name.", - "format" : "pve-node" - } } }, - "name" : "index", - "protected" : 1, - "method" : "GET", "permissions" : { - "check" : [ - "perm", - "/nodes/{node}", - [ - "Sys.Audit" - ] - ] + "description" : "The user needs 'VM.Backup' permissions on any VM, and 'Datastore.AllocateSpace' on the backup storage.", + "user" : "all" }, + "protected" : 1, "proxyto" : "node", - "description" : "Service list.", "returns" : { - "links" : [ - { - "rel" : "child", - "href" : "{service}" - } - ], - "items" : { - "type" : "object", - "properties" : {} - }, - "type" : "array" + "type" : "string" } } }, - "text" : "services", + "leaf" : 1, + "path" : "/nodes/{node}/vzdump", + "text" : "vzdump" + }, + { "children" : [ { - "leaf" : 0, - "path" : "/nodes/{node}/services/{service}", - "info" : { - "GET" : { - "method" : "GET", - "returns" : { - "links" : [ - { - "rel" : "child", - "href" : "{subdir}" - } - ], - "items" : { - "properties" : { - "subdir" : { - "type" : "string" - } - }, - "type" : "object" - }, - "type" : "array" - }, - "description" : "Directory index", - "name" : "srvcmdidx", - "parameters" : { - "properties" : { - "service" : { - "enum" : [ - "pveproxy", - "pvedaemon", - "spiceproxy", - "pvestatd", - "pve-cluster", - "corosync", - "pve-firewall", - "pvefw-logger", - "pve-ha-crm", - "pve-ha-lrm", - "sshd", - "syslog", - "cron", - "postfix", - "ksmtuned", - "systemd-timesyncd" - ], - "description" : "Service ID", - "type" : "string" - }, - "node" : { - "description" : "The cluster node name.", - "type" : "string", - "format" : "pve-node" - } - }, - "additionalProperties" : 0 - }, - "permissions" : { - "check" : [ - "perm", - "/nodes/{node}", - [ - "Sys.Audit" - ] - ] - } - } - }, "children" : [ { - "leaf" : 1, - "path" : "/nodes/{node}/services/{service}/state", "info" : { "GET" : { - "returns" : { - "properties" : {}, - "type" : "object" - }, - "permissions" : { - "check" : [ - "perm", - "/nodes/{node}", - [ - "Sys.Audit" - ] - ] - }, - "proxyto" : "node", "description" : "Read service properties", "method" : "GET", "name" : "service_state", "parameters" : { + "additionalProperties" : 0, "properties" : { "node" : { - "type" : "string", "description" : "The cluster node name.", - "format" : "pve-node" + "format" : "pve-node", + "type" : "string" }, "service" : { + "description" : "Service ID", "enum" : [ "pveproxy", "pvedaemon", @@ -16851,41 +16692,47 @@ var pveapi = [ "ksmtuned", "systemd-timesyncd" ], - "description" : "Service ID", "type" : "string" } - }, - "additionalProperties" : 0 - }, - "protected" : 1 - } - }, - "text" : "state" - }, - { - "text" : "start", - "info" : { - "POST" : { - "returns" : { - "type" : "string" + } }, "permissions" : { "check" : [ "perm", "/nodes/{node}", [ - "Sys.Modify" + "Sys.Audit" ] ] }, - "description" : "Start service.", + "protected" : 1, "proxyto" : "node", + "returns" : { + "properties" : {}, + "type" : "object" + } + } + }, + "leaf" : 1, + "path" : "/nodes/{node}/services/{service}/state", + "text" : "state" + }, + { + "info" : { + "POST" : { + "description" : "Start service.", "method" : "POST", "name" : "service_start", "parameters" : { + "additionalProperties" : 0, "properties" : { + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, "service" : { - "type" : "string", + "description" : "Service ID", "enum" : [ "pveproxy", "pvedaemon", @@ -16904,31 +16751,10 @@ var pveapi = [ "ksmtuned", "systemd-timesyncd" ], - "description" : "Service ID" - }, - "node" : { - "format" : "pve-node", - "description" : "The cluster node name.", "type" : "string" } - }, - "additionalProperties" : 0 - }, - "protected" : 1 - } - }, - "path" : "/nodes/{node}/services/{service}/start", - "leaf" : 1 - }, - { - "text" : "stop", - "info" : { - "POST" : { - "returns" : { - "type" : "string" + } }, - "description" : "Stop service.", - "proxyto" : "node", "permissions" : { "check" : [ "perm", @@ -16938,18 +16764,33 @@ var pveapi = [ ] ] }, - "method" : "POST", "protected" : 1, + "proxyto" : "node", + "returns" : { + "type" : "string" + } + } + }, + "leaf" : 1, + "path" : "/nodes/{node}/services/{service}/start", + "text" : "start" + }, + { + "info" : { + "POST" : { + "description" : "Stop service.", + "method" : "POST", "name" : "service_stop", "parameters" : { "additionalProperties" : 0, "properties" : { "node" : { + "description" : "The cluster node name.", "format" : "pve-node", - "type" : "string", - "description" : "The cluster node name." + "type" : "string" }, "service" : { + "description" : "Service ID", "enum" : [ "pveproxy", "pvedaemon", @@ -16968,24 +16809,10 @@ var pveapi = [ "ksmtuned", "systemd-timesyncd" ], - "description" : "Service ID", "type" : "string" } } - } - } - }, - "path" : "/nodes/{node}/services/{service}/stop", - "leaf" : 1 - }, - { - "path" : "/nodes/{node}/services/{service}/restart", - "leaf" : 1, - "text" : "restart", - "info" : { - "POST" : { - "proxyto" : "node", - "description" : "Restart service.", + }, "permissions" : { "check" : [ "perm", @@ -16995,19 +16822,33 @@ var pveapi = [ ] ] }, + "protected" : 1, + "proxyto" : "node", "returns" : { "type" : "string" - }, - "protected" : 1, + } + } + }, + "leaf" : 1, + "path" : "/nodes/{node}/services/{service}/stop", + "text" : "stop" + }, + { + "info" : { + "POST" : { + "description" : "Restart service.", + "method" : "POST", + "name" : "service_restart", "parameters" : { "additionalProperties" : 0, "properties" : { "node" : { "description" : "The cluster node name.", - "type" : "string", - "format" : "pve-node" + "format" : "pve-node", + "type" : "string" }, "service" : { + "description" : "Service ID", "enum" : [ "pveproxy", "pvedaemon", @@ -17026,28 +16867,45 @@ var pveapi = [ "ksmtuned", "systemd-timesyncd" ], - "description" : "Service ID", "type" : "string" } } }, - "name" : "service_restart", - "method" : "POST" + "permissions" : { + "check" : [ + "perm", + "/nodes/{node}", + [ + "Sys.Modify" + ] + ] + }, + "protected" : 1, + "proxyto" : "node", + "returns" : { + "type" : "string" + } } - } + }, + "leaf" : 1, + "path" : "/nodes/{node}/services/{service}/restart", + "text" : "restart" }, { - "path" : "/nodes/{node}/services/{service}/reload", - "leaf" : 1, - "text" : "reload", "info" : { "POST" : { + "description" : "Reload service.", + "method" : "POST", "name" : "service_reload", "parameters" : { "additionalProperties" : 0, "properties" : { + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, "service" : { - "type" : "string", "description" : "Service ID", "enum" : [ "pveproxy", @@ -17066,17 +16924,11 @@ var pveapi = [ "postfix", "ksmtuned", "systemd-timesyncd" - ] - }, - "node" : { - "type" : "string", - "description" : "The cluster node name.", - "format" : "pve-node" + ], + "type" : "string" } } }, - "protected" : 1, - "method" : "POST", "permissions" : { "check" : [ "perm", @@ -17086,109 +16938,236 @@ var pveapi = [ ] ] }, - "description" : "Reload service.", + "protected" : 1, "proxyto" : "node", "returns" : { "type" : "string" } } + }, + "leaf" : 1, + "path" : "/nodes/{node}/services/{service}/reload", + "text" : "reload" + } + ], + "info" : { + "GET" : { + "description" : "Directory index", + "method" : "GET", + "name" : "srvcmdidx", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, + "service" : { + "description" : "Service ID", + "enum" : [ + "pveproxy", + "pvedaemon", + "spiceproxy", + "pvestatd", + "pve-cluster", + "corosync", + "pve-firewall", + "pvefw-logger", + "pve-ha-crm", + "pve-ha-lrm", + "sshd", + "syslog", + "cron", + "postfix", + "ksmtuned", + "systemd-timesyncd" + ], + "type" : "string" + } + } + }, + "permissions" : { + "check" : [ + "perm", + "/nodes/{node}", + [ + "Sys.Audit" + ] + ] + }, + "returns" : { + "items" : { + "properties" : { + "subdir" : { + "type" : "string" + } + }, + "type" : "object" + }, + "links" : [ + { + "href" : "{subdir}", + "rel" : "child" + } + ], + "type" : "array" + } + } + }, + "leaf" : 0, + "path" : "/nodes/{node}/services/{service}", + "text" : "{service}" + } + ], + "info" : { + "GET" : { + "description" : "Service list.", + "method" : "GET", + "name" : "index", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + } + } + }, + "permissions" : { + "check" : [ + "perm", + "/nodes/{node}", + [ + "Sys.Audit" + ] + ] + }, + "protected" : 1, + "proxyto" : "node", + "returns" : { + "items" : { + "properties" : {}, + "type" : "object" + }, + "links" : [ + { + "href" : "{service}", + "rel" : "child" } - } - ], - "text" : "{service}" + ], + "type" : "array" + } } - ], + }, "leaf" : 0, - "path" : "/nodes/{node}/services" + "path" : "/nodes/{node}/services", + "text" : "services" }, { - "text" : "subscription", "info" : { "GET" : { - "permissions" : { - "user" : "all" - }, + "description" : "Read subscription info.", + "method" : "GET", + "name" : "get", "parameters" : { + "additionalProperties" : 0, "properties" : { "node" : { "description" : "The cluster node name.", - "type" : "string", - "format" : "pve-node" + "format" : "pve-node", + "type" : "string" } - }, - "additionalProperties" : 0 + } + }, + "permissions" : { + "user" : "all" }, - "name" : "get", - "description" : "Read subscription info.", "proxyto" : "node", "returns" : { "type" : "object" - }, - "method" : "GET" + } }, - "PUT" : { - "returns" : { - "type" : "null" - }, - "method" : "PUT", + "POST" : { + "description" : "Update subscription info.", + "method" : "POST", + "name" : "update", "parameters" : { "additionalProperties" : 0, "properties" : { + "force" : { + "default" : 0, + "description" : "Always connect to server, even if we have up to date info inside local cache.", + "optional" : 1, + "type" : "boolean" + }, "node" : { - "format" : "pve-node", "description" : "The cluster node name.", - "type" : "string" - }, - "key" : { - "description" : "Proxmox VE subscription key", + "format" : "pve-node", "type" : "string" } } }, - "name" : "set", "protected" : 1, - "description" : "Set subscription key.", - "proxyto" : "node" - }, - "POST" : { "proxyto" : "node", - "protected" : 1, - "description" : "Update subscription info.", + "returns" : { + "type" : "null" + } + }, + "PUT" : { + "description" : "Set subscription key.", + "method" : "PUT", + "name" : "set", "parameters" : { "additionalProperties" : 0, "properties" : { - "force" : { - "description" : "Always connect to server, even if we have up to date info inside local cache.", - "default" : 0, - "type" : "boolean", - "optional" : 1 + "key" : { + "description" : "Proxmox VE subscription key", + "type" : "string" }, "node" : { - "type" : "string", "description" : "The cluster node name.", - "format" : "pve-node" + "format" : "pve-node", + "type" : "string" } } }, - "name" : "update", + "protected" : 1, + "proxyto" : "node", "returns" : { "type" : "null" - }, - "method" : "POST" + } } }, + "leaf" : 1, "path" : "/nodes/{node}/subscription", - "leaf" : 1 + "text" : "subscription" }, { - "path" : "/nodes/{node}/network", - "leaf" : 0, "children" : [ { "info" : { "DELETE" : { - "returns" : { - "type" : "null" + "description" : "Delete network device configuration", + "method" : "DELETE", + "name" : "delete_network", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "iface" : { + "description" : "Network interface name.", + "format" : "pve-iface", + "maxLength" : 20, + "minLength" : 2, + "type" : "string" + }, + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + } + } }, "permissions" : { "check" : [ @@ -17199,321 +17178,265 @@ var pveapi = [ ] ] }, + "protected" : 1, "proxyto" : "node", - "description" : "Delete network device configuration", - "method" : "DELETE", + "returns" : { + "type" : "null" + } + }, + "GET" : { + "description" : "Read network device configuration", + "method" : "GET", + "name" : "network_config", "parameters" : { + "additionalProperties" : 0, "properties" : { - "node" : { - "format" : "pve-node", - "type" : "string", - "description" : "The cluster node name." - }, "iface" : { - "maxLength" : 20, - "format" : "pve-iface", "description" : "Network interface name.", + "format" : "pve-iface", + "maxLength" : 20, "minLength" : 2, "type" : "string" + }, + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" } - }, - "additionalProperties" : 0 - }, - "name" : "delete_network", - "protected" : 1 - }, - "PUT" : { - "returns" : { - "type" : "null" + } }, "permissions" : { "check" : [ "perm", "/nodes/{node}", [ - "Sys.Modify" + "Sys.Audit" ] ] }, "proxyto" : "node", + "returns" : { + "properties" : { + "method" : { + "type" : "string" + }, + "type" : { + "type" : "string" + } + }, + "type" : "object" + } + }, + "PUT" : { "description" : "Update network device configuration", "method" : "PUT", "name" : "update_network", "parameters" : { "additionalProperties" : 0, "properties" : { - "slaves" : { - "optional" : 1, - "type" : "string", - "description" : "Specify the interfaces used by the bonding device.", - "format" : "pve-iface-list" - }, - "netmask" : { - "format" : "ipv4mask", - "optional" : 1, - "type" : "string", - "description" : "Network mask.", - "requires" : "address" - }, "address" : { + "description" : "IP address.", "format" : "ipv4", + "optional" : 1, "requires" : "netmask", - "description" : "IP address.", - "type" : "string", - "optional" : 1 + "type" : "string" }, - "bridge_ports" : { - "format" : "pve-iface-list", - "description" : "Specify the iterfaces you want to add to your bridge.", - "type" : "string", - "optional" : 1 + "address6" : { + "description" : "IP address.", + "format" : "ipv6", + "optional" : 1, + "requires" : "netmask6", + "type" : "string" }, "autostart" : { + "description" : "Automatically start interface on boot.", "optional" : 1, - "type" : "boolean", - "description" : "Automatically start interface on boot." + "type" : "boolean" }, - "type" : { - "type" : "string", - "description" : "Network interface type", + "bond_mode" : { + "description" : "Bonding mode.", "enum" : [ - "bridge", - "bond", - "eth", - "alias", - "vlan", - "OVSBridge", - "OVSBond", - "OVSPort", - "OVSIntPort", - "unknown" - ] - }, - "gateway6" : { - "type" : "string", + "balance-rr", + "active-backup", + "balance-xor", + "broadcast", + "802.3ad", + "balance-tlb", + "balance-alb", + "balance-slb", + "lacp-balance-slb", + "lacp-balance-tcp" + ], "optional" : 1, - "description" : "Default ipv6 gateway address.", - "format" : "ipv6" + "type" : "string" }, - "gateway" : { - "format" : "ipv4", + "bond_xmit_hash_policy" : { + "description" : "Selects the transmit hash policy to use for slave selection in balance-xor and 802.3ad modes.", + "enum" : [ + "layer2", + "layer2+3", + "layer3+4" + ], "optional" : 1, - "type" : "string", - "description" : "Default gateway address." + "type" : "string" }, - "ovs_bridge" : { - "type" : "string", + "bridge_ports" : { + "description" : "Specify the iterfaces you want to add to your bridge.", + "format" : "pve-iface-list", "optional" : 1, - "description" : "The OVS bridge associated with a OVS port. This is required when you create an OVS port.", - "format" : "pve-iface" + "type" : "string" }, - "delete" : { - "type" : "string", + "bridge_vlan_aware" : { + "description" : "Enable bridge vlan support.", "optional" : 1, - "description" : "A list of settings you want to delete.", - "format" : "pve-configid-list" + "type" : "boolean" }, "comments" : { - "description" : "Comments", - "type" : "string", - "optional" : 1 - }, - "ovs_tag" : { - "optional" : 1, - "type" : "integer", - "maximum" : 4094, - "description" : "Specify a VLan tag (used by OVSPort, OVSIntPort, OVSBond)", - "minimum" : 1 - }, - "ovs_options" : { - "description" : "OVS interface options.", - "optional" : 1, - "type" : "string", - "maxLength" : 1024 - }, - "node" : { - "type" : "string", - "description" : "The cluster node name.", - "format" : "pve-node" - }, - "comments6" : { - "type" : "string", - "optional" : 1, - "description" : "Comments" - }, - "bridge_vlan_aware" : { + "description" : "Comments", "optional" : 1, - "type" : "boolean", - "description" : "Enable bridge vlan support." + "type" : "string" }, - "address6" : { - "format" : "ipv6", + "comments6" : { + "description" : "Comments", "optional" : 1, - "type" : "string", - "description" : "IP address.", - "requires" : "netmask6" + "type" : "string" }, - "bond_xmit_hash_policy" : { - "description" : "Selects the transmit hash policy to use for slave selection in balance-xor and 802.3ad modes.", - "enum" : [ - "layer2", - "layer2+3", - "layer3+4" - ], + "delete" : { + "description" : "A list of settings you want to delete.", + "format" : "pve-configid-list", "optional" : 1, "type" : "string" }, - "ovs_bonds" : { - "format" : "pve-iface-list", - "description" : "Specify the interfaces used by the bonding device.", + "gateway" : { + "description" : "Default gateway address.", + "format" : "ipv4", "optional" : 1, "type" : "string" }, - "bond_mode" : { + "gateway6" : { + "description" : "Default ipv6 gateway address.", + "format" : "ipv6", "optional" : 1, - "type" : "string", - "description" : "Bonding mode.", - "enum" : [ - "balance-rr", - "active-backup", - "balance-xor", - "broadcast", - "802.3ad", - "balance-tlb", - "balance-alb", - "balance-slb", - "lacp-balance-slb", - "lacp-balance-tcp" - ] + "type" : "string" }, "iface" : { + "description" : "Network interface name.", "format" : "pve-iface", "maxLength" : 20, "minLength" : 2, - "description" : "Network interface name.", "type" : "string" }, - "ovs_ports" : { - "format" : "pve-iface-list", + "netmask" : { + "description" : "Network mask.", + "format" : "ipv4mask", "optional" : 1, - "type" : "string", - "description" : "Specify the iterfaces you want to add to your bridge." + "requires" : "address", + "type" : "string" }, "netmask6" : { + "description" : "Network mask.", "maximum" : 128, - "type" : "integer", + "minimum" : 0, "optional" : 1, "requires" : "address6", - "description" : "Network mask.", - "minimum" : 0 - } - } - }, - "protected" : 1 - }, - "GET" : { - "description" : "Read network device configuration", - "proxyto" : "node", - "parameters" : { - "additionalProperties" : 0, - "properties" : { + "type" : "integer" + }, "node" : { + "description" : "The cluster node name.", "format" : "pve-node", - "type" : "string", - "description" : "The cluster node name." + "type" : "string" }, - "iface" : { - "type" : "string", - "description" : "Network interface name.", - "minLength" : 2, - "maxLength" : 20, - "format" : "pve-iface" + "ovs_bonds" : { + "description" : "Specify the interfaces used by the bonding device.", + "format" : "pve-iface-list", + "optional" : 1, + "type" : "string" + }, + "ovs_bridge" : { + "description" : "The OVS bridge associated with a OVS port. This is required when you create an OVS port.", + "format" : "pve-iface", + "optional" : 1, + "type" : "string" + }, + "ovs_options" : { + "description" : "OVS interface options.", + "maxLength" : 1024, + "optional" : 1, + "type" : "string" + }, + "ovs_ports" : { + "description" : "Specify the iterfaces you want to add to your bridge.", + "format" : "pve-iface-list", + "optional" : 1, + "type" : "string" + }, + "ovs_tag" : { + "description" : "Specify a VLan tag (used by OVSPort, OVSIntPort, OVSBond)", + "maximum" : 4094, + "minimum" : 1, + "optional" : 1, + "type" : "integer" + }, + "slaves" : { + "description" : "Specify the interfaces used by the bonding device.", + "format" : "pve-iface-list", + "optional" : 1, + "type" : "string" + }, + "type" : { + "description" : "Network interface type", + "enum" : [ + "bridge", + "bond", + "eth", + "alias", + "vlan", + "OVSBridge", + "OVSBond", + "OVSPort", + "OVSIntPort", + "unknown" + ], + "type" : "string" } } }, - "name" : "network_config", "permissions" : { "check" : [ "perm", "/nodes/{node}", [ - "Sys.Audit" + "Sys.Modify" ] ] }, + "protected" : 1, + "proxyto" : "node", "returns" : { - "properties" : { - "method" : { - "type" : "string" - }, - "type" : { - "type" : "string" - } - }, - "type" : "object" - }, - "method" : "GET" + "type" : "null" + } } }, - "text" : "{iface}", "leaf" : 1, - "path" : "/nodes/{node}/network/{iface}" + "path" : "/nodes/{node}/network/{iface}", + "text" : "{iface}" } ], - "text" : "network", "info" : { - "GET" : { - "returns" : { - "items" : { - "properties" : {}, - "type" : "object" - }, - "links" : [ - { - "rel" : "child", - "href" : "{iface}" - } - ], - "type" : "array" - }, - "method" : "GET", - "proxyto" : "node", - "description" : "List available networks", - "permissions" : { - "user" : "all" - }, - "name" : "index", + "DELETE" : { + "description" : "Revert network configuration changes.", + "method" : "DELETE", + "name" : "revert_network_changes", "parameters" : { "additionalProperties" : 0, "properties" : { - "type" : { - "optional" : 1, - "type" : "string", - "description" : "Only list specific interface types.", - "enum" : [ - "bridge", - "bond", - "eth", - "alias", - "vlan", - "OVSBridge", - "OVSBond", - "OVSPort", - "OVSIntPort", - "any_bridge" - ] - }, "node" : { - "format" : "pve-node", "description" : "The cluster node name.", + "format" : "pve-node", "type" : "string" } } - } - }, - "DELETE" : { - "proxyto" : "node", - "description" : "Revert network configuration changes.", + }, "permissions" : { "check" : [ "perm", @@ -17523,83 +17446,26 @@ var pveapi = [ ] ] }, + "protected" : 1, + "proxyto" : "node", "returns" : { "type" : "null" - }, - "protected" : 1, - "parameters" : { - "additionalProperties" : 0, - "properties" : { - "node" : { - "description" : "The cluster node name.", - "type" : "string", - "format" : "pve-node" - } - } - }, - "name" : "revert_network_changes", - "method" : "DELETE" + } }, - "POST" : { - "protected" : 1, - "name" : "create_network", + "GET" : { + "description" : "List available networks", + "method" : "GET", + "name" : "index", "parameters" : { + "additionalProperties" : 0, "properties" : { - "ovs_bridge" : { - "description" : "The OVS bridge associated with a OVS port. This is required when you create an OVS port.", - "type" : "string", - "optional" : 1, - "format" : "pve-iface" - }, - "gateway" : { - "type" : "string", - "optional" : 1, - "description" : "Default gateway address.", - "format" : "ipv4" - }, - "gateway6" : { - "format" : "ipv6", - "description" : "Default ipv6 gateway address.", - "type" : "string", - "optional" : 1 - }, "node" : { - "format" : "pve-node", - "type" : "string", - "description" : "The cluster node name." - }, - "ovs_options" : { - "maxLength" : 1024, - "description" : "OVS interface options.", - "type" : "string", - "optional" : 1 - }, - "comments" : { - "optional" : 1, - "type" : "string", - "description" : "Comments" - }, - "ovs_tag" : { - "optional" : 1, - "type" : "integer", - "maximum" : 4094, - "description" : "Specify a VLan tag (used by OVSPort, OVSIntPort, OVSBond)", - "minimum" : 1 - }, - "netmask" : { - "optional" : 1, - "type" : "string", - "requires" : "address", - "description" : "Network mask.", - "format" : "ipv4mask" - }, - "slaves" : { - "type" : "string", - "optional" : 1, - "description" : "Specify the interfaces used by the bonding device.", - "format" : "pve-iface-list" + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" }, "type" : { + "description" : "Only list specific interface types.", "enum" : [ "bridge", "bond", @@ -17610,28 +17476,56 @@ var pveapi = [ "OVSBond", "OVSPort", "OVSIntPort", - "unknown" + "any_bridge" ], - "description" : "Network interface type", - "type" : "string" - }, - "autostart" : { - "description" : "Automatically start interface on boot.", - "type" : "boolean", - "optional" : 1 - }, - "bridge_ports" : { - "format" : "pve-iface-list", - "type" : "string", "optional" : 1, - "description" : "Specify the iterfaces you want to add to your bridge." - }, + "type" : "string" + } + } + }, + "permissions" : { + "user" : "all" + }, + "proxyto" : "node", + "returns" : { + "items" : { + "properties" : {}, + "type" : "object" + }, + "links" : [ + { + "href" : "{iface}", + "rel" : "child" + } + ], + "type" : "array" + } + }, + "POST" : { + "description" : "Create network device configuration", + "method" : "POST", + "name" : "create_network", + "parameters" : { + "additionalProperties" : 0, + "properties" : { "address" : { + "description" : "IP address.", + "format" : "ipv4", + "optional" : 1, "requires" : "netmask", + "type" : "string" + }, + "address6" : { "description" : "IP address.", - "type" : "string", + "format" : "ipv6", + "optional" : 1, + "requires" : "netmask6", + "type" : "string" + }, + "autostart" : { + "description" : "Automatically start interface on boot.", "optional" : 1, - "format" : "ipv4" + "type" : "boolean" }, "bond_mode" : { "description" : "Bonding mode.", @@ -17650,223 +17544,224 @@ var pveapi = [ "optional" : 1, "type" : "string" }, - "ovs_bonds" : { + "bond_xmit_hash_policy" : { + "description" : "Selects the transmit hash policy to use for slave selection in balance-xor and 802.3ad modes.", + "enum" : [ + "layer2", + "layer2+3", + "layer3+4" + ], + "optional" : 1, + "type" : "string" + }, + "bridge_ports" : { + "description" : "Specify the iterfaces you want to add to your bridge.", "format" : "pve-iface-list", - "type" : "string", "optional" : 1, - "description" : "Specify the interfaces used by the bonding device." + "type" : "string" }, - "netmask6" : { - "minimum" : 0, + "bridge_vlan_aware" : { + "description" : "Enable bridge vlan support.", "optional" : 1, - "type" : "integer", - "maximum" : 128, - "description" : "Network mask.", - "requires" : "address6" + "type" : "boolean" }, - "ovs_ports" : { + "comments" : { + "description" : "Comments", "optional" : 1, - "type" : "string", - "description" : "Specify the iterfaces you want to add to your bridge.", - "format" : "pve-iface-list" + "type" : "string" + }, + "comments6" : { + "description" : "Comments", + "optional" : 1, + "type" : "string" + }, + "gateway" : { + "description" : "Default gateway address.", + "format" : "ipv4", + "optional" : 1, + "type" : "string" + }, + "gateway6" : { + "description" : "Default ipv6 gateway address.", + "format" : "ipv6", + "optional" : 1, + "type" : "string" }, "iface" : { + "description" : "Network interface name.", "format" : "pve-iface", "maxLength" : 20, - "type" : "string", - "description" : "Network interface name.", - "minLength" : 2 + "minLength" : 2, + "type" : "string" }, - "comments6" : { + "netmask" : { + "description" : "Network mask.", + "format" : "ipv4mask", "optional" : 1, - "type" : "string", - "description" : "Comments" + "requires" : "address", + "type" : "string" }, - "bridge_vlan_aware" : { - "description" : "Enable bridge vlan support.", + "netmask6" : { + "description" : "Network mask.", + "maximum" : 128, + "minimum" : 0, "optional" : 1, - "type" : "boolean" + "requires" : "address6", + "type" : "integer" }, - "address6" : { - "format" : "ipv6", - "description" : "IP address.", - "requires" : "netmask6", + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, + "ovs_bonds" : { + "description" : "Specify the interfaces used by the bonding device.", + "format" : "pve-iface-list", "optional" : 1, "type" : "string" }, - "bond_xmit_hash_policy" : { - "type" : "string", + "ovs_bridge" : { + "description" : "The OVS bridge associated with a OVS port. This is required when you create an OVS port.", + "format" : "pve-iface", + "optional" : 1, + "type" : "string" + }, + "ovs_options" : { + "description" : "OVS interface options.", + "maxLength" : 1024, + "optional" : 1, + "type" : "string" + }, + "ovs_ports" : { + "description" : "Specify the iterfaces you want to add to your bridge.", + "format" : "pve-iface-list", + "optional" : 1, + "type" : "string" + }, + "ovs_tag" : { + "description" : "Specify a VLan tag (used by OVSPort, OVSIntPort, OVSBond)", + "maximum" : 4094, + "minimum" : 1, + "optional" : 1, + "type" : "integer" + }, + "slaves" : { + "description" : "Specify the interfaces used by the bonding device.", + "format" : "pve-iface-list", "optional" : 1, + "type" : "string" + }, + "type" : { + "description" : "Network interface type", "enum" : [ - "layer2", - "layer2+3", - "layer3+4" + "bridge", + "bond", + "eth", + "alias", + "vlan", + "OVSBridge", + "OVSBond", + "OVSPort", + "OVSIntPort", + "unknown" ], - "description" : "Selects the transmit hash policy to use for slave selection in balance-xor and 802.3ad modes." + "type" : "string" } - }, - "additionalProperties" : 0 + } }, - "method" : "POST", - "proxyto" : "node", - "description" : "Create network device configuration", "permissions" : { "check" : [ "perm", "/nodes/{node}", [ "Sys.Modify" - ] - ] - }, - "returns" : { - "type" : "null" - } - } - } - }, - { - "path" : "/nodes/{node}/tasks", - "leaf" : 0, - "text" : "tasks", - "children" : [ - { - "leaf" : 0, - "path" : "/nodes/{node}/tasks/{upid}", - "info" : { - "DELETE" : { - "returns" : { - "type" : "null" - }, - "permissions" : { - "user" : "all", - "description" : "The user needs 'Sys.Modify' permissions on '/nodes/' if the task does not belong to him." - }, - "description" : "Stop a task.", - "proxyto" : "node", - "method" : "DELETE", - "name" : "stop_task", - "parameters" : { - "additionalProperties" : 0, - "properties" : { - "node" : { - "type" : "string", - "description" : "The cluster node name.", - "format" : "pve-node" - }, - "upid" : { - "type" : "string" - } - } - }, - "protected" : 1 - }, - "GET" : { - "method" : "GET", - "returns" : { - "links" : [ - { - "href" : "{name}", - "rel" : "child" - } - ], - "items" : { - "type" : "object", - "properties" : {} - }, - "type" : "array" - }, - "description" : "", - "parameters" : { - "additionalProperties" : 0, - "properties" : { - "node" : { - "format" : "pve-node", - "description" : "The cluster node name.", - "type" : "string" - }, - "upid" : { - "type" : "string" - } - } - }, - "name" : "upid_index", - "permissions" : { - "user" : "all" - } - } + ] + ] }, + "protected" : 1, + "proxyto" : "node", + "returns" : { + "type" : "null" + } + } + }, + "leaf" : 0, + "path" : "/nodes/{node}/network", + "text" : "network" + }, + { + "children" : [ + { "children" : [ { "info" : { "GET" : { + "description" : "Read task log.", "method" : "GET", "name" : "read_task_log", "parameters" : { + "additionalProperties" : 0, "properties" : { - "start" : { + "limit" : { + "minimum" : 0, "optional" : 1, - "type" : "integer", - "minimum" : 0 - }, - "upid" : { - "type" : "string" + "type" : "integer" }, "node" : { "description" : "The cluster node name.", - "type" : "string", - "format" : "pve-node" + "format" : "pve-node", + "type" : "string" }, - "limit" : { - "type" : "integer", + "start" : { + "minimum" : 0, "optional" : 1, - "minimum" : 0 + "type" : "integer" + }, + "upid" : { + "type" : "string" } - }, - "additionalProperties" : 0 + } + }, + "permissions" : { + "description" : "The user needs 'Sys.Audit' permissions on '/nodes/' if the task does not belong to him.", + "user" : "all" }, "protected" : 1, + "proxyto" : "node", "returns" : { - "type" : "array", "items" : { - "type" : "object", "properties" : { "n" : { - "type" : "integer", - "description" : "Line number" + "description" : "Line number", + "type" : "integer" }, "t" : { - "type" : "string", - "description" : "Line text" + "description" : "Line text", + "type" : "string" } - } - } - }, - "permissions" : { - "description" : "The user needs 'Sys.Audit' permissions on '/nodes/' if the task does not belong to him.", - "user" : "all" - }, - "proxyto" : "node", - "description" : "Read task log." + }, + "type" : "object" + }, + "type" : "array" + } } }, - "text" : "log", "leaf" : 1, - "path" : "/nodes/{node}/tasks/{upid}/log" + "path" : "/nodes/{node}/tasks/{upid}/log", + "text" : "log" }, { - "path" : "/nodes/{node}/tasks/{upid}/status", - "leaf" : 1, - "text" : "status", "info" : { "GET" : { + "description" : "Read task status.", + "method" : "GET", "name" : "read_task_status", "parameters" : { "additionalProperties" : 0, "properties" : { "node" : { - "format" : "pve-node", "description" : "The cluster node name.", + "format" : "pve-node", "type" : "string" }, "upid" : { @@ -17874,127 +17769,151 @@ var pveapi = [ } } }, - "protected" : 1, - "method" : "GET", "permissions" : { "description" : "The user needs 'Sys.Audit' permissions on '/nodes/' if the task does not belong to him.", "user" : "all" }, + "protected" : 1, "proxyto" : "node", - "description" : "Read task status.", "returns" : { "properties" : { "pid" : { "type" : "integer" }, "status" : { - "type" : "string", "enum" : [ "running", "stopped" - ] + ], + "type" : "string" } }, "type" : "object" } } - } + }, + "leaf" : 1, + "path" : "/nodes/{node}/tasks/{upid}/status", + "text" : "status" } ], - "text" : "{upid}" - } - ], - "info" : { - "GET" : { - "returns" : { - "type" : "array", - "items" : { - "type" : "object", - "properties" : { - "upid" : { - "type" : "string" + "info" : { + "DELETE" : { + "description" : "Stop a task.", + "method" : "DELETE", + "name" : "stop_task", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, + "upid" : { + "type" : "string" + } } + }, + "permissions" : { + "description" : "The user needs 'Sys.Modify' permissions on '/nodes/' if the task does not belong to him.", + "user" : "all" + }, + "protected" : 1, + "proxyto" : "node", + "returns" : { + "type" : "null" } }, - "links" : [ - { - "rel" : "child", - "href" : "{upid}" + "GET" : { + "description" : "", + "method" : "GET", + "name" : "upid_index", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, + "upid" : { + "type" : "string" + } + } + }, + "permissions" : { + "user" : "all" + }, + "returns" : { + "items" : { + "properties" : {}, + "type" : "object" + }, + "links" : [ + { + "href" : "{name}", + "rel" : "child" + } + ], + "type" : "array" } - ] + } }, - "method" : "GET", - "proxyto" : "node", + "leaf" : 0, + "path" : "/nodes/{node}/tasks/{upid}", + "text" : "{upid}" + } + ], + "info" : { + "GET" : { "description" : "Read task list for one node (finished tasks).", - "permissions" : { - "user" : "all", - "description" : "List task associated with the current user, or all task the user has 'Sys.Audit' permissions on /nodes/ (the the task runs on)." - }, + "method" : "GET", + "name" : "node_tasks", "parameters" : { "additionalProperties" : 0, "properties" : { - "vmid" : { - "description" : "Only list tasks for this VM.", - "type" : "integer", + "errors" : { "optional" : 1, - "format" : "pve-vmid", - "minimum" : 1 + "type" : "boolean" }, - "start" : { + "limit" : { "minimum" : 0, "optional" : 1, "type" : "integer" }, - "errors" : { - "optional" : 1, - "type" : "boolean" - }, "node" : { "description" : "The cluster node name.", - "type" : "string", - "format" : "pve-node" + "format" : "pve-node", + "type" : "string" }, - "limit" : { + "start" : { "minimum" : 0, - "type" : "integer", - "optional" : 1 + "optional" : 1, + "type" : "integer" }, "userfilter" : { - "type" : "string", - "optional" : 1 - } - } - }, - "name" : "node_tasks" - } - } - }, - { - "leaf" : 0, - "path" : "/nodes/{node}/scan", - "info" : { - "GET" : { - "parameters" : { - "additionalProperties" : 0, - "properties" : { - "node" : { - "description" : "The cluster node name.", - "type" : "string", - "format" : "pve-node" + "optional" : 1, + "type" : "string" + }, + "vmid" : { + "description" : "Only list tasks for this VM.", + "format" : "pve-vmid", + "minimum" : 1, + "optional" : 1, + "type" : "integer" } } }, "permissions" : { + "description" : "List task associated with the current user, or all task the user has 'Sys.Audit' permissions on /nodes/ (the the task runs on).", "user" : "all" }, - "name" : "index", - "description" : "Index of available scan methods", - "method" : "GET", + "proxyto" : "node", "returns" : { - "type" : "array", "items" : { "properties" : { - "method" : { + "upid" : { "type" : "string" } }, @@ -18002,65 +17921,36 @@ var pveapi = [ }, "links" : [ { - "rel" : "child", - "href" : "{method}" + "href" : "{upid}", + "rel" : "child" } - ] + ], + "type" : "array" } } }, + "leaf" : 0, + "path" : "/nodes/{node}/tasks", + "text" : "tasks" + }, + { "children" : [ { "info" : { "GET" : { - "proxyto" : "node", "description" : "Scan zfs pool list on local node.", - "permissions" : { - "check" : [ - "perm", - "/storage", - [ - "Datastore.Allocate" - ] - ] - }, - "returns" : { - "type" : "array", - "items" : { - "properties" : { - "pool" : { - "type" : "string" - } - }, - "type" : "object" - } - }, - "protected" : 1, + "method" : "GET", + "name" : "zfsscan", "parameters" : { + "additionalProperties" : 0, "properties" : { "node" : { "description" : "The cluster node name.", - "type" : "string", - "format" : "pve-node" + "format" : "pve-node", + "type" : "string" } - }, - "additionalProperties" : 0 - }, - "name" : "zfsscan", - "method" : "GET" - } - }, - "text" : "zfs", - "leaf" : 1, - "path" : "/nodes/{node}/scan/zfs" - }, - { - "leaf" : 1, - "path" : "/nodes/{node}/scan/nfs", - "info" : { - "GET" : { - "description" : "Scan remote NFS server.", - "proxyto" : "node", + } + }, "permissions" : { "check" : [ "perm", @@ -18070,56 +17960,44 @@ var pveapi = [ ] ] }, + "protected" : 1, + "proxyto" : "node", "returns" : { - "type" : "array", "items" : { - "type" : "object", "properties" : { - "path" : { - "type" : "string" - }, - "options" : { + "pool" : { "type" : "string" } - } - } - }, - "protected" : 1, + }, + "type" : "object" + }, + "type" : "array" + } + } + }, + "leaf" : 1, + "path" : "/nodes/{node}/scan/zfs", + "text" : "zfs" + }, + { + "info" : { + "GET" : { + "description" : "Scan remote NFS server.", + "method" : "GET", "name" : "nfsscan", "parameters" : { + "additionalProperties" : 0, "properties" : { "node" : { - "format" : "pve-node", "description" : "The cluster node name.", + "format" : "pve-node", "type" : "string" }, "server" : { "format" : "pve-storage-server", "type" : "string" } - }, - "additionalProperties" : 0 - }, - "method" : "GET" - } - }, - "text" : "nfs" - }, - { - "leaf" : 1, - "path" : "/nodes/{node}/scan/glusterfs", - "info" : { - "GET" : { - "returns" : { - "items" : { - "properties" : { - "volname" : { - "type" : "string" - } - }, - "type" : "object" - }, - "type" : "array" + } }, "permissions" : { "check" : [ @@ -18130,35 +18008,96 @@ var pveapi = [ ] ] }, - "description" : "Scan remote GlusterFS server.", + "protected" : 1, "proxyto" : "node", + "returns" : { + "items" : { + "properties" : { + "options" : { + "type" : "string" + }, + "path" : { + "type" : "string" + } + }, + "type" : "object" + }, + "type" : "array" + } + } + }, + "leaf" : 1, + "path" : "/nodes/{node}/scan/nfs", + "text" : "nfs" + }, + { + "info" : { + "GET" : { + "description" : "Scan remote GlusterFS server.", "method" : "GET", "name" : "glusterfsscan", "parameters" : { + "additionalProperties" : 0, "properties" : { "node" : { + "description" : "The cluster node name.", "format" : "pve-node", - "type" : "string", - "description" : "The cluster node name." + "type" : "string" }, "server" : { "format" : "pve-storage-server", "type" : "string" } - }, - "additionalProperties" : 0 + } + }, + "permissions" : { + "check" : [ + "perm", + "/storage", + [ + "Datastore.Allocate" + ] + ] }, - "protected" : 1 + "protected" : 1, + "proxyto" : "node", + "returns" : { + "items" : { + "properties" : { + "volname" : { + "type" : "string" + } + }, + "type" : "object" + }, + "type" : "array" + } } }, + "leaf" : 1, + "path" : "/nodes/{node}/scan/glusterfs", "text" : "glusterfs" }, { - "text" : "iscsi", "info" : { "GET" : { - "proxyto" : "node", "description" : "Scan remote iSCSI server.", + "method" : "GET", + "name" : "iscsiscan", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, + "portal" : { + "format" : "pve-storage-portal-dns", + "type" : "string" + } + } + }, "permissions" : { "check" : [ "perm", @@ -18168,58 +18107,44 @@ var pveapi = [ ] ] }, + "protected" : 1, + "proxyto" : "node", "returns" : { - "type" : "array", "items" : { "properties" : { - "target" : { + "portal" : { "type" : "string" }, - "portal" : { + "target" : { "type" : "string" } }, "type" : "object" - } - }, - "protected" : 1, - "parameters" : { - "properties" : { - "portal" : { - "type" : "string", - "format" : "pve-storage-portal-dns" - }, - "node" : { - "type" : "string", - "description" : "The cluster node name.", - "format" : "pve-node" - } }, - "additionalProperties" : 0 - }, - "name" : "iscsiscan", - "method" : "GET" + "type" : "array" + } } }, + "leaf" : 1, "path" : "/nodes/{node}/scan/iscsi", - "leaf" : 1 + "text" : "iscsi" }, { "info" : { "GET" : { - "returns" : { - "type" : "array", - "items" : { - "type" : "object", - "properties" : { - "vg" : { - "type" : "string" - } + "description" : "List local LVM volume groups.", + "method" : "GET", + "name" : "lvmscan", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" } } }, - "proxyto" : "node", - "description" : "List local LVM volume groups.", "permissions" : { "check" : [ "perm", @@ -18229,46 +18154,46 @@ var pveapi = [ ] ] }, - "method" : "GET", "protected" : 1, - "name" : "lvmscan", - "parameters" : { - "additionalProperties" : 0, - "properties" : { - "node" : { - "format" : "pve-node", - "description" : "The cluster node name.", - "type" : "string" - } - } + "proxyto" : "node", + "returns" : { + "items" : { + "properties" : { + "vg" : { + "type" : "string" + } + }, + "type" : "object" + }, + "type" : "array" } } }, - "text" : "lvm", "leaf" : 1, - "path" : "/nodes/{node}/scan/lvm" + "path" : "/nodes/{node}/scan/lvm", + "text" : "lvm" }, { "info" : { "GET" : { + "description" : "List local LVM Thin Pools.", + "method" : "GET", + "name" : "lvmthinscan", "parameters" : { + "additionalProperties" : 0, "properties" : { "node" : { + "description" : "The cluster node name.", "format" : "pve-node", - "type" : "string", - "description" : "The cluster node name." + "type" : "string" }, "vg" : { + "maxLength" : 100, "pattern" : "[a-zA-Z0-9\\.\\+\\_][a-zA-Z0-9\\.\\+\\_\\-]+", - "type" : "string", - "maxLength" : 100 + "type" : "string" } - }, - "additionalProperties" : 0 + } }, - "name" : "lvmthinscan", - "protected" : 1, - "method" : "GET", "permissions" : { "check" : [ "perm", @@ -18278,10 +18203,9 @@ var pveapi = [ ] ] }, - "description" : "List local LVM Thin Pools.", + "protected" : 1, "proxyto" : "node", "returns" : { - "type" : "array", "items" : { "properties" : { "lv" : { @@ -18289,20 +18213,31 @@ var pveapi = [ } }, "type" : "object" - } + }, + "type" : "array" } } }, - "text" : "lvmthin", "leaf" : 1, - "path" : "/nodes/{node}/scan/lvmthin" + "path" : "/nodes/{node}/scan/lvmthin", + "text" : "lvmthin" }, { - "path" : "/nodes/{node}/scan/usb", - "leaf" : 1, - "text" : "usb", "info" : { "GET" : { + "description" : "List local USB devices.", + "method" : "GET", + "name" : "usbscan", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + } + } + }, "permissions" : { "check" : [ "perm", @@ -18312,291 +18247,129 @@ var pveapi = [ ] ] }, + "protected" : 1, "proxyto" : "node", - "description" : "List local USB devices.", "returns" : { "items" : { "properties" : { - "speed" : { - "type" : "string" - }, - "serial" : { - "optional" : 1, - "type" : "string" + "busnum" : { + "type" : "integer" }, - "product" : { - "type" : "string", - "optional" : 1 + "class" : { + "type" : "integer" }, "devnum" : { "type" : "integer" }, - "vendid" : { + "level" : { + "type" : "integer" + }, + "manufacturer" : { + "optional" : 1, "type" : "string" }, - "busnum" : { + "port" : { "type" : "integer" }, - "class" : { - "type" : "integer" + "prodid" : { + "type" : "string" }, - "usbpath" : { + "product" : { + "optional" : 1, + "type" : "string" + }, + "serial" : { "optional" : 1, "type" : "string" }, - "prodid" : { + "speed" : { "type" : "string" }, - "level" : { - "type" : "integer" - }, - "manufacturer" : { + "usbpath" : { "optional" : 1, "type" : "string" }, - "port" : { - "type" : "integer" + "vendid" : { + "type" : "string" } }, "type" : "object" }, "type" : "array" - }, - "name" : "usbscan", - "parameters" : { - "additionalProperties" : 0, - "properties" : { - "node" : { - "format" : "pve-node", - "type" : "string", - "description" : "The cluster node name." - } + } + } + }, + "leaf" : 1, + "path" : "/nodes/{node}/scan/usb", + "text" : "usb" + } + ], + "info" : { + "GET" : { + "description" : "Index of available scan methods", + "method" : "GET", + "name" : "index", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + } + } + }, + "permissions" : { + "user" : "all" + }, + "returns" : { + "items" : { + "properties" : { + "method" : { + "type" : "string" } }, - "protected" : 1, - "method" : "GET" - } + "type" : "object" + }, + "links" : [ + { + "href" : "{method}", + "rel" : "child" + } + ], + "type" : "array" } } - ], + }, + "leaf" : 0, + "path" : "/nodes/{node}/scan", "text" : "scan" }, { - "path" : "/nodes/{node}/storage", - "leaf" : 0, - "text" : "storage", "children" : [ { - "leaf" : 0, - "path" : "/nodes/{node}/storage/{storage}", - "info" : { - "GET" : { - "returns" : { - "links" : [ - { - "href" : "{subdir}", - "rel" : "child" - } - ], - "items" : { - "type" : "object", - "properties" : { - "subdir" : { - "type" : "string" - } - } - }, - "type" : "array" - }, - "method" : "GET", - "parameters" : { - "additionalProperties" : 0, - "properties" : { - "node" : { - "description" : "The cluster node name.", - "type" : "string", - "format" : "pve-node" - }, - "storage" : { - "description" : "The storage identifier.", - "type" : "string", - "format" : "pve-storage-id" - } - } - }, - "permissions" : { - "check" : [ - "perm", - "/storage/{storage}", - [ - "Datastore.Audit", - "Datastore.AllocateSpace" - ], - "any", - 1 - ] - }, - "name" : "diridx", - "description" : "" - } - }, - "text" : "{storage}", "children" : [ { - "info" : { - "GET" : { - "method" : "GET", - "parameters" : { - "additionalProperties" : 0, - "properties" : { - "storage" : { - "description" : "The storage identifier.", - "type" : "string", - "format" : "pve-storage-id" - }, - "vmid" : { - "format" : "pve-vmid", - "minimum" : 1, - "description" : "Only list images for this VM", - "optional" : 1, - "type" : "integer" - }, - "node" : { - "format" : "pve-node", - "type" : "string", - "description" : "The cluster node name." - }, - "content" : { - "description" : "Only list content of this type.", - "optional" : 1, - "type" : "string", - "format" : "pve-storage-content" - } - } - }, - "name" : "index", - "protected" : 1, - "returns" : { - "type" : "array", - "items" : { - "properties" : { - "volid" : { - "type" : "string" - } - }, - "type" : "object" - }, - "links" : [ - { - "href" : "{volid}", - "rel" : "child" - } - ] - }, - "permissions" : { - "check" : [ - "perm", - "/storage/{storage}", - [ - "Datastore.Audit", - "Datastore.AllocateSpace" - ], - "any", - 1 - ] - }, - "proxyto" : "node", - "description" : "List storage content." - }, - "POST" : { - "returns" : { - "description" : "Volume identifier", - "type" : "string" - }, - "description" : "Allocate disk images.", - "proxyto" : "node", - "permissions" : { - "check" : [ - "perm", - "/storage/{storage}", - [ - "Datastore.AllocateSpace" - ] - ] - }, - "method" : "POST", - "protected" : 1, - "parameters" : { - "additionalProperties" : 0, - "properties" : { - "format" : { - "requires" : "size", - "enum" : [ - "raw", - "qcow2", - "subvol" - ], - "type" : "string", - "optional" : 1 - }, - "vmid" : { - "format" : "pve-vmid", - "minimum" : 1, - "description" : "Specify owner VM", - "type" : "integer" - }, - "storage" : { - "format" : "pve-storage-id", - "description" : "The storage identifier.", - "type" : "string" - }, - "size" : { - "pattern" : "\\d+[MG]?", - "description" : "Size in kilobyte (1024 bytes). Optional suffixes 'M' (megabyte, 1024K) and 'G' (gigabyte, 1024M)", - "type" : "string" - }, - "filename" : { - "type" : "string", - "description" : "The name of the file to create." - }, - "node" : { - "type" : "string", - "description" : "The cluster node name.", - "format" : "pve-node" - } - } - }, - "name" : "create" - } - }, "children" : [ { "info" : { - "GET" : { - "returns" : { - "type" : "object" - }, - "proxyto" : "node", - "description" : "Get volume attributes", - "permissions" : { - "description" : "You need read access for the volume.", - "user" : "all" - }, - "method" : "GET", - "protected" : 1, + "DELETE" : { + "description" : "Delete volume", + "method" : "DELETE", + "name" : "delete", "parameters" : { "additionalProperties" : 0, "properties" : { - "storage" : { - "type" : "string", - "optional" : 1, - "description" : "The storage identifier.", - "format" : "pve-storage-id" - }, "node" : { "description" : "The cluster node name.", - "type" : "string", - "format" : "pve-node" + "format" : "pve-node", + "type" : "string" + }, + "storage" : { + "description" : "The storage identifier.", + "format" : "pve-storage-id", + "optional" : 1, + "type" : "string" }, "volume" : { "description" : "Volume identifier", @@ -18604,97 +18377,129 @@ var pveapi = [ } } }, - "name" : "info" + "permissions" : { + "description" : "You need 'Datastore.Allocate' privilege on the storage (or 'Datastore.AllocateSpace' for backup volumes if you have VM.Backup privilege on the VM).", + "user" : "all" + }, + "protected" : 1, + "proxyto" : "node", + "returns" : { + "type" : "null" + } }, - "DELETE" : { + "GET" : { + "description" : "Get volume attributes", + "method" : "GET", + "name" : "info", "parameters" : { "additionalProperties" : 0, "properties" : { - "volume" : { - "type" : "string", - "description" : "Volume identifier" - }, "node" : { "description" : "The cluster node name.", - "type" : "string", - "format" : "pve-node" + "format" : "pve-node", + "type" : "string" }, "storage" : { - "format" : "pve-storage-id", "description" : "The storage identifier.", + "format" : "pve-storage-id", "optional" : 1, "type" : "string" + }, + "volume" : { + "description" : "Volume identifier", + "type" : "string" } } }, - "name" : "delete", - "protected" : 1, - "method" : "DELETE", "permissions" : { - "description" : "You need 'Datastore.Allocate' privilege on the storage (or 'Datastore.AllocateSpace' for backup volumes if you have VM.Backup privilege on the VM).", + "description" : "You need read access for the volume.", "user" : "all" }, + "protected" : 1, "proxyto" : "node", - "description" : "Delete volume", "returns" : { - "type" : "null" + "type" : "object" } }, "POST" : { + "description" : "Copy a volume. This is experimental code - do not use.", + "method" : "POST", + "name" : "copy", "parameters" : { "additionalProperties" : 0, "properties" : { + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, + "storage" : { + "description" : "The storage identifier.", + "format" : "pve-storage-id", + "optional" : 1, + "type" : "string" + }, "target" : { - "type" : "string", - "description" : "Target volume identifier" + "description" : "Target volume identifier", + "type" : "string" }, "target_node" : { - "type" : "string", - "optional" : 1, "description" : "Target node. Default is local node.", - "format" : "pve-node" - }, - "storage" : { - "format" : "pve-storage-id", - "description" : "The storage identifier.", - "type" : "string", - "optional" : 1 + "format" : "pve-node", + "optional" : 1, + "type" : "string" }, "volume" : { - "type" : "string", - "description" : "Source volume identifier" - }, - "node" : { - "description" : "The cluster node name.", - "type" : "string", - "format" : "pve-node" + "description" : "Source volume identifier", + "type" : "string" } } }, - "name" : "copy", - "description" : "Copy a volume. This is experimental code - do not use.", "protected" : 1, "proxyto" : "node", "returns" : { "type" : "string" - }, - "method" : "POST" + } } }, - "text" : "{volume}", "leaf" : 1, - "path" : "/nodes/{node}/storage/{storage}/content/{volume}" + "path" : "/nodes/{node}/storage/{storage}/content/{volume}", + "text" : "{volume}" } ], - "text" : "content", - "leaf" : 0, - "path" : "/nodes/{node}/storage/{storage}/content" - }, - { - "leaf" : 1, - "path" : "/nodes/{node}/storage/{storage}/status", "info" : { "GET" : { + "description" : "List storage content.", + "method" : "GET", + "name" : "index", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "content" : { + "description" : "Only list content of this type.", + "format" : "pve-storage-content", + "optional" : 1, + "type" : "string" + }, + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, + "storage" : { + "description" : "The storage identifier.", + "format" : "pve-storage-id", + "type" : "string" + }, + "vmid" : { + "description" : "Only list images for this VM", + "format" : "pve-vmid", + "minimum" : 1, + "optional" : 1, + "type" : "integer" + } + } + }, "permissions" : { "check" : [ "perm", @@ -18707,82 +18512,182 @@ var pveapi = [ 1 ] }, - "description" : "Read storage status.", + "protected" : 1, "proxyto" : "node", "returns" : { - "properties" : {}, - "type" : "object" - }, + "items" : { + "properties" : { + "volid" : { + "type" : "string" + } + }, + "type" : "object" + }, + "links" : [ + { + "href" : "{volid}", + "rel" : "child" + } + ], + "type" : "array" + } + }, + "POST" : { + "description" : "Allocate disk images.", + "method" : "POST", + "name" : "create", "parameters" : { + "additionalProperties" : 0, "properties" : { + "filename" : { + "description" : "The name of the file to create.", + "type" : "string" + }, + "format" : { + "enum" : [ + "raw", + "qcow2", + "subvol" + ], + "optional" : 1, + "requires" : "size", + "type" : "string" + }, + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, + "size" : { + "description" : "Size in kilobyte (1024 bytes). Optional suffixes 'M' (megabyte, 1024K) and 'G' (gigabyte, 1024M)", + "pattern" : "\\d+[MG]?", + "type" : "string" + }, "storage" : { "description" : "The storage identifier.", - "type" : "string", - "format" : "pve-storage-id" + "format" : "pve-storage-id", + "type" : "string" }, + "vmid" : { + "description" : "Specify owner VM", + "format" : "pve-vmid", + "minimum" : 1, + "type" : "integer" + } + } + }, + "permissions" : { + "check" : [ + "perm", + "/storage/{storage}", + [ + "Datastore.AllocateSpace" + ] + ] + }, + "protected" : 1, + "proxyto" : "node", + "returns" : { + "description" : "Volume identifier", + "type" : "string" + } + } + }, + "leaf" : 0, + "path" : "/nodes/{node}/storage/{storage}/content", + "text" : "content" + }, + { + "info" : { + "GET" : { + "description" : "Read storage status.", + "method" : "GET", + "name" : "read_status", + "parameters" : { + "additionalProperties" : 0, + "properties" : { "node" : { "description" : "The cluster node name.", - "type" : "string", - "format" : "pve-node" + "format" : "pve-node", + "type" : "string" + }, + "storage" : { + "description" : "The storage identifier.", + "format" : "pve-storage-id", + "type" : "string" } - }, - "additionalProperties" : 0 + } + }, + "permissions" : { + "check" : [ + "perm", + "/storage/{storage}", + [ + "Datastore.Audit", + "Datastore.AllocateSpace" + ], + "any", + 1 + ] }, - "name" : "read_status", "protected" : 1, - "method" : "GET" + "proxyto" : "node", + "returns" : { + "properties" : {}, + "type" : "object" + } } }, + "leaf" : 1, + "path" : "/nodes/{node}/storage/{storage}/status", "text" : "status" }, { "info" : { "GET" : { - "protected" : 1, + "description" : "Read storage RRD statistics (returns PNG).", + "method" : "GET", + "name" : "rrd", "parameters" : { + "additionalProperties" : 0, "properties" : { + "cf" : { + "description" : "The RRD consolidation function", + "enum" : [ + "AVERAGE", + "MAX" + ], + "optional" : 1, + "type" : "string" + }, "ds" : { - "type" : "string", "description" : "The list of datasources you want to display.", - "format" : "pve-configid-list" + "format" : "pve-configid-list", + "type" : "string" }, "node" : { "description" : "The cluster node name.", - "type" : "string", - "format" : "pve-node" - }, - "timeframe" : { - "type" : "string", - "enum" : [ - "hour", - "day", - "week", - "month", - "year" - ], - "description" : "Specify the time frame you are interested in." + "format" : "pve-node", + "type" : "string" }, "storage" : { - "type" : "string", "description" : "The storage identifier.", - "format" : "pve-storage-id" - }, - "cf" : { - "type" : "string", - "optional" : 1, + "format" : "pve-storage-id", + "type" : "string" + }, + "timeframe" : { + "description" : "Specify the time frame you are interested in.", "enum" : [ - "AVERAGE", - "MAX" + "hour", + "day", + "week", + "month", + "year" ], - "description" : "The RRD consolidation function" + "type" : "string" } - }, - "additionalProperties" : 0 + } }, - "name" : "rrd", - "method" : "GET", - "proxyto" : "node", - "description" : "Read storage RRD statistics (returns PNG).", "permissions" : { "check" : [ "perm", @@ -18795,6 +18700,8 @@ var pveapi = [ 1 ] }, + "protected" : 1, + "proxyto" : "node", "returns" : { "properties" : { "filename" : { @@ -18805,23 +18712,39 @@ var pveapi = [ } } }, - "text" : "rrd", "leaf" : 1, - "path" : "/nodes/{node}/storage/{storage}/rrd" + "path" : "/nodes/{node}/storage/{storage}/rrd", + "text" : "rrd" }, { "info" : { "GET" : { - "protected" : 1, + "description" : "Read storage RRD statistics.", + "method" : "GET", + "name" : "rrddata", "parameters" : { + "additionalProperties" : 0, "properties" : { + "cf" : { + "description" : "The RRD consolidation function", + "enum" : [ + "AVERAGE", + "MAX" + ], + "optional" : 1, + "type" : "string" + }, "node" : { - "format" : "pve-node", "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, + "storage" : { + "description" : "The storage identifier.", + "format" : "pve-storage-id", "type" : "string" }, "timeframe" : { - "type" : "string", "description" : "Specify the time frame you are interested in.", "enum" : [ "hour", @@ -18829,29 +18752,11 @@ var pveapi = [ "week", "month", "year" - ] - }, - "storage" : { - "format" : "pve-storage-id", - "type" : "string", - "description" : "The storage identifier." - }, - "cf" : { - "type" : "string", - "optional" : 1, - "enum" : [ - "AVERAGE", - "MAX" ], - "description" : "The RRD consolidation function" + "type" : "string" } - }, - "additionalProperties" : 0 + } }, - "name" : "rrddata", - "method" : "GET", - "proxyto" : "node", - "description" : "Read storage RRD statistics.", "permissions" : { "check" : [ "perm", @@ -18864,61 +18769,56 @@ var pveapi = [ 1 ] }, + "protected" : 1, + "proxyto" : "node", "returns" : { "items" : { - "type" : "object", - "properties" : {} + "properties" : {}, + "type" : "object" }, "type" : "array" } } }, - "text" : "rrddata", "leaf" : 1, - "path" : "/nodes/{node}/storage/{storage}/rrddata" + "path" : "/nodes/{node}/storage/{storage}/rrddata", + "text" : "rrddata" }, { - "path" : "/nodes/{node}/storage/{storage}/upload", - "leaf" : 1, - "text" : "upload", "info" : { "POST" : { - "returns" : { - "type" : "string" - }, - "method" : "POST", "description" : "Upload templates and ISO images.", - "protected" : 1, + "method" : "POST", + "name" : "upload", "parameters" : { "additionalProperties" : 0, "properties" : { - "storage" : { - "format" : "pve-storage-id", - "description" : "The storage identifier.", - "type" : "string" - }, - "tmpfilename" : { - "optional" : 1, - "type" : "string", - "description" : "The source file name. This parameter is usually set by the REST handler. You can only overwrite it when connecting to the trustet port on localhost." - }, "content" : { "description" : "Content type.", - "type" : "string", - "format" : "pve-storage-content" + "format" : "pve-storage-content", + "type" : "string" }, "filename" : { - "type" : "string", - "description" : "The name of the file to create." + "description" : "The name of the file to create.", + "type" : "string" }, "node" : { "description" : "The cluster node name.", - "type" : "string", - "format" : "pve-node" + "format" : "pve-node", + "type" : "string" + }, + "storage" : { + "description" : "The storage identifier.", + "format" : "pve-storage-id", + "type" : "string" + }, + "tmpfilename" : { + "description" : "The source file name. This parameter is usually set by the REST handler. You can only overwrite it when connecting to the trustet port on localhost.", + "optional" : 1, + "type" : "string" } } }, - "name" : "upload", "permissions" : { "check" : [ "perm", @@ -18927,86 +18827,159 @@ var pveapi = [ "Datastore.AllocateTemplate" ] ] + }, + "protected" : 1, + "returns" : { + "type" : "string" + } + } + }, + "leaf" : 1, + "path" : "/nodes/{node}/storage/{storage}/upload", + "text" : "upload" + } + ], + "info" : { + "GET" : { + "description" : "", + "method" : "GET", + "name" : "diridx", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, + "storage" : { + "description" : "The storage identifier.", + "format" : "pve-storage-id", + "type" : "string" } } + }, + "permissions" : { + "check" : [ + "perm", + "/storage/{storage}", + [ + "Datastore.Audit", + "Datastore.AllocateSpace" + ], + "any", + 1 + ] + }, + "returns" : { + "items" : { + "properties" : { + "subdir" : { + "type" : "string" + } + }, + "type" : "object" + }, + "links" : [ + { + "href" : "{subdir}", + "rel" : "child" + } + ], + "type" : "array" } } - ] + }, + "leaf" : 0, + "path" : "/nodes/{node}/storage/{storage}", + "text" : "{storage}" } ], "info" : { "GET" : { + "description" : "Get status for all datastores.", + "method" : "GET", + "name" : "index", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "content" : { + "description" : "Only list stores which support this content type.", + "format" : "pve-storage-content-list", + "optional" : 1, + "type" : "string" + }, + "enabled" : { + "default" : 0, + "description" : "Only list stores which are enabled (not disabled in config).", + "optional" : 1, + "type" : "boolean" + }, + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, + "storage" : { + "description" : "Only list status for specified storage", + "format" : "pve-storage-id", + "optional" : 1, + "type" : "string" + }, + "target" : { + "description" : "If target is different to 'node', we only lists shared storages which content is accessible on this 'node' and the specified 'target' node.", + "format" : "pve-node", + "optional" : 1, + "type" : "string" + } + } + }, "permissions" : { "description" : "Only list entries where you have 'Datastore.Audit' or 'Datastore.AllocateSpace' permissions on '/storage/'", "user" : "all" }, + "protected" : 1, "proxyto" : "node", - "description" : "Get status for all datastores.", "returns" : { - "type" : "array", "items" : { - "type" : "object", "properties" : { "storage" : { "type" : "string" } - } + }, + "type" : "object" }, "links" : [ { "href" : "{storage}", "rel" : "child" } - ] - }, - "parameters" : { - "properties" : { - "target" : { - "format" : "pve-node", - "description" : "If target is different to 'node', we only lists shared storages which content is accessible on this 'node' and the specified 'target' node.", - "type" : "string", - "optional" : 1 - }, - "storage" : { - "format" : "pve-storage-id", - "type" : "string", - "optional" : 1, - "description" : "Only list status for specified storage" - }, - "enabled" : { - "description" : "Only list stores which are enabled (not disabled in config).", - "type" : "boolean", - "optional" : 1, - "default" : 0 - }, - "content" : { - "format" : "pve-storage-content-list", - "type" : "string", - "optional" : 1, - "description" : "Only list stores which support this content type." - }, - "node" : { - "format" : "pve-node", - "description" : "The cluster node name.", - "type" : "string" - } - }, - "additionalProperties" : 0 - }, - "name" : "index", - "protected" : 1, - "method" : "GET" + ], + "type" : "array" + } } - } + }, + "leaf" : 0, + "path" : "/nodes/{node}/storage", + "text" : "storage" }, { - "text" : "apt", "children" : [ { "info" : { - "POST" : { - "returns" : { - "type" : "string" + "GET" : { + "description" : "List available updates.", + "method" : "GET", + "name" : "list_updates", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + } + } }, "permissions" : { "check" : [ @@ -19017,53 +18990,40 @@ var pveapi = [ ] ] }, - "description" : "This is used to resynchronize the package index files from their sources (apt-get update).", + "protected" : 1, "proxyto" : "node", + "returns" : { + "items" : { + "properties" : {}, + "type" : "object" + }, + "type" : "array" + } + }, + "POST" : { + "description" : "This is used to resynchronize the package index files from their sources (apt-get update).", "method" : "POST", "name" : "update_database", "parameters" : { "additionalProperties" : 0, "properties" : { + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, "notify" : { - "description" : "Send notification mail about new packages (to email address specified for user 'root@pam').", "default" : 0, - "type" : "boolean", - "optional" : 1 + "description" : "Send notification mail about new packages (to email address specified for user 'root@pam').", + "optional" : 1, + "type" : "boolean" }, "quiet" : { "default" : 0, + "description" : "Only produces output suitable for logging, omitting progress indicators.", "optional" : 1, - "type" : "boolean", - "description" : "Only produces output suitable for logging, omitting progress indicators." - }, - "node" : { - "format" : "pve-node", - "description" : "The cluster node name.", - "type" : "string" - } - } - }, - "protected" : 1 - }, - "GET" : { - "method" : "GET", - "name" : "list_updates", - "parameters" : { - "properties" : { - "node" : { - "type" : "string", - "description" : "The cluster node name.", - "format" : "pve-node" + "type" : "boolean" } - }, - "additionalProperties" : 0 - }, - "protected" : 1, - "returns" : { - "type" : "array", - "items" : { - "type" : "object", - "properties" : {} } }, "permissions" : { @@ -19075,72 +19035,76 @@ var pveapi = [ ] ] }, - "description" : "List available updates.", - "proxyto" : "node" + "protected" : 1, + "proxyto" : "node", + "returns" : { + "type" : "string" + } } }, - "text" : "update", "leaf" : 1, - "path" : "/nodes/{node}/apt/update" + "path" : "/nodes/{node}/apt/update", + "text" : "update" }, { - "leaf" : 1, - "path" : "/nodes/{node}/apt/changelog", "info" : { "GET" : { + "description" : "Get package changelogs.", "method" : "GET", - "returns" : { - "type" : "string" - }, - "permissions" : { - "check" : [ - "perm", - "/nodes/{node}", - [ - "Sys.Modify" - ] - ] - }, "name" : "changelog", "parameters" : { + "additionalProperties" : 0, "properties" : { - "node" : { - "format" : "pve-node", - "type" : "string", - "description" : "The cluster node name." - }, "name" : { "description" : "Package name.", "type" : "string" }, + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, "version" : { "description" : "Package version.", - "type" : "string", - "optional" : 1 + "optional" : 1, + "type" : "string" } - }, - "additionalProperties" : 0 + } }, - "description" : "Get package changelogs.", - "proxyto" : "node" + "permissions" : { + "check" : [ + "perm", + "/nodes/{node}", + [ + "Sys.Modify" + ] + ] + }, + "proxyto" : "node", + "returns" : { + "type" : "string" + } } }, + "leaf" : 1, + "path" : "/nodes/{node}/apt/changelog", "text" : "changelog" }, { - "text" : "versions", "info" : { "GET" : { + "description" : "Get package information for important Proxmox packages.", + "method" : "GET", "name" : "versions", "parameters" : { + "additionalProperties" : 0, "properties" : { "node" : { + "description" : "The cluster node name.", "format" : "pve-node", - "type" : "string", - "description" : "The cluster node name." + "type" : "string" } - }, - "additionalProperties" : 0 + } }, "permissions" : { "check" : [ @@ -19152,217 +19116,254 @@ var pveapi = [ ] }, "proxyto" : "node", - "description" : "Get package information for important Proxmox packages.", - "method" : "GET", "returns" : { - "type" : "array", "items" : { "properties" : {}, "type" : "object" - } + }, + "type" : "array" } } }, + "leaf" : 1, "path" : "/nodes/{node}/apt/versions", - "leaf" : 1 + "text" : "versions" } ], "info" : { "GET" : { - "returns" : { - "type" : "array", - "items" : { - "type" : "object", - "properties" : { - "id" : { - "type" : "string" - } - } - }, - "links" : [ - { - "href" : "{id}", - "rel" : "child" - } - ] - }, + "description" : "Directory index for apt (Advanced Package Tool).", "method" : "GET", + "name" : "index", "parameters" : { "additionalProperties" : 0, "properties" : { "node" : { + "description" : "The cluster node name.", "format" : "pve-node", - "type" : "string", - "description" : "The cluster node name." + "type" : "string" } } }, - "name" : "index", "permissions" : { "user" : "all" }, - "description" : "Directory index for apt (Advanced Package Tool)." + "returns" : { + "items" : { + "properties" : { + "id" : { + "type" : "string" + } + }, + "type" : "object" + }, + "links" : [ + { + "href" : "{id}", + "rel" : "child" + } + ], + "type" : "array" + } } }, + "leaf" : 0, "path" : "/nodes/{node}/apt", - "leaf" : 0 + "text" : "apt" }, { "children" : [ { - "text" : "rules", "children" : [ { - "text" : "{pos}", "info" : { "DELETE" : { + "description" : "Delete rule.", "method" : "DELETE", - "protected" : 1, + "name" : "delete_rule", "parameters" : { "additionalProperties" : 0, "properties" : { - "node" : { - "description" : "The cluster node name.", - "type" : "string", - "format" : "pve-node" - }, "digest" : { - "maxLength" : 40, "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", + "maxLength" : 40, "optional" : 1, "type" : "string" }, + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, "pos" : { - "type" : "integer", - "optional" : 1, "description" : "Update rule at position .", - "minimum" : 0 + "minimum" : 0, + "optional" : 1, + "type" : "integer" } } }, - "name" : "delete_rule", + "permissions" : { + "check" : [ + "perm", + "/nodes/{node}", + [ + "Sys.Modify" + ] + ] + }, + "protected" : 1, + "proxyto" : "node", "returns" : { "type" : "null" + } + }, + "GET" : { + "description" : "Get single rule data.", + "method" : "GET", + "name" : "get_rule", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, + "pos" : { + "description" : "Update rule at position .", + "minimum" : 0, + "optional" : 1, + "type" : "integer" + } + } }, - "proxyto" : "node", - "description" : "Delete rule.", "permissions" : { "check" : [ "perm", "/nodes/{node}", [ - "Sys.Modify" + "Sys.Audit" ] ] + }, + "proxyto" : "node", + "returns" : { + "properties" : { + "pos" : { + "type" : "integer" + } + }, + "type" : "object" } }, "PUT" : { + "description" : "Modify rule data.", + "method" : "PUT", "name" : "update_rule", "parameters" : { + "additionalProperties" : 0, "properties" : { - "dest" : { - "type" : "string", - "optional" : 1, - "description" : "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.", - "format" : "pve-fw-addr-spec" - }, - "digest" : { - "maxLength" : 40, - "optional" : 1, - "type" : "string", - "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications." - }, - "source" : { - "format" : "pve-fw-addr-spec", + "action" : { + "description" : "Rule action ('ACCEPT', 'DROP', 'REJECT') or security group name.", + "maxLength" : 20, + "minLength" : 2, "optional" : 1, - "type" : "string", - "description" : "Restrict packet source 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." + "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", + "type" : "string" }, "comment" : { "optional" : 1, "type" : "string" }, - "node" : { - "format" : "pve-node", - "type" : "string", - "description" : "The cluster node name." - }, - "moveto" : { - "minimum" : 0, - "description" : "Move rule to new position . Other arguments are ignored.", + "delete" : { + "description" : "A list of settings you want to delete.", + "format" : "pve-configid-list", "optional" : 1, - "type" : "integer" + "type" : "string" }, - "delete" : { - "type" : "string", + "dest" : { + "description" : "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.", + "format" : "pve-fw-addr-spec", "optional" : 1, - "description" : "A list of settings you want to delete.", - "format" : "pve-configid-list" + "type" : "string" }, - "type" : { + "digest" : { + "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", + "maxLength" : 40, "optional" : 1, - "type" : "string", - "enum" : [ - "in", - "out", - "group" - ] + "type" : "string" }, "dport" : { - "format" : "pve-fw-dport-spec", "description" : "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.", - "type" : "string", - "optional" : 1 + "format" : "pve-fw-dport-spec", + "optional" : 1, + "type" : "string" }, - "sport" : { + "enable" : { + "minimum" : 0, "optional" : 1, - "type" : "string", - "description" : "Restrict TCP/UDP source 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.", - "format" : "pve-fw-sport-spec" + "type" : "integer" }, "iface" : { - "maxLength" : 20, + "description" : "Network interface name. You have to use network configuration key names for VMs and containers ('net\\d+'). Host related rules can use arbitrary strings.", "format" : "pve-iface", - "type" : "string", - "optional" : 1, + "maxLength" : 20, "minLength" : 2, - "description" : "Network interface name. You have to use network configuration key names for VMs and containers ('net\\d+'). Host related rules can use arbitrary strings." + "optional" : 1, + "type" : "string" }, - "proto" : { - "format" : "pve-fw-protocol-spec", - "type" : "string", + "macro" : { + "maxLength" : 128, + "optional" : 1, + "type" : "string" + }, + "moveto" : { + "description" : "Move rule to new position . Other arguments are ignored.", + "minimum" : 0, "optional" : 1, - "description" : "IP protocol. You can use protocol names ('tcp'/'udp') or simple numbers, as defined in '/etc/protocols'." + "type" : "integer" + }, + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" }, "pos" : { + "description" : "Update rule at position .", "minimum" : 0, - "type" : "integer", "optional" : 1, - "description" : "Update rule at position ." + "type" : "integer" }, - "macro" : { - "maxLength" : 128, + "proto" : { + "description" : "IP protocol. You can use protocol names ('tcp'/'udp') or simple numbers, as defined in '/etc/protocols'.", + "format" : "pve-fw-protocol-spec", "optional" : 1, "type" : "string" }, - "action" : { - "minLength" : 2, - "description" : "Rule action ('ACCEPT', 'DROP', 'REJECT') or security group name.", - "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", - "type" : "string", + "source" : { + "description" : "Restrict packet source 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.", + "format" : "pve-fw-addr-spec", "optional" : 1, - "maxLength" : 20 + "type" : "string" }, - "enable" : { - "minimum" : 0, - "type" : "integer", - "optional" : 1 + "sport" : { + "description" : "Restrict TCP/UDP source 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.", + "format" : "pve-fw-sport-spec", + "optional" : 1, + "type" : "string" + }, + "type" : { + "enum" : [ + "in", + "out", + "group" + ], + "optional" : 1, + "type" : "string" } - }, - "additionalProperties" : 0 + } }, - "protected" : 1, - "method" : "PUT", "permissions" : { "check" : [ "perm", @@ -19372,66 +19373,51 @@ var pveapi = [ ] ] }, + "protected" : 1, "proxyto" : "node", - "description" : "Modify rule data.", "returns" : { "type" : "null" } - }, - "GET" : { - "method" : "GET", - "returns" : { - "type" : "object", - "properties" : { - "pos" : { - "type" : "integer" - } - } - }, - "parameters" : { - "properties" : { - "node" : { - "description" : "The cluster node name.", - "type" : "string", - "format" : "pve-node" - }, - "pos" : { - "minimum" : 0, - "description" : "Update rule at position .", - "type" : "integer", - "optional" : 1 - } - }, - "additionalProperties" : 0 - }, - "permissions" : { - "check" : [ - "perm", - "/nodes/{node}", - [ - "Sys.Audit" - ] - ] - }, - "name" : "get_rule", - "proxyto" : "node", - "description" : "Get single rule data." } }, + "leaf" : 1, "path" : "/nodes/{node}/firewall/rules/{pos}", - "leaf" : 1 + "text" : "{pos}" } ], "info" : { "GET" : { + "description" : "List rules.", + "method" : "GET", + "name" : "get_rules", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + } + } + }, + "permissions" : { + "check" : [ + "perm", + "/nodes/{node}", + [ + "Sys.Audit" + ] + ] + }, + "proxyto" : "node", "returns" : { "items" : { - "type" : "object", "properties" : { "pos" : { "type" : "integer" } - } + }, + "type" : "object" }, "links" : [ { @@ -19440,128 +19426,102 @@ var pveapi = [ } ], "type" : "array" - }, - "method" : "GET", - "description" : "List rules.", - "proxyto" : "node", - "permissions" : { - "check" : [ - "perm", - "/nodes/{node}", - [ - "Sys.Audit" - ] - ] - }, - "parameters" : { - "additionalProperties" : 0, - "properties" : { - "node" : { - "description" : "The cluster node name.", - "type" : "string", - "format" : "pve-node" - } - } - }, - "name" : "get_rules" + } }, "POST" : { + "description" : "Create new rule.", "method" : "POST", "name" : "create_rule", "parameters" : { + "additionalProperties" : 0, "properties" : { - "dport" : { - "format" : "pve-fw-dport-spec", - "type" : "string", - "optional" : 1, - "description" : "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." - }, - "enable" : { - "minimum" : 0, - "optional" : 1, - "type" : "integer" - }, - "type" : { - "enum" : [ - "in", - "out", - "group" - ], - "optional" : 0, - "type" : "string" - }, "action" : { - "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", "description" : "Rule action ('ACCEPT', 'DROP', 'REJECT') or security group name.", + "maxLength" : 20, "minLength" : 2, "optional" : 0, - "type" : "string", - "maxLength" : 20 - }, - "pos" : { - "minimum" : 0, - "description" : "Update rule at position .", - "type" : "integer", - "optional" : 1 + "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+", + "type" : "string" }, - "proto" : { - "description" : "IP protocol. You can use protocol names ('tcp'/'udp') or simple numbers, as defined in '/etc/protocols'.", + "comment" : { "optional" : 1, - "type" : "string", - "format" : "pve-fw-protocol-spec" + "type" : "string" }, - "macro" : { - "type" : "string", + "dest" : { + "description" : "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.", + "format" : "pve-fw-addr-spec", "optional" : 1, - "maxLength" : 128 + "type" : "string" }, - "node" : { - "type" : "string", - "description" : "The cluster node name.", - "format" : "pve-node" + "digest" : { + "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", + "maxLength" : 40, + "optional" : 1, + "type" : "string" }, - "comment" : { + "dport" : { + "description" : "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.", + "format" : "pve-fw-dport-spec", "optional" : 1, "type" : "string" }, + "enable" : { + "minimum" : 0, + "optional" : 1, + "type" : "integer" + }, "iface" : { + "description" : "Network interface name. You have to use network configuration key names for VMs and containers ('net\\d+'). Host related rules can use arbitrary strings.", "format" : "pve-iface", "maxLength" : 20, "minLength" : 2, - "description" : "Network interface name. You have to use network configuration key names for VMs and containers ('net\\d+'). Host related rules can use arbitrary strings.", "optional" : 1, "type" : "string" }, - "sport" : { - "format" : "pve-fw-sport-spec", - "description" : "Restrict TCP/UDP source 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.", + "macro" : { + "maxLength" : 128, "optional" : 1, "type" : "string" }, - "dest" : { - "description" : "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.", - "type" : "string", + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, + "pos" : { + "description" : "Update rule at position .", + "minimum" : 0, + "optional" : 1, + "type" : "integer" + }, + "proto" : { + "description" : "IP protocol. You can use protocol names ('tcp'/'udp') or simple numbers, as defined in '/etc/protocols'.", + "format" : "pve-fw-protocol-spec", "optional" : 1, - "format" : "pve-fw-addr-spec" + "type" : "string" }, "source" : { - "format" : "pve-fw-addr-spec", "description" : "Restrict packet source 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.", - "type" : "string", - "optional" : 1 + "format" : "pve-fw-addr-spec", + "optional" : 1, + "type" : "string" }, - "digest" : { - "maxLength" : 40, + "sport" : { + "description" : "Restrict TCP/UDP source 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.", + "format" : "pve-fw-sport-spec", "optional" : 1, - "type" : "string", - "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications." + "type" : "string" + }, + "type" : { + "enum" : [ + "in", + "out", + "group" + ], + "optional" : 0, + "type" : "string" } - }, - "additionalProperties" : 0 - }, - "protected" : 1, - "returns" : { - "type" : "null" + } }, "permissions" : { "check" : [ @@ -19572,54 +19532,52 @@ var pveapi = [ ] ] }, - "description" : "Create new rule.", - "proxyto" : "node" + "protected" : 1, + "proxyto" : "node", + "returns" : { + "type" : "null" + } } }, + "leaf" : 0, "path" : "/nodes/{node}/firewall/rules", - "leaf" : 0 + "text" : "rules" }, { - "leaf" : 1, - "path" : "/nodes/{node}/firewall/options", "info" : { - "PUT" : { - "protected" : 1, - "name" : "set_options", + "GET" : { + "description" : "Get host firewall options.", + "method" : "GET", + "name" : "get_options", "parameters" : { "additionalProperties" : 0, "properties" : { - "digest" : { - "type" : "string", - "optional" : 1, - "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", - "maxLength" : 40 - }, - "nf_conntrack_max" : { - "minimum" : 32768, - "type" : "integer", - "optional" : 1, - "description" : "Maximum number of tracked connections." - }, - "ndp" : { - "optional" : 1, - "type" : "boolean", - "description" : "Enable NDP." - }, - "nf_conntrack_tcp_timeout_established" : { - "minimum" : 7875, + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + } + } + }, + "permissions" : { + "check" : [ + "perm", + "/nodes/{node}", + [ + "Sys.Audit" + ] + ] + }, + "proxyto" : "node", + "returns" : { + "properties" : { + "enable" : { + "description" : "Enable host firewall rules.", "optional" : 1, - "type" : "integer", - "description" : "Conntrack established timeout." - }, - "nosmurfs" : { - "description" : "Enable SMURFS filter.", - "type" : "boolean", - "optional" : 1 + "type" : "boolean" }, - "tcp_flags_log_level" : { - "optional" : 1, - "type" : "string", + "log_level_in" : { + "description" : "Log level for incoming traffic.", "enum" : [ "emerg", "alert", @@ -19631,11 +19589,11 @@ var pveapi = [ "debug", "nolog" ], - "description" : "Log level for illegal tcp flags filter." - }, - "log_level_in" : { "optional" : 1, - "type" : "string", + "type" : "string" + }, + "log_level_out" : { + "description" : "Log level for outgoing traffic.", "enum" : [ "emerg", "alert", @@ -19647,9 +19605,33 @@ var pveapi = [ "debug", "nolog" ], - "description" : "Log level for incoming traffic." + "optional" : 1, + "type" : "string" + }, + "ndp" : { + "description" : "Enable NDP.", + "optional" : 1, + "type" : "boolean" + }, + "nf_conntrack_max" : { + "description" : "Maximum number of tracked connections.", + "minimum" : 32768, + "optional" : 1, + "type" : "integer" + }, + "nf_conntrack_tcp_timeout_established" : { + "description" : "Conntrack established timeout.", + "minimum" : 7875, + "optional" : 1, + "type" : "integer" + }, + "nosmurfs" : { + "description" : "Enable SMURFS filter.", + "optional" : 1, + "type" : "boolean" }, "smurf_log_level" : { + "description" : "Log level for SMURFS filter.", "enum" : [ "emerg", "alert", @@ -19661,27 +19643,11 @@ var pveapi = [ "debug", "nolog" ], - "description" : "Log level for SMURFS filter.", "optional" : 1, "type" : "string" }, - "delete" : { - "description" : "A list of settings you want to delete.", - "type" : "string", - "optional" : 1, - "format" : "pve-configid-list" - }, - "node" : { - "format" : "pve-node", - "type" : "string", - "description" : "The cluster node name." - }, - "tcpflags" : { - "optional" : 1, - "type" : "boolean", - "description" : "Filter illegal combinations of TCP flags." - }, - "log_level_out" : { + "tcp_flags_log_level" : { + "description" : "Log level for illegal tcp flags filter.", "enum" : [ "emerg", "alert", @@ -19693,74 +19659,44 @@ var pveapi = [ "debug", "nolog" ], - "description" : "Log level for outgoing traffic.", - "type" : "string", - "optional" : 1 + "optional" : 1, + "type" : "string" }, - "enable" : { - "type" : "boolean", + "tcpflags" : { + "description" : "Filter illegal combinations of TCP flags.", "optional" : 1, - "description" : "Enable host firewall rules." + "type" : "boolean" } - } - }, - "method" : "PUT", - "proxyto" : "node", - "description" : "Set Firewall options.", - "permissions" : { - "check" : [ - "perm", - "/nodes/{node}", - [ - "Sys.Modify" - ] - ] - }, - "returns" : { - "type" : "null" + }, + "type" : "object" } }, - "GET" : { - "proxyto" : "node", - "description" : "Get host firewall options.", - "permissions" : { - "check" : [ - "perm", - "/nodes/{node}", - [ - "Sys.Audit" - ] - ] - }, + "PUT" : { + "description" : "Set Firewall options.", + "method" : "PUT", + "name" : "set_options", "parameters" : { + "additionalProperties" : 0, "properties" : { - "node" : { - "description" : "The cluster node name.", - "type" : "string", - "format" : "pve-node" - } - }, - "additionalProperties" : 0 - }, - "name" : "get_options", - "returns" : { - "type" : "object", - "properties" : { - "nf_conntrack_tcp_timeout_established" : { - "description" : "Conntrack established timeout.", - "type" : "integer", + "delete" : { + "description" : "A list of settings you want to delete.", + "format" : "pve-configid-list", "optional" : 1, - "minimum" : 7875 + "type" : "string" }, - "nosmurfs" : { - "description" : "Enable SMURFS filter.", - "type" : "boolean", - "optional" : 1 + "digest" : { + "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", + "maxLength" : 40, + "optional" : 1, + "type" : "string" }, - "tcp_flags_log_level" : { - "type" : "string", + "enable" : { + "description" : "Enable host firewall rules.", "optional" : 1, - "description" : "Log level for illegal tcp flags filter.", + "type" : "boolean" + }, + "log_level_in" : { + "description" : "Log level for incoming traffic.", "enum" : [ "emerg", "alert", @@ -19771,20 +19707,12 @@ var pveapi = [ "info", "debug", "nolog" - ] - }, - "nf_conntrack_max" : { - "description" : "Maximum number of tracked connections.", - "type" : "integer", - "optional" : 1, - "minimum" : 32768 - }, - "ndp" : { - "type" : "boolean", + ], "optional" : 1, - "description" : "Enable NDP." + "type" : "string" }, - "smurf_log_level" : { + "log_level_out" : { + "description" : "Log level for outgoing traffic.", "enum" : [ "emerg", "alert", @@ -19796,14 +19724,38 @@ var pveapi = [ "debug", "nolog" ], - "description" : "Log level for SMURFS filter.", "optional" : 1, "type" : "string" }, - "log_level_in" : { + "ndp" : { + "description" : "Enable NDP.", "optional" : 1, - "type" : "string", - "description" : "Log level for incoming traffic.", + "type" : "boolean" + }, + "nf_conntrack_max" : { + "description" : "Maximum number of tracked connections.", + "minimum" : 32768, + "optional" : 1, + "type" : "integer" + }, + "nf_conntrack_tcp_timeout_established" : { + "description" : "Conntrack established timeout.", + "minimum" : 7875, + "optional" : 1, + "type" : "integer" + }, + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, + "nosmurfs" : { + "description" : "Enable SMURFS filter.", + "optional" : 1, + "type" : "boolean" + }, + "smurf_log_level" : { + "description" : "Log level for SMURFS filter.", "enum" : [ "emerg", "alert", @@ -19814,15 +19766,12 @@ var pveapi = [ "info", "debug", "nolog" - ] - }, - "tcpflags" : { - "description" : "Filter illegal combinations of TCP flags.", - "type" : "boolean", - "optional" : 1 + ], + "optional" : 1, + "type" : "string" }, - "log_level_out" : { - "description" : "Log level for outgoing traffic.", + "tcp_flags_log_level" : { + "description" : "Log level for illegal tcp flags filter.", "enum" : [ "emerg", "alert", @@ -19834,51 +19783,62 @@ var pveapi = [ "debug", "nolog" ], - "type" : "string", - "optional" : 1 + "optional" : 1, + "type" : "string" }, - "enable" : { - "description" : "Enable host firewall rules.", + "tcpflags" : { + "description" : "Filter illegal combinations of TCP flags.", "optional" : 1, "type" : "boolean" } } }, - "method" : "GET" + "permissions" : { + "check" : [ + "perm", + "/nodes/{node}", + [ + "Sys.Modify" + ] + ] + }, + "protected" : 1, + "proxyto" : "node", + "returns" : { + "type" : "null" + } } }, + "leaf" : 1, + "path" : "/nodes/{node}/firewall/options", "text" : "options" }, { - "leaf" : 1, - "path" : "/nodes/{node}/firewall/log", "info" : { "GET" : { - "protected" : 1, + "description" : "Read firewall log", + "method" : "GET", "name" : "log", "parameters" : { + "additionalProperties" : 0, "properties" : { - "start" : { - "type" : "integer", - "optional" : 1, - "minimum" : 0 - }, "limit" : { - "type" : "integer", + "minimum" : 0, "optional" : 1, - "minimum" : 0 + "type" : "integer" }, "node" : { - "format" : "pve-node", "description" : "The cluster node name.", + "format" : "pve-node", "type" : "string" + }, + "start" : { + "minimum" : 0, + "optional" : 1, + "type" : "integer" } - }, - "additionalProperties" : 0 + } }, - "method" : "GET", - "description" : "Read firewall log", - "proxyto" : "node", "permissions" : { "check" : [ "perm", @@ -19888,124 +19848,123 @@ var pveapi = [ ] ] }, + "protected" : 1, + "proxyto" : "node", "returns" : { "items" : { - "type" : "object", "properties" : { "n" : { - "type" : "integer", - "description" : "Line number" + "description" : "Line number", + "type" : "integer" }, "t" : { - "type" : "string", - "description" : "Line text" + "description" : "Line text", + "type" : "string" } - } + }, + "type" : "object" }, "type" : "array" } } }, + "leaf" : 1, + "path" : "/nodes/{node}/firewall/log", "text" : "log" } ], - "text" : "firewall", "info" : { "GET" : { + "description" : "Directory index.", + "method" : "GET", + "name" : "index", "parameters" : { + "additionalProperties" : 0, "properties" : { "node" : { "description" : "The cluster node name.", - "type" : "string", - "format" : "pve-node" + "format" : "pve-node", + "type" : "string" } - }, - "additionalProperties" : 0 + } }, "permissions" : { "user" : "all" }, - "name" : "index", - "description" : "Directory index.", "returns" : { - "type" : "array", "items" : { "properties" : {}, "type" : "object" }, "links" : [ { - "rel" : "child", - "href" : "{name}" + "href" : "{name}", + "rel" : "child" } - ] - }, - "method" : "GET" + ], + "type" : "array" + } } }, + "leaf" : 0, "path" : "/nodes/{node}/firewall", - "leaf" : 0 + "text" : "firewall" }, { "info" : { "GET" : { + "description" : "API version details", + "method" : "GET", + "name" : "version", "parameters" : { + "additionalProperties" : 0, "properties" : { "node" : { - "format" : "pve-node", "description" : "The cluster node name.", + "format" : "pve-node", "type" : "string" } - }, - "additionalProperties" : 0 + } }, - "name" : "version", "permissions" : { "user" : "all" }, "proxyto" : "node", - "description" : "API version details", - "method" : "GET", "returns" : { - "type" : "object", "properties" : { - "repoid" : { + "release" : { "type" : "string" }, - "release" : { + "repoid" : { "type" : "string" }, "version" : { "type" : "string" } - } + }, + "type" : "object" } } }, - "text" : "version", "leaf" : 1, - "path" : "/nodes/{node}/version" + "path" : "/nodes/{node}/version", + "text" : "version" }, { "info" : { "GET" : { - "method" : "GET", - "returns" : { - "properties" : {}, - "type" : "object" - }, "description" : "Read node status", - "proxyto" : "node", + "method" : "GET", "name" : "status", "parameters" : { + "additionalProperties" : 0, "properties" : { "node" : { - "type" : "string", "description" : "The cluster node name.", - "format" : "pve-node" + "format" : "pve-node", + "type" : "string" } - }, - "additionalProperties" : 0 + } }, "permissions" : { "check" : [ @@ -20015,17 +19974,20 @@ var pveapi = [ "Sys.Audit" ] ] + }, + "proxyto" : "node", + "returns" : { + "properties" : {}, + "type" : "object" } }, "POST" : { + "description" : "Reboot or shutdown a node.", + "method" : "POST", "name" : "node_cmd", "parameters" : { + "additionalProperties" : 0, "properties" : { - "node" : { - "type" : "string", - "description" : "The cluster node name.", - "format" : "pve-node" - }, "command" : { "description" : "Specify the command.", "enum" : [ @@ -20033,12 +19995,14 @@ var pveapi = [ "shutdown" ], "type" : "string" + }, + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" } - }, - "additionalProperties" : 0 + } }, - "protected" : 1, - "method" : "POST", "permissions" : { "check" : [ "perm", @@ -20048,30 +20012,33 @@ var pveapi = [ ] ] }, + "protected" : 1, "proxyto" : "node", - "description" : "Reboot or shutdown a node.", "returns" : { "type" : "null" } } }, - "text" : "status", "leaf" : 1, - "path" : "/nodes/{node}/status" + "path" : "/nodes/{node}/status", + "text" : "status" }, { - "leaf" : 1, - "path" : "/nodes/{node}/netstat", "info" : { "GET" : { - "returns" : { - "type" : "array", - "items" : { - "properties" : {}, - "type" : "object" + "description" : "Read tap/vm network device interface counters", + "method" : "GET", + "name" : "netstat", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + } } }, - "method" : "GET", "permissions" : { "check" : [ "perm", @@ -20081,43 +20048,25 @@ var pveapi = [ ] ] }, - "parameters" : { - "properties" : { - "node" : { - "description" : "The cluster node name.", - "type" : "string", - "format" : "pve-node" - } - }, - "additionalProperties" : 0 - }, - "name" : "netstat", "proxyto" : "node", - "description" : "Read tap/vm network device interface counters" + "returns" : { + "items" : { + "properties" : {}, + "type" : "object" + }, + "type" : "array" + } } }, + "leaf" : 1, + "path" : "/nodes/{node}/netstat", "text" : "netstat" }, { "info" : { "POST" : { - "returns" : { - "properties" : {}, - "type" : "array" - }, - "proxyto" : "node", "description" : "Execute multiple commands in order.", - "permissions" : { - "check" : [ - "perm", - "/nodes/{node}", - [ - "Sys.Audit" - ] - ] - }, "method" : "POST", - "protected" : 1, "name" : "execute", "parameters" : { "additionalProperties" : 0, @@ -20127,30 +20076,60 @@ var pveapi = [ "type" : "string" }, "node" : { + "description" : "The cluster node name.", "format" : "pve-node", - "type" : "string", - "description" : "The cluster node name." + "type" : "string" } } + }, + "permissions" : { + "check" : [ + "perm", + "/nodes/{node}", + [ + "Sys.Audit" + ] + ] + }, + "protected" : 1, + "proxyto" : "node", + "returns" : { + "properties" : {}, + "type" : "array" } } }, - "text" : "execute", "leaf" : 1, - "path" : "/nodes/{node}/execute" + "path" : "/nodes/{node}/execute", + "text" : "execute" }, { - "text" : "rrd", "info" : { "GET" : { + "description" : "Read node RRD statistics (returns PNG)", + "method" : "GET", "name" : "rrd", "parameters" : { "additionalProperties" : 0, "properties" : { + "cf" : { + "description" : "The RRD consolidation function", + "enum" : [ + "AVERAGE", + "MAX" + ], + "optional" : 1, + "type" : "string" + }, "ds" : { - "type" : "string", "description" : "The list of datasources you want to display.", - "format" : "pve-configid-list" + "format" : "pve-configid-list", + "type" : "string" + }, + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" }, "timeframe" : { "description" : "Specify the time frame you are interested in.", @@ -20162,20 +20141,6 @@ var pveapi = [ "year" ], "type" : "string" - }, - "node" : { - "description" : "The cluster node name.", - "type" : "string", - "format" : "pve-node" - }, - "cf" : { - "type" : "string", - "optional" : 1, - "enum" : [ - "AVERAGE", - "MAX" - ], - "description" : "The RRD consolidation function" } } }, @@ -20189,54 +20154,44 @@ var pveapi = [ ] }, "protected" : 1, - "description" : "Read node RRD statistics (returns PNG)", "returns" : { - "type" : "object", "properties" : { "filename" : { "type" : "string" } - } - }, - "method" : "GET" + }, + "type" : "object" + } } }, + "leaf" : 1, "path" : "/nodes/{node}/rrd", - "leaf" : 1 + "text" : "rrd" }, { - "leaf" : 1, - "path" : "/nodes/{node}/rrddata", "info" : { "GET" : { + "description" : "Read node RRD statistics", + "method" : "GET", "name" : "rrddata", - "permissions" : { - "check" : [ - "perm", - "/nodes/{node}", - [ - "Sys.Audit" - ] - ] - }, "parameters" : { + "additionalProperties" : 0, "properties" : { "cf" : { - "optional" : 1, - "type" : "string", "description" : "The RRD consolidation function", "enum" : [ "AVERAGE", "MAX" - ] + ], + "optional" : 1, + "type" : "string" }, "node" : { + "description" : "The cluster node name.", "format" : "pve-node", - "type" : "string", - "description" : "The cluster node name." + "type" : "string" }, "timeframe" : { - "type" : "string", "description" : "Specify the time frame you are interested in.", "enum" : [ "hour", @@ -20244,262 +20199,248 @@ var pveapi = [ "week", "month", "year" - ] + ], + "type" : "string" } - }, - "additionalProperties" : 0 - }, - "protected" : 1, - "description" : "Read node RRD statistics", - "returns" : { - "type" : "array", - "items" : { - "type" : "object", - "properties" : {} } }, - "method" : "GET" - } - }, - "text" : "rrddata" - }, - { - "leaf" : 1, - "path" : "/nodes/{node}/syslog", - "info" : { - "GET" : { - "description" : "Read system log", - "proxyto" : "node", "permissions" : { "check" : [ "perm", "/nodes/{node}", [ - "Sys.Syslog" + "Sys.Audit" ] ] }, + "protected" : 1, "returns" : { "items" : { - "properties" : { - "t" : { - "type" : "string", - "description" : "Line text" - }, - "n" : { - "description" : "Line number", - "type" : "integer" - } - }, + "properties" : {}, "type" : "object" }, "type" : "array" - }, - "protected" : 1, + } + } + }, + "leaf" : 1, + "path" : "/nodes/{node}/rrddata", + "text" : "rrddata" + }, + { + "info" : { + "GET" : { + "description" : "Read system log", + "method" : "GET", + "name" : "syslog", "parameters" : { + "additionalProperties" : 0, "properties" : { - "since" : { + "limit" : { + "minimum" : 0, "optional" : 1, - "type" : "string", - "pattern" : "^\\d{4}-\\d{2}-\\d{2}( \\d{2}:\\d{2}(:\\d{2})?)?$", - "description" : "Display all log since this date-time string." + "type" : "integer" }, "node" : { - "type" : "string", "description" : "The cluster node name.", - "format" : "pve-node" + "format" : "pve-node", + "type" : "string" }, - "limit" : { + "since" : { + "description" : "Display all log since this date-time string.", + "optional" : 1, + "pattern" : "^\\d{4}-\\d{2}-\\d{2}( \\d{2}:\\d{2}(:\\d{2})?)?$", + "type" : "string" + }, + "start" : { "minimum" : 0, "optional" : 1, "type" : "integer" }, "until" : { "description" : "Display all log until this date-time string.", - "pattern" : "^\\d{4}-\\d{2}-\\d{2}( \\d{2}:\\d{2}(:\\d{2})?)?$", "optional" : 1, + "pattern" : "^\\d{4}-\\d{2}-\\d{2}( \\d{2}:\\d{2}(:\\d{2})?)?$", "type" : "string" - }, - "start" : { - "minimum" : 0, - "type" : "integer", - "optional" : 1 } - }, - "additionalProperties" : 0 + } }, - "name" : "syslog", - "method" : "GET" + "permissions" : { + "check" : [ + "perm", + "/nodes/{node}", + [ + "Sys.Syslog" + ] + ] + }, + "protected" : 1, + "proxyto" : "node", + "returns" : { + "items" : { + "properties" : { + "n" : { + "description" : "Line number", + "type" : "integer" + }, + "t" : { + "description" : "Line text", + "type" : "string" + } + }, + "type" : "object" + }, + "type" : "array" + } } }, + "leaf" : 1, + "path" : "/nodes/{node}/syslog", "text" : "syslog" }, { "info" : { "POST" : { - "returns" : { + "description" : "Creates a VNC Shell proxy.", + "method" : "POST", + "name" : "vncshell", + "parameters" : { + "additionalProperties" : 0, "properties" : { - "user" : { - "type" : "string" - }, - "port" : { - "type" : "integer" - }, - "ticket" : { + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", "type" : "string" }, - "upid" : { - "type" : "string" + "upgrade" : { + "default" : 0, + "description" : "Run 'apt-get dist-upgrade' instead of normal shell.", + "optional" : 1, + "type" : "boolean" }, - "cert" : { - "type" : "string" + "websocket" : { + "description" : "use websocket instead of standard vnc.", + "optional" : 1, + "type" : "boolean" } - }, - "additionalProperties" : 0 + } }, - "method" : "POST", "permissions" : { - "description" : "Restricted to users on realm 'pam'", "check" : [ "perm", "/nodes/{node}", [ "Sys.Console" ] - ] + ], + "description" : "Restricted to users on realm 'pam'" }, - "parameters" : { + "protected" : 1, + "returns" : { + "additionalProperties" : 0, "properties" : { - "upgrade" : { - "description" : "Run 'apt-get dist-upgrade' instead of normal shell.", - "default" : 0, - "type" : "boolean", - "optional" : 1 + "cert" : { + "type" : "string" }, - "node" : { - "type" : "string", - "description" : "The cluster node name.", - "format" : "pve-node" + "port" : { + "type" : "integer" }, - "websocket" : { - "optional" : 1, - "type" : "boolean", - "description" : "use websocket instead of standard vnc." + "ticket" : { + "type" : "string" + }, + "upid" : { + "type" : "string" + }, + "user" : { + "type" : "string" } - }, - "additionalProperties" : 0 - }, - "name" : "vncshell", - "protected" : 1, - "description" : "Creates a VNC Shell proxy." + } + } } }, - "text" : "vncshell", "leaf" : 1, - "path" : "/nodes/{node}/vncshell" + "path" : "/nodes/{node}/vncshell", + "text" : "vncshell" }, { - "text" : "vncwebsocket", "info" : { "GET" : { - "method" : "GET", - "returns" : { - "properties" : { - "port" : { - "type" : "string" - } - }, - "type" : "object" - }, "description" : "Opens a weksocket for VNC traffic.", + "method" : "GET", + "name" : "vncwebsocket", "parameters" : { + "additionalProperties" : 0, "properties" : { - "vncticket" : { - "maxLength" : 512, - "description" : "Ticket from previous call to vncproxy.", - "type" : "string" - }, "node" : { - "format" : "pve-node", "description" : "The cluster node name.", + "format" : "pve-node", "type" : "string" }, "port" : { - "minimum" : 5900, "description" : "Port number returned by previous vncproxy call.", "maximum" : 5999, + "minimum" : 5900, "type" : "integer" + }, + "vncticket" : { + "description" : "Ticket from previous call to vncproxy.", + "maxLength" : 512, + "type" : "string" } - }, - "additionalProperties" : 0 + } }, - "name" : "vncwebsocket", "permissions" : { - "description" : "Restricted to users on realm 'pam'. You also need to pass a valid ticket (vncticket).", "check" : [ "perm", "/nodes/{node}", [ "Sys.Console" ] - ] + ], + "description" : "Restricted to users on realm 'pam'. You also need to pass a valid ticket (vncticket)." + }, + "returns" : { + "properties" : { + "port" : { + "type" : "string" + } + }, + "type" : "object" } } }, + "leaf" : 1, "path" : "/nodes/{node}/vncwebsocket", - "leaf" : 1 + "text" : "vncwebsocket" }, { "info" : { "POST" : { + "description" : "Creates a SPICE shell.", "method" : "POST", - "protected" : 1, + "name" : "spiceshell", "parameters" : { "additionalProperties" : 0, "properties" : { - "upgrade" : { - "description" : "Run 'apt-get dist-upgrade' instead of normal shell.", - "default" : 0, - "type" : "boolean", - "optional" : 1 - }, - "proxy" : { - "format" : "address", - "optional" : 1, - "type" : "string", - "description" : "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 resonable setting is to use same node you use to connect to the API (This is window.location.hostname for the JS GUI)." - }, "node" : { + "description" : "The cluster node name.", "format" : "pve-node", - "type" : "string", - "description" : "The cluster node name." - } - } - }, - "name" : "spiceshell", - "returns" : { - "description" : "Returned values can be directly passed to the 'remote-viewer' application.", - "additionalProperties" : 1, - "properties" : { - "proxy" : { - "type" : "string" - }, - "tls-port" : { - "type" : "integer" - }, - "password" : { "type" : "string" }, - "type" : { + "proxy" : { + "description" : "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 resonable setting is to use same node you use to connect to the API (This is window.location.hostname for the JS GUI).", + "format" : "address", + "optional" : 1, "type" : "string" }, - "host" : { - "type" : "string" + "upgrade" : { + "default" : 0, + "description" : "Run 'apt-get dist-upgrade' instead of normal shell.", + "optional" : 1, + "type" : "boolean" } } }, - "proxyto" : "node", - "description" : "Creates a SPICE shell.", "permissions" : { "check" : [ "perm", @@ -20509,47 +20450,52 @@ var pveapi = [ ] ], "description" : "Restricted to users on realm 'pam'" + }, + "protected" : 1, + "proxyto" : "node", + "returns" : { + "additionalProperties" : 1, + "description" : "Returned values can be directly passed to the 'remote-viewer' application.", + "properties" : { + "host" : { + "type" : "string" + }, + "password" : { + "type" : "string" + }, + "proxy" : { + "type" : "string" + }, + "tls-port" : { + "type" : "integer" + }, + "type" : { + "type" : "string" + } + } } } }, - "text" : "spiceshell", "leaf" : 1, - "path" : "/nodes/{node}/spiceshell" + "path" : "/nodes/{node}/spiceshell", + "text" : "spiceshell" }, { - "path" : "/nodes/{node}/dns", - "leaf" : 1, - "text" : "dns", "info" : { "GET" : { + "description" : "Read DNS settings.", "method" : "GET", - "returns" : { - "type" : "object", + "name" : "dns", + "parameters" : { "additionalProperties" : 0, "properties" : { - "search" : { - "description" : "Search domain for host-name lookup.", - "type" : "string", - "optional" : 1 - }, - "dns3" : { - "optional" : 1, - "type" : "string", - "description" : "Third name server IP address." - }, - "dns2" : { - "description" : "Second name server IP address.", - "type" : "string", - "optional" : 1 - }, - "dns1" : { - "type" : "string", - "optional" : 1, - "description" : "First name server IP address." + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" } } }, - "name" : "dns", "permissions" : { "check" : [ "perm", @@ -20559,55 +20505,70 @@ var pveapi = [ ] ] }, - "parameters" : { + "proxyto" : "node", + "returns" : { "additionalProperties" : 0, "properties" : { - "node" : { - "format" : "pve-node", - "type" : "string", - "description" : "The cluster node name." + "dns1" : { + "description" : "First name server IP address.", + "optional" : 1, + "type" : "string" + }, + "dns2" : { + "description" : "Second name server IP address.", + "optional" : 1, + "type" : "string" + }, + "dns3" : { + "description" : "Third name server IP address.", + "optional" : 1, + "type" : "string" + }, + "search" : { + "description" : "Search domain for host-name lookup.", + "optional" : 1, + "type" : "string" } - } - }, - "description" : "Read DNS settings.", - "proxyto" : "node" + }, + "type" : "object" + } }, "PUT" : { + "description" : "Write DNS settings.", + "method" : "PUT", "name" : "update_dns", "parameters" : { "additionalProperties" : 0, "properties" : { - "search" : { - "description" : "Search domain for host-name lookup.", + "dns1" : { + "description" : "First name server IP address.", + "format" : "ip", + "optional" : 1, "type" : "string" }, - "dns3" : { - "description" : "Third name server IP address.", - "type" : "string", + "dns2" : { + "description" : "Second name server IP address.", + "format" : "ip", "optional" : 1, - "format" : "ip" + "type" : "string" }, - "dns2" : { - "type" : "string", + "dns3" : { + "description" : "Third name server IP address.", + "format" : "ip", "optional" : 1, - "description" : "Second name server IP address.", - "format" : "ip" + "type" : "string" }, "node" : { + "description" : "The cluster node name.", "format" : "pve-node", - "type" : "string", - "description" : "The cluster node name." + "type" : "string" }, - "dns1" : { - "description" : "First name server IP address.", - "optional" : 1, - "type" : "string", - "format" : "ip" + "search" : { + "description" : "Search domain for host-name lookup.", + "type" : "string" } } }, - "protected" : 1, - "method" : "PUT", "permissions" : { "check" : [ "perm", @@ -20617,51 +20578,33 @@ var pveapi = [ ] ] }, - "description" : "Write DNS settings.", + "protected" : 1, "proxyto" : "node", "returns" : { "type" : "null" } } - } + }, + "leaf" : 1, + "path" : "/nodes/{node}/dns", + "text" : "dns" }, { "info" : { "GET" : { - "method" : "GET", - "returns" : { - "properties" : { - "localtime" : { - "minimum" : 1297163644, - "type" : "integer", - "description" : "Seconds since 1970-01-01 00:00:00 (local time)" - }, - "time" : { - "minimum" : 1297163644, - "type" : "integer", - "description" : "Seconds since 1970-01-01 00:00:00 UTC." - }, - "timezone" : { - "type" : "string", - "description" : "Time zone" - } - }, - "type" : "object", - "additionalProperties" : 0 - }, - "proxyto" : "node", "description" : "Read server time and time zone settings.", + "method" : "GET", + "name" : "time", "parameters" : { + "additionalProperties" : 0, "properties" : { "node" : { + "description" : "The cluster node name.", "format" : "pve-node", - "type" : "string", - "description" : "The cluster node name." + "type" : "string" } - }, - "additionalProperties" : 0 + } }, - "name" : "time", "permissions" : { "check" : [ "perm", @@ -20670,14 +20613,47 @@ var pveapi = [ "Sys.Audit" ] ] + }, + "proxyto" : "node", + "returns" : { + "additionalProperties" : 0, + "properties" : { + "localtime" : { + "description" : "Seconds since 1970-01-01 00:00:00 (local time)", + "minimum" : 1297163644, + "type" : "integer" + }, + "time" : { + "description" : "Seconds since 1970-01-01 00:00:00 UTC.", + "minimum" : 1297163644, + "type" : "integer" + }, + "timezone" : { + "description" : "Time zone", + "type" : "string" + } + }, + "type" : "object" } }, "PUT" : { - "returns" : { - "type" : "null" - }, "description" : "Set time zone.", - "proxyto" : "node", + "method" : "PUT", + "name" : "set_timezone", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, + "timezone" : { + "description" : "Time zone. The file '/usr/share/zoneinfo/zone.tab' contains the list of valid names.", + "type" : "string" + } + } + }, "permissions" : { "check" : [ "perm", @@ -20687,117 +20663,105 @@ var pveapi = [ ] ] }, - "method" : "PUT", "protected" : 1, - "parameters" : { - "properties" : { - "timezone" : { - "type" : "string", - "description" : "Time zone. The file '/usr/share/zoneinfo/zone.tab' contains the list of valid names." - }, - "node" : { - "description" : "The cluster node name.", - "type" : "string", - "format" : "pve-node" - } - }, - "additionalProperties" : 0 - }, - "name" : "set_timezone" + "proxyto" : "node", + "returns" : { + "type" : "null" + } } }, - "text" : "time", "leaf" : 1, - "path" : "/nodes/{node}/time" + "path" : "/nodes/{node}/time", + "text" : "time" }, { "info" : { - "POST" : { - "protected" : 1, - "name" : "apl_download", + "GET" : { + "description" : "Get list of appliances.", + "method" : "GET", + "name" : "aplinfo", "parameters" : { "additionalProperties" : 0, "properties" : { - "storage" : { - "description" : "Only list status for specified storage", - "type" : "string", - "format" : "pve-storage-id" - }, "node" : { + "description" : "The cluster node name.", "format" : "pve-node", - "type" : "string", - "description" : "The cluster node name." - }, - "template" : { - "type" : "string", - "description" : "The template wich will downloaded", - "maxLength" : 255 + "type" : "string" } } }, - "method" : "POST", - "proxyto" : "node", - "description" : "Download appliance templates.", "permissions" : { - "check" : [ - "perm", - "/storage/{storage}", - [ - "Datastore.AllocateTemplate" - ] - ] + "user" : "all" }, - "returns" : { - "type" : "string" - } - }, - "GET" : { + "proxyto" : "node", "returns" : { "items" : { - "type" : "object", - "properties" : {} + "properties" : {}, + "type" : "object" }, "type" : "array" - }, - "method" : "GET", - "description" : "Get list of appliances.", - "proxyto" : "node", + } + }, + "POST" : { + "description" : "Download appliance templates.", + "method" : "POST", + "name" : "apl_download", "parameters" : { "additionalProperties" : 0, "properties" : { "node" : { - "format" : "pve-node", "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, + "storage" : { + "description" : "Only list status for specified storage", + "format" : "pve-storage-id", + "type" : "string" + }, + "template" : { + "description" : "The template wich will downloaded", + "maxLength" : 255, "type" : "string" } } }, - "name" : "aplinfo", "permissions" : { - "user" : "all" + "check" : [ + "perm", + "/storage/{storage}", + [ + "Datastore.AllocateTemplate" + ] + ] + }, + "protected" : 1, + "proxyto" : "node", + "returns" : { + "type" : "string" } } }, - "text" : "aplinfo", "leaf" : 1, - "path" : "/nodes/{node}/aplinfo" + "path" : "/nodes/{node}/aplinfo", + "text" : "aplinfo" }, { "info" : { "GET" : { + "description" : "Gather various systems information about a node", + "method" : "GET", + "name" : "report", "parameters" : { + "additionalProperties" : 0, "properties" : { "node" : { - "format" : "pve-node", "description" : "The cluster node name.", + "format" : "pve-node", "type" : "string" } - }, - "additionalProperties" : 0 + } }, - "name" : "report", - "protected" : 1, - "method" : "GET", "permissions" : { "check" : [ "perm", @@ -20807,44 +20771,38 @@ var pveapi = [ ] ] }, - "description" : "Gather various systems information about a node", + "protected" : 1, "proxyto" : "node", "returns" : { "type" : "string" } } }, - "text" : "report", "leaf" : 1, - "path" : "/nodes/{node}/report" + "path" : "/nodes/{node}/report", + "text" : "report" }, { - "text" : "startall", "info" : { "POST" : { + "description" : "Start all VMs and containers (when onboot=1).", "method" : "POST", - "protected" : 1, + "name" : "startall", "parameters" : { + "additionalProperties" : 0, "properties" : { "force" : { + "description" : "force if onboot=0.", "optional" : 1, - "type" : "boolean", - "description" : "force if onboot=0." + "type" : "boolean" }, "node" : { - "type" : "string", "description" : "The cluster node name.", - "format" : "pve-node" + "format" : "pve-node", + "type" : "string" } - }, - "additionalProperties" : 0 - }, - "name" : "startall", - "returns" : { - "type" : "string" + } }, - "proxyto" : "node", - "description" : "Start all VMs and containers (when onboot=1).", "permissions" : { "check" : [ "perm", @@ -20853,446 +20811,188 @@ var pveapi = [ "VM.PowerMgmt" ] ] + }, + "protected" : 1, + "proxyto" : "node", + "returns" : { + "type" : "string" } } }, + "leaf" : 1, "path" : "/nodes/{node}/startall", - "leaf" : 1 + "text" : "startall" }, { - "text" : "stopall", "info" : { "POST" : { "description" : "Stop all VMs and Containers.", - "proxyto" : "node", - "permissions" : { - "check" : [ - "perm", - "/", - [ - "VM.PowerMgmt" - ] - ] - }, - "returns" : { - "type" : "string" - }, - "protected" : 1, + "method" : "POST", + "name" : "stopall", "parameters" : { + "additionalProperties" : 0, "properties" : { "node" : { + "description" : "The cluster node name.", "format" : "pve-node", - "type" : "string", - "description" : "The cluster node name." + "type" : "string" } - }, - "additionalProperties" : 0 - }, - "name" : "stopall", - "method" : "POST" - } - }, - "path" : "/nodes/{node}/stopall", - "leaf" : 1 - }, - { - "info" : { - "POST" : { - "returns" : { - "type" : "string" + } }, "permissions" : { "check" : [ "perm", "/", [ - "VM.Migrate" + "VM.PowerMgmt" ] ] }, + "protected" : 1, "proxyto" : "node", - "description" : "Migrate all VMs and Containers.", - "method" : "POST", - "parameters" : { - "properties" : { - "maxworkers" : { - "optional" : 1, - "type" : "integer", - "description" : "Maximal number of parallel migration job. If not set use 'max_workers' from datacenter.cfg, one of both must be set!", - "minimum" : 1 - }, - "node" : { - "description" : "The cluster node name.", - "type" : "string", - "format" : "pve-node" - }, - "target" : { - "description" : "Target node.", - "type" : "string", - "format" : "pve-node" - } - }, - "additionalProperties" : 0 - }, - "name" : "migrateall", - "protected" : 1 - } - }, - "text" : "migrateall", - "leaf" : 1, - "path" : "/nodes/{node}/migrateall" - } - ], - "text" : "{node}", - "leaf" : 0, - "path" : "/nodes/{node}" - } - ], - "info" : { - "GET" : { - "permissions" : { - "user" : "all" - }, - "parameters" : { - "additionalProperties" : 0 - }, - "name" : "index", - "description" : "Cluster node index.", - "method" : "GET", - "returns" : { - "links" : [ - { - "href" : "{node}", - "rel" : "child" - } - ], - "items" : { - "properties" : {}, - "type" : "object" - }, - "type" : "array" - } - } - } - }, - { - "info" : { - "POST" : { - "returns" : { - "type" : "null" - }, - "method" : "POST", - "description" : "Create a new storage.", - "protected" : 1, - "name" : "create", - "parameters" : { - "additionalProperties" : 0, - "type" : "object", - "properties" : { - "volume" : { - "description" : "Glusterfs Volume.", - "type" : "string", - "optional" : 1 - }, - "sparse" : { - "description" : "use sparse volumes", - "type" : "boolean", - "optional" : 1 - }, - "type" : { - "description" : "Storage type.", - "enum" : [ - "zfspool", - "lvm", - "iscsi", - "rbd", - "dir", - "iscsidirect", - "nfs", - "glusterfs", - "zfs", - "lvmthin", - "sheepdog", - "drbd" - ], - "type" : "string" - }, - "iscsiprovider" : { - "description" : "iscsi provider", - "type" : "string", - "optional" : 1 - }, - "saferemove" : { - "optional" : 1, - "type" : "boolean", - "description" : "Zero-out data when removing LVs." - }, - "storage" : { - "type" : "string", - "description" : "The storage identifier.", - "format" : "pve-storage-id" - }, - "redundancy" : { - "minimum" : 1, - "optional" : 1, - "type" : "integer", - "maximum" : 16, - "default" : 2, - "description" : "The redundancy count specifies the number of nodes to which the resource should be deployed. It must be at least 1 and at most the number of nodes in the cluster." - }, - "pool" : { - "type" : "string", - "optional" : 1, - "description" : "Pool." - }, - "path" : { - "description" : "File system path.", - "optional" : 1, - "type" : "string", - "format" : "pve-storage-path" - }, - "server" : { - "optional" : 1, - "type" : "string", - "description" : "Server IP or DNS name.", - "format" : "pve-storage-server" - }, - "comstar_tg" : { - "optional" : 1, - "type" : "string", - "description" : "target group for comstar views" - }, - "saferemove_throughput" : { - "type" : "string", - "optional" : 1, - "description" : "Wipe throughput (cstream -t parameter value)." - }, - "maxfiles" : { - "type" : "integer", - "optional" : 1, - "description" : "Maximal number of backup files per VM. Use '0' for unlimted.", - "minimum" : 0 - }, - "options" : { - "type" : "string", - "optional" : 1, - "description" : "NFS mount options (see 'man nfs')", - "format" : "pve-storage-options" - }, - "comstar_hg" : { - "optional" : 1, - "type" : "string", - "description" : "host group for comstar views" - }, - "username" : { - "description" : "RBD Id.", - "type" : "string", - "optional" : 1 - }, - "authsupported" : { - "optional" : 1, - "type" : "string", - "description" : "Authsupported." - }, - "server2" : { - "description" : "Backup volfile server IP or DNS name.", - "requires" : "server", - "type" : "string", - "optional" : 1, - "format" : "pve-storage-server" - }, - "content" : { - "format" : "pve-storage-content-list", - "optional" : 1, - "type" : "string", - "description" : "Allowed content types.\n\nNOTE: the value 'rootdir' is used for Containers, and value 'images' for VMs.\n" - }, - "base" : { - "description" : "Base volume. This volume is automatically activated.", - "type" : "string", - "optional" : 1, - "format" : "pve-volume-id" - }, - "monhost" : { - "description" : "Monitors daemon ips.", - "optional" : 1, - "type" : "string" - }, - "format" : { - "optional" : 1, - "type" : "string", - "description" : "Default image format.", - "format" : "pve-storage-format" - }, - "nowritecache" : { - "type" : "boolean", - "optional" : 1, - "description" : "disable write caching on the target" - }, - "target" : { - "description" : "iSCSI target.", - "type" : "string", - "optional" : 1 + "returns" : { + "type" : "string" + } + } }, - "thinpool" : { - "type" : "string", - "optional" : 1, - "description" : "LVM thin pool LV name.", - "format" : "pve-storage-vgname" + "leaf" : 1, + "path" : "/nodes/{node}/stopall", + "text" : "stopall" + }, + { + "info" : { + "POST" : { + "description" : "Migrate all VMs and Containers.", + "method" : "POST", + "name" : "migrateall", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "maxworkers" : { + "description" : "Maximal number of parallel migration job. If not set use 'max_workers' from datacenter.cfg, one of both must be set!", + "minimum" : 1, + "optional" : 1, + "type" : "integer" + }, + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + }, + "target" : { + "description" : "Target node.", + "format" : "pve-node", + "type" : "string" + } + } + }, + "permissions" : { + "check" : [ + "perm", + "/", + [ + "VM.Migrate" + ] + ] + }, + "protected" : 1, + "proxyto" : "node", + "returns" : { + "type" : "string" + } + } }, - "krbd" : { - "type" : "boolean", - "optional" : 1, - "description" : "Access rbd through krbd kernel module." + "leaf" : 1, + "path" : "/nodes/{node}/migrateall", + "text" : "migrateall" + } + ], + "info" : { + "GET" : { + "description" : "Node index.", + "method" : "GET", + "name" : "index", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "node" : { + "description" : "The cluster node name.", + "format" : "pve-node", + "type" : "string" + } + } }, - "shared" : { - "description" : "Mark storage as shared.", - "optional" : 1, - "type" : "boolean" + "permissions" : { + "user" : "all" }, - "transport" : { - "enum" : [ - "tcp", - "rdma", - "unix" + "returns" : { + "items" : { + "properties" : {}, + "type" : "object" + }, + "links" : [ + { + "href" : "{name}", + "rel" : "child" + } ], - "description" : "Gluster transport: tcp or rdma", - "optional" : 1, - "type" : "string" - }, - "vgname" : { - "description" : "Volume group name.", - "optional" : 1, - "type" : "string", - "format" : "pve-storage-vgname" - }, - "blocksize" : { - "optional" : 1, - "type" : "string", - "description" : "block size" - }, - "export" : { - "optional" : 1, - "type" : "string", - "description" : "NFS export path.", - "format" : "pve-storage-path" - }, - "portal" : { - "type" : "string", - "optional" : 1, - "description" : "iSCSI portal (IP or DNS name with optional port).", - "format" : "pve-storage-portal-dns" - }, - "nodes" : { - "format" : "pve-node-list", - "description" : "List of cluster node names.", - "type" : "string", - "optional" : 1 - }, - "disable" : { - "type" : "boolean", - "optional" : 1, - "description" : "Flag to disable the storage." + "type" : "array" } } }, - "permissions" : { - "check" : [ - "perm", - "/storage", - [ - "Datastore.Allocate" - ] - ] - } - }, + "leaf" : 0, + "path" : "/nodes/{node}", + "text" : "{node}" + } + ], + "info" : { "GET" : { - "returns" : { - "type" : "array", - "items" : { - "type" : "object", - "properties" : { - "storage" : { - "type" : "string" - } - } - }, - "links" : [ - { - "rel" : "child", - "href" : "{storage}" - } - ] - }, + "description" : "Cluster node index.", "method" : "GET", + "name" : "index", "parameters" : { - "properties" : { - "type" : { - "type" : "string", - "optional" : 1, - "description" : "Only list storage of specific type", - "enum" : [ - "zfspool", - "lvm", - "iscsi", - "rbd", - "dir", - "iscsidirect", - "nfs", - "glusterfs", - "zfs", - "lvmthin", - "sheepdog", - "drbd" - ] - } - }, "additionalProperties" : 0 }, "permissions" : { - "description" : "Only list entries where you have 'Datastore.Audit' or 'Datastore.AllocateSpace' permissions on '/storage/'", "user" : "all" }, - "name" : "index", - "description" : "Storage index." + "returns" : { + "items" : { + "properties" : {}, + "type" : "object" + }, + "links" : [ + { + "href" : "{node}", + "rel" : "child" + } + ], + "type" : "array" + } } }, - "text" : "storage", + "leaf" : 0, + "path" : "/nodes", + "text" : "nodes" + }, + { "children" : [ { - "leaf" : 1, - "path" : "/storage/{storage}", "info" : { - "GET" : { - "name" : "read", - "permissions" : { - "check" : [ - "perm", - "/storage/{storage}", - [ - "Datastore.Allocate" - ] - ] - }, + "DELETE" : { + "description" : "Delete storage configuration.", + "method" : "DELETE", + "name" : "delete", "parameters" : { "additionalProperties" : 0, "properties" : { "storage" : { - "format" : "pve-storage-id", "description" : "The storage identifier.", + "format" : "pve-storage-id", "type" : "string" } } }, - "description" : "Read storage configuration.", - "returns" : {}, - "method" : "GET" - }, - "DELETE" : { - "returns" : { - "type" : "null" - }, - "method" : "DELETE", "permissions" : { "check" : [ "perm", @@ -21302,596 +21002,813 @@ var pveapi = [ ] ] }, + "protected" : 1, + "returns" : { + "type" : "null" + } + }, + "GET" : { + "description" : "Read storage configuration.", + "method" : "GET", + "name" : "read", "parameters" : { "additionalProperties" : 0, "properties" : { "storage" : { + "description" : "The storage identifier.", "format" : "pve-storage-id", - "type" : "string", - "description" : "The storage identifier." + "type" : "string" } } }, - "name" : "delete", - "protected" : 1, - "description" : "Delete storage configuration." + "permissions" : { + "check" : [ + "perm", + "/storage/{storage}", + [ + "Datastore.Allocate" + ] + ] + }, + "returns" : {} }, "PUT" : { - "method" : "PUT", - "returns" : { - "type" : "null" - }, - "parameters" : { - "additionalProperties" : 0, - "type" : "object", - "properties" : { - "delete" : { - "maxLength" : 4096, - "format" : "pve-configid-list", - "optional" : 1, - "type" : "string", - "description" : "A list of settings you want to delete." - }, - "transport" : { - "type" : "string", - "optional" : 1, - "enum" : [ - "tcp", - "rdma", - "unix" - ], - "description" : "Gluster transport: tcp or rdma" - }, - "shared" : { - "description" : "Mark storage as shared.", - "type" : "boolean", - "optional" : 1 - }, - "krbd" : { + "description" : "Update storage configuration.", + "method" : "PUT", + "name" : "update", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "blocksize" : { + "description" : "block size", "optional" : 1, - "type" : "boolean", - "description" : "Access rbd through krbd kernel module." + "type" : "string" }, - "pool" : { - "description" : "Pool.", - "type" : "string", - "optional" : 1 + "comstar_hg" : { + "description" : "host group for comstar views", + "optional" : 1, + "type" : "string" }, - "redundancy" : { - "description" : "The redundancy count specifies the number of nodes to which the resource should be deployed. It must be at least 1 and at most the number of nodes in the cluster.", - "type" : "integer", + "comstar_tg" : { + "description" : "target group for comstar views", "optional" : 1, - "maximum" : 16, - "default" : 2, - "minimum" : 1 + "type" : "string" }, - "server" : { - "description" : "Server IP or DNS name.", - "type" : "string", + "content" : { + "description" : "Allowed content types.\n\nNOTE: the value 'rootdir' is used for Containers, and value 'images' for VMs.\n", + "format" : "pve-storage-content-list", "optional" : 1, - "format" : "pve-storage-server" + "type" : "string" }, - "saferemove" : { - "type" : "boolean", + "delete" : { + "description" : "A list of settings you want to delete.", + "format" : "pve-configid-list", + "maxLength" : 4096, "optional" : 1, - "description" : "Zero-out data when removing LVs." + "type" : "string" }, "digest" : { + "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", "maxLength" : 40, - "type" : "string", "optional" : 1, - "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications." - }, - "storage" : { - "format" : "pve-storage-id", - "description" : "The storage identifier.", "type" : "string" }, - "sparse" : { - "description" : "use sparse volumes", - "type" : "boolean", - "optional" : 1 - }, - "nowritecache" : { - "description" : "disable write caching on the target", - "type" : "boolean", - "optional" : 1 + "disable" : { + "description" : "Flag to disable the storage.", + "optional" : 1, + "type" : "boolean" }, "format" : { "description" : "Default image format.", + "format" : "pve-storage-format", "optional" : 1, - "type" : "string", - "format" : "pve-storage-format" - }, - "content" : { - "format" : "pve-storage-content-list", - "description" : "Allowed content types.\n\nNOTE: the value 'rootdir' is used for Containers, and value 'images' for VMs.\n", - "type" : "string", - "optional" : 1 + "type" : "string" }, - "server2" : { - "format" : "pve-storage-server", - "type" : "string", + "krbd" : { + "description" : "Access rbd through krbd kernel module.", "optional" : 1, - "description" : "Backup volfile server IP or DNS name.", - "requires" : "server" + "type" : "boolean" }, - "disable" : { - "description" : "Flag to disable the storage.", - "type" : "boolean", - "optional" : 1 + "maxfiles" : { + "description" : "Maximal number of backup files per VM. Use '0' for unlimted.", + "minimum" : 0, + "optional" : 1, + "type" : "integer" }, "nodes" : { + "description" : "List of cluster node names.", "format" : "pve-node-list", "optional" : 1, - "type" : "string", - "description" : "List of cluster node names." + "type" : "string" }, - "comstar_hg" : { - "type" : "string", + "nowritecache" : { + "description" : "disable write caching on the target", "optional" : 1, - "description" : "host group for comstar views" + "type" : "boolean" }, "options" : { - "format" : "pve-storage-options", "description" : "NFS mount options (see 'man nfs')", - "type" : "string", - "optional" : 1 + "format" : "pve-storage-options", + "optional" : 1, + "type" : "string" + }, + "pool" : { + "description" : "Pool.", + "optional" : 1, + "type" : "string" + }, + "redundancy" : { + "default" : 2, + "description" : "The redundancy count specifies the number of nodes to which the resource should be deployed. It must be at least 1 and at most the number of nodes in the cluster.", + "maximum" : 16, + "minimum" : 1, + "optional" : 1, + "type" : "integer" + }, + "saferemove" : { + "description" : "Zero-out data when removing LVs.", + "optional" : 1, + "type" : "boolean" }, "saferemove_throughput" : { + "description" : "Wipe throughput (cstream -t parameter value).", "optional" : 1, - "type" : "string", - "description" : "Wipe throughput (cstream -t parameter value)." + "type" : "string" }, - "maxfiles" : { - "minimum" : 0, - "type" : "integer", + "server" : { + "description" : "Server IP or DNS name.", + "format" : "pve-storage-server", "optional" : 1, - "description" : "Maximal number of backup files per VM. Use '0' for unlimted." + "type" : "string" }, - "blocksize" : { + "server2" : { + "description" : "Backup volfile server IP or DNS name.", + "format" : "pve-storage-server", "optional" : 1, - "type" : "string", - "description" : "block size" + "requires" : "server", + "type" : "string" + }, + "shared" : { + "description" : "Mark storage as shared.", + "optional" : 1, + "type" : "boolean" + }, + "sparse" : { + "description" : "use sparse volumes", + "optional" : 1, + "type" : "boolean" + }, + "storage" : { + "description" : "The storage identifier.", + "format" : "pve-storage-id", + "type" : "string" + }, + "transport" : { + "description" : "Gluster transport: tcp or rdma", + "enum" : [ + "tcp", + "rdma", + "unix" + ], + "optional" : 1, + "type" : "string" }, "username" : { "description" : "RBD Id.", - "type" : "string", - "optional" : 1 - }, - "comstar_tg" : { - "description" : "target group for comstar views", - "type" : "string", - "optional" : 1 + "optional" : 1, + "type" : "string" } + }, + "type" : "object" + }, + "permissions" : { + "check" : [ + "perm", + "/storage", + [ + "Datastore.Allocate" + ] + ] + }, + "protected" : 1, + "returns" : { + "type" : "null" + } + } + }, + "leaf" : 1, + "path" : "/storage/{storage}", + "text" : "{storage}" + } + ], + "info" : { + "GET" : { + "description" : "Storage index.", + "method" : "GET", + "name" : "index", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "type" : { + "description" : "Only list storage of specific type", + "enum" : [ + "dir", + "drbd", + "glusterfs", + "iscsi", + "iscsidirect", + "lvm", + "lvmthin", + "nfs", + "rbd", + "sheepdog", + "zfs", + "zfspool" + ], + "optional" : 1, + "type" : "string" + } + } + }, + "permissions" : { + "description" : "Only list entries where you have 'Datastore.Audit' or 'Datastore.AllocateSpace' permissions on '/storage/'", + "user" : "all" + }, + "returns" : { + "items" : { + "properties" : { + "storage" : { + "type" : "string" } }, - "permissions" : { - "check" : [ - "perm", - "/storage", - [ - "Datastore.Allocate" - ] - ] + "type" : "object" + }, + "links" : [ + { + "href" : "{storage}", + "rel" : "child" + } + ], + "type" : "array" + } + }, + "POST" : { + "description" : "Create a new storage.", + "method" : "POST", + "name" : "create", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "authsupported" : { + "description" : "Authsupported.", + "optional" : 1, + "type" : "string" + }, + "base" : { + "description" : "Base volume. This volume is automatically activated.", + "format" : "pve-volume-id", + "optional" : 1, + "type" : "string" + }, + "blocksize" : { + "description" : "block size", + "optional" : 1, + "type" : "string" + }, + "comstar_hg" : { + "description" : "host group for comstar views", + "optional" : 1, + "type" : "string" + }, + "comstar_tg" : { + "description" : "target group for comstar views", + "optional" : 1, + "type" : "string" + }, + "content" : { + "description" : "Allowed content types.\n\nNOTE: the value 'rootdir' is used for Containers, and value 'images' for VMs.\n", + "format" : "pve-storage-content-list", + "optional" : 1, + "type" : "string" + }, + "disable" : { + "description" : "Flag to disable the storage.", + "optional" : 1, + "type" : "boolean" + }, + "export" : { + "description" : "NFS export path.", + "format" : "pve-storage-path", + "optional" : 1, + "type" : "string" + }, + "format" : { + "description" : "Default image format.", + "format" : "pve-storage-format", + "optional" : 1, + "type" : "string" + }, + "iscsiprovider" : { + "description" : "iscsi provider", + "optional" : 1, + "type" : "string" + }, + "krbd" : { + "description" : "Access rbd through krbd kernel module.", + "optional" : 1, + "type" : "boolean" }, - "name" : "update", - "description" : "Update storage configuration.", - "protected" : 1 - } - }, - "text" : "{storage}" - } - ], - "leaf" : 0, - "path" : "/storage" - }, - { - "leaf" : 0, - "path" : "/access", - "info" : { - "GET" : { - "method" : "GET", - "returns" : { - "type" : "array", - "links" : [ - { - "href" : "{subdir}", - "rel" : "child" - } - ], - "items" : { - "properties" : { - "subdir" : { - "type" : "string" - } + "maxfiles" : { + "description" : "Maximal number of backup files per VM. Use '0' for unlimted.", + "minimum" : 0, + "optional" : 1, + "type" : "integer" }, - "type" : "object" - } - }, - "name" : "index", - "permissions" : { - "user" : "all" - }, - "parameters" : { - "additionalProperties" : 0 - }, - "description" : "Directory index." - } - }, - "text" : "access", - "children" : [ - { - "info" : { - "POST" : { - "method" : "POST", - "returns" : { - "type" : "null" + "monhost" : { + "description" : "Monitors daemon ips.", + "optional" : 1, + "type" : "string" }, - "protected" : 1, - "description" : "Create new user.", - "name" : "create_user", - "permissions" : { - "check" : [ - "and", - [ - "userid-param", - "Realm.AllocateUser" - ], - [ - "userid-group", - [ - "User.Modify" - ], - "groups_param", - 1 - ] - ], - "description" : "You need 'Realm.AllocateUser' on '/access/realm/' on the realm of user , and 'User.Modify' permissions to '/access/groups/' for any group specified (or 'User.Modify' on '/access/groups' if you pass no groups." + "nodes" : { + "description" : "List of cluster node names.", + "format" : "pve-node-list", + "optional" : 1, + "type" : "string" }, - "parameters" : { - "properties" : { - "enable" : { - "type" : "boolean", - "optional" : 1, - "default" : 1, - "description" : "Enable the account (default). You can set this to '0' to disable the accout" - }, - "lastname" : { - "type" : "string", - "optional" : 1 - }, - "keys" : { - "optional" : 1, - "type" : "string", - "description" : "Keys for two factor auth (yubico)." - }, - "firstname" : { - "optional" : 1, - "type" : "string" - }, - "groups" : { - "optional" : 1, - "type" : "string", - "format" : "pve-groupid-list" - }, - "password" : { - "optional" : 1, - "type" : "string", - "description" : "Initial password.", - "minLength" : 5, - "maxLength" : 64 - }, - "email" : { - "format" : "email-opt", - "optional" : 1, - "type" : "string" - }, - "comment" : { - "type" : "string", - "optional" : 1 - }, - "userid" : { - "type" : "string", - "description" : "User ID", - "format" : "pve-userid", - "maxLength" : 64 - }, - "expire" : { - "minimum" : 0, - "description" : "Account expiration date (seconds since epoch). '0' means no expiration date.", - "type" : "integer", - "optional" : 1 - } - }, - "additionalProperties" : 0 - } - }, - "GET" : { - "returns" : { - "items" : { - "type" : "object", - "properties" : { - "userid" : { - "type" : "string" - } - } - }, - "links" : [ - { - "href" : "{userid}", - "rel" : "child" - } + "nowritecache" : { + "description" : "disable write caching on the target", + "optional" : 1, + "type" : "boolean" + }, + "options" : { + "description" : "NFS mount options (see 'man nfs')", + "format" : "pve-storage-options", + "optional" : 1, + "type" : "string" + }, + "path" : { + "description" : "File system path.", + "format" : "pve-storage-path", + "optional" : 1, + "type" : "string" + }, + "pool" : { + "description" : "Pool.", + "optional" : 1, + "type" : "string" + }, + "portal" : { + "description" : "iSCSI portal (IP or DNS name with optional port).", + "format" : "pve-storage-portal-dns", + "optional" : 1, + "type" : "string" + }, + "redundancy" : { + "default" : 2, + "description" : "The redundancy count specifies the number of nodes to which the resource should be deployed. It must be at least 1 and at most the number of nodes in the cluster.", + "maximum" : 16, + "minimum" : 1, + "optional" : 1, + "type" : "integer" + }, + "saferemove" : { + "description" : "Zero-out data when removing LVs.", + "optional" : 1, + "type" : "boolean" + }, + "saferemove_throughput" : { + "description" : "Wipe throughput (cstream -t parameter value).", + "optional" : 1, + "type" : "string" + }, + "server" : { + "description" : "Server IP or DNS name.", + "format" : "pve-storage-server", + "optional" : 1, + "type" : "string" + }, + "server2" : { + "description" : "Backup volfile server IP or DNS name.", + "format" : "pve-storage-server", + "optional" : 1, + "requires" : "server", + "type" : "string" + }, + "shared" : { + "description" : "Mark storage as shared.", + "optional" : 1, + "type" : "boolean" + }, + "sparse" : { + "description" : "use sparse volumes", + "optional" : 1, + "type" : "boolean" + }, + "storage" : { + "description" : "The storage identifier.", + "format" : "pve-storage-id", + "type" : "string" + }, + "target" : { + "description" : "iSCSI target.", + "optional" : 1, + "type" : "string" + }, + "thinpool" : { + "description" : "LVM thin pool LV name.", + "format" : "pve-storage-vgname", + "optional" : 1, + "type" : "string" + }, + "transport" : { + "description" : "Gluster transport: tcp or rdma", + "enum" : [ + "tcp", + "rdma", + "unix" ], - "type" : "array" + "optional" : 1, + "type" : "string" }, - "method" : "GET", - "name" : "index", - "parameters" : { - "additionalProperties" : 0, - "properties" : { - "enabled" : { - "description" : "Optional filter for enable property.", - "type" : "boolean", - "optional" : 1 - } - } + "type" : { + "description" : "Storage type.", + "enum" : [ + "dir", + "drbd", + "glusterfs", + "iscsi", + "iscsidirect", + "lvm", + "lvmthin", + "nfs", + "rbd", + "sheepdog", + "zfs", + "zfspool" + ], + "type" : "string" }, - "permissions" : { - "description" : "The returned list is restricted to users where you have 'User.Modify' or 'Sys.Audit' permissions on '/access/groups' or on a group the user belongs too. But it always includes the current (authenticated) user.", - "user" : "all" + "username" : { + "description" : "RBD Id.", + "optional" : 1, + "type" : "string" }, - "description" : "User index." - } + "vgname" : { + "description" : "Volume group name.", + "format" : "pve-storage-vgname", + "optional" : 1, + "type" : "string" + }, + "volume" : { + "description" : "Glusterfs Volume.", + "optional" : 1, + "type" : "string" + } + }, + "type" : "object" + }, + "permissions" : { + "check" : [ + "perm", + "/storage", + [ + "Datastore.Allocate" + ] + ] }, - "text" : "users", + "protected" : 1, + "returns" : { + "type" : "null" + } + } + }, + "leaf" : 0, + "path" : "/storage", + "text" : "storage" + }, + { + "children" : [ + { "children" : [ { - "leaf" : 1, - "path" : "/access/users/{userid}", "info" : { - "PUT" : { - "protected" : 1, - "description" : "Update user configuration.", - "name" : "update_user", + "DELETE" : { + "description" : "Delete user.", + "method" : "DELETE", + "name" : "delete_user", "parameters" : { "additionalProperties" : 0, "properties" : { - "expire" : { - "minimum" : 0, - "type" : "integer", - "optional" : 1, - "description" : "Account expiration date (seconds since epoch). '0' means no expiration date." - }, - "comment" : { - "type" : "string", - "optional" : 1 - }, - "email" : { - "format" : "email-opt", - "optional" : 1, - "type" : "string" - }, "userid" : { "description" : "User ID", - "type" : "string", "format" : "pve-userid", - "maxLength" : 64 - }, - "keys" : { - "description" : "Keys for two factor auth (yubico).", - "optional" : 1, - "type" : "string" - }, - "groups" : { - "format" : "pve-groupid-list", - "type" : "string", - "optional" : 1 - }, - "firstname" : { - "optional" : 1, - "type" : "string" - }, - "enable" : { - "type" : "boolean", - "optional" : 1, - "description" : "Enable/disable the account." - }, - "append" : { - "optional" : 1, - "type" : "boolean", - "requires" : "groups" - }, - "lastname" : { - "optional" : 1, + "maxLength" : 64, "type" : "string" } } }, "permissions" : { "check" : [ - "userid-group", + "and", [ - "User.Modify" + "userid-param", + "Realm.AllocateUser" ], - "groups_param", - 1 + [ + "userid-group", + [ + "User.Modify" + ] + ] ] }, + "protected" : 1, "returns" : { "type" : "null" - }, - "method" : "PUT" + } }, - "DELETE" : { - "protected" : 1, - "description" : "Delete user.", + "GET" : { + "description" : "Get user configuration.", + "method" : "GET", + "name" : "read_user", "parameters" : { "additionalProperties" : 0, "properties" : { "userid" : { - "maxLength" : 64, + "description" : "User ID", "format" : "pve-userid", - "type" : "string", - "description" : "User ID" + "maxLength" : 64, + "type" : "string" } } }, "permissions" : { "check" : [ - "and", - [ - "userid-param", - "Realm.AllocateUser" - ], + "userid-group", [ - "userid-group", - [ - "User.Modify" - ] + "User.Modify", + "Sys.Audit" ] ] }, - "name" : "delete_user", - "method" : "DELETE", - "returns" : { - "type" : "null" - } - }, - "GET" : { - "method" : "GET", "returns" : { "additionalProperties" : 0, "properties" : { - "keys" : { - "type" : "string", - "optional" : 1 - }, - "firstname" : { - "type" : "string", - "optional" : 1 + "comment" : { + "optional" : 1, + "type" : "string" }, - "groups" : { - "type" : "array" + "email" : { + "optional" : 1, + "type" : "string" }, "enable" : { "type" : "boolean" }, - "lastname" : { + "expire" : { + "optional" : 1, + "type" : "integer" + }, + "firstname" : { "optional" : 1, "type" : "string" }, - "expire" : { - "type" : "integer", - "optional" : 1 + "groups" : { + "type" : "array" }, - "email" : { - "type" : "string", - "optional" : 1 + "keys" : { + "optional" : 1, + "type" : "string" }, - "comment" : { - "type" : "string", - "optional" : 1 + "lastname" : { + "optional" : 1, + "type" : "string" } } - }, + } + }, + "PUT" : { + "description" : "Update user configuration.", + "method" : "PUT", + "name" : "update_user", "parameters" : { + "additionalProperties" : 0, "properties" : { + "append" : { + "optional" : 1, + "requires" : "groups", + "type" : "boolean" + }, + "comment" : { + "optional" : 1, + "type" : "string" + }, + "email" : { + "format" : "email-opt", + "optional" : 1, + "type" : "string" + }, + "enable" : { + "description" : "Enable/disable the account.", + "optional" : 1, + "type" : "boolean" + }, + "expire" : { + "description" : "Account expiration date (seconds since epoch). '0' means no expiration date.", + "minimum" : 0, + "optional" : 1, + "type" : "integer" + }, + "firstname" : { + "optional" : 1, + "type" : "string" + }, + "groups" : { + "format" : "pve-groupid-list", + "optional" : 1, + "type" : "string" + }, + "keys" : { + "description" : "Keys for two factor auth (yubico).", + "optional" : 1, + "type" : "string" + }, + "lastname" : { + "optional" : 1, + "type" : "string" + }, "userid" : { "description" : "User ID", - "type" : "string", "format" : "pve-userid", - "maxLength" : 64 + "maxLength" : 64, + "type" : "string" } - }, - "additionalProperties" : 0 + } }, - "name" : "read_user", "permissions" : { "check" : [ "userid-group", [ - "User.Modify", - "Sys.Audit" - ] + "User.Modify" + ], + "groups_param", + 1 ] }, - "description" : "Get user configuration." + "protected" : 1, + "returns" : { + "type" : "null" + } } }, + "leaf" : 1, + "path" : "/access/users/{userid}", "text" : "{userid}" } ], - "leaf" : 0, - "path" : "/access/users" - }, - { "info" : { "GET" : { + "description" : "User index.", + "method" : "GET", "name" : "index", - "permissions" : { - "user" : "all", - "description" : "The returned list is restricted to groups where you have 'User.Modify', 'Sys.Audit' or 'Group.Allocate' permissions on /access/groups/." - }, "parameters" : { - "additionalProperties" : 0 + "additionalProperties" : 0, + "properties" : { + "enabled" : { + "description" : "Optional filter for enable property.", + "optional" : 1, + "type" : "boolean" + } + } + }, + "permissions" : { + "description" : "The returned list is restricted to users where you have 'User.Modify' or 'Sys.Audit' permissions on '/access/groups' or on a group the user belongs too. But it always includes the current (authenticated) user.", + "user" : "all" }, - "description" : "Group index.", - "method" : "GET", "returns" : { - "links" : [ - { - "href" : "{groupid}", - "rel" : "child" - } - ], "items" : { "properties" : { - "groupid" : { + "userid" : { "type" : "string" } }, "type" : "object" }, + "links" : [ + { + "href" : "{userid}", + "rel" : "child" + } + ], "type" : "array" } }, "POST" : { - "returns" : { - "type" : "null" - }, + "description" : "Create new user.", "method" : "POST", - "name" : "create_group", - "permissions" : { - "check" : [ - "perm", - "/access/groups", - [ - "Group.Allocate" - ] - ] - }, + "name" : "create_user", "parameters" : { "additionalProperties" : 0, "properties" : { - "groupid" : { - "format" : "pve-groupid", + "comment" : { + "optional" : 1, "type" : "string" }, - "comment" : { + "email" : { + "format" : "email-opt", + "optional" : 1, + "type" : "string" + }, + "enable" : { + "default" : 1, + "description" : "Enable the account (default). You can set this to '0' to disable the accout", + "optional" : 1, + "type" : "boolean" + }, + "expire" : { + "description" : "Account expiration date (seconds since epoch). '0' means no expiration date.", + "minimum" : 0, + "optional" : 1, + "type" : "integer" + }, + "firstname" : { + "optional" : 1, + "type" : "string" + }, + "groups" : { + "format" : "pve-groupid-list", + "optional" : 1, + "type" : "string" + }, + "keys" : { + "description" : "Keys for two factor auth (yubico).", + "optional" : 1, + "type" : "string" + }, + "lastname" : { "optional" : 1, "type" : "string" + }, + "password" : { + "description" : "Initial password.", + "maxLength" : 64, + "minLength" : 5, + "optional" : 1, + "type" : "string" + }, + "userid" : { + "description" : "User ID", + "format" : "pve-userid", + "maxLength" : 64, + "type" : "string" } } }, - "description" : "Create new group.", - "protected" : 1 + "permissions" : { + "check" : [ + "and", + [ + "userid-param", + "Realm.AllocateUser" + ], + [ + "userid-group", + [ + "User.Modify" + ], + "groups_param", + 1 + ] + ], + "description" : "You need 'Realm.AllocateUser' on '/access/realm/' on the realm of user , and 'User.Modify' permissions to '/access/groups/' for any group specified (or 'User.Modify' on '/access/groups' if you pass no groups." + }, + "protected" : 1, + "returns" : { + "type" : "null" + } } }, + "leaf" : 0, + "path" : "/access/users", + "text" : "users" + }, + { "children" : [ { "info" : { "DELETE" : { + "description" : "Delete group.", + "method" : "DELETE", + "name" : "delete_group", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "groupid" : { + "format" : "pve-groupid", + "type" : "string" + } + } + }, "permissions" : { "check" : [ "perm", @@ -21901,60 +21818,42 @@ var pveapi = [ ] ] }, - "name" : "delete_group", - "parameters" : { - "properties" : { - "groupid" : { - "type" : "string", - "format" : "pve-groupid" - } - }, - "additionalProperties" : 0 - }, "protected" : 1, - "description" : "Delete group.", "returns" : { "type" : "null" - }, - "method" : "DELETE" + } }, - "PUT" : { - "method" : "PUT", - "returns" : { - "type" : "null" + "GET" : { + "description" : "Get group configuration.", + "method" : "GET", + "name" : "read_group", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "groupid" : { + "format" : "pve-groupid", + "type" : "string" + } + } }, - "description" : "Update group data.", - "protected" : 1, "permissions" : { "check" : [ "perm", "/access/groups", [ + "Sys.Audit", "Group.Allocate" - ] + ], + "any", + 1 ] }, - "name" : "update_group", - "parameters" : { - "additionalProperties" : 0, - "properties" : { - "groupid" : { - "type" : "string", - "format" : "pve-groupid" - }, - "comment" : { - "type" : "string", - "optional" : 1 - } - } - } - }, - "GET" : { "returns" : { + "additionalProperties" : 0, "properties" : { "comment" : { - "type" : "string", - "optional" : 1 + "optional" : 1, + "type" : "string" }, "members" : { "items" : { @@ -21963,74 +21862,119 @@ var pveapi = [ "type" : "array" } }, - "type" : "object", - "additionalProperties" : 0 - }, - "method" : "GET", - "name" : "read_group", + "type" : "object" + } + }, + "PUT" : { + "description" : "Update group data.", + "method" : "PUT", + "name" : "update_group", "parameters" : { + "additionalProperties" : 0, "properties" : { + "comment" : { + "optional" : 1, + "type" : "string" + }, "groupid" : { "format" : "pve-groupid", "type" : "string" } - }, - "additionalProperties" : 0 + } }, "permissions" : { "check" : [ "perm", "/access/groups", [ - "Sys.Audit", "Group.Allocate" - ], - "any", - 1 + ] ] }, - "description" : "Get group configuration." + "protected" : 1, + "returns" : { + "type" : "null" + } } }, - "text" : "{groupid}", "leaf" : 1, - "path" : "/access/groups/{groupid}" + "path" : "/access/groups/{groupid}", + "text" : "{groupid}" + } + ], + "info" : { + "GET" : { + "description" : "Group index.", + "method" : "GET", + "name" : "index", + "parameters" : { + "additionalProperties" : 0 + }, + "permissions" : { + "description" : "The returned list is restricted to groups where you have 'User.Modify', 'Sys.Audit' or 'Group.Allocate' permissions on /access/groups/.", + "user" : "all" + }, + "returns" : { + "items" : { + "properties" : { + "groupid" : { + "type" : "string" + } + }, + "type" : "object" + }, + "links" : [ + { + "href" : "{groupid}", + "rel" : "child" + } + ], + "type" : "array" + } + }, + "POST" : { + "description" : "Create new group.", + "method" : "POST", + "name" : "create_group", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "comment" : { + "optional" : 1, + "type" : "string" + }, + "groupid" : { + "format" : "pve-groupid", + "type" : "string" + } + } + }, + "permissions" : { + "check" : [ + "perm", + "/access/groups", + [ + "Group.Allocate" + ] + ] + }, + "protected" : 1, + "returns" : { + "type" : "null" + } } - ], - "text" : "groups", + }, "leaf" : 0, - "path" : "/access/groups" + "path" : "/access/groups", + "text" : "groups" }, { "children" : [ { - "text" : "{roleid}", "info" : { - "GET" : { - "returns" : {}, - "method" : "GET", - "name" : "read_role", - "parameters" : { - "properties" : { - "roleid" : { - "format" : "pve-roleid", - "type" : "string" - } - }, - "additionalProperties" : 0 - }, - "permissions" : { - "user" : "all" - }, - "description" : "Get role configuration." - }, "DELETE" : { - "method" : "DELETE", - "returns" : { - "type" : "null" - }, "description" : "Delete role.", - "protected" : 1, + "method" : "DELETE", "name" : "delete_role", "parameters" : { "additionalProperties" : 0, @@ -22049,53 +21993,76 @@ var pveapi = [ "Sys.Modify" ] ] + }, + "protected" : 1, + "returns" : { + "type" : "null" } }, - "PUT" : { + "GET" : { + "description" : "Get role configuration.", + "method" : "GET", + "name" : "read_role", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "roleid" : { + "format" : "pve-roleid", + "type" : "string" + } + } + }, "permissions" : { - "check" : [ - "perm", - "/access", - [ - "Sys.Modify" - ] - ] + "user" : "all" }, + "returns" : {} + }, + "PUT" : { + "description" : "Create new role.", + "method" : "PUT", + "name" : "update_role", "parameters" : { "additionalProperties" : 0, "properties" : { "append" : { + "optional" : 1, "requires" : "privs", - "type" : "boolean", - "optional" : 1 - }, - "roleid" : { - "format" : "pve-roleid", - "type" : "string" + "type" : "boolean" }, "privs" : { "format" : "pve-priv-list", "type" : "string" + }, + "roleid" : { + "format" : "pve-roleid", + "type" : "string" } } }, - "name" : "update_role", - "description" : "Create new role.", + "permissions" : { + "check" : [ + "perm", + "/access", + [ + "Sys.Modify" + ] + ] + }, "protected" : 1, - "method" : "PUT", "returns" : { "type" : "null" } } }, + "leaf" : 1, "path" : "/access/roles/{roleid}", - "leaf" : 1 + "text" : "{roleid}" } ], - "text" : "roles", "info" : { "GET" : { "description" : "Role index.", + "method" : "GET", "name" : "index", "parameters" : { "additionalProperties" : 0 @@ -22104,78 +22071,86 @@ var pveapi = [ "user" : "all" }, "returns" : { - "type" : "array", - "links" : [ - { - "href" : "{roleid}", - "rel" : "child" - } - ], "items" : { - "type" : "object", "properties" : { "roleid" : { "type" : "string" } + }, + "type" : "object" + }, + "links" : [ + { + "href" : "{roleid}", + "rel" : "child" } - } - }, - "method" : "GET" + ], + "type" : "array" + } }, "POST" : { "description" : "Create new role.", - "protected" : 1, - "permissions" : { - "check" : [ - "perm", - "/access", - [ - "Sys.Modify" - ] - ] - }, + "method" : "POST", + "name" : "create_role", "parameters" : { "additionalProperties" : 0, "properties" : { - "roleid" : { - "type" : "string", - "format" : "pve-roleid" - }, "privs" : { "format" : "pve-priv-list", "optional" : 1, "type" : "string" + }, + "roleid" : { + "format" : "pve-roleid", + "type" : "string" } } }, - "name" : "create_role", - "method" : "POST", + "permissions" : { + "check" : [ + "perm", + "/access", + [ + "Sys.Modify" + ] + ] + }, + "protected" : 1, "returns" : { "type" : "null" } } }, + "leaf" : 0, "path" : "/access/roles", - "leaf" : 0 + "text" : "roles" }, { "info" : { "GET" : { - "permissions" : { - "user" : "all", - "description" : "The returned list is restricted to objects where you have rights to modify permissions." - }, + "description" : "Get Access Control List (ACLs).", + "method" : "GET", + "name" : "read_acl", "parameters" : { "additionalProperties" : 0 }, - "name" : "read_acl", - "description" : "Get Access Control List (ACLs).", + "permissions" : { + "description" : "The returned list is restricted to objects where you have rights to modify permissions.", + "user" : "all" + }, "returns" : { "items" : { + "additionalProperties" : 0, "properties" : { "path" : { "type" : "string" }, + "propagate" : { + "type" : "boolean" + }, + "roleid" : { + "type" : "string" + }, "type" : { "enum" : [ "user", @@ -22183,59 +22158,53 @@ var pveapi = [ ], "type" : "string" }, - "propagate" : { - "type" : "boolean" - }, - "roleid" : { - "type" : "string" - }, "ugid" : { "type" : "string" } }, - "type" : "object", - "additionalProperties" : 0 + "type" : "object" }, "type" : "array" - }, - "method" : "GET" + } }, "PUT" : { + "description" : "Update Access Control List (add or remove permissions).", + "method" : "PUT", "name" : "update_acl", "parameters" : { "additionalProperties" : 0, "properties" : { "delete" : { - "type" : "boolean", + "description" : "Remove permissions (instead of adding it).", "optional" : 1, - "description" : "Remove permissions (instead of adding it)." + "type" : "boolean" }, - "users" : { - "format" : "pve-userid-list", - "type" : "string", + "groups" : { + "description" : "List of groups.", + "format" : "pve-groupid-list", "optional" : 1, - "description" : "List of users." + "type" : "string" }, "path" : { "description" : "Access control path", "type" : "string" }, - "roles" : { - "description" : "List of roles.", - "type" : "string", - "format" : "pve-roleid-list" - }, "propagate" : { + "default" : 1, "description" : "Allow to propagate (inherit) permissions.", - "type" : "boolean", "optional" : 1, - "default" : 1 + "type" : "boolean" }, - "groups" : { - "description" : "List of groups.", + "roles" : { + "description" : "List of roles.", + "format" : "pve-roleid-list", + "type" : "string" + }, + "users" : { + "description" : "List of users.", + "format" : "pve-userid-list", "optional" : 1, - "type" : "string", - "format" : "pve-groupid-list" + "type" : "string" } } }, @@ -22245,118 +22214,35 @@ var pveapi = [ "{path}" ] }, - "description" : "Update Access Control List (add or remove permissions).", "protected" : 1, "returns" : { "type" : "null" - }, - "method" : "PUT" + } } }, - "text" : "acl", "leaf" : 1, - "path" : "/access/acl" + "path" : "/access/acl", + "text" : "acl" }, { - "text" : "domains", "children" : [ { - "path" : "/access/domains/{realm}", - "leaf" : 1, - "text" : "{realm}", "info" : { - "PUT" : { - "parameters" : { - "properties" : { - "base_dn" : { - "maxLength" : 256, - "type" : "string", - "optional" : 1, - "description" : "LDAP base domain name", - "pattern" : "\\w+=[^,]+(,\\s*\\w+=[^,]+)*" - }, - "realm" : { - "description" : "Authentication domain ID", - "type" : "string", - "format" : "pve-realm", - "maxLength" : 32 - }, - "user_attr" : { - "maxLength" : 256, - "pattern" : "\\S{2,}", - "description" : "LDAP user attribute name", - "optional" : 1, - "type" : "string" - }, - "secure" : { - "type" : "boolean", - "optional" : 1, - "description" : "Use secure LDAPS protocol." - }, - "server1" : { - "format" : "address", - "maxLength" : 256, - "optional" : 1, - "type" : "string", - "description" : "Server IP address (or DNS name)" - }, - "domain" : { - "maxLength" : 256, - "description" : "AD domain name", - "pattern" : "\\S+", - "optional" : 1, - "type" : "string" - }, - "server2" : { - "maxLength" : 256, - "format" : "address", - "type" : "string", - "optional" : 1, - "description" : "Fallback Server IP address (or DNS name)" - }, - "delete" : { - "type" : "string", - "optional" : 1, - "description" : "A list of settings you want to delete.", - "maxLength" : 4096, - "format" : "pve-configid-list" - }, - "comment" : { - "maxLength" : 4096, - "optional" : 1, - "type" : "string", - "description" : "Description." - }, - "default" : { - "description" : "Use this as default realm", - "type" : "boolean", - "optional" : 1 - }, - "port" : { - "description" : "Server port.", - "maximum" : 65535, - "type" : "integer", - "optional" : 1, - "minimum" : 1 - }, - "digest" : { - "optional" : 1, - "type" : "string", - "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", - "maxLength" : 40 - }, - "tfa" : { - "optional" : 1, - "type" : "string", - "description" : "Use Two-factor authentication.", - "maxLength" : 128, - "format" : "pve-tfa-config" + "DELETE" : { + "description" : "Delete an authentication server.", + "method" : "DELETE", + "name" : "delete", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "realm" : { + "description" : "Authentication domain ID", + "format" : "pve-realm", + "maxLength" : 32, + "type" : "string" } - }, - "type" : "object", - "additionalProperties" : 0 + } }, - "name" : "update", "permissions" : { "check" : [ "perm", @@ -22367,83 +22253,166 @@ var pveapi = [ ] }, "protected" : 1, - "description" : "Update authentication server settings.", "returns" : { "type" : "null" - }, - "method" : "PUT" + } }, - "DELETE" : { - "method" : "DELETE", - "returns" : { - "type" : "null" - }, - "protected" : 1, - "description" : "Delete an authentication server.", + "GET" : { + "description" : "Get auth server configuration.", + "method" : "GET", + "name" : "read", "parameters" : { + "additionalProperties" : 0, "properties" : { "realm" : { + "description" : "Authentication domain ID", "format" : "pve-realm", "maxLength" : 32, - "type" : "string", - "description" : "Authentication domain ID" + "type" : "string" } - }, - "additionalProperties" : 0 + } }, - "name" : "delete", "permissions" : { "check" : [ "perm", "/access/realm", [ - "Realm.Allocate" - ] + "Realm.Allocate", + "Sys.Audit" + ], + "any", + 1 ] - } + }, + "returns" : {} }, - "GET" : { + "PUT" : { + "description" : "Update authentication server settings.", + "method" : "PUT", + "name" : "update", "parameters" : { + "additionalProperties" : 0, "properties" : { + "base_dn" : { + "description" : "LDAP base domain name", + "maxLength" : 256, + "optional" : 1, + "pattern" : "\\w+=[^,]+(,\\s*\\w+=[^,]+)*", + "type" : "string" + }, + "comment" : { + "description" : "Description.", + "maxLength" : 4096, + "optional" : 1, + "type" : "string" + }, + "default" : { + "description" : "Use this as default realm", + "optional" : 1, + "type" : "boolean" + }, + "delete" : { + "description" : "A list of settings you want to delete.", + "format" : "pve-configid-list", + "maxLength" : 4096, + "optional" : 1, + "type" : "string" + }, + "digest" : { + "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.", + "maxLength" : 40, + "optional" : 1, + "type" : "string" + }, + "domain" : { + "description" : "AD domain name", + "maxLength" : 256, + "optional" : 1, + "pattern" : "\\S+", + "type" : "string" + }, + "port" : { + "description" : "Server port.", + "maximum" : 65535, + "minimum" : 1, + "optional" : 1, + "type" : "integer" + }, "realm" : { - "type" : "string", "description" : "Authentication domain ID", "format" : "pve-realm", - "maxLength" : 32 + "maxLength" : 32, + "type" : "string" + }, + "secure" : { + "description" : "Use secure LDAPS protocol.", + "optional" : 1, + "type" : "boolean" + }, + "server1" : { + "description" : "Server IP address (or DNS name)", + "format" : "address", + "maxLength" : 256, + "optional" : 1, + "type" : "string" + }, + "server2" : { + "description" : "Fallback Server IP address (or DNS name)", + "format" : "address", + "maxLength" : 256, + "optional" : 1, + "type" : "string" + }, + "tfa" : { + "description" : "Use Two-factor authentication.", + "format" : "pve-tfa-config", + "maxLength" : 128, + "optional" : 1, + "type" : "string" + }, + "user_attr" : { + "description" : "LDAP user attribute name", + "maxLength" : 256, + "optional" : 1, + "pattern" : "\\S{2,}", + "type" : "string" } }, - "additionalProperties" : 0 + "type" : "object" }, - "name" : "read", "permissions" : { "check" : [ "perm", "/access/realm", [ - "Realm.Allocate", - "Sys.Audit" - ], - "any", - 1 + "Realm.Allocate" + ] ] }, - "description" : "Get auth server configuration.", - "method" : "GET", - "returns" : {} + "protected" : 1, + "returns" : { + "type" : "null" + } } - } + }, + "leaf" : 1, + "path" : "/access/domains/{realm}", + "text" : "{realm}" } ], "info" : { "GET" : { + "description" : "Authentication domain index.", + "method" : "GET", + "name" : "index", + "parameters" : { + "additionalProperties" : 0 + }, + "permissions" : { + "description" : "Anyone can access that, because we need that list for the login box (before the user is authenticated).", + "user" : "world" + }, "returns" : { - "type" : "array", - "links" : [ - { - "rel" : "child", - "href" : "{realm}" - } - ], "items" : { "properties" : { "comment" : { @@ -22459,117 +22428,110 @@ var pveapi = [ "yubico", "oath" ], - "type" : "string", - "optional" : 1 + "optional" : 1, + "type" : "string" } }, "type" : "object" - } - }, - "method" : "GET", - "parameters" : { - "additionalProperties" : 0 - }, - "name" : "index", - "permissions" : { - "user" : "world", - "description" : "Anyone can access that, because we need that list for the login box (before the user is authenticated)." - }, - "description" : "Authentication domain index." + }, + "links" : [ + { + "href" : "{realm}", + "rel" : "child" + } + ], + "type" : "array" + } }, "POST" : { - "method" : "POST", - "returns" : { - "type" : "null" - }, "description" : "Add an authentication server.", - "protected" : 1, + "method" : "POST", "name" : "create", "parameters" : { + "additionalProperties" : 0, "properties" : { - "server1" : { - "optional" : 1, - "type" : "string", - "description" : "Server IP address (or DNS name)", + "base_dn" : { + "description" : "LDAP base domain name", "maxLength" : 256, - "format" : "address" - }, - "secure" : { - "description" : "Use secure LDAPS protocol.", - "type" : "boolean", - "optional" : 1 - }, - "type" : { - "description" : "Realm type.", - "enum" : [ - "ldap", - "pam", - "pve", - "ad" - ], + "optional" : 1, + "pattern" : "\\w+=[^,]+(,\\s*\\w+=[^,]+)*", "type" : "string" }, - "user_attr" : { - "pattern" : "\\S{2,}", - "description" : "LDAP user attribute name", + "comment" : { + "description" : "Description.", + "maxLength" : 4096, "optional" : 1, - "type" : "string", - "maxLength" : 256 - }, - "realm" : { - "format" : "pve-realm", - "maxLength" : 32, - "type" : "string", - "description" : "Authentication domain ID" + "type" : "string" }, - "base_dn" : { - "pattern" : "\\w+=[^,]+(,\\s*\\w+=[^,]+)*", - "description" : "LDAP base domain name", + "default" : { + "description" : "Use this as default realm", "optional" : 1, - "type" : "string", - "maxLength" : 256 + "type" : "boolean" }, - "tfa" : { - "description" : "Use Two-factor authentication.", + "domain" : { + "description" : "AD domain name", + "maxLength" : 256, "optional" : 1, - "type" : "string", - "maxLength" : 128, - "format" : "pve-tfa-config" + "pattern" : "\\S+", + "type" : "string" }, "port" : { - "minimum" : 1, + "description" : "Server port.", "maximum" : 65535, - "type" : "integer", + "minimum" : 1, "optional" : 1, - "description" : "Server port." + "type" : "integer" }, - "default" : { + "realm" : { + "description" : "Authentication domain ID", + "format" : "pve-realm", + "maxLength" : 32, + "type" : "string" + }, + "secure" : { + "description" : "Use secure LDAPS protocol.", "optional" : 1, - "type" : "boolean", - "description" : "Use this as default realm" + "type" : "boolean" }, - "comment" : { - "maxLength" : 4096, - "description" : "Description.", - "type" : "string", - "optional" : 1 + "server1" : { + "description" : "Server IP address (or DNS name)", + "format" : "address", + "maxLength" : 256, + "optional" : 1, + "type" : "string" }, - "domain" : { + "server2" : { + "description" : "Fallback Server IP address (or DNS name)", + "format" : "address", "maxLength" : 256, - "type" : "string", "optional" : 1, - "pattern" : "\\S+", - "description" : "AD domain name" + "type" : "string" }, - "server2" : { + "tfa" : { + "description" : "Use Two-factor authentication.", + "format" : "pve-tfa-config", + "maxLength" : 128, + "optional" : 1, + "type" : "string" + }, + "type" : { + "description" : "Realm type.", + "enum" : [ + "ad", + "ldap", + "pam", + "pve" + ], + "type" : "string" + }, + "user_attr" : { + "description" : "LDAP user attribute name", "maxLength" : 256, - "format" : "address", - "type" : "string", "optional" : 1, - "description" : "Fallback Server IP address (or DNS name)" + "pattern" : "\\S{2,}", + "type" : "string" } }, - "additionalProperties" : 0, "type" : "object" }, "permissions" : { @@ -22580,282 +22542,204 @@ var pveapi = [ "Realm.Allocate" ] ] + }, + "protected" : 1, + "returns" : { + "type" : "null" } } }, + "leaf" : 0, "path" : "/access/domains", - "leaf" : 0 + "text" : "domains" }, { "info" : { + "GET" : { + "description" : "Dummy. Useful for formaters which want to priovde a login page.", + "method" : "GET", + "name" : "get_ticket", + "parameters" : { + "additionalProperties" : 0 + }, + "permissions" : { + "user" : "world" + }, + "returns" : { + "type" : "null" + } + }, "POST" : { + "description" : "Create or verify authentication ticket.", "method" : "POST", - "returns" : { - "type" : "object", + "name" : "create_ticket", + "parameters" : { + "additionalProperties" : 0, "properties" : { - "CSRFPreventionToken" : { - "optional" : 1, - "type" : "string" - }, - "ticket" : { + "otp" : { + "description" : "One-time password for Two-factor authentication.", "optional" : 1, "type" : "string" }, - "username" : { - "type" : "string" - } - } - }, - "parameters" : { - "properties" : { "password" : { "description" : "The secret password. This can also be a valid ticket.", "type" : "string" }, - "privs" : { + "path" : { + "description" : "Verify ticket, and check if user have access 'privs' on 'path'", "maxLength" : 64, - "format" : "pve-priv-list", - "optional" : 1, - "type" : "string", - "requires" : "path", - "description" : "Verify ticket, and check if user have access 'privs' on 'path'" - }, - "otp" : { "optional" : 1, - "type" : "string", - "description" : "One-time password for Two-factor authentication." - }, - "path" : { "requires" : "privs", + "type" : "string" + }, + "privs" : { "description" : "Verify ticket, and check if user have access 'privs' on 'path'", + "format" : "pve-priv-list", + "maxLength" : 64, "optional" : 1, - "type" : "string", - "maxLength" : 64 + "requires" : "path", + "type" : "string" }, "realm" : { "description" : "You can optionally pass the realm using this parameter. Normally the realm is simply added to the username @.", - "optional" : 1, - "type" : "string", + "format" : "pve-realm", "maxLength" : 32, - "format" : "pve-realm" + "optional" : 1, + "type" : "string" }, "username" : { "description" : "User name", - "type" : "string", - "maxLength" : 64 + "maxLength" : 64, + "type" : "string" } - }, - "additionalProperties" : 0 - }, - "name" : "create_ticket", - "permissions" : { - "user" : "world", - "description" : "You need to pass valid credientials." - }, - "description" : "Create or verify authentication ticket.", - "protected" : 1 - }, - "GET" : { - "parameters" : { - "additionalProperties" : 0 + } }, "permissions" : { + "description" : "You need to pass valid credientials.", "user" : "world" }, - "name" : "get_ticket", - "description" : "Dummy. Useful for formaters which want to priovde a login page.", - "returns" : { - "type" : "null" - }, - "method" : "GET" - } - }, - "text" : "ticket", - "leaf" : 1, - "path" : "/access/ticket" - }, - { - "info" : { - "PUT" : { + "protected" : 1, "returns" : { - "type" : "null" - }, - "method" : "PUT", - "permissions" : { - "description" : "Each user is allowed to change his own password. A user can change the password of another user if he has 'Realm.AllocateUser' (on the realm of user ) and 'User.Modify' permission on /access/groups/ on a group where user is member of.", - "check" : [ - "or", - [ - "userid-param", - "self" - ], - [ - "and", - [ - "userid-param", - "Realm.AllocateUser" - ], - [ - "userid-group", - [ - "User.Modify" - ] - ] - ] - ] - }, - "parameters" : { "properties" : { - "password" : { - "maxLength" : 64, - "type" : "string", - "description" : "The new password.", - "minLength" : 5 + "CSRFPreventionToken" : { + "optional" : 1, + "type" : "string" }, - "userid" : { - "format" : "pve-userid", - "maxLength" : 64, - "description" : "User ID", + "ticket" : { + "optional" : 1, + "type" : "string" + }, + "username" : { "type" : "string" } }, - "additionalProperties" : 0 - }, - "name" : "change_passsword", - "description" : "Change user password.", - "protected" : 1 - } - }, - "text" : "password", - "leaf" : 1, - "path" : "/access/password" - } - ] - }, - { - "info" : { - "GET" : { - "description" : "Pool index.", - "name" : "index", - "parameters" : { - "additionalProperties" : 0 - }, - "permissions" : { - "user" : "all", - "description" : "List all pools where you have Pool.Allocate or VM.Allocate permissions on /pool/." - }, - "returns" : { - "type" : "array", - "links" : [ - { - "rel" : "child", - "href" : "{poolid}" + "type" : "object" } - ], - "items" : { - "properties" : { - "poolid" : { - "type" : "string" - } - }, - "type" : "object" } }, - "method" : "GET" + "leaf" : 1, + "path" : "/access/ticket", + "text" : "ticket" }, - "POST" : { - "name" : "create_pool", - "permissions" : { - "check" : [ - "perm", - "/pool/{poolid}", - [ - "Pool.Allocate" - ] - ] - }, - "parameters" : { - "additionalProperties" : 0, - "properties" : { - "poolid" : { - "format" : "pve-poolid", - "type" : "string" - }, - "comment" : { - "optional" : 1, - "type" : "string" - } - } - }, - "protected" : 1, - "description" : "Create new pool.", - "method" : "POST", - "returns" : { - "type" : "null" - } - } - }, - "children" : [ { - "leaf" : 1, - "path" : "/pools/{poolid}", "info" : { "PUT" : { + "description" : "Change user password.", "method" : "PUT", - "returns" : { - "type" : "null" - }, + "name" : "change_passsword", "parameters" : { "additionalProperties" : 0, "properties" : { - "storage" : { - "type" : "string", - "optional" : 1, - "description" : "List of storage IDs.", - "format" : "pve-storage-id-list" - }, - "vms" : { - "format" : "pve-vmid-list", - "type" : "string", - "optional" : 1, - "description" : "List of virtual machines." - }, - "delete" : { - "description" : "Remove vms/storage (instead of adding it).", - "optional" : 1, - "type" : "boolean" + "password" : { + "description" : "The new password.", + "maxLength" : 64, + "minLength" : 5, + "type" : "string" }, - "poolid" : { - "format" : "pve-poolid", + "userid" : { + "description" : "User ID", + "format" : "pve-userid", + "maxLength" : 64, "type" : "string" - }, - "comment" : { - "type" : "string", - "optional" : 1 } } }, "permissions" : { "check" : [ - "perm", - "/pool/{poolid}", + "or", [ - "Pool.Allocate" + "userid-param", + "self" + ], + [ + "and", + [ + "userid-param", + "Realm.AllocateUser" + ], + [ + "userid-group", + [ + "User.Modify" + ] + ] ] ], - "description" : "You also need the right to modify permissions on any object you add/delete." + "description" : "Each user is allowed to change his own password. A user can change the password of another user if he has 'Realm.AllocateUser' (on the realm of user ) and 'User.Modify' permission on /access/groups/ on a group where user is member of." }, - "name" : "update_pool", - "description" : "Update pool data.", - "protected" : 1 - }, - "DELETE" : { + "protected" : 1, "returns" : { "type" : "null" + } + } + }, + "leaf" : 1, + "path" : "/access/password", + "text" : "password" + } + ], + "info" : { + "GET" : { + "description" : "Directory index.", + "method" : "GET", + "name" : "index", + "parameters" : { + "additionalProperties" : 0 + }, + "permissions" : { + "user" : "all" + }, + "returns" : { + "items" : { + "properties" : { + "subdir" : { + "type" : "string" + } }, - "method" : "DELETE", + "type" : "object" + }, + "links" : [ + { + "href" : "{subdir}", + "rel" : "child" + } + ], + "type" : "array" + } + } + }, + "leaf" : 0, + "path" : "/access", + "text" : "access" + }, + { + "children" : [ + { + "info" : { + "DELETE" : { "description" : "Delete pool.", - "protected" : 1, + "method" : "DELETE", + "name" : "delete_pool", "parameters" : { "additionalProperties" : 0, "properties" : { @@ -22865,29 +22749,33 @@ var pveapi = [ } } }, - "name" : "delete_pool", "permissions" : { - "description" : "You can only delete empty pools (no members).", "check" : [ "perm", "/pool/{poolid}", [ "Pool.Allocate" ] - ] + ], + "description" : "You can only delete empty pools (no members)." + }, + "protected" : 1, + "returns" : { + "type" : "null" } }, "GET" : { "description" : "Get pool configuration.", + "method" : "GET", "name" : "read_pool", "parameters" : { + "additionalProperties" : 0, "properties" : { "poolid" : { - "type" : "string", - "format" : "pve-poolid" + "format" : "pve-poolid", + "type" : "string" } - }, - "additionalProperties" : 0 + } }, "permissions" : { "check" : [ @@ -22898,88 +22786,200 @@ var pveapi = [ ] ] }, - "method" : "GET", "returns" : { + "additionalProperties" : 0, "properties" : { + "comment" : { + "optional" : 1, + "type" : "string" + }, "members" : { - "type" : "array", "items" : { "additionalProperties" : 1, - "type" : "object", "properties" : { - "vmid" : { - "optional" : 1, - "type" : "integer" - }, - "storage" : { - "type" : "string", - "optional" : 1 - }, "id" : { "type" : "string" }, "node" : { "type" : "string" }, + "storage" : { + "optional" : 1, + "type" : "string" + }, "type" : { - "type" : "string", "enum" : [ "qemu", "lxc", "openvz", "storage" - ] + ], + "type" : "string" + }, + "vmid" : { + "optional" : 1, + "type" : "integer" } - } - } - }, + }, + "type" : "object" + }, + "type" : "array" + } + }, + "type" : "object" + } + }, + "PUT" : { + "description" : "Update pool data.", + "method" : "PUT", + "name" : "update_pool", + "parameters" : { + "additionalProperties" : 0, + "properties" : { "comment" : { "optional" : 1, "type" : "string" + }, + "delete" : { + "description" : "Remove vms/storage (instead of adding it).", + "optional" : 1, + "type" : "boolean" + }, + "poolid" : { + "format" : "pve-poolid", + "type" : "string" + }, + "storage" : { + "description" : "List of storage IDs.", + "format" : "pve-storage-id-list", + "optional" : 1, + "type" : "string" + }, + "vms" : { + "description" : "List of virtual machines.", + "format" : "pve-vmid-list", + "optional" : 1, + "type" : "string" } - }, - "additionalProperties" : 0, - "type" : "object" + } + }, + "permissions" : { + "check" : [ + "perm", + "/pool/{poolid}", + [ + "Pool.Allocate" + ] + ], + "description" : "You also need the right to modify permissions on any object you add/delete." + }, + "protected" : 1, + "returns" : { + "type" : "null" } } }, + "leaf" : 1, + "path" : "/pools/{poolid}", "text" : "{poolid}" } ], - "text" : "pools", - "leaf" : 0, - "path" : "/pools" - }, - { - "leaf" : 1, - "path" : "/version", "info" : { "GET" : { + "description" : "Pool index.", + "method" : "GET", + "name" : "index", + "parameters" : { + "additionalProperties" : 0 + }, + "permissions" : { + "description" : "List all pools where you have Pool.Allocate or VM.Allocate permissions on /pool/.", + "user" : "all" + }, "returns" : { - "type" : "object", - "properties" : { - "version" : { - "type" : "string" + "items" : { + "properties" : { + "poolid" : { + "type" : "string" + } }, - "repoid" : { + "type" : "object" + }, + "links" : [ + { + "href" : "{poolid}", + "rel" : "child" + } + ], + "type" : "array" + } + }, + "POST" : { + "description" : "Create new pool.", + "method" : "POST", + "name" : "create_pool", + "parameters" : { + "additionalProperties" : 0, + "properties" : { + "comment" : { + "optional" : 1, "type" : "string" }, - "release" : { + "poolid" : { + "format" : "pve-poolid", "type" : "string" } } }, - "method" : "GET", - "description" : "API version details. The result also includes the global datacenter confguration.", "permissions" : { - "user" : "all" + "check" : [ + "perm", + "/pool/{poolid}", + [ + "Pool.Allocate" + ] + ] }, + "protected" : 1, + "returns" : { + "type" : "null" + } + } + }, + "leaf" : 0, + "path" : "/pools", + "text" : "pools" + }, + { + "info" : { + "GET" : { + "description" : "API version details. The result also includes the global datacenter confguration.", + "method" : "GET", + "name" : "version", "parameters" : { "additionalProperties" : 0 }, - "name" : "version" + "permissions" : { + "user" : "all" + }, + "returns" : { + "properties" : { + "release" : { + "type" : "string" + }, + "repoid" : { + "type" : "string" + }, + "version" : { + "type" : "string" + } + }, + "type" : "object" + } } }, + "leaf" : 1, + "path" : "/version", "text" : "version" } ] diff --git a/extractapi.pl b/extractapi.pl index 0488ea9..afd2cf1 100755 --- a/extractapi.pl +++ b/extractapi.pl @@ -39,6 +39,6 @@ sub cleanup_tree { my $tree = cleanup_tree(PVE::RESTHandler::api_dump('PVE::API2')); -print "var pveapi = " . to_json($tree, {pretty => 1}) . ";\n\n"; +print "var pveapi = " . to_json($tree, {pretty => 1, canonical => 1}) . ";\n\n"; exit(0);