]> git.proxmox.com Git - pve-docs.git/blame - api-viewer/apidata.js
add and use wiki and forum macros
[pve-docs.git] / api-viewer / apidata.js
CommitLineData
56122987
DM
1var pveapi = [
2 {
56122987
DM
3 "children" : [
4 {
56122987
DM
5 "children" : [
6 {
56122987
DM
7 "children" : [
8 {
44660702
DM
9 "children" : [
10 {
11 "info" : {
12 "DELETE" : {
13 "description" : "Delete rule.",
14 "method" : "DELETE",
15 "name" : "delete_rule",
16 "parameters" : {
17 "additionalProperties" : 0,
18 "properties" : {
19 "digest" : {
20 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
21 "maxLength" : 40,
22 "optional" : 1,
23 "type" : "string"
24 },
25 "group" : {
26 "description" : "Security Group name.",
4bd7df8b 27 "maxLength" : 18,
44660702
DM
28 "minLength" : 2,
29 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
30 "type" : "string"
31 },
32 "pos" : {
33 "description" : "Update rule at position <pos>.",
34 "minimum" : 0,
35 "optional" : 1,
4bd7df8b 36 "type" : "integer",
2c0dde61 37 "typetext" : "integer (0 - N)"
44660702
DM
38 }
39 }
40 },
41 "permissions" : {
42 "check" : [
43 "perm",
44 "/",
45 [
46 "Sys.Modify"
47 ]
48 ]
49 },
50 "protected" : 1,
51 "proxyto" : null,
52 "returns" : {
53 "type" : "null"
7aacca6f
DM
54 }
55 },
44660702
DM
56 "GET" : {
57 "description" : "Get single rule data.",
58 "method" : "GET",
59 "name" : "get_rule",
60 "parameters" : {
61 "additionalProperties" : 0,
62 "properties" : {
63 "group" : {
64 "description" : "Security Group name.",
4bd7df8b 65 "maxLength" : 18,
44660702
DM
66 "minLength" : 2,
67 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
68 "type" : "string"
69 },
70 "pos" : {
71 "description" : "Update rule at position <pos>.",
72 "minimum" : 0,
73 "optional" : 1,
4bd7df8b 74 "type" : "integer",
2c0dde61 75 "typetext" : "integer (0 - N)"
44660702 76 }
7aacca6f 77 }
56122987 78 },
44660702
DM
79 "permissions" : {
80 "check" : [
81 "perm",
82 "/",
83 [
84 "Sys.Audit"
85 ]
86 ]
87 },
88 "proxyto" : null,
89 "returns" : {
90 "properties" : {
91 "pos" : {
92 "type" : "integer"
93 }
94 },
95 "type" : "object"
56122987 96 }
44660702 97 },
7aacca6f 98 "PUT" : {
44660702
DM
99 "description" : "Modify rule data.",
100 "method" : "PUT",
101 "name" : "update_rule",
7aacca6f
DM
102 "parameters" : {
103 "additionalProperties" : 0,
104 "properties" : {
44660702
DM
105 "action" : {
106 "description" : "Rule action ('ACCEPT', 'DROP', 'REJECT') or security group name.",
7aacca6f 107 "maxLength" : 20,
44660702 108 "minLength" : 2,
7aacca6f 109 "optional" : 1,
44660702 110 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
7aacca6f
DM
111 "type" : "string"
112 },
44660702 113 "comment" : {
e94f0d56 114 "description" : "Descriptive comment.",
7aacca6f 115 "optional" : 1,
44660702 116 "type" : "string"
7aacca6f 117 },
44660702
DM
118 "delete" : {
119 "description" : "A list of settings you want to delete.",
120 "format" : "pve-configid-list",
7aacca6f 121 "optional" : 1,
44660702 122 "type" : "string"
7aacca6f 123 },
44660702
DM
124 "dest" : {
125 "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.",
126 "format" : "pve-fw-addr-spec",
7aacca6f 127 "optional" : 1,
44660702 128 "type" : "string"
7aacca6f
DM
129 },
130 "digest" : {
131 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
44660702 132 "maxLength" : 40,
7aacca6f 133 "optional" : 1,
44660702 134 "type" : "string"
7aacca6f 135 },
44660702
DM
136 "dport" : {
137 "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.",
138 "format" : "pve-fw-dport-spec",
7aacca6f 139 "optional" : 1,
44660702 140 "type" : "string"
7aacca6f 141 },
44660702 142 "enable" : {
e94f0d56 143 "description" : "Flag to enable/disable a rule.",
44660702 144 "minimum" : 0,
7aacca6f 145 "optional" : 1,
4bd7df8b 146 "type" : "integer",
2c0dde61 147 "typetext" : "integer (0 - N)"
7aacca6f 148 },
44660702
DM
149 "group" : {
150 "description" : "Security Group name.",
4bd7df8b 151 "maxLength" : 18,
44660702
DM
152 "minLength" : 2,
153 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
154 "type" : "string"
155 },
156 "iface" : {
157 "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.",
158 "format" : "pve-iface",
159 "maxLength" : 20,
160 "minLength" : 2,
7aacca6f 161 "optional" : 1,
44660702 162 "type" : "string"
7aacca6f 163 },
44660702 164 "macro" : {
e94f0d56 165 "description" : "Use predefined standard macro.",
44660702
DM
166 "maxLength" : 128,
167 "optional" : 1,
168 "type" : "string"
7aacca6f
DM
169 },
170 "moveto" : {
171 "description" : "Move rule to new position <moveto>. Other arguments are ignored.",
44660702 172 "minimum" : 0,
7aacca6f 173 "optional" : 1,
4bd7df8b 174 "type" : "integer",
2c0dde61 175 "typetext" : "integer (0 - N)"
7aacca6f 176 },
44660702
DM
177 "pos" : {
178 "description" : "Update rule at position <pos>.",
179 "minimum" : 0,
180 "optional" : 1,
4bd7df8b 181 "type" : "integer",
2c0dde61 182 "typetext" : "integer (0 - N)"
7aacca6f 183 },
44660702
DM
184 "proto" : {
185 "description" : "IP protocol. You can use protocol names ('tcp'/'udp') or simple numbers, as defined in '/etc/protocols'.",
186 "format" : "pve-fw-protocol-spec",
7aacca6f 187 "optional" : 1,
44660702
DM
188 "type" : "string"
189 },
190 "source" : {
191 "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.",
192 "format" : "pve-fw-addr-spec",
193 "optional" : 1,
194 "type" : "string"
195 },
196 "sport" : {
197 "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.",
198 "format" : "pve-fw-sport-spec",
199 "optional" : 1,
200 "type" : "string"
7aacca6f
DM
201 },
202 "type" : {
e94f0d56 203 "description" : "Rule type.",
7aacca6f
DM
204 "enum" : [
205 "in",
206 "out",
207 "group"
208 ],
209 "optional" : 1,
210 "type" : "string"
211 }
212 }
213 },
7aacca6f
DM
214 "permissions" : {
215 "check" : [
216 "perm",
217 "/",
218 [
219 "Sys.Modify"
220 ]
221 ]
222 },
44660702 223 "protected" : 1,
7aacca6f
DM
224 "proxyto" : null,
225 "returns" : {
226 "type" : "null"
227 }
7aacca6f
DM
228 }
229 },
44660702 230 "leaf" : 1,
7aacca6f 231 "path" : "/cluster/firewall/groups/{group}/{pos}",
44660702 232 "text" : "{pos}"
7aacca6f
DM
233 }
234 ],
44660702
DM
235 "info" : {
236 "DELETE" : {
237 "description" : "Delete security group.",
238 "method" : "DELETE",
239 "name" : "delete_security_group",
240 "parameters" : {
241 "additionalProperties" : 0,
242 "properties" : {
243 "group" : {
244 "description" : "Security Group name.",
4bd7df8b 245 "maxLength" : 18,
44660702
DM
246 "minLength" : 2,
247 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
248 "type" : "string"
249 }
56122987 250 }
7aacca6f 251 },
44660702
DM
252 "permissions" : {
253 "check" : [
254 "perm",
255 "/",
256 [
257 "Sys.Modify"
258 ]
7aacca6f 259 ]
56122987 260 },
44660702
DM
261 "protected" : 1,
262 "returns" : {
263 "type" : "null"
56122987 264 }
7aacca6f 265 },
7aacca6f 266 "GET" : {
44660702 267 "description" : "List rules.",
7aacca6f 268 "method" : "GET",
44660702
DM
269 "name" : "get_rules",
270 "parameters" : {
271 "additionalProperties" : 0,
7aacca6f 272 "properties" : {
44660702
DM
273 "group" : {
274 "description" : "Security Group name.",
4bd7df8b 275 "maxLength" : 18,
44660702
DM
276 "minLength" : 2,
277 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
278 "type" : "string"
7aacca6f 279 }
44660702 280 }
7aacca6f
DM
281 },
282 "permissions" : {
283 "check" : [
284 "perm",
285 "/",
286 [
287 "Sys.Audit"
288 ]
289 ]
290 },
44660702
DM
291 "proxyto" : null,
292 "returns" : {
293 "items" : {
294 "properties" : {
295 "pos" : {
296 "type" : "integer"
297 }
298 },
299 "type" : "object"
300 },
301 "links" : [
302 {
303 "href" : "{pos}",
304 "rel" : "child"
305 }
306 ],
307 "type" : "array"
308 }
309 },
310 "POST" : {
311 "description" : "Create new rule.",
312 "method" : "POST",
313 "name" : "create_rule",
7aacca6f
DM
314 "parameters" : {
315 "additionalProperties" : 0,
316 "properties" : {
44660702
DM
317 "action" : {
318 "description" : "Rule action ('ACCEPT', 'DROP', 'REJECT') or security group name.",
319 "maxLength" : 20,
56122987 320 "minLength" : 2,
44660702
DM
321 "optional" : 0,
322 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
7aacca6f 323 "type" : "string"
56122987 324 },
44660702 325 "comment" : {
e94f0d56 326 "description" : "Descriptive comment.",
56122987 327 "optional" : 1,
7aacca6f 328 "type" : "string"
56122987 329 },
44660702
DM
330 "dest" : {
331 "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.",
56122987
DM
332 "format" : "pve-fw-addr-spec",
333 "optional" : 1,
44660702 334 "type" : "string"
56122987 335 },
44660702
DM
336 "digest" : {
337 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
338 "maxLength" : 40,
7aacca6f 339 "optional" : 1,
44660702 340 "type" : "string"
56122987 341 },
44660702
DM
342 "dport" : {
343 "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.",
344 "format" : "pve-fw-dport-spec",
56122987 345 "optional" : 1,
44660702 346 "type" : "string"
56122987 347 },
7aacca6f 348 "enable" : {
e94f0d56 349 "description" : "Flag to enable/disable a rule.",
44660702 350 "minimum" : 0,
7aacca6f 351 "optional" : 1,
4bd7df8b 352 "type" : "integer",
2c0dde61 353 "typetext" : "integer (0 - N)"
56122987 354 },
44660702
DM
355 "group" : {
356 "description" : "Security Group name.",
4bd7df8b 357 "maxLength" : 18,
44660702 358 "minLength" : 2,
7aacca6f 359 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
44660702
DM
360 "type" : "string"
361 },
362 "iface" : {
363 "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.",
364 "format" : "pve-iface",
365 "maxLength" : 20,
7aacca6f 366 "minLength" : 2,
44660702
DM
367 "optional" : 1,
368 "type" : "string"
56122987 369 },
7aacca6f 370 "macro" : {
e94f0d56 371 "description" : "Use predefined standard macro.",
44660702 372 "maxLength" : 128,
7aacca6f 373 "optional" : 1,
44660702 374 "type" : "string"
7aacca6f
DM
375 },
376 "pos" : {
377 "description" : "Update rule at position <pos>.",
44660702 378 "minimum" : 0,
56122987 379 "optional" : 1,
4bd7df8b 380 "type" : "integer",
2c0dde61 381 "typetext" : "integer (0 - N)"
7aacca6f
DM
382 },
383 "proto" : {
384 "description" : "IP protocol. You can use protocol names ('tcp'/'udp') or simple numbers, as defined in '/etc/protocols'.",
44660702 385 "format" : "pve-fw-protocol-spec",
7aacca6f 386 "optional" : 1,
44660702
DM
387 "type" : "string"
388 },
389 "source" : {
390 "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.",
391 "format" : "pve-fw-addr-spec",
392 "optional" : 1,
393 "type" : "string"
394 },
395 "sport" : {
396 "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.",
397 "format" : "pve-fw-sport-spec",
398 "optional" : 1,
399 "type" : "string"
400 },
401 "type" : {
e94f0d56 402 "description" : "Rule type.",
44660702
DM
403 "enum" : [
404 "in",
405 "out",
406 "group"
407 ],
408 "optional" : 0,
409 "type" : "string"
56122987 410 }
44660702 411 }
56122987 412 },
56122987
DM
413 "permissions" : {
414 "check" : [
415 "perm",
416 "/",
417 [
418 "Sys.Modify"
419 ]
420 ]
421 },
44660702
DM
422 "protected" : 1,
423 "proxyto" : null,
56122987
DM
424 "returns" : {
425 "type" : "null"
7aacca6f 426 }
44660702
DM
427 }
428 },
429 "leaf" : 0,
430 "path" : "/cluster/firewall/groups/{group}",
431 "text" : "{group}"
432 }
433 ],
434 "info" : {
435 "GET" : {
436 "description" : "List security groups.",
437 "method" : "GET",
438 "name" : "list_security_groups",
439 "parameters" : {
440 "additionalProperties" : 0
441 },
442 "permissions" : {
443 "user" : "all"
444 },
445 "returns" : {
446 "items" : {
447 "properties" : {
448 "comment" : {
449 "optional" : 1,
450 "type" : "string"
451 },
452 "digest" : {
453 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
454 "maxLength" : 40,
455 "optional" : 0,
456 "type" : "string"
457 },
458 "group" : {
459 "description" : "Security Group name.",
4bd7df8b 460 "maxLength" : 18,
44660702
DM
461 "minLength" : 2,
462 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
463 "type" : "string"
464 }
465 },
466 "type" : "object"
56122987 467 },
44660702
DM
468 "links" : [
469 {
470 "href" : "{group}",
471 "rel" : "child"
472 }
473 ],
474 "type" : "array"
475 }
476 },
477 "POST" : {
478 "description" : "Create new security group.",
479 "method" : "POST",
480 "name" : "create_security_group",
481 "parameters" : {
482 "additionalProperties" : 0,
483 "properties" : {
484 "comment" : {
485 "optional" : 1,
486 "type" : "string"
487 },
488 "digest" : {
489 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
490 "maxLength" : 40,
491 "optional" : 1,
492 "type" : "string"
493 },
494 "group" : {
495 "description" : "Security Group name.",
4bd7df8b 496 "maxLength" : 18,
44660702
DM
497 "minLength" : 2,
498 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
499 "type" : "string"
500 },
501 "rename" : {
502 "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.",
4bd7df8b 503 "maxLength" : 18,
44660702
DM
504 "minLength" : 2,
505 "optional" : 1,
506 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
507 "type" : "string"
508 }
509 }
510 },
511 "permissions" : {
512 "check" : [
513 "perm",
514 "/",
515 [
516 "Sys.Modify"
517 ]
518 ]
519 },
520 "protected" : 1,
521 "returns" : {
522 "type" : "null"
523 }
524 }
525 },
526 "leaf" : 0,
527 "path" : "/cluster/firewall/groups",
528 "text" : "groups"
529 },
530 {
531 "children" : [
532 {
533 "info" : {
7aacca6f 534 "DELETE" : {
44660702
DM
535 "description" : "Delete rule.",
536 "method" : "DELETE",
537 "name" : "delete_rule",
538 "parameters" : {
539 "additionalProperties" : 0,
540 "properties" : {
541 "digest" : {
542 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
543 "maxLength" : 40,
544 "optional" : 1,
545 "type" : "string"
546 },
547 "pos" : {
548 "description" : "Update rule at position <pos>.",
549 "minimum" : 0,
550 "optional" : 1,
4bd7df8b 551 "type" : "integer",
2c0dde61 552 "typetext" : "integer (0 - N)"
44660702
DM
553 }
554 }
555 },
56122987
DM
556 "permissions" : {
557 "check" : [
558 "perm",
559 "/",
560 [
7aacca6f 561 "Sys.Modify"
56122987
DM
562 ]
563 ]
564 },
44660702 565 "protected" : 1,
56122987
DM
566 "proxyto" : null,
567 "returns" : {
7aacca6f 568 "type" : "null"
44660702
DM
569 }
570 },
571 "GET" : {
572 "description" : "Get single rule data.",
573 "method" : "GET",
574 "name" : "get_rule",
56122987
DM
575 "parameters" : {
576 "additionalProperties" : 0,
577 "properties" : {
578 "pos" : {
7aacca6f 579 "description" : "Update rule at position <pos>.",
44660702 580 "minimum" : 0,
56122987 581 "optional" : 1,
4bd7df8b 582 "type" : "integer",
2c0dde61 583 "typetext" : "integer (0 - N)"
7aacca6f
DM
584 }
585 }
586 },
7aacca6f
DM
587 "permissions" : {
588 "check" : [
589 "perm",
590 "/",
591 [
592 "Sys.Audit"
593 ]
594 ]
56122987 595 },
44660702
DM
596 "proxyto" : null,
597 "returns" : {
7aacca6f 598 "properties" : {
44660702
DM
599 "pos" : {
600 "type" : "integer"
7aacca6f 601 }
44660702
DM
602 },
603 "type" : "object"
604 }
56122987 605 },
44660702
DM
606 "PUT" : {
607 "description" : "Modify rule data.",
608 "method" : "PUT",
609 "name" : "update_rule",
7aacca6f
DM
610 "parameters" : {
611 "additionalProperties" : 0,
612 "properties" : {
44660702
DM
613 "action" : {
614 "description" : "Rule action ('ACCEPT', 'DROP', 'REJECT') or security group name.",
615 "maxLength" : 20,
616 "minLength" : 2,
617 "optional" : 1,
618 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
619 "type" : "string"
7aacca6f 620 },
44660702 621 "comment" : {
e94f0d56 622 "description" : "Descriptive comment.",
44660702
DM
623 "optional" : 1,
624 "type" : "string"
7aacca6f 625 },
44660702
DM
626 "delete" : {
627 "description" : "A list of settings you want to delete.",
628 "format" : "pve-configid-list",
629 "optional" : 1,
630 "type" : "string"
631 },
632 "dest" : {
633 "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.",
634 "format" : "pve-fw-addr-spec",
635 "optional" : 1,
636 "type" : "string"
637 },
638 "digest" : {
639 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
640 "maxLength" : 40,
641 "optional" : 1,
642 "type" : "string"
643 },
644 "dport" : {
645 "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.",
646 "format" : "pve-fw-dport-spec",
647 "optional" : 1,
648 "type" : "string"
649 },
650 "enable" : {
e94f0d56 651 "description" : "Flag to enable/disable a rule.",
44660702
DM
652 "minimum" : 0,
653 "optional" : 1,
4bd7df8b 654 "type" : "integer",
2c0dde61 655 "typetext" : "integer (0 - N)"
44660702
DM
656 },
657 "iface" : {
658 "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.",
659 "format" : "pve-iface",
660 "maxLength" : 20,
7aacca6f 661 "minLength" : 2,
44660702
DM
662 "optional" : 1,
663 "type" : "string"
7aacca6f 664 },
44660702 665 "macro" : {
e94f0d56 666 "description" : "Use predefined standard macro.",
44660702
DM
667 "maxLength" : 128,
668 "optional" : 1,
669 "type" : "string"
670 },
671 "moveto" : {
672 "description" : "Move rule to new position <moveto>. Other arguments are ignored.",
673 "minimum" : 0,
674 "optional" : 1,
4bd7df8b 675 "type" : "integer",
2c0dde61 676 "typetext" : "integer (0 - N)"
44660702
DM
677 },
678 "pos" : {
679 "description" : "Update rule at position <pos>.",
680 "minimum" : 0,
681 "optional" : 1,
4bd7df8b 682 "type" : "integer",
2c0dde61 683 "typetext" : "integer (0 - N)"
44660702
DM
684 },
685 "proto" : {
686 "description" : "IP protocol. You can use protocol names ('tcp'/'udp') or simple numbers, as defined in '/etc/protocols'.",
687 "format" : "pve-fw-protocol-spec",
688 "optional" : 1,
689 "type" : "string"
690 },
691 "source" : {
692 "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.",
693 "format" : "pve-fw-addr-spec",
694 "optional" : 1,
695 "type" : "string"
696 },
697 "sport" : {
698 "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.",
699 "format" : "pve-fw-sport-spec",
700 "optional" : 1,
701 "type" : "string"
702 },
703 "type" : {
e94f0d56 704 "description" : "Rule type.",
44660702
DM
705 "enum" : [
706 "in",
707 "out",
708 "group"
709 ],
710 "optional" : 1,
711 "type" : "string"
7aacca6f 712 }
56122987
DM
713 }
714 },
7aacca6f
DM
715 "permissions" : {
716 "check" : [
717 "perm",
718 "/",
719 [
720 "Sys.Modify"
721 ]
722 ]
723 },
44660702
DM
724 "protected" : 1,
725 "proxyto" : null,
726 "returns" : {
727 "type" : "null"
728 }
7aacca6f 729 }
56122987 730 },
44660702
DM
731 "leaf" : 1,
732 "path" : "/cluster/firewall/rules/{pos}",
733 "text" : "{pos}"
7aacca6f
DM
734 }
735 ],
7aacca6f 736 "info" : {
44660702
DM
737 "GET" : {
738 "description" : "List rules.",
739 "method" : "GET",
740 "name" : "get_rules",
7aacca6f 741 "parameters" : {
44660702 742 "additionalProperties" : 0
7aacca6f
DM
743 },
744 "permissions" : {
745 "check" : [
746 "perm",
747 "/",
748 [
44660702 749 "Sys.Audit"
7aacca6f
DM
750 ]
751 ]
752 },
44660702 753 "proxyto" : null,
7aacca6f 754 "returns" : {
7aacca6f
DM
755 "items" : {
756 "properties" : {
44660702
DM
757 "pos" : {
758 "type" : "integer"
7aacca6f
DM
759 }
760 },
761 "type" : "object"
56122987 762 },
7aacca6f
DM
763 "links" : [
764 {
44660702 765 "href" : "{pos}",
7aacca6f
DM
766 "rel" : "child"
767 }
44660702
DM
768 ],
769 "type" : "array"
7aacca6f 770 }
44660702 771 },
7aacca6f 772 "POST" : {
44660702 773 "description" : "Create new rule.",
7aacca6f 774 "method" : "POST",
44660702 775 "name" : "create_rule",
7aacca6f
DM
776 "parameters" : {
777 "additionalProperties" : 0,
778 "properties" : {
44660702
DM
779 "action" : {
780 "description" : "Rule action ('ACCEPT', 'DROP', 'REJECT') or security group name.",
781 "maxLength" : 20,
7aacca6f 782 "minLength" : 2,
44660702
DM
783 "optional" : 0,
784 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
785 "type" : "string"
7aacca6f
DM
786 },
787 "comment" : {
e94f0d56 788 "description" : "Descriptive comment.",
7aacca6f
DM
789 "optional" : 1,
790 "type" : "string"
44660702
DM
791 },
792 "dest" : {
793 "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.",
794 "format" : "pve-fw-addr-spec",
795 "optional" : 1,
796 "type" : "string"
797 },
798 "digest" : {
799 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
800 "maxLength" : 40,
801 "optional" : 1,
802 "type" : "string"
803 },
804 "dport" : {
805 "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.",
806 "format" : "pve-fw-dport-spec",
807 "optional" : 1,
808 "type" : "string"
809 },
810 "enable" : {
e94f0d56 811 "description" : "Flag to enable/disable a rule.",
44660702
DM
812 "minimum" : 0,
813 "optional" : 1,
4bd7df8b 814 "type" : "integer",
2c0dde61 815 "typetext" : "integer (0 - N)"
44660702
DM
816 },
817 "iface" : {
818 "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.",
819 "format" : "pve-iface",
820 "maxLength" : 20,
821 "minLength" : 2,
822 "optional" : 1,
823 "type" : "string"
824 },
825 "macro" : {
e94f0d56 826 "description" : "Use predefined standard macro.",
44660702
DM
827 "maxLength" : 128,
828 "optional" : 1,
829 "type" : "string"
830 },
831 "pos" : {
832 "description" : "Update rule at position <pos>.",
833 "minimum" : 0,
834 "optional" : 1,
4bd7df8b 835 "type" : "integer",
2c0dde61 836 "typetext" : "integer (0 - N)"
44660702
DM
837 },
838 "proto" : {
839 "description" : "IP protocol. You can use protocol names ('tcp'/'udp') or simple numbers, as defined in '/etc/protocols'.",
840 "format" : "pve-fw-protocol-spec",
841 "optional" : 1,
842 "type" : "string"
843 },
844 "source" : {
845 "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.",
846 "format" : "pve-fw-addr-spec",
847 "optional" : 1,
848 "type" : "string"
849 },
850 "sport" : {
851 "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.",
852 "format" : "pve-fw-sport-spec",
853 "optional" : 1,
854 "type" : "string"
855 },
856 "type" : {
e94f0d56 857 "description" : "Rule type.",
44660702
DM
858 "enum" : [
859 "in",
860 "out",
861 "group"
862 ],
863 "optional" : 0,
864 "type" : "string"
7aacca6f
DM
865 }
866 }
867 },
868 "permissions" : {
869 "check" : [
870 "perm",
871 "/",
872 [
873 "Sys.Modify"
874 ]
875 ]
876 },
44660702
DM
877 "protected" : 1,
878 "proxyto" : null,
7aacca6f 879 "returns" : {
44660702
DM
880 "type" : "null"
881 }
882 }
883 },
884 "leaf" : 0,
885 "path" : "/cluster/firewall/rules",
886 "text" : "rules"
887 },
888 {
889 "children" : [
890 {
891 "children" : [
892 {
893 "info" : {
894 "DELETE" : {
895 "description" : "Remove IP or Network from IPSet.",
896 "method" : "DELETE",
897 "name" : "remove_ip",
898 "parameters" : {
899 "additionalProperties" : 0,
900 "properties" : {
901 "cidr" : {
902 "description" : "Network/IP specification in CIDR format.",
903 "format" : "IPorCIDRorAlias",
904 "type" : "string"
905 },
906 "digest" : {
907 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
908 "maxLength" : 40,
909 "optional" : 1,
910 "type" : "string"
911 },
912 "name" : {
913 "description" : "IP set name.",
914 "maxLength" : 64,
915 "minLength" : 2,
916 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
917 "type" : "string"
918 }
919 }
920 },
921 "permissions" : {
922 "check" : [
923 "perm",
924 "/",
925 [
926 "Sys.Modify"
927 ]
928 ]
929 },
930 "protected" : 1,
931 "returns" : {
932 "type" : "null"
933 }
7aacca6f 934 },
44660702
DM
935 "GET" : {
936 "description" : "Read IP or Network settings from IPSet.",
937 "method" : "GET",
938 "name" : "read_ip",
939 "parameters" : {
940 "additionalProperties" : 0,
941 "properties" : {
942 "cidr" : {
943 "description" : "Network/IP specification in CIDR format.",
944 "format" : "IPorCIDRorAlias",
945 "type" : "string"
946 },
947 "name" : {
948 "description" : "IP set name.",
949 "maxLength" : 64,
950 "minLength" : 2,
951 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
952 "type" : "string"
953 }
954 }
955 },
956 "permissions" : {
957 "check" : [
958 "perm",
959 "/",
960 [
961 "Sys.Audit"
962 ]
963 ]
964 },
965 "protected" : 1,
966 "returns" : {
967 "type" : "object"
968 }
7aacca6f 969 },
44660702
DM
970 "PUT" : {
971 "description" : "Update IP or Network settings",
972 "method" : "PUT",
973 "name" : "update_ip",
974 "parameters" : {
975 "additionalProperties" : 0,
976 "properties" : {
977 "cidr" : {
978 "description" : "Network/IP specification in CIDR format.",
979 "format" : "IPorCIDRorAlias",
980 "type" : "string"
981 },
982 "comment" : {
983 "optional" : 1,
984 "type" : "string"
985 },
986 "digest" : {
987 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
988 "maxLength" : 40,
989 "optional" : 1,
990 "type" : "string"
991 },
992 "name" : {
993 "description" : "IP set name.",
994 "maxLength" : 64,
995 "minLength" : 2,
996 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
997 "type" : "string"
998 },
999 "nomatch" : {
1000 "optional" : 1,
1001 "type" : "boolean"
1002 }
1003 }
1004 },
1005 "permissions" : {
1006 "check" : [
1007 "perm",
1008 "/",
1009 [
1010 "Sys.Modify"
1011 ]
1012 ]
1013 },
1014 "protected" : 1,
1015 "returns" : {
1016 "type" : "null"
1017 }
7aacca6f
DM
1018 }
1019 },
44660702
DM
1020 "leaf" : 1,
1021 "path" : "/cluster/firewall/ipset/{name}/{cidr}",
1022 "text" : "{cidr}"
7aacca6f 1023 }
44660702 1024 ],
7aacca6f
DM
1025 "info" : {
1026 "DELETE" : {
44660702
DM
1027 "description" : "Delete IPSet",
1028 "method" : "DELETE",
1029 "name" : "delete_ipset",
56122987 1030 "parameters" : {
44660702 1031 "additionalProperties" : 0,
56122987
DM
1032 "properties" : {
1033 "name" : {
44660702 1034 "description" : "IP set name.",
56122987 1035 "maxLength" : 64,
44660702 1036 "minLength" : 2,
56122987 1037 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
44660702 1038 "type" : "string"
56122987 1039 }
44660702 1040 }
7aacca6f 1041 },
56122987
DM
1042 "permissions" : {
1043 "check" : [
1044 "perm",
1045 "/",
1046 [
1047 "Sys.Modify"
1048 ]
1049 ]
1050 },
7aacca6f
DM
1051 "protected" : 1,
1052 "returns" : {
1053 "type" : "null"
44660702 1054 }
7aacca6f 1055 },
44660702
DM
1056 "GET" : {
1057 "description" : "List IPSet content",
1058 "method" : "GET",
1059 "name" : "get_ipset",
56122987
DM
1060 "parameters" : {
1061 "additionalProperties" : 0,
1062 "properties" : {
7aacca6f 1063 "name" : {
44660702 1064 "description" : "IP set name.",
7aacca6f 1065 "maxLength" : 64,
7aacca6f 1066 "minLength" : 2,
44660702 1067 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
56122987 1068 "type" : "string"
56122987 1069 }
7aacca6f 1070 }
56122987 1071 },
56122987
DM
1072 "permissions" : {
1073 "check" : [
1074 "perm",
1075 "/",
1076 [
44660702 1077 "Sys.Audit"
56122987
DM
1078 ]
1079 ]
44660702
DM
1080 },
1081 "returns" : {
1082 "items" : {
1083 "properties" : {
1084 "cidr" : {
1085 "type" : "string"
1086 },
1087 "comment" : {
1088 "optional" : 1,
1089 "type" : "string"
1090 },
1091 "digest" : {
1092 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
1093 "maxLength" : 40,
1094 "optional" : 0,
1095 "type" : "string"
1096 },
1097 "nomatch" : {
1098 "optional" : 1,
1099 "type" : "boolean"
1100 }
1101 },
1102 "type" : "object"
1103 },
1104 "links" : [
1105 {
1106 "href" : "{cidr}",
1107 "rel" : "child"
1108 }
1109 ],
1110 "type" : "array"
7aacca6f
DM
1111 }
1112 },
44660702
DM
1113 "POST" : {
1114 "description" : "Add IP or Network to IPSet.",
1115 "method" : "POST",
1116 "name" : "create_ip",
56122987
DM
1117 "parameters" : {
1118 "additionalProperties" : 0,
1119 "properties" : {
44660702
DM
1120 "cidr" : {
1121 "description" : "Network/IP specification in CIDR format.",
1122 "format" : "IPorCIDRorAlias",
1123 "type" : "string"
1124 },
1125 "comment" : {
1126 "optional" : 1,
1127 "type" : "string"
1128 },
1129 "name" : {
1130 "description" : "IP set name.",
1131 "maxLength" : 64,
1132 "minLength" : 2,
1133 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
1134 "type" : "string"
1135 },
1136 "nomatch" : {
1137 "optional" : 1,
1138 "type" : "boolean"
56122987
DM
1139 }
1140 }
1141 },
56122987
DM
1142 "permissions" : {
1143 "check" : [
1144 "perm",
1145 "/",
1146 [
44660702 1147 "Sys.Modify"
56122987
DM
1148 ]
1149 ]
1150 },
44660702 1151 "protected" : 1,
56122987 1152 "returns" : {
44660702
DM
1153 "type" : "null"
1154 }
56122987
DM
1155 }
1156 },
44660702
DM
1157 "leaf" : 0,
1158 "path" : "/cluster/firewall/ipset/{name}",
1159 "text" : "{name}"
56122987
DM
1160 }
1161 ],
56122987 1162 "info" : {
44660702
DM
1163 "GET" : {
1164 "description" : "List IPSets",
1165 "method" : "GET",
1166 "name" : "ipset_index",
56122987 1167 "parameters" : {
7aacca6f 1168 "additionalProperties" : 0
56122987 1169 },
56122987
DM
1170 "permissions" : {
1171 "check" : [
1172 "perm",
1173 "/",
1174 [
7aacca6f 1175 "Sys.Audit"
56122987
DM
1176 ]
1177 ]
1178 },
56122987
DM
1179 "returns" : {
1180 "items" : {
1181 "properties" : {
44660702
DM
1182 "comment" : {
1183 "optional" : 1,
1184 "type" : "string"
56122987 1185 },
44660702
DM
1186 "digest" : {
1187 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
1188 "maxLength" : 40,
1189 "optional" : 0,
1190 "type" : "string"
1191 },
1192 "name" : {
1193 "description" : "IP set name.",
1194 "maxLength" : 64,
1195 "minLength" : 2,
1196 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
7aacca6f 1197 "type" : "string"
56122987
DM
1198 }
1199 },
1200 "type" : "object"
44660702
DM
1201 },
1202 "links" : [
1203 {
1204 "href" : "{name}",
1205 "rel" : "child"
1206 }
1207 ],
1208 "type" : "array"
56122987 1209 }
44660702
DM
1210 },
1211 "POST" : {
1212 "description" : "Create new IPSet",
1213 "method" : "POST",
1214 "name" : "create_ipset",
7aacca6f
DM
1215 "parameters" : {
1216 "additionalProperties" : 0,
1217 "properties" : {
44660702
DM
1218 "comment" : {
1219 "optional" : 1,
1220 "type" : "string"
1221 },
1222 "digest" : {
1223 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
1224 "maxLength" : 40,
1225 "optional" : 1,
1226 "type" : "string"
1227 },
1228 "name" : {
1229 "description" : "IP set name.",
1230 "maxLength" : 64,
1231 "minLength" : 2,
1232 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
1233 "type" : "string"
1234 },
1235 "rename" : {
1236 "description" : "Rename an existing IPSet. You can set 'rename' to the same value as 'name' to update the 'comment' of an existing IPSet.",
1237 "maxLength" : 64,
1238 "minLength" : 2,
1239 "optional" : 1,
1240 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
1241 "type" : "string"
7aacca6f
DM
1242 }
1243 }
1244 },
56122987
DM
1245 "permissions" : {
1246 "check" : [
1247 "perm",
1248 "/",
1249 [
44660702 1250 "Sys.Modify"
56122987
DM
1251 ]
1252 ]
1253 },
44660702 1254 "protected" : 1,
56122987 1255 "returns" : {
44660702
DM
1256 "type" : "null"
1257 }
56122987 1258 }
7aacca6f 1259 },
44660702
DM
1260 "leaf" : 0,
1261 "path" : "/cluster/firewall/ipset",
1262 "text" : "ipset"
1263 },
56122987 1264 {
44660702
DM
1265 "children" : [
1266 {
1267 "info" : {
1268 "DELETE" : {
1269 "description" : "Remove IP or Network alias.",
1270 "method" : "DELETE",
1271 "name" : "remove_alias",
1272 "parameters" : {
1273 "additionalProperties" : 0,
1274 "properties" : {
1275 "digest" : {
1276 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
1277 "maxLength" : 40,
1278 "optional" : 1,
1279 "type" : "string"
1280 },
1281 "name" : {
1282 "description" : "Alias name.",
1283 "maxLength" : 64,
1284 "minLength" : 2,
1285 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
1286 "type" : "string"
1287 }
1288 }
1289 },
1290 "permissions" : {
1291 "check" : [
1292 "perm",
1293 "/",
1294 [
1295 "Sys.Modify"
1296 ]
1297 ]
1298 },
1299 "protected" : 1,
1300 "returns" : {
1301 "type" : "null"
1302 }
1303 },
1304 "GET" : {
1305 "description" : "Read alias.",
1306 "method" : "GET",
1307 "name" : "read_alias",
1308 "parameters" : {
1309 "additionalProperties" : 0,
1310 "properties" : {
1311 "name" : {
1312 "description" : "Alias name.",
1313 "maxLength" : 64,
1314 "minLength" : 2,
1315 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
1316 "type" : "string"
1317 }
1318 }
1319 },
1320 "permissions" : {
1321 "check" : [
1322 "perm",
1323 "/",
1324 [
1325 "Sys.Audit"
1326 ]
1327 ]
1328 },
1329 "returns" : {
1330 "type" : "object"
1331 }
1332 },
1333 "PUT" : {
1334 "description" : "Update IP or Network alias.",
1335 "method" : "PUT",
1336 "name" : "update_alias",
1337 "parameters" : {
1338 "additionalProperties" : 0,
1339 "properties" : {
1340 "cidr" : {
1341 "description" : "Network/IP specification in CIDR format.",
1342 "format" : "IPorCIDR",
1343 "type" : "string"
1344 },
1345 "comment" : {
1346 "optional" : 1,
1347 "type" : "string"
1348 },
1349 "digest" : {
1350 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
1351 "maxLength" : 40,
1352 "optional" : 1,
1353 "type" : "string"
1354 },
1355 "name" : {
1356 "description" : "Alias name.",
1357 "maxLength" : 64,
1358 "minLength" : 2,
1359 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
1360 "type" : "string"
1361 },
1362 "rename" : {
1363 "description" : "Rename an existing alias.",
1364 "maxLength" : 64,
1365 "minLength" : 2,
1366 "optional" : 1,
1367 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
1368 "type" : "string"
1369 }
1370 }
1371 },
1372 "permissions" : {
1373 "check" : [
1374 "perm",
1375 "/",
1376 [
1377 "Sys.Modify"
1378 ]
1379 ]
1380 },
1381 "protected" : 1,
1382 "returns" : {
1383 "type" : "null"
1384 }
1385 }
1386 },
1387 "leaf" : 1,
1388 "path" : "/cluster/firewall/aliases/{name}",
1389 "text" : "{name}"
1390 }
1391 ],
1392 "info" : {
1393 "GET" : {
1394 "description" : "List aliases",
1395 "method" : "GET",
1396 "name" : "get_aliases",
1397 "parameters" : {
1398 "additionalProperties" : 0
1399 },
1400 "permissions" : {
1401 "check" : [
1402 "perm",
1403 "/",
1404 [
1405 "Sys.Audit"
1406 ]
1407 ]
1408 },
1409 "returns" : {
1410 "items" : {
1411 "properties" : {
1412 "cidr" : {
1413 "type" : "string"
1414 },
1415 "comment" : {
1416 "optional" : 1,
1417 "type" : "string"
1418 },
1419 "digest" : {
1420 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
1421 "maxLength" : 40,
1422 "optional" : 0,
1423 "type" : "string"
1424 },
1425 "name" : {
1426 "type" : "string"
1427 }
1428 },
1429 "type" : "object"
1430 },
1431 "links" : [
1432 {
1433 "href" : "{name}",
1434 "rel" : "child"
1435 }
1436 ],
1437 "type" : "array"
1438 }
1439 },
1440 "POST" : {
1441 "description" : "Create IP or Network Alias.",
1442 "method" : "POST",
1443 "name" : "create_alias",
56122987
DM
1444 "parameters" : {
1445 "additionalProperties" : 0,
1446 "properties" : {
44660702
DM
1447 "cidr" : {
1448 "description" : "Network/IP specification in CIDR format.",
1449 "format" : "IPorCIDR",
1450 "type" : "string"
1451 },
1452 "comment" : {
1453 "optional" : 1,
1454 "type" : "string"
1455 },
1456 "name" : {
1457 "description" : "Alias name.",
1458 "maxLength" : 64,
1459 "minLength" : 2,
1460 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
1461 "type" : "string"
56122987
DM
1462 }
1463 }
1464 },
56122987
DM
1465 "permissions" : {
1466 "check" : [
1467 "perm",
1468 "/",
1469 [
1470 "Sys.Modify"
1471 ]
1472 ]
1473 },
44660702 1474 "protected" : 1,
56122987
DM
1475 "returns" : {
1476 "type" : "null"
1477 }
44660702
DM
1478 }
1479 },
1480 "leaf" : 0,
1481 "path" : "/cluster/firewall/aliases",
1482 "text" : "aliases"
1483 },
1484 {
1485 "info" : {
1486 "GET" : {
1487 "description" : "Get Firewall options.",
1488 "method" : "GET",
1489 "name" : "get_options",
1490 "parameters" : {
1491 "additionalProperties" : 0
7aacca6f 1492 },
56122987
DM
1493 "permissions" : {
1494 "check" : [
1495 "perm",
1496 "/",
1497 [
44660702 1498 "Sys.Audit"
56122987
DM
1499 ]
1500 ]
1501 },
44660702 1502 "returns" : {
56122987 1503 "properties" : {
44660702
DM
1504 "enable" : {
1505 "description" : "Enable or disable the firewall cluster wide.",
1506 "minimum" : 0,
56122987 1507 "optional" : 1,
7aacca6f 1508 "type" : "integer"
56122987 1509 },
44660702
DM
1510 "policy_in" : {
1511 "description" : "Input policy.",
1512 "enum" : [
1513 "ACCEPT",
1514 "REJECT",
1515 "DROP"
1516 ],
56122987 1517 "optional" : 1,
44660702 1518 "type" : "string"
7aacca6f 1519 },
44660702
DM
1520 "policy_out" : {
1521 "description" : "Output policy.",
1522 "enum" : [
1523 "ACCEPT",
1524 "REJECT",
1525 "DROP"
1526 ],
7aacca6f 1527 "optional" : 1,
44660702
DM
1528 "type" : "string"
1529 }
1530 },
1531 "type" : "object"
1532 }
1533 },
1534 "PUT" : {
1535 "description" : "Set Firewall options.",
1536 "method" : "PUT",
1537 "name" : "set_options",
1538 "parameters" : {
1539 "additionalProperties" : 0,
1540 "properties" : {
1541 "delete" : {
1542 "description" : "A list of settings you want to delete.",
1543 "format" : "pve-configid-list",
56122987 1544 "optional" : 1,
44660702 1545 "type" : "string"
56122987 1546 },
44660702
DM
1547 "digest" : {
1548 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
1549 "maxLength" : 40,
56122987 1550 "optional" : 1,
44660702 1551 "type" : "string"
56122987 1552 },
44660702
DM
1553 "enable" : {
1554 "description" : "Enable or disable the firewall cluster wide.",
7aacca6f 1555 "minimum" : 0,
56122987 1556 "optional" : 1,
4bd7df8b 1557 "type" : "integer",
2c0dde61 1558 "typetext" : "integer (0 - N)"
56122987 1559 },
44660702
DM
1560 "policy_in" : {
1561 "description" : "Input policy.",
56122987 1562 "enum" : [
44660702
DM
1563 "ACCEPT",
1564 "REJECT",
1565 "DROP"
56122987 1566 ],
56122987 1567 "optional" : 1,
44660702 1568 "type" : "string"
56122987 1569 },
44660702
DM
1570 "policy_out" : {
1571 "description" : "Output policy.",
56122987 1572 "enum" : [
44660702
DM
1573 "ACCEPT",
1574 "REJECT",
1575 "DROP"
56122987 1576 ],
7aacca6f 1577 "optional" : 1,
44660702 1578 "type" : "string"
56122987 1579 }
44660702
DM
1580 }
1581 },
1582 "permissions" : {
1583 "check" : [
1584 "perm",
1585 "/",
1586 [
1587 "Sys.Modify"
1588 ]
1589 ]
7aacca6f
DM
1590 },
1591 "protected" : 1,
44660702
DM
1592 "returns" : {
1593 "type" : "null"
1594 }
1595 }
1596 },
1597 "leaf" : 1,
1598 "path" : "/cluster/firewall/options",
1599 "text" : "options"
1600 },
1601 {
1602 "info" : {
7aacca6f 1603 "GET" : {
44660702 1604 "description" : "List available macros",
7aacca6f 1605 "method" : "GET",
44660702
DM
1606 "name" : "get_macros",
1607 "parameters" : {
1608 "additionalProperties" : 0
7aacca6f 1609 },
44660702
DM
1610 "permissions" : {
1611 "user" : "all"
1612 },
1613 "returns" : {
1614 "items" : {
1615 "properties" : {
1616 "descr" : {
1617 "description" : "More verbose description (if available).",
1618 "type" : "string"
1619 },
1620 "macro" : {
1621 "description" : "Macro name.",
1622 "type" : "string"
1623 }
1624 },
1625 "type" : "object"
1626 },
1627 "type" : "array"
1628 }
1629 }
1630 },
1631 "leaf" : 1,
1632 "path" : "/cluster/firewall/macros",
1633 "text" : "macros"
1634 },
1635 {
1636 "info" : {
1637 "GET" : {
1638 "description" : "Lists possible IPSet/Alias reference which are allowed in source/dest properties.",
1639 "method" : "GET",
1640 "name" : "refs",
7aacca6f 1641 "parameters" : {
44660702 1642 "additionalProperties" : 0,
7aacca6f 1643 "properties" : {
44660702
DM
1644 "type" : {
1645 "description" : "Only list references of specified type.",
1646 "enum" : [
1647 "alias",
1648 "ipset"
1649 ],
1650 "optional" : 1,
1651 "type" : "string"
7aacca6f 1652 }
44660702 1653 }
7aacca6f
DM
1654 },
1655 "permissions" : {
1656 "check" : [
1657 "perm",
1658 "/",
1659 [
1660 "Sys.Audit"
1661 ]
1662 ]
1663 },
44660702
DM
1664 "returns" : {
1665 "items" : {
1666 "properties" : {
1667 "comment" : {
1668 "optional" : 1,
1669 "type" : "string"
1670 },
1671 "name" : {
1672 "type" : "string"
1673 },
1674 "ref" : {
1675 "type" : "string"
1676 },
1677 "type" : {
1678 "enum" : [
1679 "alias",
1680 "ipset"
1681 ],
1682 "type" : "string"
1683 }
1684 },
1685 "type" : "object"
1686 },
1687 "type" : "array"
1688 }
56122987
DM
1689 }
1690 },
7aacca6f 1691 "leaf" : 1,
44660702
DM
1692 "path" : "/cluster/firewall/refs",
1693 "text" : "refs"
56122987
DM
1694 }
1695 ],
56122987 1696 "info" : {
44660702
DM
1697 "GET" : {
1698 "description" : "Directory index.",
1699 "method" : "GET",
1700 "name" : "index",
56122987 1701 "parameters" : {
56122987
DM
1702 "additionalProperties" : 0
1703 },
44660702
DM
1704 "permissions" : {
1705 "user" : "all"
1706 },
56122987 1707 "returns" : {
44660702
DM
1708 "items" : {
1709 "properties" : {},
1710 "type" : "object"
1711 },
7aacca6f
DM
1712 "links" : [
1713 {
44660702
DM
1714 "href" : "{name}",
1715 "rel" : "child"
7aacca6f
DM
1716 }
1717 ],
7aacca6f 1718 "type" : "array"
7aacca6f 1719 }
56122987
DM
1720 }
1721 },
44660702
DM
1722 "leaf" : 0,
1723 "path" : "/cluster/firewall",
1724 "text" : "firewall"
7aacca6f
DM
1725 },
1726 {
56122987
DM
1727 "children" : [
1728 {
56122987 1729 "info" : {
44660702
DM
1730 "DELETE" : {
1731 "description" : "Delete vzdump backup job definition.",
1732 "method" : "DELETE",
1733 "name" : "delete_job",
1734 "parameters" : {
1735 "additionalProperties" : 0,
1736 "properties" : {
1737 "id" : {
1738 "description" : "The job ID.",
1739 "maxLength" : 50,
1740 "type" : "string"
1741 }
1742 }
1743 },
1744 "permissions" : {
1745 "check" : [
1746 "perm",
1747 "/",
1748 [
1749 "Sys.Modify"
1750 ]
1751 ]
1752 },
1753 "protected" : 1,
56122987
DM
1754 "returns" : {
1755 "type" : "null"
44660702
DM
1756 }
1757 },
1758 "GET" : {
1759 "description" : "Read vzdump backup job definition.",
1760 "method" : "GET",
1761 "name" : "read_job",
1762 "parameters" : {
1763 "additionalProperties" : 0,
1764 "properties" : {
1765 "id" : {
1766 "description" : "The job ID.",
1767 "maxLength" : 50,
1768 "type" : "string"
1769 }
1770 }
56122987 1771 },
7aacca6f
DM
1772 "permissions" : {
1773 "check" : [
1774 "perm",
1775 "/",
1776 [
44660702 1777 "Sys.Audit"
7aacca6f
DM
1778 ]
1779 ]
1780 },
44660702
DM
1781 "returns" : {
1782 "type" : "object"
1783 }
1784 },
1785 "PUT" : {
1786 "description" : "Update vzdump backup job definition.",
1787 "method" : "PUT",
1788 "name" : "update_job",
56122987 1789 "parameters" : {
44660702 1790 "additionalProperties" : 0,
56122987 1791 "properties" : {
44660702
DM
1792 "all" : {
1793 "default" : 0,
1794 "description" : "Backup all known guest systems on this host.",
7aacca6f 1795 "optional" : 1,
44660702 1796 "type" : "boolean"
7aacca6f 1797 },
44660702
DM
1798 "bwlimit" : {
1799 "default" : 0,
1800 "description" : "Limit I/O bandwidth (KBytes per second).",
1801 "minimum" : 0,
1802 "optional" : 1,
4bd7df8b 1803 "type" : "integer",
2c0dde61 1804 "typetext" : "integer (0 - N)"
44660702
DM
1805 },
1806 "compress" : {
1807 "default" : "0",
1808 "description" : "Compress dump file.",
7aacca6f 1809 "enum" : [
44660702
DM
1810 "0",
1811 "1",
1812 "gzip",
1813 "lzo"
7aacca6f 1814 ],
44660702
DM
1815 "optional" : 1,
1816 "type" : "string"
7aacca6f 1817 },
44660702
DM
1818 "delete" : {
1819 "description" : "A list of settings you want to delete.",
1820 "format" : "pve-configid-list",
7aacca6f 1821 "optional" : 1,
44660702 1822 "type" : "string"
56122987 1823 },
44660702
DM
1824 "dow" : {
1825 "description" : "Day of week selection.",
1826 "format" : "pve-day-of-week-list",
7aacca6f 1827 "optional" : 1,
44660702 1828 "type" : "string"
56122987 1829 },
44660702
DM
1830 "dumpdir" : {
1831 "description" : "Store resulting files to specified directory.",
56122987 1832 "optional" : 1,
44660702 1833 "type" : "string"
56122987 1834 },
44660702
DM
1835 "enabled" : {
1836 "default" : "1",
1837 "description" : "Enable or disable the job.",
1838 "optional" : 1,
1839 "type" : "boolean"
1840 },
1841 "exclude" : {
1842 "description" : "Exclude specified guest systems (assumes --all)",
1843 "format" : "pve-vmid-list",
1844 "optional" : 1,
1845 "type" : "string"
1846 },
1847 "exclude-path" : {
1848 "description" : "Exclude certain files/directories (shell globs).",
1849 "format" : "string-alist",
1850 "optional" : 1,
1851 "type" : "string"
1852 },
1853 "id" : {
1854 "description" : "The job ID.",
1855 "maxLength" : 50,
1856 "type" : "string"
1857 },
1858 "ionice" : {
1859 "default" : 7,
1860 "description" : "Set CFQ ionice priority.",
1861 "maximum" : 8,
1862 "minimum" : 0,
1863 "optional" : 1,
4bd7df8b 1864 "type" : "integer",
2c0dde61 1865 "typetext" : "integer (0 - 8)"
44660702
DM
1866 },
1867 "lockwait" : {
1868 "default" : 180,
1869 "description" : "Maximal time to wait for the global lock (minutes).",
1870 "minimum" : 0,
1871 "optional" : 1,
4bd7df8b 1872 "type" : "integer",
2c0dde61 1873 "typetext" : "integer (0 - N)"
44660702
DM
1874 },
1875 "mailnotification" : {
1876 "default" : "always",
1877 "description" : "Specify when to send an email",
56122987 1878 "enum" : [
44660702
DM
1879 "always",
1880 "failure"
56122987 1881 ],
44660702
DM
1882 "optional" : 1,
1883 "type" : "string"
1884 },
1885 "mailto" : {
1886 "description" : "Comma-separated list of email addresses that should receive email notifications.",
1887 "format" : "string-list",
1888 "optional" : 1,
1889 "type" : "string"
1890 },
1891 "maxfiles" : {
1892 "default" : 1,
1893 "description" : "Maximal number of backup files per guest system.",
1894 "minimum" : 1,
1895 "optional" : 1,
4bd7df8b 1896 "type" : "integer",
2c0dde61 1897 "typetext" : "integer (1 - N)"
44660702
DM
1898 },
1899 "mode" : {
1900 "default" : "snapshot",
1901 "description" : "Backup mode.",
1902 "enum" : [
1903 "snapshot",
1904 "suspend",
1905 "stop"
1906 ],
1907 "optional" : 1,
1908 "type" : "string"
1909 },
1910 "node" : {
1911 "description" : "Only run if executed on this node.",
1912 "format" : "pve-node",
1913 "optional" : 1,
1914 "type" : "string"
1915 },
1916 "pigz" : {
1917 "default" : 0,
1918 "description" : "Use pigz instead of gzip when N>0. N=1 uses half of cores, N>1 uses N as thread count.",
1919 "optional" : 1,
1920 "type" : "integer"
1921 },
1922 "quiet" : {
1923 "default" : 0,
1924 "description" : "Be quiet.",
1925 "optional" : 1,
1926 "type" : "boolean"
1927 },
1928 "remove" : {
1929 "default" : 1,
1930 "description" : "Remove old backup files if there are more than 'maxfiles' backup files.",
1931 "optional" : 1,
1932 "type" : "boolean"
1933 },
1934 "script" : {
1935 "description" : "Use specified hook script.",
1936 "optional" : 1,
1937 "type" : "string"
1938 },
1939 "size" : {
1940 "default" : 1024,
1941 "description" : "Unused, will be removed in a future release.",
1942 "minimum" : 500,
1943 "optional" : 1,
4bd7df8b 1944 "type" : "integer",
2c0dde61 1945 "typetext" : "integer (500 - N)"
44660702
DM
1946 },
1947 "starttime" : {
1948 "description" : "Job Start time.",
1949 "pattern" : "\\d{1,2}:\\d{1,2}",
56122987 1950 "type" : "string",
44660702 1951 "typetext" : "HH:MM"
7aacca6f 1952 },
44660702
DM
1953 "stdexcludes" : {
1954 "default" : 1,
1955 "description" : "Exclude temporary files and logs.",
1956 "optional" : 1,
1957 "type" : "boolean"
1958 },
1959 "stop" : {
1960 "default" : 0,
1961 "description" : "Stop runnig backup jobs on this host.",
1962 "optional" : 1,
1963 "type" : "boolean"
1964 },
1965 "stopwait" : {
1966 "default" : 10,
1967 "description" : "Maximal time to wait until a guest system is stopped (minutes).",
1968 "minimum" : 0,
1969 "optional" : 1,
4bd7df8b 1970 "type" : "integer",
2c0dde61 1971 "typetext" : "integer (0 - N)"
44660702
DM
1972 },
1973 "storage" : {
1974 "description" : "Store resulting file to this storage.",
1975 "format" : "pve-storage-id",
1976 "optional" : 1,
7aacca6f 1977 "type" : "string"
56122987 1978 },
44660702
DM
1979 "tmpdir" : {
1980 "description" : "Store temporary files to specified directory.",
1981 "optional" : 1,
1982 "type" : "string"
1983 },
1984 "vmid" : {
1985 "description" : "The ID of the guest system you want to backup.",
1986 "format" : "pve-vmid-list",
1987 "optional" : 1,
1988 "type" : "string"
56122987 1989 }
44660702 1990 }
56122987
DM
1991 },
1992 "permissions" : {
1993 "check" : [
1994 "perm",
1995 "/",
1996 [
44660702 1997 "Sys.Modify"
56122987
DM
1998 ]
1999 ]
2000 },
44660702
DM
2001 "protected" : 1,
2002 "returns" : {
2003 "type" : "null"
7aacca6f 2004 }
56122987
DM
2005 }
2006 },
44660702
DM
2007 "leaf" : 1,
2008 "path" : "/cluster/backup/{id}",
2009 "text" : "{id}"
2010 }
2011 ],
2012 "info" : {
2013 "GET" : {
2014 "description" : "List vzdump backup schedule.",
2015 "method" : "GET",
2016 "name" : "index",
2017 "parameters" : {
2018 "additionalProperties" : 0
2019 },
2020 "permissions" : {
2021 "check" : [
2022 "perm",
2023 "/",
2024 [
2025 "Sys.Audit"
2026 ]
2027 ]
2028 },
2029 "returns" : {
2030 "items" : {
2031 "properties" : {
2032 "id" : {
2033 "type" : "string"
2034 }
2035 },
2036 "type" : "object"
2037 },
2038 "links" : [
2039 {
2040 "href" : "{id}",
2041 "rel" : "child"
2042 }
2043 ],
2044 "type" : "array"
2045 }
2046 },
2047 "POST" : {
2048 "description" : "Create new vzdump backup job.",
2049 "method" : "POST",
2050 "name" : "create_job",
2051 "parameters" : {
2052 "additionalProperties" : 0,
2053 "properties" : {
2054 "all" : {
2055 "default" : 0,
2056 "description" : "Backup all known guest systems on this host.",
2057 "optional" : 1,
2058 "type" : "boolean"
2059 },
2060 "bwlimit" : {
2061 "default" : 0,
2062 "description" : "Limit I/O bandwidth (KBytes per second).",
2063 "minimum" : 0,
2064 "optional" : 1,
4bd7df8b 2065 "type" : "integer",
2c0dde61 2066 "typetext" : "integer (0 - N)"
44660702
DM
2067 },
2068 "compress" : {
2069 "default" : "0",
2070 "description" : "Compress dump file.",
2071 "enum" : [
2072 "0",
2073 "1",
2074 "gzip",
2075 "lzo"
2076 ],
2077 "optional" : 1,
2078 "type" : "string"
2079 },
2080 "dow" : {
2081 "default" : "mon,tue,wed,thu,fri,sat,sun",
2082 "description" : "Day of week selection.",
2083 "format" : "pve-day-of-week-list",
2084 "optional" : 1,
2085 "type" : "string"
2086 },
2087 "dumpdir" : {
2088 "description" : "Store resulting files to specified directory.",
2089 "optional" : 1,
2090 "type" : "string"
2091 },
2092 "enabled" : {
2093 "default" : "1",
2094 "description" : "Enable or disable the job.",
2095 "optional" : 1,
2096 "type" : "boolean"
2097 },
2098 "exclude" : {
2099 "description" : "Exclude specified guest systems (assumes --all)",
2100 "format" : "pve-vmid-list",
2101 "optional" : 1,
2102 "type" : "string"
2103 },
2104 "exclude-path" : {
2105 "description" : "Exclude certain files/directories (shell globs).",
2106 "format" : "string-alist",
2107 "optional" : 1,
2108 "type" : "string"
2109 },
2110 "ionice" : {
2111 "default" : 7,
2112 "description" : "Set CFQ ionice priority.",
2113 "maximum" : 8,
2114 "minimum" : 0,
2115 "optional" : 1,
4bd7df8b 2116 "type" : "integer",
2c0dde61 2117 "typetext" : "integer (0 - 8)"
44660702
DM
2118 },
2119 "lockwait" : {
2120 "default" : 180,
2121 "description" : "Maximal time to wait for the global lock (minutes).",
2122 "minimum" : 0,
2123 "optional" : 1,
4bd7df8b 2124 "type" : "integer",
2c0dde61 2125 "typetext" : "integer (0 - N)"
44660702
DM
2126 },
2127 "mailnotification" : {
2128 "default" : "always",
2129 "description" : "Specify when to send an email",
2130 "enum" : [
2131 "always",
2132 "failure"
2133 ],
2134 "optional" : 1,
2135 "type" : "string"
2136 },
2137 "mailto" : {
2138 "description" : "Comma-separated list of email addresses that should receive email notifications.",
2139 "format" : "string-list",
2140 "optional" : 1,
2141 "type" : "string"
2142 },
2143 "maxfiles" : {
2144 "default" : 1,
2145 "description" : "Maximal number of backup files per guest system.",
2146 "minimum" : 1,
2147 "optional" : 1,
4bd7df8b 2148 "type" : "integer",
2c0dde61 2149 "typetext" : "integer (1 - N)"
44660702
DM
2150 },
2151 "mode" : {
2152 "default" : "snapshot",
2153 "description" : "Backup mode.",
2154 "enum" : [
2155 "snapshot",
2156 "suspend",
2157 "stop"
2158 ],
2159 "optional" : 1,
2160 "type" : "string"
2161 },
2162 "node" : {
2163 "description" : "Only run if executed on this node.",
2164 "format" : "pve-node",
2165 "optional" : 1,
2166 "type" : "string"
2167 },
2168 "pigz" : {
2169 "default" : 0,
2170 "description" : "Use pigz instead of gzip when N>0. N=1 uses half of cores, N>1 uses N as thread count.",
2171 "optional" : 1,
2172 "type" : "integer"
2173 },
2174 "quiet" : {
2175 "default" : 0,
2176 "description" : "Be quiet.",
2177 "optional" : 1,
2178 "type" : "boolean"
2179 },
2180 "remove" : {
2181 "default" : 1,
2182 "description" : "Remove old backup files if there are more than 'maxfiles' backup files.",
2183 "optional" : 1,
2184 "type" : "boolean"
2185 },
2186 "script" : {
2187 "description" : "Use specified hook script.",
2188 "optional" : 1,
2189 "type" : "string"
2190 },
2191 "size" : {
2192 "default" : 1024,
2193 "description" : "Unused, will be removed in a future release.",
2194 "minimum" : 500,
2195 "optional" : 1,
4bd7df8b 2196 "type" : "integer",
2c0dde61 2197 "typetext" : "integer (500 - N)"
44660702
DM
2198 },
2199 "starttime" : {
2200 "description" : "Job Start time.",
2201 "pattern" : "\\d{1,2}:\\d{1,2}",
2202 "type" : "string",
2203 "typetext" : "HH:MM"
2204 },
2205 "stdexcludes" : {
2206 "default" : 1,
2207 "description" : "Exclude temporary files and logs.",
2208 "optional" : 1,
2209 "type" : "boolean"
2210 },
2211 "stop" : {
2212 "default" : 0,
2213 "description" : "Stop runnig backup jobs on this host.",
2214 "optional" : 1,
2215 "type" : "boolean"
2216 },
2217 "stopwait" : {
2218 "default" : 10,
2219 "description" : "Maximal time to wait until a guest system is stopped (minutes).",
2220 "minimum" : 0,
2221 "optional" : 1,
4bd7df8b 2222 "type" : "integer",
2c0dde61 2223 "typetext" : "integer (0 - N)"
44660702
DM
2224 },
2225 "storage" : {
2226 "description" : "Store resulting file to this storage.",
2227 "format" : "pve-storage-id",
2228 "optional" : 1,
2229 "type" : "string"
2230 },
2231 "tmpdir" : {
2232 "description" : "Store temporary files to specified directory.",
2233 "optional" : 1,
2234 "type" : "string"
2235 },
2236 "vmid" : {
2237 "description" : "The ID of the guest system you want to backup.",
2238 "format" : "pve-vmid-list",
2239 "optional" : 1,
2240 "type" : "string"
2241 }
2242 }
2243 },
2244 "permissions" : {
2245 "check" : [
2246 "perm",
2247 "/",
2248 [
2249 "Sys.Modify"
2250 ]
2251 ]
2252 },
2253 "protected" : 1,
2254 "returns" : {
2255 "type" : "null"
2256 }
2257 }
2258 },
2259 "leaf" : 0,
2260 "path" : "/cluster/backup",
2261 "text" : "backup"
2262 },
2263 {
2264 "children" : [
2265 {
2266 "children" : [
2267 {
2268 "children" : [
56122987 2269 {
56122987
DM
2270 "info" : {
2271 "POST" : {
44660702
DM
2272 "description" : "Request resource migration (online) to another node.",
2273 "method" : "POST",
2274 "name" : "migrate",
56122987 2275 "parameters" : {
7aacca6f 2276 "additionalProperties" : 0,
56122987
DM
2277 "properties" : {
2278 "node" : {
7aacca6f 2279 "description" : "The cluster node name.",
44660702 2280 "format" : "pve-node",
7aacca6f 2281 "type" : "string"
56122987
DM
2282 },
2283 "sid" : {
44660702 2284 "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).",
56122987 2285 "format" : "pve-ha-resource-or-vm-id",
7aacca6f 2286 "type" : "string",
44660702 2287 "typetext" : "<type>:<name>"
56122987 2288 }
7aacca6f 2289 }
56122987 2290 },
56122987
DM
2291 "permissions" : {
2292 "check" : [
2293 "perm",
2294 "/",
2295 [
2296 "Sys.Console"
2297 ]
2298 ]
2299 },
7aacca6f 2300 "protected" : 1,
7aacca6f
DM
2301 "returns" : {
2302 "type" : "null"
44660702 2303 }
56122987 2304 }
44660702
DM
2305 },
2306 "leaf" : 1,
2307 "path" : "/cluster/ha/resources/{sid}/migrate",
2308 "text" : "migrate"
2309 },
2310 {
2311 "info" : {
2312 "POST" : {
2313 "description" : "Request resource relocatzion to another node. This stops the service on the old node, and restarts it on the target node.",
2314 "method" : "POST",
2315 "name" : "relocate",
2316 "parameters" : {
2317 "additionalProperties" : 0,
2318 "properties" : {
2319 "node" : {
2320 "description" : "The cluster node name.",
2321 "format" : "pve-node",
2322 "type" : "string"
2323 },
2324 "sid" : {
2325 "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).",
2326 "format" : "pve-ha-resource-or-vm-id",
2327 "type" : "string",
2328 "typetext" : "<type>:<name>"
2329 }
2330 }
2331 },
2332 "permissions" : {
2333 "check" : [
2334 "perm",
2335 "/",
2336 [
2337 "Sys.Console"
2338 ]
2339 ]
2340 },
2341 "protected" : 1,
2342 "returns" : {
2343 "type" : "null"
2344 }
2345 }
2346 },
2347 "leaf" : 1,
2348 "path" : "/cluster/ha/resources/{sid}/relocate",
2349 "text" : "relocate"
2350 }
2351 ],
2352 "info" : {
2353 "DELETE" : {
2354 "description" : "Delete resource configuration.",
2355 "method" : "DELETE",
2356 "name" : "delete",
7aacca6f 2357 "parameters" : {
44660702 2358 "additionalProperties" : 0,
7aacca6f
DM
2359 "properties" : {
2360 "sid" : {
2361 "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).",
44660702 2362 "format" : "pve-ha-resource-or-vm-id",
7aacca6f 2363 "type" : "string",
44660702
DM
2364 "typetext" : "<type>:<name>"
2365 }
2366 }
2367 },
2368 "permissions" : {
2369 "check" : [
2370 "perm",
2371 "/",
2372 [
2373 "Sys.Console"
2374 ]
2375 ]
2376 },
2377 "protected" : 1,
2378 "returns" : {
2379 "type" : "null"
2380 }
2381 },
2382 "GET" : {
2383 "description" : "Read resource configuration.",
2384 "method" : "GET",
2385 "name" : "read",
2386 "parameters" : {
2387 "additionalProperties" : 0,
2388 "properties" : {
2389 "sid" : {
2390 "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).",
7aacca6f 2391 "format" : "pve-ha-resource-or-vm-id",
44660702 2392 "type" : "string",
7aacca6f
DM
2393 "typetext" : "<type>:<name>"
2394 }
44660702 2395 }
7aacca6f
DM
2396 },
2397 "permissions" : {
2398 "check" : [
2399 "perm",
2400 "/",
2401 [
2402 "Sys.Audit"
2403 ]
2404 ]
2405 },
44660702 2406 "returns" : {}
7aacca6f 2407 },
56122987 2408 "PUT" : {
44660702 2409 "description" : "Update resource configuration.",
7aacca6f 2410 "method" : "PUT",
44660702 2411 "name" : "update",
56122987
DM
2412 "parameters" : {
2413 "additionalProperties" : 0,
2414 "properties" : {
44660702
DM
2415 "comment" : {
2416 "description" : "Description.",
2417 "maxLength" : 4096,
56122987 2418 "optional" : 1,
44660702 2419 "type" : "string"
56122987 2420 },
7aacca6f
DM
2421 "delete" : {
2422 "description" : "A list of settings you want to delete.",
7aacca6f 2423 "format" : "pve-configid-list",
44660702
DM
2424 "maxLength" : 4096,
2425 "optional" : 1,
2426 "type" : "string"
56122987 2427 },
44660702
DM
2428 "digest" : {
2429 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
2430 "maxLength" : 40,
2431 "optional" : 1,
2432 "type" : "string"
56122987 2433 },
44660702
DM
2434 "group" : {
2435 "description" : "The HA group identifier.",
2436 "format" : "pve-configid",
7aacca6f 2437 "optional" : 1,
44660702 2438 "type" : "string"
56122987
DM
2439 },
2440 "max_relocate" : {
7aacca6f 2441 "default" : 1,
56122987 2442 "description" : "Maximal number of service relocate tries when a service failes to start.",
44660702
DM
2443 "minimum" : 0,
2444 "optional" : 1,
4bd7df8b 2445 "type" : "integer",
2c0dde61 2446 "typetext" : "integer (0 - N)"
7aacca6f 2447 },
44660702
DM
2448 "max_restart" : {
2449 "default" : 1,
2450 "description" : "Maximal number of tries to restart the service on a node after its start failed.",
2451 "minimum" : 0,
7aacca6f 2452 "optional" : 1,
4bd7df8b 2453 "type" : "integer",
2c0dde61 2454 "typetext" : "integer (0 - N)"
44660702
DM
2455 },
2456 "sid" : {
2457 "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).",
2458 "format" : "pve-ha-resource-or-vm-id",
2459 "type" : "string",
2460 "typetext" : "<type>:<name>"
7aacca6f
DM
2461 },
2462 "state" : {
44660702
DM
2463 "default" : "enabled",
2464 "description" : "Resource state.",
7aacca6f
DM
2465 "enum" : [
2466 "enabled",
2467 "disabled"
2468 ],
7aacca6f 2469 "optional" : 1,
44660702 2470 "type" : "string"
56122987 2471 }
44660702
DM
2472 },
2473 "type" : "object"
56122987 2474 },
56122987
DM
2475 "permissions" : {
2476 "check" : [
2477 "perm",
2478 "/",
2479 [
2480 "Sys.Console"
2481 ]
2482 ]
2483 },
7aacca6f 2484 "protected" : 1,
56122987
DM
2485 "returns" : {
2486 "type" : "null"
2487 }
2488 }
2489 },
44660702 2490 "leaf" : 0,
7aacca6f 2491 "path" : "/cluster/ha/resources/{sid}",
44660702 2492 "text" : "{sid}"
56122987
DM
2493 }
2494 ],
7aacca6f
DM
2495 "info" : {
2496 "GET" : {
44660702
DM
2497 "description" : "List HA resources.",
2498 "method" : "GET",
2499 "name" : "index",
7aacca6f 2500 "parameters" : {
44660702
DM
2501 "additionalProperties" : 0,
2502 "properties" : {
2503 "type" : {
2504 "description" : "Only list resources of specific type",
2505 "enum" : [
2506 "ct",
2507 "vm"
2508 ],
2509 "optional" : 1,
2510 "type" : "string"
2511 }
2512 }
7aacca6f 2513 },
7aacca6f
DM
2514 "permissions" : {
2515 "check" : [
2516 "perm",
2517 "/",
2518 [
2519 "Sys.Audit"
2520 ]
2521 ]
2522 },
7aacca6f 2523 "returns" : {
7aacca6f 2524 "items" : {
7aacca6f 2525 "properties" : {
44660702 2526 "sid" : {
7aacca6f
DM
2527 "type" : "string"
2528 }
44660702
DM
2529 },
2530 "type" : "object"
7aacca6f
DM
2531 },
2532 "links" : [
2533 {
44660702 2534 "href" : "{sid}",
7aacca6f
DM
2535 "rel" : "child"
2536 }
44660702
DM
2537 ],
2538 "type" : "array"
7aacca6f
DM
2539 }
2540 },
2541 "POST" : {
44660702 2542 "description" : "Create a new HA resource.",
7aacca6f 2543 "method" : "POST",
44660702 2544 "name" : "create",
7aacca6f 2545 "parameters" : {
44660702 2546 "additionalProperties" : 0,
7aacca6f
DM
2547 "properties" : {
2548 "comment" : {
7aacca6f 2549 "description" : "Description.",
44660702 2550 "maxLength" : 4096,
7aacca6f
DM
2551 "optional" : 1,
2552 "type" : "string"
2553 },
44660702
DM
2554 "group" : {
2555 "description" : "The HA group identifier.",
2556 "format" : "pve-configid",
7aacca6f 2557 "optional" : 1,
44660702 2558 "type" : "string"
7aacca6f 2559 },
44660702
DM
2560 "max_relocate" : {
2561 "default" : 1,
2562 "description" : "Maximal number of service relocate tries when a service failes to start.",
2563 "minimum" : 0,
7aacca6f 2564 "optional" : 1,
4bd7df8b 2565 "type" : "integer",
2c0dde61 2566 "typetext" : "integer (0 - N)"
7aacca6f 2567 },
44660702
DM
2568 "max_restart" : {
2569 "default" : 1,
2570 "description" : "Maximal number of tries to restart the service on a node after its start failed.",
2571 "minimum" : 0,
2572 "optional" : 1,
4bd7df8b 2573 "type" : "integer",
2c0dde61 2574 "typetext" : "integer (0 - N)"
44660702
DM
2575 },
2576 "sid" : {
2577 "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).",
2578 "format" : "pve-ha-resource-or-vm-id",
2579 "type" : "string",
2580 "typetext" : "<type>:<name>"
2581 },
2582 "state" : {
2583 "default" : "enabled",
2584 "description" : "Resource state.",
7aacca6f 2585 "enum" : [
44660702
DM
2586 "enabled",
2587 "disabled"
7aacca6f 2588 ],
7aacca6f
DM
2589 "optional" : 1,
2590 "type" : "string"
2591 },
44660702
DM
2592 "type" : {
2593 "description" : "Resource type.",
2594 "enum" : [
2595 "ct",
2596 "vm"
2597 ],
2598 "optional" : 1,
2599 "type" : "string"
2600 }
7aacca6f 2601 },
44660702 2602 "type" : "object"
7aacca6f
DM
2603 },
2604 "permissions" : {
2605 "check" : [
2606 "perm",
2607 "/",
2608 [
2609 "Sys.Console"
2610 ]
2611 ]
2612 },
44660702
DM
2613 "protected" : 1,
2614 "returns" : {
2615 "type" : "null"
2616 }
7aacca6f
DM
2617 }
2618 },
44660702
DM
2619 "leaf" : 0,
2620 "path" : "/cluster/ha/resources",
2621 "text" : "resources"
2622 },
2623 {
56122987
DM
2624 "children" : [
2625 {
56122987 2626 "info" : {
44660702
DM
2627 "DELETE" : {
2628 "description" : "Delete ha group configuration.",
2629 "method" : "DELETE",
2630 "name" : "delete",
56122987 2631 "parameters" : {
7aacca6f 2632 "additionalProperties" : 0,
56122987 2633 "properties" : {
7aacca6f
DM
2634 "group" : {
2635 "description" : "The HA group identifier.",
44660702
DM
2636 "format" : "pve-configid",
2637 "type" : "string"
56122987 2638 }
7aacca6f 2639 }
56122987 2640 },
56122987
DM
2641 "permissions" : {
2642 "check" : [
2643 "perm",
2644 "/",
2645 [
7aacca6f 2646 "Sys.Console"
56122987
DM
2647 ]
2648 ]
2649 },
44660702 2650 "protected" : 1,
7aacca6f
DM
2651 "returns" : {
2652 "type" : "null"
56122987
DM
2653 }
2654 },
44660702
DM
2655 "GET" : {
2656 "description" : "Read ha group configuration.",
2657 "method" : "GET",
2658 "name" : "read",
56122987 2659 "parameters" : {
44660702 2660 "additionalProperties" : 0,
56122987
DM
2661 "properties" : {
2662 "group" : {
2663 "description" : "The HA group identifier.",
44660702
DM
2664 "format" : "pve-configid",
2665 "type" : "string"
56122987 2666 }
44660702 2667 }
56122987 2668 },
56122987
DM
2669 "permissions" : {
2670 "check" : [
2671 "perm",
2672 "/",
2673 [
44660702 2674 "Sys.Audit"
56122987
DM
2675 ]
2676 ]
2677 },
44660702 2678 "returns" : {}
7aacca6f 2679 },
44660702
DM
2680 "PUT" : {
2681 "description" : "Update ha group configuration.",
2682 "method" : "PUT",
2683 "name" : "update",
7aacca6f 2684 "parameters" : {
44660702 2685 "additionalProperties" : 0,
7aacca6f 2686 "properties" : {
44660702
DM
2687 "comment" : {
2688 "description" : "Description.",
2689 "maxLength" : 4096,
2690 "optional" : 1,
2691 "type" : "string"
2692 },
2693 "delete" : {
2694 "description" : "A list of settings you want to delete.",
2695 "format" : "pve-configid-list",
2696 "maxLength" : 4096,
2697 "optional" : 1,
2698 "type" : "string"
2699 },
2700 "digest" : {
2701 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
2702 "maxLength" : 40,
2703 "optional" : 1,
2704 "type" : "string"
2705 },
7aacca6f
DM
2706 "group" : {
2707 "description" : "The HA group identifier.",
44660702
DM
2708 "format" : "pve-configid",
2709 "type" : "string"
2710 },
2711 "nodes" : {
2712 "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').",
2713 "format" : "pve-ha-group-node-list",
2714 "optional" : 1,
7aacca6f 2715 "type" : "string",
44660702
DM
2716 "typetext" : "<node>[:<pri>]{,<node>[:<pri>]}*"
2717 },
2718 "nofailback" : {
2719 "default" : 0,
2720 "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.",
2721 "optional" : 1,
2722 "type" : "boolean"
2723 },
2724 "restricted" : {
2725 "default" : 0,
2726 "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.",
2727 "optional" : 1,
2728 "type" : "boolean"
7aacca6f
DM
2729 }
2730 },
44660702 2731 "type" : "object"
7aacca6f 2732 },
7aacca6f
DM
2733 "permissions" : {
2734 "check" : [
2735 "perm",
2736 "/",
2737 [
44660702 2738 "Sys.Console"
7aacca6f
DM
2739 ]
2740 ]
2741 },
44660702
DM
2742 "protected" : 1,
2743 "returns" : {
2744 "type" : "null"
2745 }
56122987
DM
2746 }
2747 },
2748 "leaf" : 1,
44660702
DM
2749 "path" : "/cluster/ha/groups/{group}",
2750 "text" : "{group}"
56122987 2751 }
44660702
DM
2752 ],
2753 "info" : {
2754 "GET" : {
2755 "description" : "Get HA groups.",
2756 "method" : "GET",
2757 "name" : "index",
2758 "parameters" : {
2759 "additionalProperties" : 0
2760 },
2761 "permissions" : {
2762 "check" : [
2763 "perm",
2764 "/",
2765 [
2766 "Sys.Audit"
2767 ]
2768 ]
2769 },
2770 "returns" : {
2771 "items" : {
2772 "properties" : {
2773 "group" : {
2774 "type" : "string"
2775 }
2776 },
2777 "type" : "object"
2778 },
2779 "links" : [
2780 {
2781 "href" : "{group}",
2782 "rel" : "child"
2783 }
2784 ],
2785 "type" : "array"
2786 }
2787 },
2788 "POST" : {
2789 "description" : "Create a new HA group.",
2790 "method" : "POST",
2791 "name" : "create",
2792 "parameters" : {
2793 "additionalProperties" : 0,
2794 "properties" : {
2795 "comment" : {
2796 "description" : "Description.",
2797 "maxLength" : 4096,
2798 "optional" : 1,
2799 "type" : "string"
2800 },
2801 "group" : {
2802 "description" : "The HA group identifier.",
2803 "format" : "pve-configid",
2804 "type" : "string"
2805 },
2806 "nodes" : {
2807 "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').",
2808 "format" : "pve-ha-group-node-list",
2809 "optional" : 0,
2810 "type" : "string",
2811 "typetext" : "<node>[:<pri>]{,<node>[:<pri>]}*"
2812 },
2813 "nofailback" : {
2814 "default" : 0,
2815 "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.",
2816 "optional" : 1,
2817 "type" : "boolean"
2818 },
2819 "restricted" : {
2820 "default" : 0,
2821 "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.",
2822 "optional" : 1,
2823 "type" : "boolean"
2824 },
2825 "type" : {
2826 "description" : "Group type.",
2827 "enum" : [
2828 "group"
2829 ],
2830 "optional" : 1,
2831 "type" : "string"
2832 }
2833 },
2834 "type" : "object"
2835 },
2836 "permissions" : {
2837 "check" : [
2838 "perm",
2839 "/",
2840 [
2841 "Sys.Console"
2842 ]
2843 ]
2844 },
2845 "protected" : 1,
2846 "returns" : {
2847 "type" : "null"
2848 }
2849 }
2850 },
2851 "leaf" : 0,
2852 "path" : "/cluster/ha/groups",
2853 "text" : "groups"
7aacca6f
DM
2854 },
2855 {
7aacca6f
DM
2856 "children" : [
2857 {
2858 "info" : {
2859 "GET" : {
56122987 2860 "description" : "Get HA manger status.",
44660702 2861 "method" : "GET",
7aacca6f 2862 "name" : "status",
44660702
DM
2863 "parameters" : {
2864 "additionalProperties" : 0
2865 },
56122987
DM
2866 "permissions" : {
2867 "check" : [
2868 "perm",
2869 "/",
2870 [
2871 "Sys.Audit"
2872 ]
2873 ]
7aacca6f 2874 },
44660702
DM
2875 "returns" : {
2876 "type" : "array"
56122987
DM
2877 }
2878 }
7aacca6f 2879 },
7aacca6f 2880 "leaf" : 1,
44660702
DM
2881 "path" : "/cluster/ha/status/current",
2882 "text" : "current"
56122987
DM
2883 },
2884 {
2885 "info" : {
2886 "GET" : {
7aacca6f 2887 "description" : "Get full HA manger status, including LRM status.",
44660702
DM
2888 "method" : "GET",
2889 "name" : "manager_status",
7aacca6f
DM
2890 "parameters" : {
2891 "additionalProperties" : 0
2892 },
56122987
DM
2893 "permissions" : {
2894 "check" : [
2895 "perm",
2896 "/",
2897 [
2898 "Sys.Audit"
2899 ]
2900 ]
44660702
DM
2901 },
2902 "returns" : {
2903 "type" : "object"
7aacca6f 2904 }
56122987
DM
2905 }
2906 },
56122987 2907 "leaf" : 1,
44660702
DM
2908 "path" : "/cluster/ha/status/manager_status",
2909 "text" : "manager_status"
56122987
DM
2910 }
2911 ],
56122987
DM
2912 "info" : {
2913 "GET" : {
44660702 2914 "description" : "Directory index.",
7aacca6f 2915 "method" : "GET",
44660702
DM
2916 "name" : "index",
2917 "parameters" : {
2918 "additionalProperties" : 0
2919 },
2920 "permissions" : {
2921 "user" : "all"
2922 },
56122987 2923 "returns" : {
56122987
DM
2924 "items" : {
2925 "properties" : {},
2926 "type" : "object"
2927 },
2928 "links" : [
2929 {
44660702
DM
2930 "href" : "{name}",
2931 "rel" : "child"
56122987 2932 }
7aacca6f
DM
2933 ],
2934 "type" : "array"
44660702 2935 }
56122987 2936 }
7aacca6f 2937 },
44660702 2938 "leaf" : 0,
7aacca6f 2939 "path" : "/cluster/ha/status",
44660702 2940 "text" : "status"
56122987
DM
2941 }
2942 ],
56122987
DM
2943 "info" : {
2944 "GET" : {
7aacca6f 2945 "description" : "Directory index.",
44660702
DM
2946 "method" : "GET",
2947 "name" : "index",
2948 "parameters" : {
2949 "additionalProperties" : 0
2950 },
7aacca6f
DM
2951 "permissions" : {
2952 "check" : [
2953 "perm",
2954 "/",
2955 [
2956 "Sys.Audit"
2957 ]
2958 ]
2959 },
56122987 2960 "returns" : {
56122987 2961 "items" : {
7aacca6f
DM
2962 "properties" : {
2963 "id" : {
2964 "type" : "string"
2965 }
44660702
DM
2966 },
2967 "type" : "object"
7aacca6f
DM
2968 },
2969 "links" : [
2970 {
2971 "href" : "{id}",
2972 "rel" : "child"
2973 }
44660702
DM
2974 ],
2975 "type" : "array"
7aacca6f
DM
2976 }
2977 }
44660702
DM
2978 },
2979 "leaf" : 0,
2980 "path" : "/cluster/ha",
2981 "text" : "ha"
7aacca6f
DM
2982 },
2983 {
7aacca6f
DM
2984 "info" : {
2985 "GET" : {
2986 "description" : "Read cluster log",
44660702
DM
2987 "method" : "GET",
2988 "name" : "log",
56122987 2989 "parameters" : {
7aacca6f 2990 "additionalProperties" : 0,
56122987
DM
2991 "properties" : {
2992 "max" : {
7aacca6f 2993 "description" : "Maximum number of entries.",
44660702
DM
2994 "minimum" : 1,
2995 "optional" : 1,
4bd7df8b 2996 "type" : "integer",
2c0dde61 2997 "typetext" : "integer (1 - N)"
56122987 2998 }
7aacca6f 2999 }
56122987 3000 },
44660702
DM
3001 "permissions" : {
3002 "user" : "all"
3003 },
7aacca6f 3004 "returns" : {
7aacca6f 3005 "items" : {
44660702
DM
3006 "properties" : {},
3007 "type" : "object"
3008 },
3009 "type" : "array"
7aacca6f 3010 }
56122987 3011 }
44660702
DM
3012 },
3013 "leaf" : 1,
3014 "path" : "/cluster/log",
3015 "text" : "log"
56122987
DM
3016 },
3017 {
56122987
DM
3018 "info" : {
3019 "GET" : {
44660702 3020 "description" : "Resources index (cluster wide).",
7aacca6f 3021 "method" : "GET",
7aacca6f 3022 "name" : "resources",
56122987
DM
3023 "parameters" : {
3024 "additionalProperties" : 0,
3025 "properties" : {
3026 "type" : {
3027 "enum" : [
3028 "vm",
3029 "storage",
3030 "node"
44660702
DM
3031 ],
3032 "optional" : 1,
3033 "type" : "string"
56122987
DM
3034 }
3035 }
3036 },
44660702
DM
3037 "permissions" : {
3038 "user" : "all"
3039 },
3040 "returns" : {
3041 "items" : {
3042 "properties" : {},
3043 "type" : "object"
3044 },
3045 "type" : "array"
3046 }
56122987
DM
3047 }
3048 },
7aacca6f 3049 "leaf" : 1,
44660702
DM
3050 "path" : "/cluster/resources",
3051 "text" : "resources"
56122987
DM
3052 },
3053 {
56122987
DM
3054 "info" : {
3055 "GET" : {
7aacca6f 3056 "description" : "List recent tasks (cluster wide).",
44660702 3057 "method" : "GET",
7aacca6f 3058 "name" : "tasks",
56122987
DM
3059 "parameters" : {
3060 "additionalProperties" : 0
3061 },
44660702
DM
3062 "permissions" : {
3063 "user" : "all"
3064 },
56122987
DM
3065 "returns" : {
3066 "items" : {
3067 "properties" : {
3068 "upid" : {
3069 "type" : "string"
3070 }
44660702
DM
3071 },
3072 "type" : "object"
3073 },
3074 "type" : "array"
7aacca6f 3075 }
56122987
DM
3076 }
3077 },
7aacca6f 3078 "leaf" : 1,
44660702
DM
3079 "path" : "/cluster/tasks",
3080 "text" : "tasks"
56122987
DM
3081 },
3082 {
56122987 3083 "info" : {
7aacca6f 3084 "GET" : {
44660702
DM
3085 "description" : "Get datacenter options.",
3086 "method" : "GET",
3087 "name" : "get_options",
56122987 3088 "parameters" : {
7aacca6f
DM
3089 "additionalProperties" : 0
3090 },
3091 "permissions" : {
3092 "check" : [
3093 "perm",
3094 "/",
3095 [
3096 "Sys.Audit"
3097 ]
3098 ]
3099 },
7aacca6f 3100 "returns" : {
44660702
DM
3101 "properties" : {},
3102 "type" : "object"
7aacca6f
DM
3103 }
3104 },
3105 "PUT" : {
44660702
DM
3106 "description" : "Set datacenter options.",
3107 "method" : "PUT",
7aacca6f
DM
3108 "name" : "set_options",
3109 "parameters" : {
3110 "additionalProperties" : 0,
3111 "properties" : {
56122987 3112 "console" : {
56122987 3113 "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).",
56122987
DM
3114 "enum" : [
3115 "applet",
3116 "vv",
3117 "html5"
44660702
DM
3118 ],
3119 "optional" : 1,
3120 "type" : "string"
56122987 3121 },
7aacca6f 3122 "delete" : {
7aacca6f 3123 "description" : "A list of settings you want to delete.",
44660702 3124 "format" : "pve-configid-list",
7aacca6f
DM
3125 "optional" : 1,
3126 "type" : "string"
3127 },
44660702
DM
3128 "email_from" : {
3129 "description" : "Specify email address to send notification from (default is root@$hostname)",
3130 "format" : "email-opt",
7aacca6f 3131 "optional" : 1,
44660702
DM
3132 "type" : "string"
3133 },
3134 "fencing" : {
3135 "default" : "watchdog",
3136 "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",
7aacca6f 3137 "enum" : [
44660702
DM
3138 "watchdog",
3139 "hardware",
3140 "both"
7aacca6f 3141 ],
44660702
DM
3142 "optional" : 1,
3143 "type" : "string"
3144 },
3145 "http_proxy" : {
3146 "description" : "Specify external http proxy which is used for downloads (example: 'http://username:password@host:port/')",
3147 "optional" : 1,
3148 "pattern" : "http://.*",
3149 "type" : "string"
7aacca6f 3150 },
56122987 3151 "keyboard" : {
44660702 3152 "description" : "Default keybord layout for vnc server.",
56122987 3153 "enum" : [
44660702
DM
3154 "de",
3155 "de-ch",
7aacca6f 3156 "da",
56122987 3157 "en-gb",
44660702
DM
3158 "en-us",
3159 "es",
3160 "fi",
3161 "fr",
3162 "fr-be",
3163 "fr-ca",
3164 "fr-ch",
3165 "hu",
7aacca6f 3166 "is",
44660702
DM
3167 "it",
3168 "ja",
3169 "lt",
56122987 3170 "mk",
7aacca6f 3171 "nl",
56122987 3172 "no",
44660702 3173 "pl",
7aacca6f 3174 "pt",
44660702
DM
3175 "pt-br",
3176 "sv",
3177 "sl",
3178 "tr"
56122987 3179 ],
56122987
DM
3180 "optional" : 1,
3181 "type" : "string"
3182 },
44660702
DM
3183 "language" : {
3184 "description" : "Default GUI language.",
3185 "enum" : [
3186 "en",
3187 "de"
3188 ],
56122987 3189 "optional" : 1,
44660702 3190 "type" : "string"
56122987 3191 },
4bd7df8b
DM
3192 "mac_prefix" : {
3193 "description" : "Prefix for autogenerated MAC addresses.",
3194 "optional" : 1,
3195 "pattern" : "(?^i:[a-f0-9]{2}(?::[a-f0-9]{2}){0,2}:?)",
3196 "type" : "string"
3197 },
44660702
DM
3198 "max_workers" : {
3199 "description" : "Defines how many workers (per node) are maximal started on actions like 'stopall VMs' or task from the ha-manager.",
3200 "minimum" : 1,
56122987 3201 "optional" : 1,
4bd7df8b 3202 "type" : "integer",
2c0dde61 3203 "typetext" : "integer (1 - N)"
56122987 3204 },
7aacca6f 3205 "migration_unsecure" : {
44660702 3206 "description" : "Migration is secure using SSH tunnel by default. For secure private networks you can disable it to speed up migration.",
56122987 3207 "optional" : 1,
44660702 3208 "type" : "boolean"
56122987
DM
3209 }
3210 }
3211 },
44660702
DM
3212 "permissions" : {
3213 "check" : [
3214 "perm",
3215 "/",
3216 [
3217 "Sys.Modify"
3218 ]
3219 ]
3220 },
56122987 3221 "protected" : 1,
7aacca6f
DM
3222 "returns" : {
3223 "type" : "null"
44660702 3224 }
7aacca6f
DM
3225 }
3226 },
44660702
DM
3227 "leaf" : 1,
3228 "path" : "/cluster/options",
7aacca6f
DM
3229 "text" : "options"
3230 },
3231 {
7aacca6f 3232 "info" : {
56122987 3233 "GET" : {
44660702
DM
3234 "description" : "Get cluster status informations.",
3235 "method" : "GET",
3236 "name" : "get_status",
56122987
DM
3237 "parameters" : {
3238 "additionalProperties" : 0
3239 },
56122987
DM
3240 "permissions" : {
3241 "check" : [
3242 "perm",
3243 "/",
3244 [
3245 "Sys.Audit"
3246 ]
3247 ]
3248 },
7aacca6f 3249 "protected" : 1,
56122987 3250 "returns" : {
56122987 3251 "items" : {
56122987
DM
3252 "properties" : {
3253 "type" : {
3254 "type" : "string"
3255 }
44660702
DM
3256 },
3257 "type" : "object"
7aacca6f
DM
3258 },
3259 "type" : "array"
56122987
DM
3260 }
3261 }
3262 },
44660702 3263 "leaf" : 1,
7aacca6f 3264 "path" : "/cluster/status",
44660702 3265 "text" : "status"
56122987
DM
3266 },
3267 {
56122987
DM
3268 "info" : {
3269 "GET" : {
56122987 3270 "description" : "Get next free VMID. If you pass an VMID it will raise an error if the ID is already used.",
44660702
DM
3271 "method" : "GET",
3272 "name" : "nextid",
56122987 3273 "parameters" : {
44660702 3274 "additionalProperties" : 0,
56122987
DM
3275 "properties" : {
3276 "vmid" : {
44660702 3277 "description" : "The (unique) ID of the VM.",
56122987 3278 "format" : "pve-vmid",
7aacca6f 3279 "minimum" : 1,
7aacca6f 3280 "optional" : 1,
4bd7df8b 3281 "type" : "integer",
2c0dde61 3282 "typetext" : "integer (1 - N)"
56122987 3283 }
44660702 3284 }
56122987 3285 },
7aacca6f
DM
3286 "permissions" : {
3287 "user" : "all"
44660702
DM
3288 },
3289 "returns" : {
3290 "description" : "The next free VMID.",
3291 "type" : "integer"
7aacca6f 3292 }
56122987
DM
3293 }
3294 },
7aacca6f 3295 "leaf" : 1,
44660702
DM
3296 "path" : "/cluster/nextid",
3297 "text" : "nextid"
56122987
DM
3298 }
3299 ],
44660702
DM
3300 "info" : {
3301 "GET" : {
3302 "description" : "Cluster index.",
3303 "method" : "GET",
3304 "name" : "index",
3305 "parameters" : {
3306 "additionalProperties" : 0
3307 },
3308 "permissions" : {
3309 "user" : "all"
3310 },
3311 "returns" : {
3312 "items" : {
3313 "properties" : {},
3314 "type" : "object"
3315 },
3316 "links" : [
3317 {
3318 "href" : "{name}",
3319 "rel" : "child"
3320 }
3321 ],
3322 "type" : "array"
3323 }
3324 }
3325 },
3326 "leaf" : 0,
3327 "path" : "/cluster",
7aacca6f 3328 "text" : "cluster"
56122987
DM
3329 },
3330 {
56122987
DM
3331 "children" : [
3332 {
7aacca6f
DM
3333 "children" : [
3334 {
3335 "children" : [
3336 {
56122987
DM
3337 "children" : [
3338 {
56122987
DM
3339 "children" : [
3340 {
3341 "children" : [
3342 {
56122987
DM
3343 "info" : {
3344 "DELETE" : {
44660702 3345 "description" : "Delete rule.",
7aacca6f 3346 "method" : "DELETE",
44660702 3347 "name" : "delete_rule",
56122987 3348 "parameters" : {
44660702 3349 "additionalProperties" : 0,
56122987 3350 "properties" : {
44660702
DM
3351 "digest" : {
3352 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
3353 "maxLength" : 40,
3354 "optional" : 1,
3355 "type" : "string"
3356 },
56122987 3357 "node" : {
7aacca6f 3358 "description" : "The cluster node name.",
44660702
DM
3359 "format" : "pve-node",
3360 "type" : "string"
7aacca6f 3361 },
56122987 3362 "pos" : {
7aacca6f 3363 "description" : "Update rule at position <pos>.",
44660702 3364 "minimum" : 0,
56122987 3365 "optional" : 1,
4bd7df8b 3366 "type" : "integer",
2c0dde61 3367 "typetext" : "integer (0 - N)"
44660702
DM
3368 },
3369 "vmid" : {
3370 "description" : "The (unique) ID of the VM.",
3371 "format" : "pve-vmid",
3372 "minimum" : 1,
4bd7df8b 3373 "type" : "integer",
2c0dde61 3374 "typetext" : "integer (1 - N)"
56122987 3375 }
44660702 3376 }
7aacca6f 3377 },
56122987
DM
3378 "permissions" : {
3379 "check" : [
3380 "perm",
3381 "/vms/{vmid}",
3382 [
3383 "VM.Config.Network"
3384 ]
3385 ]
3386 },
44660702
DM
3387 "protected" : 1,
3388 "proxyto" : null,
56122987
DM
3389 "returns" : {
3390 "type" : "null"
44660702
DM
3391 }
3392 },
3393 "GET" : {
3394 "description" : "Get single rule data.",
3395 "method" : "GET",
3396 "name" : "get_rule",
3397 "parameters" : {
3398 "additionalProperties" : 0,
3399 "properties" : {
3400 "node" : {
3401 "description" : "The cluster node name.",
3402 "format" : "pve-node",
3403 "type" : "string"
3404 },
3405 "pos" : {
3406 "description" : "Update rule at position <pos>.",
3407 "minimum" : 0,
3408 "optional" : 1,
4bd7df8b 3409 "type" : "integer",
2c0dde61 3410 "typetext" : "integer (0 - N)"
44660702
DM
3411 },
3412 "vmid" : {
3413 "description" : "The (unique) ID of the VM.",
3414 "format" : "pve-vmid",
3415 "minimum" : 1,
4bd7df8b 3416 "type" : "integer",
2c0dde61 3417 "typetext" : "integer (1 - N)"
44660702
DM
3418 }
3419 }
56122987 3420 },
56122987
DM
3421 "permissions" : {
3422 "check" : [
3423 "perm",
3424 "/vms/{vmid}",
3425 [
44660702 3426 "VM.Audit"
56122987
DM
3427 ]
3428 ]
3429 },
56122987 3430 "proxyto" : null,
44660702
DM
3431 "returns" : {
3432 "properties" : {
3433 "pos" : {
3434 "type" : "integer"
3435 }
3436 },
3437 "type" : "object"
3438 }
3439 },
3440 "PUT" : {
7aacca6f
DM
3441 "description" : "Modify rule data.",
3442 "method" : "PUT",
44660702 3443 "name" : "update_rule",
56122987 3444 "parameters" : {
44660702 3445 "additionalProperties" : 0,
56122987 3446 "properties" : {
44660702
DM
3447 "action" : {
3448 "description" : "Rule action ('ACCEPT', 'DROP', 'REJECT') or security group name.",
3449 "maxLength" : 20,
3450 "minLength" : 2,
56122987 3451 "optional" : 1,
44660702 3452 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
7aacca6f
DM
3453 "type" : "string"
3454 },
7aacca6f 3455 "comment" : {
e94f0d56 3456 "description" : "Descriptive comment.",
7aacca6f
DM
3457 "optional" : 1,
3458 "type" : "string"
3459 },
3460 "delete" : {
7aacca6f 3461 "description" : "A list of settings you want to delete.",
44660702
DM
3462 "format" : "pve-configid-list",
3463 "optional" : 1,
3464 "type" : "string"
7aacca6f
DM
3465 },
3466 "dest" : {
44660702 3467 "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.",
7aacca6f 3468 "format" : "pve-fw-addr-spec",
56122987 3469 "optional" : 1,
44660702 3470 "type" : "string"
56122987 3471 },
7aacca6f 3472 "digest" : {
44660702 3473 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
7aacca6f 3474 "maxLength" : 40,
56122987 3475 "optional" : 1,
44660702
DM
3476 "type" : "string"
3477 },
3478 "dport" : {
3479 "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.",
3480 "format" : "pve-fw-dport-spec",
3481 "optional" : 1,
3482 "type" : "string"
56122987 3483 },
7aacca6f 3484 "enable" : {
e94f0d56 3485 "description" : "Flag to enable/disable a rule.",
44660702 3486 "minimum" : 0,
56122987 3487 "optional" : 1,
4bd7df8b 3488 "type" : "integer",
2c0dde61 3489 "typetext" : "integer (0 - N)"
7aacca6f 3490 },
44660702
DM
3491 "iface" : {
3492 "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.",
3493 "format" : "pve-iface",
3494 "maxLength" : 20,
7aacca6f 3495 "minLength" : 2,
56122987 3496 "optional" : 1,
44660702 3497 "type" : "string"
56122987 3498 },
44660702 3499 "macro" : {
e94f0d56 3500 "description" : "Use predefined standard macro.",
44660702 3501 "maxLength" : 128,
56122987 3502 "optional" : 1,
44660702 3503 "type" : "string"
56122987 3504 },
44660702
DM
3505 "moveto" : {
3506 "description" : "Move rule to new position <moveto>. Other arguments are ignored.",
3507 "minimum" : 0,
56122987 3508 "optional" : 1,
4bd7df8b 3509 "type" : "integer",
2c0dde61 3510 "typetext" : "integer (0 - N)"
56122987 3511 },
44660702
DM
3512 "node" : {
3513 "description" : "The cluster node name.",
3514 "format" : "pve-node",
3515 "type" : "string"
3516 },
3517 "pos" : {
3518 "description" : "Update rule at position <pos>.",
3519 "minimum" : 0,
3520 "optional" : 1,
4bd7df8b 3521 "type" : "integer",
2c0dde61 3522 "typetext" : "integer (0 - N)"
56122987 3523 },
44660702
DM
3524 "proto" : {
3525 "description" : "IP protocol. You can use protocol names ('tcp'/'udp') or simple numbers, as defined in '/etc/protocols'.",
3526 "format" : "pve-fw-protocol-spec",
3527 "optional" : 1,
3528 "type" : "string"
7aacca6f 3529 },
44660702
DM
3530 "source" : {
3531 "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.",
3532 "format" : "pve-fw-addr-spec",
56122987 3533 "optional" : 1,
7aacca6f 3534 "type" : "string"
56122987
DM
3535 },
3536 "sport" : {
3537 "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.",
44660702
DM
3538 "format" : "pve-fw-sport-spec",
3539 "optional" : 1,
3540 "type" : "string"
3541 },
3542 "type" : {
e94f0d56 3543 "description" : "Rule type.",
44660702
DM
3544 "enum" : [
3545 "in",
3546 "out",
3547 "group"
3548 ],
56122987 3549 "optional" : 1,
56122987 3550 "type" : "string"
44660702
DM
3551 },
3552 "vmid" : {
3553 "description" : "The (unique) ID of the VM.",
3554 "format" : "pve-vmid",
3555 "minimum" : 1,
4bd7df8b 3556 "type" : "integer",
2c0dde61 3557 "typetext" : "integer (1 - N)"
56122987 3558 }
44660702 3559 }
56122987 3560 },
56122987
DM
3561 "permissions" : {
3562 "check" : [
3563 "perm",
3564 "/vms/{vmid}",
3565 [
44660702 3566 "VM.Config.Network"
56122987
DM
3567 ]
3568 ]
7aacca6f 3569 },
44660702 3570 "protected" : 1,
7aacca6f 3571 "proxyto" : null,
7aacca6f 3572 "returns" : {
44660702
DM
3573 "type" : "null"
3574 }
56122987 3575 }
7aacca6f 3576 },
44660702 3577 "leaf" : 1,
7aacca6f 3578 "path" : "/nodes/{node}/qemu/{vmid}/firewall/rules/{pos}",
44660702 3579 "text" : "{pos}"
56122987
DM
3580 }
3581 ],
56122987 3582 "info" : {
44660702
DM
3583 "GET" : {
3584 "description" : "List rules.",
3585 "method" : "GET",
3586 "name" : "get_rules",
3587 "parameters" : {
3588 "additionalProperties" : 0,
3589 "properties" : {
3590 "node" : {
3591 "description" : "The cluster node name.",
3592 "format" : "pve-node",
3593 "type" : "string"
3594 },
3595 "vmid" : {
3596 "description" : "The (unique) ID of the VM.",
3597 "format" : "pve-vmid",
3598 "minimum" : 1,
4bd7df8b 3599 "type" : "integer",
2c0dde61 3600 "typetext" : "integer (1 - N)"
44660702
DM
3601 }
3602 }
56122987 3603 },
56122987
DM
3604 "permissions" : {
3605 "check" : [
3606 "perm",
3607 "/vms/{vmid}",
3608 [
44660702 3609 "VM.Audit"
56122987
DM
3610 ]
3611 ]
7aacca6f 3612 },
44660702
DM
3613 "proxyto" : null,
3614 "returns" : {
3615 "items" : {
3616 "properties" : {
3617 "pos" : {
3618 "type" : "integer"
3619 }
3620 },
3621 "type" : "object"
3622 },
3623 "links" : [
3624 {
3625 "href" : "{pos}",
3626 "rel" : "child"
3627 }
3628 ],
3629 "type" : "array"
3630 }
3631 },
3632 "POST" : {
3633 "description" : "Create new rule.",
7aacca6f 3634 "method" : "POST",
44660702 3635 "name" : "create_rule",
56122987 3636 "parameters" : {
44660702 3637 "additionalProperties" : 0,
56122987 3638 "properties" : {
44660702
DM
3639 "action" : {
3640 "description" : "Rule action ('ACCEPT', 'DROP', 'REJECT') or security group name.",
3641 "maxLength" : 20,
3642 "minLength" : 2,
3643 "optional" : 0,
3644 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
3645 "type" : "string"
56122987 3646 },
44660702 3647 "comment" : {
e94f0d56 3648 "description" : "Descriptive comment.",
56122987 3649 "optional" : 1,
56122987
DM
3650 "type" : "string"
3651 },
44660702
DM
3652 "dest" : {
3653 "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.",
3654 "format" : "pve-fw-addr-spec",
3655 "optional" : 1,
3656 "type" : "string"
56122987 3657 },
44660702
DM
3658 "digest" : {
3659 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
3660 "maxLength" : 40,
56122987 3661 "optional" : 1,
44660702 3662 "type" : "string"
56122987 3663 },
7aacca6f
DM
3664 "dport" : {
3665 "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.",
44660702 3666 "format" : "pve-fw-dport-spec",
7aacca6f 3667 "optional" : 1,
44660702 3668 "type" : "string"
56122987
DM
3669 },
3670 "enable" : {
e94f0d56 3671 "description" : "Flag to enable/disable a rule.",
56122987 3672 "minimum" : 0,
44660702 3673 "optional" : 1,
4bd7df8b 3674 "type" : "integer",
2c0dde61 3675 "typetext" : "integer (0 - N)"
56122987 3676 },
44660702
DM
3677 "iface" : {
3678 "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.",
3679 "format" : "pve-iface",
3680 "maxLength" : 20,
7aacca6f 3681 "minLength" : 2,
44660702
DM
3682 "optional" : 1,
3683 "type" : "string"
56122987 3684 },
44660702 3685 "macro" : {
e94f0d56 3686 "description" : "Use predefined standard macro.",
44660702 3687 "maxLength" : 128,
56122987 3688 "optional" : 1,
44660702 3689 "type" : "string"
7aacca6f 3690 },
44660702
DM
3691 "node" : {
3692 "description" : "The cluster node name.",
3693 "format" : "pve-node",
3694 "type" : "string"
3695 },
3696 "pos" : {
3697 "description" : "Update rule at position <pos>.",
3698 "minimum" : 0,
3699 "optional" : 1,
4bd7df8b 3700 "type" : "integer",
2c0dde61 3701 "typetext" : "integer (0 - N)"
44660702
DM
3702 },
3703 "proto" : {
3704 "description" : "IP protocol. You can use protocol names ('tcp'/'udp') or simple numbers, as defined in '/etc/protocols'.",
3705 "format" : "pve-fw-protocol-spec",
7aacca6f 3706 "optional" : 1,
56122987 3707 "type" : "string"
7aacca6f
DM
3708 },
3709 "source" : {
3710 "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.",
44660702 3711 "format" : "pve-fw-addr-spec",
7aacca6f 3712 "optional" : 1,
44660702 3713 "type" : "string"
7aacca6f 3714 },
44660702
DM
3715 "sport" : {
3716 "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.",
3717 "format" : "pve-fw-sport-spec",
7aacca6f 3718 "optional" : 1,
44660702 3719 "type" : "string"
7aacca6f 3720 },
44660702 3721 "type" : {
e94f0d56 3722 "description" : "Rule type.",
44660702
DM
3723 "enum" : [
3724 "in",
3725 "out",
3726 "group"
3727 ],
3728 "optional" : 0,
3729 "type" : "string"
7aacca6f 3730 },
7aacca6f 3731 "vmid" : {
44660702 3732 "description" : "The (unique) ID of the VM.",
7aacca6f
DM
3733 "format" : "pve-vmid",
3734 "minimum" : 1,
4bd7df8b 3735 "type" : "integer",
2c0dde61 3736 "typetext" : "integer (1 - N)"
7aacca6f
DM
3737 }
3738 }
3739 },
56122987
DM
3740 "permissions" : {
3741 "check" : [
3742 "perm",
3743 "/vms/{vmid}",
3744 [
44660702 3745 "VM.Config.Network"
56122987
DM
3746 ]
3747 ]
3748 },
44660702
DM
3749 "protected" : 1,
3750 "proxyto" : null,
56122987 3751 "returns" : {
44660702
DM
3752 "type" : "null"
3753 }
56122987
DM
3754 }
3755 },
44660702 3756 "leaf" : 0,
7aacca6f 3757 "path" : "/nodes/{node}/qemu/{vmid}/firewall/rules",
44660702 3758 "text" : "rules"
56122987
DM
3759 },
3760 {
3761 "children" : [
3762 {
56122987 3763 "info" : {
44660702
DM
3764 "DELETE" : {
3765 "description" : "Remove IP or Network alias.",
3766 "method" : "DELETE",
3767 "name" : "remove_alias",
56122987 3768 "parameters" : {
44660702 3769 "additionalProperties" : 0,
56122987 3770 "properties" : {
44660702
DM
3771 "digest" : {
3772 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
3773 "maxLength" : 40,
3774 "optional" : 1,
3775 "type" : "string"
56122987
DM
3776 },
3777 "name" : {
56122987 3778 "description" : "Alias name.",
44660702 3779 "maxLength" : 64,
7aacca6f 3780 "minLength" : 2,
44660702 3781 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
56122987
DM
3782 "type" : "string"
3783 },
7aacca6f 3784 "node" : {
44660702 3785 "description" : "The cluster node name.",
7aacca6f 3786 "format" : "pve-node",
44660702
DM
3787 "type" : "string"
3788 },
3789 "vmid" : {
3790 "description" : "The (unique) ID of the VM.",
3791 "format" : "pve-vmid",
3792 "minimum" : 1,
4bd7df8b 3793 "type" : "integer",
2c0dde61 3794 "typetext" : "integer (1 - N)"
56122987 3795 }
44660702 3796 }
56122987 3797 },
7aacca6f
DM
3798 "permissions" : {
3799 "check" : [
3800 "perm",
3801 "/vms/{vmid}",
3802 [
3803 "VM.Config.Network"
3804 ]
3805 ]
56122987 3806 },
44660702
DM
3807 "protected" : 1,
3808 "returns" : {
3809 "type" : "null"
3810 }
3811 },
3812 "GET" : {
3813 "description" : "Read alias.",
3814 "method" : "GET",
3815 "name" : "read_alias",
56122987 3816 "parameters" : {
44660702 3817 "additionalProperties" : 0,
56122987 3818 "properties" : {
56122987 3819 "name" : {
7aacca6f 3820 "description" : "Alias name.",
44660702 3821 "maxLength" : 64,
56122987 3822 "minLength" : 2,
44660702 3823 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
56122987 3824 "type" : "string"
7aacca6f
DM
3825 },
3826 "node" : {
3827 "description" : "The cluster node name.",
44660702
DM
3828 "format" : "pve-node",
3829 "type" : "string"
3830 },
3831 "vmid" : {
3832 "description" : "The (unique) ID of the VM.",
3833 "format" : "pve-vmid",
3834 "minimum" : 1,
4bd7df8b 3835 "type" : "integer",
2c0dde61 3836 "typetext" : "integer (1 - N)"
56122987 3837 }
44660702 3838 }
56122987 3839 },
44660702
DM
3840 "permissions" : {
3841 "check" : [
3842 "perm",
3843 "/vms/{vmid}",
3844 [
3845 "VM.Audit"
3846 ]
3847 ]
56122987 3848 },
44660702
DM
3849 "returns" : {
3850 "type" : "object"
3851 }
7aacca6f 3852 },
44660702
DM
3853 "PUT" : {
3854 "description" : "Update IP or Network alias.",
3855 "method" : "PUT",
3856 "name" : "update_alias",
56122987
DM
3857 "parameters" : {
3858 "additionalProperties" : 0,
3859 "properties" : {
44660702
DM
3860 "cidr" : {
3861 "description" : "Network/IP specification in CIDR format.",
3862 "format" : "IPorCIDR",
3863 "type" : "string"
3864 },
3865 "comment" : {
3866 "optional" : 1,
3867 "type" : "string"
56122987
DM
3868 },
3869 "digest" : {
44660702 3870 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
56122987
DM
3871 "maxLength" : 40,
3872 "optional" : 1,
44660702 3873 "type" : "string"
56122987 3874 },
7aacca6f 3875 "name" : {
44660702 3876 "description" : "Alias name.",
56122987
DM
3877 "maxLength" : 64,
3878 "minLength" : 2,
3879 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
44660702 3880 "type" : "string"
7aacca6f
DM
3881 },
3882 "node" : {
7aacca6f 3883 "description" : "The cluster node name.",
44660702
DM
3884 "format" : "pve-node",
3885 "type" : "string"
3886 },
3887 "rename" : {
3888 "description" : "Rename an existing alias.",
3889 "maxLength" : 64,
3890 "minLength" : 2,
3891 "optional" : 1,
3892 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
3893 "type" : "string"
3894 },
3895 "vmid" : {
3896 "description" : "The (unique) ID of the VM.",
3897 "format" : "pve-vmid",
3898 "minimum" : 1,
4bd7df8b 3899 "type" : "integer",
2c0dde61 3900 "typetext" : "integer (1 - N)"
56122987
DM
3901 }
3902 }
3903 },
7aacca6f
DM
3904 "permissions" : {
3905 "check" : [
3906 "perm",
3907 "/vms/{vmid}",
3908 [
3909 "VM.Config.Network"
3910 ]
3911 ]
3912 },
3913 "protected" : 1,
7aacca6f
DM
3914 "returns" : {
3915 "type" : "null"
44660702 3916 }
56122987
DM
3917 }
3918 },
44660702 3919 "leaf" : 1,
7aacca6f 3920 "path" : "/nodes/{node}/qemu/{vmid}/firewall/aliases/{name}",
44660702 3921 "text" : "{name}"
56122987
DM
3922 }
3923 ],
3924 "info" : {
44660702
DM
3925 "GET" : {
3926 "description" : "List aliases",
3927 "method" : "GET",
3928 "name" : "get_aliases",
56122987 3929 "parameters" : {
44660702 3930 "additionalProperties" : 0,
56122987 3931 "properties" : {
7aacca6f 3932 "node" : {
7aacca6f 3933 "description" : "The cluster node name.",
44660702 3934 "format" : "pve-node",
7aacca6f 3935 "type" : "string"
56122987 3936 },
44660702
DM
3937 "vmid" : {
3938 "description" : "The (unique) ID of the VM.",
3939 "format" : "pve-vmid",
3940 "minimum" : 1,
4bd7df8b 3941 "type" : "integer",
2c0dde61 3942 "typetext" : "integer (1 - N)"
56122987 3943 }
44660702 3944 }
56122987 3945 },
56122987
DM
3946 "permissions" : {
3947 "check" : [
3948 "perm",
3949 "/vms/{vmid}",
3950 [
44660702 3951 "VM.Audit"
56122987
DM
3952 ]
3953 ]
3954 },
56122987
DM
3955 "returns" : {
3956 "items" : {
3957 "properties" : {
44660702 3958 "cidr" : {
56122987
DM
3959 "type" : "string"
3960 },
44660702
DM
3961 "comment" : {
3962 "optional" : 1,
7aacca6f 3963 "type" : "string"
56122987
DM
3964 },
3965 "digest" : {
56122987 3966 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
44660702 3967 "maxLength" : 40,
56122987
DM
3968 "optional" : 0,
3969 "type" : "string"
3970 },
44660702 3971 "name" : {
56122987
DM
3972 "type" : "string"
3973 }
44660702
DM
3974 },
3975 "type" : "object"
56122987 3976 },
56122987
DM
3977 "links" : [
3978 {
3979 "href" : "{name}",
3980 "rel" : "child"
3981 }
44660702
DM
3982 ],
3983 "type" : "array"
3984 }
3985 },
3986 "POST" : {
3987 "description" : "Create IP or Network Alias.",
3988 "method" : "POST",
3989 "name" : "create_alias",
56122987 3990 "parameters" : {
7aacca6f 3991 "additionalProperties" : 0,
56122987 3992 "properties" : {
44660702
DM
3993 "cidr" : {
3994 "description" : "Network/IP specification in CIDR format.",
3995 "format" : "IPorCIDR",
3996 "type" : "string"
3997 },
3998 "comment" : {
3999 "optional" : 1,
4000 "type" : "string"
4001 },
4002 "name" : {
4003 "description" : "Alias name.",
4004 "maxLength" : 64,
4005 "minLength" : 2,
4006 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
4007 "type" : "string"
56122987
DM
4008 },
4009 "node" : {
7aacca6f 4010 "description" : "The cluster node name.",
44660702 4011 "format" : "pve-node",
56122987 4012 "type" : "string"
44660702
DM
4013 },
4014 "vmid" : {
4015 "description" : "The (unique) ID of the VM.",
4016 "format" : "pve-vmid",
4017 "minimum" : 1,
4bd7df8b 4018 "type" : "integer",
2c0dde61 4019 "typetext" : "integer (1 - N)"
56122987 4020 }
7aacca6f 4021 }
56122987 4022 },
44660702
DM
4023 "permissions" : {
4024 "check" : [
4025 "perm",
4026 "/vms/{vmid}",
4027 [
4028 "VM.Config.Network"
4029 ]
4030 ]
4031 },
4032 "protected" : 1,
4033 "returns" : {
4034 "type" : "null"
4035 }
56122987 4036 }
44660702
DM
4037 },
4038 "leaf" : 0,
4039 "path" : "/nodes/{node}/qemu/{vmid}/firewall/aliases",
4040 "text" : "aliases"
56122987
DM
4041 },
4042 {
56122987
DM
4043 "children" : [
4044 {
7aacca6f
DM
4045 "children" : [
4046 {
4047 "info" : {
4048 "DELETE" : {
44660702 4049 "description" : "Remove IP or Network from IPSet.",
7aacca6f 4050 "method" : "DELETE",
44660702 4051 "name" : "remove_ip",
7aacca6f 4052 "parameters" : {
44660702 4053 "additionalProperties" : 0,
7aacca6f 4054 "properties" : {
44660702
DM
4055 "cidr" : {
4056 "description" : "Network/IP specification in CIDR format.",
4057 "format" : "IPorCIDRorAlias",
4058 "type" : "string"
4059 },
4060 "digest" : {
4061 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
4062 "maxLength" : 40,
4063 "optional" : 1,
4064 "type" : "string"
4065 },
7aacca6f 4066 "name" : {
7aacca6f 4067 "description" : "IP set name.",
44660702
DM
4068 "maxLength" : 64,
4069 "minLength" : 2,
7aacca6f 4070 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
44660702 4071 "type" : "string"
7aacca6f
DM
4072 },
4073 "node" : {
4074 "description" : "The cluster node name.",
44660702
DM
4075 "format" : "pve-node",
4076 "type" : "string"
7aacca6f
DM
4077 },
4078 "vmid" : {
44660702 4079 "description" : "The (unique) ID of the VM.",
7aacca6f 4080 "format" : "pve-vmid",
44660702 4081 "minimum" : 1,
4bd7df8b 4082 "type" : "integer",
2c0dde61 4083 "typetext" : "integer (1 - N)"
7aacca6f 4084 }
44660702 4085 }
7aacca6f 4086 },
7aacca6f
DM
4087 "permissions" : {
4088 "check" : [
4089 "perm",
4090 "/vms/{vmid}",
4091 [
4092 "VM.Config.Network"
4093 ]
4094 ]
4095 },
4096 "protected" : 1,
44660702
DM
4097 "returns" : {
4098 "type" : "null"
4099 }
56122987 4100 },
44660702
DM
4101 "GET" : {
4102 "description" : "Read IP or Network settings from IPSet.",
4103 "method" : "GET",
4104 "name" : "read_ip",
7aacca6f 4105 "parameters" : {
44660702 4106 "additionalProperties" : 0,
7aacca6f 4107 "properties" : {
7aacca6f 4108 "cidr" : {
44660702 4109 "description" : "Network/IP specification in CIDR format.",
7aacca6f 4110 "format" : "IPorCIDRorAlias",
44660702 4111 "type" : "string"
7aacca6f
DM
4112 },
4113 "name" : {
7aacca6f 4114 "description" : "IP set name.",
44660702 4115 "maxLength" : 64,
7aacca6f 4116 "minLength" : 2,
44660702
DM
4117 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
4118 "type" : "string"
7aacca6f 4119 },
44660702
DM
4120 "node" : {
4121 "description" : "The cluster node name.",
4122 "format" : "pve-node",
7aacca6f
DM
4123 "type" : "string"
4124 },
44660702
DM
4125 "vmid" : {
4126 "description" : "The (unique) ID of the VM.",
4127 "format" : "pve-vmid",
4128 "minimum" : 1,
4bd7df8b 4129 "type" : "integer",
2c0dde61 4130 "typetext" : "integer (1 - N)"
7aacca6f 4131 }
44660702 4132 }
7aacca6f 4133 },
44660702
DM
4134 "permissions" : {
4135 "check" : [
4136 "perm",
4137 "/vms/{vmid}",
4138 [
4139 "VM.Audit"
4140 ]
4141 ]
4142 },
4143 "protected" : 1,
7aacca6f 4144 "returns" : {
44660702 4145 "type" : "object"
7aacca6f 4146 }
56122987 4147 },
44660702
DM
4148 "PUT" : {
4149 "description" : "Update IP or Network settings",
4150 "method" : "PUT",
4151 "name" : "update_ip",
7aacca6f
DM
4152 "parameters" : {
4153 "additionalProperties" : 0,
4154 "properties" : {
44660702
DM
4155 "cidr" : {
4156 "description" : "Network/IP specification in CIDR format.",
4157 "format" : "IPorCIDRorAlias",
4158 "type" : "string"
4159 },
4160 "comment" : {
4161 "optional" : 1,
4162 "type" : "string"
4163 },
4164 "digest" : {
4165 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
4166 "maxLength" : 40,
4167 "optional" : 1,
4168 "type" : "string"
4169 },
7aacca6f 4170 "name" : {
7aacca6f 4171 "description" : "IP set name.",
44660702 4172 "maxLength" : 64,
7aacca6f 4173 "minLength" : 2,
44660702
DM
4174 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
4175 "type" : "string"
7aacca6f
DM
4176 },
4177 "node" : {
7aacca6f 4178 "description" : "The cluster node name.",
44660702 4179 "format" : "pve-node",
7aacca6f
DM
4180 "type" : "string"
4181 },
44660702
DM
4182 "nomatch" : {
4183 "optional" : 1,
4184 "type" : "boolean"
7aacca6f
DM
4185 },
4186 "vmid" : {
4187 "description" : "The (unique) ID of the VM.",
44660702 4188 "format" : "pve-vmid",
7aacca6f 4189 "minimum" : 1,
4bd7df8b 4190 "type" : "integer",
2c0dde61 4191 "typetext" : "integer (1 - N)"
7aacca6f
DM
4192 }
4193 }
4194 },
4195 "permissions" : {
4196 "check" : [
4197 "perm",
4198 "/vms/{vmid}",
4199 [
44660702 4200 "VM.Config.Network"
7aacca6f
DM
4201 ]
4202 ]
4203 },
7aacca6f 4204 "protected" : 1,
7aacca6f 4205 "returns" : {
44660702 4206 "type" : "null"
7aacca6f 4207 }
56122987 4208 }
7aacca6f 4209 },
7aacca6f 4210 "leaf" : 1,
44660702
DM
4211 "path" : "/nodes/{node}/qemu/{vmid}/firewall/ipset/{name}/{cidr}",
4212 "text" : "{cidr}"
7aacca6f 4213 }
44660702
DM
4214 ],
4215 "info" : {
4216 "DELETE" : {
4217 "description" : "Delete IPSet",
4218 "method" : "DELETE",
4219 "name" : "delete_ipset",
4220 "parameters" : {
4221 "additionalProperties" : 0,
4222 "properties" : {
4223 "name" : {
4224 "description" : "IP set name.",
4225 "maxLength" : 64,
4226 "minLength" : 2,
4227 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
4228 "type" : "string"
4229 },
4230 "node" : {
4231 "description" : "The cluster node name.",
4232 "format" : "pve-node",
4233 "type" : "string"
4234 },
4235 "vmid" : {
4236 "description" : "The (unique) ID of the VM.",
4237 "format" : "pve-vmid",
4238 "minimum" : 1,
4bd7df8b 4239 "type" : "integer",
2c0dde61 4240 "typetext" : "integer (1 - N)"
44660702
DM
4241 }
4242 }
7aacca6f 4243 },
44660702
DM
4244 "permissions" : {
4245 "check" : [
4246 "perm",
4247 "/vms/{vmid}",
4248 [
4249 "VM.Config.Network"
4250 ]
4251 ]
7aacca6f 4252 },
44660702
DM
4253 "protected" : 1,
4254 "returns" : {
4255 "type" : "null"
4256 }
4257 },
4258 "GET" : {
4259 "description" : "List IPSet content",
4260 "method" : "GET",
4261 "name" : "get_ipset",
4262 "parameters" : {
4263 "additionalProperties" : 0,
4264 "properties" : {
4265 "name" : {
4266 "description" : "IP set name.",
4267 "maxLength" : 64,
4268 "minLength" : 2,
4269 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
4270 "type" : "string"
4271 },
4272 "node" : {
4273 "description" : "The cluster node name.",
4274 "format" : "pve-node",
4275 "type" : "string"
4276 },
4277 "vmid" : {
4278 "description" : "The (unique) ID of the VM.",
4279 "format" : "pve-vmid",
4280 "minimum" : 1,
4bd7df8b 4281 "type" : "integer",
2c0dde61 4282 "typetext" : "integer (1 - N)"
44660702
DM
4283 }
4284 }
7aacca6f 4285 },
44660702
DM
4286 "permissions" : {
4287 "check" : [
4288 "perm",
4289 "/vms/{vmid}",
4290 [
4291 "VM.Audit"
4292 ]
4293 ]
7aacca6f 4294 },
44660702
DM
4295 "returns" : {
4296 "items" : {
4297 "properties" : {
4298 "cidr" : {
4299 "type" : "string"
4300 },
4301 "comment" : {
4302 "optional" : 1,
4303 "type" : "string"
4304 },
4305 "digest" : {
4306 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
4307 "maxLength" : 40,
4308 "optional" : 0,
4309 "type" : "string"
4310 },
4311 "nomatch" : {
4312 "optional" : 1,
4313 "type" : "boolean"
4314 }
4315 },
4316 "type" : "object"
4317 },
4318 "links" : [
4319 {
4320 "href" : "{cidr}",
4321 "rel" : "child"
4322 }
4323 ],
4324 "type" : "array"
56122987
DM
4325 }
4326 },
44660702
DM
4327 "POST" : {
4328 "description" : "Add IP or Network to IPSet.",
4329 "method" : "POST",
4330 "name" : "create_ip",
4331 "parameters" : {
4332 "additionalProperties" : 0,
4333 "properties" : {
4334 "cidr" : {
4335 "description" : "Network/IP specification in CIDR format.",
4336 "format" : "IPorCIDRorAlias",
4337 "type" : "string"
4338 },
4339 "comment" : {
4340 "optional" : 1,
4341 "type" : "string"
4342 },
4343 "name" : {
4344 "description" : "IP set name.",
4345 "maxLength" : 64,
4346 "minLength" : 2,
4347 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
4348 "type" : "string"
4349 },
4350 "node" : {
4351 "description" : "The cluster node name.",
4352 "format" : "pve-node",
4353 "type" : "string"
4354 },
4355 "nomatch" : {
4356 "optional" : 1,
4357 "type" : "boolean"
4358 },
4359 "vmid" : {
4360 "description" : "The (unique) ID of the VM.",
4361 "format" : "pve-vmid",
4362 "minimum" : 1,
4bd7df8b 4363 "type" : "integer",
2c0dde61 4364 "typetext" : "integer (1 - N)"
44660702
DM
4365 }
4366 }
4367 },
4368 "permissions" : {
4369 "check" : [
4370 "perm",
4371 "/vms/{vmid}",
4372 [
4373 "VM.Config.Network"
4374 ]
4375 ]
4376 },
4377 "protected" : 1,
4378 "returns" : {
4379 "type" : "null"
4380 }
4381 }
4382 },
4383 "leaf" : 0,
4384 "path" : "/nodes/{node}/qemu/{vmid}/firewall/ipset/{name}",
4385 "text" : "{name}"
4386 }
4387 ],
4388 "info" : {
4389 "GET" : {
4390 "description" : "List IPSets",
4391 "method" : "GET",
4392 "name" : "ipset_index",
4393 "parameters" : {
4394 "additionalProperties" : 0,
4395 "properties" : {
4396 "node" : {
4397 "description" : "The cluster node name.",
4398 "format" : "pve-node",
4399 "type" : "string"
4400 },
4401 "vmid" : {
4402 "description" : "The (unique) ID of the VM.",
4403 "format" : "pve-vmid",
4404 "minimum" : 1,
4bd7df8b 4405 "type" : "integer",
2c0dde61 4406 "typetext" : "integer (1 - N)"
44660702
DM
4407 }
4408 }
56122987
DM
4409 },
4410 "permissions" : {
4411 "check" : [
4412 "perm",
4413 "/vms/{vmid}",
4414 [
44660702 4415 "VM.Audit"
56122987
DM
4416 ]
4417 ]
4418 },
7aacca6f 4419 "returns" : {
7aacca6f
DM
4420 "items" : {
4421 "properties" : {
7aacca6f
DM
4422 "comment" : {
4423 "optional" : 1,
4424 "type" : "string"
4425 },
4426 "digest" : {
7aacca6f 4427 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
44660702
DM
4428 "maxLength" : 40,
4429 "optional" : 0,
4430 "type" : "string"
4431 },
4432 "name" : {
4433 "description" : "IP set name.",
4434 "maxLength" : 64,
4435 "minLength" : 2,
4436 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
4437 "type" : "string"
7aacca6f
DM
4438 }
4439 },
4440 "type" : "object"
4441 },
4442 "links" : [
4443 {
44660702
DM
4444 "href" : "{name}",
4445 "rel" : "child"
7aacca6f 4446 }
44660702
DM
4447 ],
4448 "type" : "array"
4449 }
4450 },
4451 "POST" : {
4452 "description" : "Create new IPSet",
4453 "method" : "POST",
4454 "name" : "create_ipset",
56122987
DM
4455 "parameters" : {
4456 "additionalProperties" : 0,
4457 "properties" : {
44660702
DM
4458 "comment" : {
4459 "optional" : 1,
4460 "type" : "string"
56122987 4461 },
44660702
DM
4462 "digest" : {
4463 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
4464 "maxLength" : 40,
4465 "optional" : 1,
4466 "type" : "string"
4467 },
4468 "name" : {
4469 "description" : "IP set name.",
4470 "maxLength" : 64,
4471 "minLength" : 2,
4472 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
4473 "type" : "string"
4474 },
4475 "node" : {
4476 "description" : "The cluster node name.",
4477 "format" : "pve-node",
4478 "type" : "string"
4479 },
4480 "rename" : {
4481 "description" : "Rename an existing IPSet. You can set 'rename' to the same value as 'name' to update the 'comment' of an existing IPSet.",
4482 "maxLength" : 64,
4483 "minLength" : 2,
4484 "optional" : 1,
4485 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
4486 "type" : "string"
4487 },
4488 "vmid" : {
4489 "description" : "The (unique) ID of the VM.",
4490 "format" : "pve-vmid",
4491 "minimum" : 1,
4bd7df8b 4492 "type" : "integer",
2c0dde61 4493 "typetext" : "integer (1 - N)"
44660702
DM
4494 }
4495 }
4496 },
7aacca6f
DM
4497 "permissions" : {
4498 "check" : [
4499 "perm",
4500 "/vms/{vmid}",
4501 [
4502 "VM.Config.Network"
4503 ]
4504 ]
4505 },
44660702 4506 "protected" : 1,
56122987 4507 "returns" : {
7aacca6f 4508 "type" : "null"
44660702
DM
4509 }
4510 }
4511 },
4512 "leaf" : 0,
4513 "path" : "/nodes/{node}/qemu/{vmid}/firewall/ipset",
4514 "text" : "ipset"
4515 },
4516 {
4517 "info" : {
4518 "GET" : {
4519 "description" : "Get VM firewall options.",
4520 "method" : "GET",
4521 "name" : "get_options",
7aacca6f
DM
4522 "parameters" : {
4523 "additionalProperties" : 0,
56122987 4524 "properties" : {
7aacca6f
DM
4525 "node" : {
4526 "description" : "The cluster node name.",
44660702
DM
4527 "format" : "pve-node",
4528 "type" : "string"
7aacca6f 4529 },
44660702
DM
4530 "vmid" : {
4531 "description" : "The (unique) ID of the VM.",
4532 "format" : "pve-vmid",
4533 "minimum" : 1,
4bd7df8b 4534 "type" : "integer",
2c0dde61 4535 "typetext" : "integer (1 - N)"
44660702
DM
4536 }
4537 }
4538 },
4539 "permissions" : {
4540 "check" : [
4541 "perm",
4542 "/vms/{vmid}",
4543 [
4544 "VM.Audit"
4545 ]
4546 ]
4547 },
4548 "proxyto" : "node",
4549 "returns" : {
4550 "properties" : {
4551 "dhcp" : {
4552 "description" : "Enable DHCP.",
56122987 4553 "optional" : 1,
44660702 4554 "type" : "boolean"
56122987 4555 },
44660702
DM
4556 "enable" : {
4557 "description" : "Enable/disable firewall rules.",
7aacca6f 4558 "optional" : 1,
44660702 4559 "type" : "boolean"
56122987 4560 },
44660702
DM
4561 "ipfilter" : {
4562 "description" : "Enable default IP filters. This is equivalent to adding an empty ipfilter-net<id> ipset for every interface. Such ipsets implicitly contain sane default restrictions such as restricting IPv6 link local addresses to the one derived from the interface's MAC address. For containers the configured IP addresses will be implicitly added.",
7aacca6f 4563 "optional" : 1,
44660702 4564 "type" : "boolean"
7aacca6f 4565 },
56122987 4566 "log_level_in" : {
7aacca6f 4567 "description" : "Log level for incoming traffic.",
56122987
DM
4568 "enum" : [
4569 "emerg",
4570 "alert",
4571 "crit",
4572 "err",
4573 "warning",
4574 "notice",
4575 "info",
4576 "debug",
4577 "nolog"
4578 ],
56122987
DM
4579 "optional" : 1,
4580 "type" : "string"
4581 },
44660702
DM
4582 "log_level_out" : {
4583 "description" : "Log level for outgoing traffic.",
4584 "enum" : [
4585 "emerg",
4586 "alert",
4587 "crit",
4588 "err",
4589 "warning",
4590 "notice",
4591 "info",
4592 "debug",
4593 "nolog"
4594 ],
4595 "optional" : 1,
4596 "type" : "string"
4597 },
4598 "macfilter" : {
4599 "description" : "Enable/disable MAC address filter.",
56122987 4600 "optional" : 1,
7aacca6f 4601 "type" : "boolean"
56122987
DM
4602 },
4603 "ndp" : {
44660702 4604 "description" : "Enable NDP.",
56122987 4605 "optional" : 1,
44660702 4606 "type" : "boolean"
56122987
DM
4607 },
4608 "policy_in" : {
56122987
DM
4609 "description" : "Input policy.",
4610 "enum" : [
4611 "ACCEPT",
4612 "REJECT",
4613 "DROP"
44660702
DM
4614 ],
4615 "optional" : 1,
4616 "type" : "string"
56122987 4617 },
44660702
DM
4618 "policy_out" : {
4619 "description" : "Output policy.",
4620 "enum" : [
4621 "ACCEPT",
4622 "REJECT",
4623 "DROP"
4624 ],
4625 "optional" : 1,
4626 "type" : "string"
4627 },
4628 "radv" : {
4629 "description" : "Allow sending Router Advertisement.",
4630 "optional" : 1,
4631 "type" : "boolean"
4632 }
4633 },
4634 "type" : "object"
4635 }
4636 },
4637 "PUT" : {
4638 "description" : "Set Firewall options.",
4639 "method" : "PUT",
4640 "name" : "set_options",
4641 "parameters" : {
4642 "additionalProperties" : 0,
4643 "properties" : {
4644 "delete" : {
4645 "description" : "A list of settings you want to delete.",
4646 "format" : "pve-configid-list",
4647 "optional" : 1,
4648 "type" : "string"
4649 },
4650 "dhcp" : {
4651 "description" : "Enable DHCP.",
7aacca6f 4652 "optional" : 1,
44660702 4653 "type" : "boolean"
7aacca6f
DM
4654 },
4655 "digest" : {
4656 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
44660702 4657 "maxLength" : 40,
7aacca6f 4658 "optional" : 1,
44660702 4659 "type" : "string"
7aacca6f
DM
4660 },
4661 "enable" : {
4662 "description" : "Enable/disable firewall rules.",
56122987 4663 "optional" : 1,
7aacca6f
DM
4664 "type" : "boolean"
4665 },
44660702
DM
4666 "ipfilter" : {
4667 "description" : "Enable default IP filters. This is equivalent to adding an empty ipfilter-net<id> ipset for every interface. Such ipsets implicitly contain sane default restrictions such as restricting IPv6 link local addresses to the one derived from the interface's MAC address. For containers the configured IP addresses will be implicitly added.",
4668 "optional" : 1,
4669 "type" : "boolean"
4670 },
4671 "log_level_in" : {
4672 "description" : "Log level for incoming traffic.",
56122987
DM
4673 "enum" : [
4674 "emerg",
4675 "alert",
4676 "crit",
4677 "err",
4678 "warning",
4679 "notice",
4680 "info",
4681 "debug",
4682 "nolog"
7aacca6f 4683 ],
7aacca6f 4684 "optional" : 1,
44660702 4685 "type" : "string"
7aacca6f 4686 },
44660702
DM
4687 "log_level_out" : {
4688 "description" : "Log level for outgoing traffic.",
56122987
DM
4689 "enum" : [
4690 "emerg",
4691 "alert",
4692 "crit",
4693 "err",
4694 "warning",
4695 "notice",
4696 "info",
4697 "debug",
4698 "nolog"
4699 ],
56122987 4700 "optional" : 1,
44660702 4701 "type" : "string"
56122987
DM
4702 },
4703 "macfilter" : {
56122987 4704 "description" : "Enable/disable MAC address filter.",
7aacca6f
DM
4705 "optional" : 1,
4706 "type" : "boolean"
56122987 4707 },
44660702
DM
4708 "ndp" : {
4709 "description" : "Enable NDP.",
4710 "optional" : 1,
4711 "type" : "boolean"
4712 },
4713 "node" : {
4714 "description" : "The cluster node name.",
4715 "format" : "pve-node",
4716 "type" : "string"
4717 },
56122987 4718 "policy_in" : {
44660702 4719 "description" : "Input policy.",
56122987
DM
4720 "enum" : [
4721 "ACCEPT",
4722 "REJECT",
4723 "DROP"
7aacca6f 4724 ],
56122987 4725 "optional" : 1,
7aacca6f 4726 "type" : "string"
56122987 4727 },
44660702
DM
4728 "policy_out" : {
4729 "description" : "Output policy.",
4730 "enum" : [
4731 "ACCEPT",
4732 "REJECT",
4733 "DROP"
4734 ],
56122987 4735 "optional" : 1,
44660702 4736 "type" : "string"
56122987 4737 },
44660702
DM
4738 "radv" : {
4739 "description" : "Allow sending Router Advertisement.",
56122987 4740 "optional" : 1,
44660702 4741 "type" : "boolean"
7aacca6f
DM
4742 },
4743 "vmid" : {
4744 "description" : "The (unique) ID of the VM.",
44660702 4745 "format" : "pve-vmid",
7aacca6f 4746 "minimum" : 1,
4bd7df8b 4747 "type" : "integer",
2c0dde61 4748 "typetext" : "integer (1 - N)"
56122987
DM
4749 }
4750 }
4751 },
56122987
DM
4752 "permissions" : {
4753 "check" : [
4754 "perm",
4755 "/vms/{vmid}",
4756 [
44660702 4757 "VM.Config.Network"
56122987
DM
4758 ]
4759 ]
7aacca6f 4760 },
44660702 4761 "protected" : 1,
7aacca6f 4762 "proxyto" : "node",
44660702
DM
4763 "returns" : {
4764 "type" : "null"
4765 }
56122987
DM
4766 }
4767 },
44660702 4768 "leaf" : 1,
7aacca6f 4769 "path" : "/nodes/{node}/qemu/{vmid}/firewall/options",
44660702 4770 "text" : "options"
56122987
DM
4771 },
4772 {
56122987
DM
4773 "info" : {
4774 "GET" : {
44660702
DM
4775 "description" : "Read firewall log",
4776 "method" : "GET",
4777 "name" : "log",
4778 "parameters" : {
4779 "additionalProperties" : 0,
4780 "properties" : {
4781 "limit" : {
4782 "minimum" : 0,
4783 "optional" : 1,
4bd7df8b 4784 "type" : "integer",
2c0dde61 4785 "typetext" : "integer (0 - N)"
56122987 4786 },
44660702
DM
4787 "node" : {
4788 "description" : "The cluster node name.",
4789 "format" : "pve-node",
4790 "type" : "string"
4791 },
4792 "start" : {
4793 "minimum" : 0,
4794 "optional" : 1,
4bd7df8b 4795 "type" : "integer",
2c0dde61 4796 "typetext" : "integer (0 - N)"
44660702
DM
4797 },
4798 "vmid" : {
4799 "description" : "The (unique) ID of the VM.",
4800 "format" : "pve-vmid",
4801 "minimum" : 1,
4bd7df8b 4802 "type" : "integer",
2c0dde61 4803 "typetext" : "integer (1 - N)"
44660702
DM
4804 }
4805 }
7aacca6f 4806 },
7aacca6f
DM
4807 "permissions" : {
4808 "check" : [
4809 "perm",
4810 "/vms/{vmid}",
4811 [
4812 "VM.Console"
4813 ]
4814 ]
56122987 4815 },
7aacca6f 4816 "protected" : 1,
44660702
DM
4817 "proxyto" : "node",
4818 "returns" : {
4819 "items" : {
4820 "properties" : {
4821 "n" : {
4822 "description" : "Line number",
4823 "type" : "integer"
4824 },
4825 "t" : {
4826 "description" : "Line text",
4827 "type" : "string"
4828 }
56122987 4829 },
44660702 4830 "type" : "object"
7aacca6f 4831 },
44660702 4832 "type" : "array"
7aacca6f
DM
4833 }
4834 }
4835 },
44660702 4836 "leaf" : 1,
7aacca6f 4837 "path" : "/nodes/{node}/qemu/{vmid}/firewall/log",
44660702 4838 "text" : "log"
7aacca6f
DM
4839 },
4840 {
7aacca6f
DM
4841 "info" : {
4842 "GET" : {
4843 "description" : "Lists possible IPSet/Alias reference which are allowed in source/dest properties.",
44660702
DM
4844 "method" : "GET",
4845 "name" : "refs",
56122987 4846 "parameters" : {
44660702 4847 "additionalProperties" : 0,
56122987
DM
4848 "properties" : {
4849 "node" : {
7aacca6f 4850 "description" : "The cluster node name.",
44660702 4851 "format" : "pve-node",
7aacca6f 4852 "type" : "string"
56122987
DM
4853 },
4854 "type" : {
56122987
DM
4855 "description" : "Only list references of specified type.",
4856 "enum" : [
4857 "alias",
4858 "ipset"
7aacca6f 4859 ],
44660702
DM
4860 "optional" : 1,
4861 "type" : "string"
4862 },
4863 "vmid" : {
4864 "description" : "The (unique) ID of the VM.",
4865 "format" : "pve-vmid",
4866 "minimum" : 1,
4bd7df8b 4867 "type" : "integer",
2c0dde61 4868 "typetext" : "integer (1 - N)"
56122987 4869 }
44660702
DM
4870 }
4871 },
4872 "permissions" : {
4873 "check" : [
4874 "perm",
4875 "/vms/{vmid}",
4876 [
4877 "VM.Audit"
4878 ]
4879 ]
56122987
DM
4880 },
4881 "returns" : {
56122987
DM
4882 "items" : {
4883 "properties" : {
44660702
DM
4884 "comment" : {
4885 "optional" : 1,
56122987
DM
4886 "type" : "string"
4887 },
4888 "name" : {
4889 "type" : "string"
4890 },
44660702
DM
4891 "type" : {
4892 "enum" : [
4893 "alias",
4894 "ipset"
4895 ],
7aacca6f 4896 "type" : "string"
56122987
DM
4897 }
4898 },
4899 "type" : "object"
7aacca6f
DM
4900 },
4901 "type" : "array"
4902 }
56122987 4903 }
44660702
DM
4904 },
4905 "leaf" : 1,
4906 "path" : "/nodes/{node}/qemu/{vmid}/firewall/refs",
4907 "text" : "refs"
56122987
DM
4908 }
4909 ],
56122987
DM
4910 "info" : {
4911 "GET" : {
44660702 4912 "description" : "Directory index.",
56122987 4913 "method" : "GET",
44660702 4914 "name" : "index",
56122987 4915 "parameters" : {
44660702 4916 "additionalProperties" : 0,
56122987
DM
4917 "properties" : {
4918 "node" : {
4919 "description" : "The cluster node name.",
44660702
DM
4920 "format" : "pve-node",
4921 "type" : "string"
56122987
DM
4922 },
4923 "vmid" : {
44660702 4924 "description" : "The (unique) ID of the VM.",
56122987
DM
4925 "format" : "pve-vmid",
4926 "minimum" : 1,
4bd7df8b 4927 "type" : "integer",
2c0dde61 4928 "typetext" : "integer (1 - N)"
56122987 4929 }
44660702 4930 }
56122987 4931 },
56122987
DM
4932 "permissions" : {
4933 "user" : "all"
7aacca6f 4934 },
44660702
DM
4935 "returns" : {
4936 "items" : {
4937 "properties" : {},
4938 "type" : "object"
4939 },
4940 "links" : [
4941 {
4942 "href" : "{name}",
4943 "rel" : "child"
4944 }
4945 ],
4946 "type" : "array"
4947 }
56122987 4948 }
44660702
DM
4949 },
4950 "leaf" : 0,
4951 "path" : "/nodes/{node}/qemu/{vmid}/firewall",
4952 "text" : "firewall"
56122987
DM
4953 },
4954 {
56122987
DM
4955 "info" : {
4956 "GET" : {
44660702
DM
4957 "description" : "Read VM RRD statistics (returns PNG)",
4958 "method" : "GET",
7aacca6f 4959 "name" : "rrd",
56122987
DM
4960 "parameters" : {
4961 "additionalProperties" : 0,
4962 "properties" : {
7aacca6f 4963 "cf" : {
44660702 4964 "description" : "The RRD consolidation function",
7aacca6f
DM
4965 "enum" : [
4966 "AVERAGE",
4967 "MAX"
4968 ],
7aacca6f
DM
4969 "optional" : 1,
4970 "type" : "string"
4971 },
44660702
DM
4972 "ds" : {
4973 "description" : "The list of datasources you want to display.",
4974 "format" : "pve-configid-list",
4975 "type" : "string"
56122987
DM
4976 },
4977 "node" : {
44660702 4978 "description" : "The cluster node name.",
56122987 4979 "format" : "pve-node",
44660702 4980 "type" : "string"
56122987
DM
4981 },
4982 "timeframe" : {
44660702 4983 "description" : "Specify the time frame you are interested in.",
56122987
DM
4984 "enum" : [
4985 "hour",
4986 "day",
4987 "week",
4988 "month",
4989 "year"
4990 ],
56122987
DM
4991 "type" : "string"
4992 },
44660702
DM
4993 "vmid" : {
4994 "description" : "The (unique) ID of the VM.",
4995 "format" : "pve-vmid",
4996 "minimum" : 1,
4bd7df8b 4997 "type" : "integer",
2c0dde61 4998 "typetext" : "integer (1 - N)"
56122987
DM
4999 }
5000 }
5001 },
56122987
DM
5002 "permissions" : {
5003 "check" : [
5004 "perm",
5005 "/vms/{vmid}",
5006 [
5007 "VM.Audit"
5008 ]
5009 ]
5010 },
7aacca6f
DM
5011 "protected" : 1,
5012 "returns" : {
5013 "properties" : {
5014 "filename" : {
5015 "type" : "string"
5016 }
5017 },
5018 "type" : "object"
44660702 5019 }
56122987 5020 }
44660702
DM
5021 },
5022 "leaf" : 1,
5023 "path" : "/nodes/{node}/qemu/{vmid}/rrd",
5024 "text" : "rrd"
56122987
DM
5025 },
5026 {
7aacca6f 5027 "info" : {
56122987 5028 "GET" : {
7aacca6f 5029 "description" : "Read VM RRD statistics",
44660702 5030 "method" : "GET",
56122987 5031 "name" : "rrddata",
56122987 5032 "parameters" : {
44660702 5033 "additionalProperties" : 0,
56122987 5034 "properties" : {
44660702
DM
5035 "cf" : {
5036 "description" : "The RRD consolidation function",
5037 "enum" : [
5038 "AVERAGE",
5039 "MAX"
5040 ],
5041 "optional" : 1,
5042 "type" : "string"
5043 },
56122987 5044 "node" : {
44660702 5045 "description" : "The cluster node name.",
56122987 5046 "format" : "pve-node",
44660702 5047 "type" : "string"
56122987
DM
5048 },
5049 "timeframe" : {
44660702 5050 "description" : "Specify the time frame you are interested in.",
56122987
DM
5051 "enum" : [
5052 "hour",
5053 "day",
5054 "week",
5055 "month",
5056 "year"
7aacca6f 5057 ],
44660702 5058 "type" : "string"
7aacca6f
DM
5059 },
5060 "vmid" : {
7aacca6f
DM
5061 "description" : "The (unique) ID of the VM.",
5062 "format" : "pve-vmid",
44660702 5063 "minimum" : 1,
4bd7df8b 5064 "type" : "integer",
2c0dde61 5065 "typetext" : "integer (1 - N)"
56122987 5066 }
44660702 5067 }
56122987 5068 },
56122987
DM
5069 "permissions" : {
5070 "check" : [
5071 "perm",
5072 "/vms/{vmid}",
5073 [
5074 "VM.Audit"
5075 ]
5076 ]
5077 },
44660702 5078 "protected" : 1,
7aacca6f 5079 "returns" : {
7aacca6f 5080 "items" : {
44660702
DM
5081 "properties" : {},
5082 "type" : "object"
5083 },
5084 "type" : "array"
7aacca6f 5085 }
56122987
DM
5086 }
5087 },
44660702
DM
5088 "leaf" : 1,
5089 "path" : "/nodes/{node}/qemu/{vmid}/rrddata",
56122987
DM
5090 "text" : "rrddata"
5091 },
5092 {
56122987 5093 "info" : {
44660702
DM
5094 "GET" : {
5095 "description" : "Get current virtual machine configuration. This does not include pending configuration changes (see 'pending' API).",
5096 "method" : "GET",
5097 "name" : "vm_config",
5098 "parameters" : {
5099 "additionalProperties" : 0,
5100 "properties" : {
5101 "current" : {
5102 "default" : 0,
5103 "description" : "Get current values (instead of pending values).",
5104 "optional" : 1,
5105 "type" : "boolean"
5106 },
5107 "node" : {
5108 "description" : "The cluster node name.",
5109 "format" : "pve-node",
5110 "type" : "string"
5111 },
5112 "vmid" : {
5113 "description" : "The (unique) ID of the VM.",
5114 "format" : "pve-vmid",
5115 "minimum" : 1,
4bd7df8b 5116 "type" : "integer",
2c0dde61 5117 "typetext" : "integer (1 - N)"
44660702
DM
5118 }
5119 }
7aacca6f 5120 },
56122987
DM
5121 "permissions" : {
5122 "check" : [
5123 "perm",
5124 "/vms/{vmid}",
5125 [
44660702
DM
5126 "VM.Audit"
5127 ]
56122987
DM
5128 ]
5129 },
56122987 5130 "proxyto" : "node",
44660702
DM
5131 "returns" : {
5132 "properties" : {
5133 "digest" : {
5134 "description" : "SHA1 digest of configuration file. This can be used to prevent concurrent modifications.",
5135 "type" : "string"
5136 }
5137 },
5138 "type" : "object"
5139 }
5140 },
5141 "POST" : {
7aacca6f
DM
5142 "description" : "Set virtual machine options (asynchrounous API).",
5143 "method" : "POST",
44660702 5144 "name" : "update_vm_async",
56122987 5145 "parameters" : {
44660702 5146 "additionalProperties" : 0,
56122987 5147 "properties" : {
44660702
DM
5148 "acpi" : {
5149 "default" : 1,
5150 "description" : "Enable/disable ACPI.",
5151 "optional" : 1,
5152 "type" : "boolean"
5153 },
5154 "agent" : {
7aacca6f 5155 "default" : 0,
44660702 5156 "description" : "Enable/disable Qemu GuestAgent.",
7aacca6f 5157 "optional" : 1,
44660702 5158 "type" : "boolean"
7aacca6f 5159 },
44660702 5160 "args" : {
c2993fe5 5161 "description" : "Arbitrary arguments passed to kvm.",
44660702 5162 "optional" : 1,
c2993fe5
DM
5163 "type" : "string",
5164 "verbose_description" : "Arbitrary arguments passed to kvm, for example:\n\nargs: -no-reboot -no-hpet\n\nNOTE: this option is for experts only.\n"
7aacca6f 5165 },
44660702
DM
5166 "autostart" : {
5167 "default" : 0,
5168 "description" : "Automatic restart after crash (currently ignored).",
56122987 5169 "optional" : 1,
44660702 5170 "type" : "boolean"
56122987 5171 },
44660702
DM
5172 "background_delay" : {
5173 "description" : "Time to wait for the task to finish. We return 'null' if the task finish within that time.",
5174 "maximum" : 30,
5175 "minimum" : 1,
7aacca6f 5176 "optional" : 1,
4bd7df8b 5177 "type" : "integer",
2c0dde61 5178 "typetext" : "integer (1 - 30)"
56122987 5179 },
44660702
DM
5180 "balloon" : {
5181 "description" : "Amount of target RAM for the VM in MB. Using zero disables the ballon driver.",
5182 "minimum" : 0,
7aacca6f 5183 "optional" : 1,
4bd7df8b 5184 "type" : "integer",
2c0dde61 5185 "typetext" : "integer (0 - N)"
7aacca6f 5186 },
44660702
DM
5187 "bios" : {
5188 "default" : "seabios",
5189 "description" : "Select BIOS implementation.",
5190 "enum" : [
5191 "seabios",
5192 "ovmf"
5193 ],
56122987 5194 "optional" : 1,
44660702 5195 "type" : "string"
7aacca6f 5196 },
44660702
DM
5197 "boot" : {
5198 "default" : "cdn",
5199 "description" : "Boot on floppy (a), hard disk (c), CD-ROM (d), or network (n).",
5200 "optional" : 1,
5201 "pattern" : "[acdn]{1,4}",
5202 "type" : "string"
5203 },
5204 "bootdisk" : {
5205 "description" : "Enable booting from specified disk.",
5206 "format" : "pve-qm-bootdisk",
5207 "optional" : 1,
5208 "pattern" : "(ide|sata|scsi|virtio)\\d+",
5209 "type" : "string"
5210 },
5211 "cdrom" : {
5212 "description" : "This is an alias for option -ide2",
5213 "format" : "pve-qm-drive",
5214 "optional" : 1,
7aacca6f 5215 "type" : "string",
44660702
DM
5216 "typetext" : "volume"
5217 },
5218 "cores" : {
5219 "default" : 1,
5220 "description" : "The number of cores per socket.",
5221 "minimum" : 1,
7aacca6f 5222 "optional" : 1,
4bd7df8b 5223 "type" : "integer",
2c0dde61 5224 "typetext" : "integer (1 - N)"
7aacca6f 5225 },
44660702
DM
5226 "cpu" : {
5227 "description" : "Emulated CPU type.",
56122987 5228 "format" : {
44660702
DM
5229 "cputype" : {
5230 "default" : "kvm64",
7aacca6f 5231 "default_key" : 1,
44660702 5232 "description" : "Emulated CPU type.",
56122987 5233 "enum" : [
44660702
DM
5234 "486",
5235 "athlon",
f004f5b9
DM
5236 "Broadwell",
5237 "Broadwell-noTSX",
5238 "Conroe",
44660702 5239 "core2duo",
f004f5b9
DM
5240 "coreduo",
5241 "Haswell",
5242 "Haswell-noTSX",
5243 "host",
5244 "IvyBridge",
44660702
DM
5245 "kvm32",
5246 "kvm64",
44660702 5247 "Nehalem",
44660702
DM
5248 "Opteron_G1",
5249 "Opteron_G2",
5250 "Opteron_G3",
5251 "Opteron_G4",
5252 "Opteron_G5",
f004f5b9
DM
5253 "Penryn",
5254 "pentium",
5255 "pentium2",
5256 "pentium3",
5257 "phenom",
5258 "qemu32",
5259 "qemu64",
5260 "SandyBridge",
5261 "Westmere"
56122987 5262 ],
44660702 5263 "format_description" : "cputype",
56122987
DM
5264 "type" : "string"
5265 },
44660702
DM
5266 "hidden" : {
5267 "default" : 0,
5268 "description" : "Do not identify as a KVM virtual machine.",
56122987 5269 "optional" : 1,
44660702
DM
5270 "type" : "boolean"
5271 }
5272 },
5273 "optional" : 1,
4bd7df8b
DM
5274 "type" : "string",
5275 "typetext" : "[cputype=]<cputype> [,hidden=<1|0>]"
44660702
DM
5276 },
5277 "cpulimit" : {
5278 "default" : 0,
c2993fe5 5279 "description" : "Limit of CPU usage.",
44660702
DM
5280 "maximum" : 128,
5281 "minimum" : 0,
5282 "optional" : 1,
c2993fe5 5283 "type" : "number",
2c0dde61 5284 "typetext" : "number (0 - 128)",
c2993fe5 5285 "verbose_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."
44660702
DM
5286 },
5287 "cpuunits" : {
5288 "default" : 1000,
c2993fe5 5289 "description" : "CPU weight for a VM.",
44660702
DM
5290 "maximum" : 500000,
5291 "minimum" : 0,
5292 "optional" : 1,
c2993fe5 5293 "type" : "integer",
2c0dde61 5294 "typetext" : "integer (0 - 500000)",
c2993fe5 5295 "verbose_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."
44660702
DM
5296 },
5297 "delete" : {
5298 "description" : "A list of settings you want to delete.",
5299 "format" : "pve-configid-list",
5300 "optional" : 1,
5301 "type" : "string"
5302 },
5303 "description" : {
5304 "description" : "Description for the VM. Only used on the configuration web interface. This is saved as comment inside the configuration file.",
5305 "optional" : 1,
5306 "type" : "string"
5307 },
5308 "digest" : {
5309 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
5310 "maxLength" : 40,
5311 "optional" : 1,
5312 "type" : "string"
5313 },
5314 "force" : {
5315 "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.",
5316 "optional" : 1,
5317 "requires" : "delete",
5318 "type" : "boolean"
5319 },
5320 "freeze" : {
5321 "description" : "Freeze CPU at startup (use 'c' monitor command to start execution).",
5322 "optional" : 1,
5323 "type" : "boolean"
5324 },
5325 "hostpci[n]" : {
c2993fe5 5326 "description" : "Map host PCI devices into guest.",
44660702
DM
5327 "format" : "pve-qm-hostpci",
5328 "optional" : 1,
57b78691 5329 "type" : "string",
4bd7df8b 5330 "typetext" : "[host=]<HOSTPCIID[;HOSTPCIID2...]> [,pcie=<1|0>] [,rombar=<1|0>] [,x-vga=<1|0>]",
57b78691 5331 "verbose_description" : "Map host PCI devices into guest.\n\nNOTE: This option allows direct access to host hardware. So it is no longer \npossible to migrate such machines - use with special care.\n\nCAUTION: Experimental! User reported problems with this option.\n"
44660702
DM
5332 },
5333 "hotplug" : {
5334 "default" : "network,disk,usb",
5335 "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'.",
5336 "format" : "pve-hotplug-features",
5337 "optional" : 1,
5338 "type" : "string"
5339 },
4bd7df8b
DM
5340 "hugepages" : {
5341 "description" : "Enable/disable hugepages memory.",
5342 "enum" : [
5343 "any",
5344 "2",
5345 "1024"
5346 ],
5347 "optional" : 1,
5348 "type" : "string"
5349 },
44660702
DM
5350 "ide[n]" : {
5351 "description" : "Use volume as IDE hard disk or CD-ROM (n is 0 to 3).",
5352 "format" : {
5353 "aio" : {
5354 "description" : "AIO type to use.",
5355 "enum" : [
5356 "native",
5357 "threads"
56122987 5358 ],
56122987 5359 "optional" : 1,
44660702 5360 "type" : "string"
56122987 5361 },
44660702
DM
5362 "backup" : {
5363 "description" : "Whether the drive should be included when making backups.",
56122987 5364 "optional" : 1,
44660702 5365 "type" : "boolean"
56122987 5366 },
7aacca6f
DM
5367 "bps" : {
5368 "description" : "Maximum r/w speed speed in bytes per second.",
44660702
DM
5369 "format_description" : "bps",
5370 "optional" : 1,
5371 "type" : "integer"
5372 },
5373 "bps_rd" : {
5374 "description" : "Maximum read speed speed in bytes per second.",
5375 "format_description" : "bps",
56122987 5376 "optional" : 1,
44660702 5377 "type" : "integer"
56122987 5378 },
44660702
DM
5379 "bps_wr" : {
5380 "description" : "Maximum write speed speed in bytes per second.",
5381 "format_description" : "bps",
5382 "optional" : 1,
5383 "type" : "integer"
5384 },
5385 "cache" : {
5386 "description" : "The drive's cache mode",
5387 "enum" : [
5388 "none",
5389 "writethrough",
5390 "writeback",
5391 "unsafe",
5392 "directsync"
5393 ],
44660702
DM
5394 "optional" : 1,
5395 "type" : "string"
5396 },
5397 "cyls" : {
5398 "description" : "Force the drive's physical geometry to have a specific cylinder count.",
44660702
DM
5399 "optional" : 1,
5400 "type" : "integer"
5401 },
5402 "detect_zeroes" : {
5403 "description" : "Controls whether to detect and try to optimize writes of zeroes.",
5404 "optional" : 1,
5405 "type" : "boolean"
5406 },
5407 "discard" : {
5408 "description" : "Controls whether to pass discard/trim requests to the underlying storage.",
5409 "enum" : [
5410 "ignore",
5411 "on"
5412 ],
56122987 5413 "optional" : 1,
44660702
DM
5414 "type" : "string"
5415 },
5416 "file" : {
5417 "default_key" : 1,
5418 "description" : "The drive's backing volume.",
5419 "format" : "pve-volume-id-or-qm-path",
5420 "format_description" : "volume",
5421 "type" : "string"
56122987 5422 },
7aacca6f 5423 "format" : {
7aacca6f 5424 "description" : "The drive's backing file's data format.",
56122987 5425 "enum" : [
7aacca6f
DM
5426 "raw",
5427 "cow",
5428 "qcow",
5429 "qed",
5430 "qcow2",
5431 "vmdk",
5432 "cloop"
56122987 5433 ],
f004f5b9 5434 "format_description" : "image format",
56122987 5435 "optional" : 1,
56122987
DM
5436 "type" : "string"
5437 },
44660702
DM
5438 "heads" : {
5439 "description" : "Force the drive's physical geometry to have a specific head count.",
44660702
DM
5440 "optional" : 1,
5441 "type" : "integer"
7aacca6f 5442 },
44660702
DM
5443 "iops" : {
5444 "description" : "Maximum r/w I/O speed in operations per second.",
5445 "format_description" : "iops",
56122987 5446 "optional" : 1,
44660702 5447 "type" : "integer"
56122987 5448 },
44660702
DM
5449 "iops_max" : {
5450 "description" : "Maximum unthrottled r/w I/O pool speed in operations per second.",
5451 "format_description" : "iops",
56122987 5452 "optional" : 1,
44660702 5453 "type" : "integer"
56122987 5454 },
44660702
DM
5455 "iops_rd" : {
5456 "description" : "Maximum read I/O speed in operations per second.",
5457 "format_description" : "iops",
5458 "optional" : 1,
5459 "type" : "integer"
5460 },
5461 "iops_rd_max" : {
5462 "description" : "Maximum unthrottled read I/O pool speed in operations per second.",
7aacca6f 5463 "format_description" : "iops",
44660702
DM
5464 "optional" : 1,
5465 "type" : "integer"
5466 },
5467 "iops_wr" : {
7aacca6f 5468 "description" : "Maximum write I/O speed in operations per second.",
44660702 5469 "format_description" : "iops",
56122987 5470 "optional" : 1,
7aacca6f 5471 "type" : "integer"
56122987 5472 },
44660702
DM
5473 "iops_wr_max" : {
5474 "description" : "Maximum unthrottled write I/O pool speed in operations per second.",
5475 "format_description" : "iops",
7aacca6f 5476 "optional" : 1,
44660702 5477 "type" : "integer"
56122987 5478 },
44660702
DM
5479 "mbps" : {
5480 "description" : "Maximum r/w speed speed in megabytes per second.",
5481 "format_description" : "mbps",
5482 "optional" : 1,
5483 "type" : "number"
5484 },
5485 "mbps_max" : {
5486 "description" : "Maximum unthrottled r/w pool speed in megabytes per second.",
5487 "format_description" : "mbps",
5488 "optional" : 1,
5489 "type" : "number"
5490 },
5491 "mbps_rd" : {
5492 "description" : "Maximum read speed speed in megabytes per second.",
5493 "format_description" : "mbps",
5494 "optional" : 1,
5495 "type" : "number"
5496 },
5497 "mbps_rd_max" : {
5498 "description" : "Maximum unthrottled read pool speed in megabytes per second.",
5499 "format_description" : "mbps",
5500 "optional" : 1,
5501 "type" : "number"
5502 },
5503 "mbps_wr" : {
5504 "description" : "Maximum write speed speed in megabytes per second.",
5505 "format_description" : "mbps",
5506 "optional" : 1,
5507 "type" : "number"
5508 },
5509 "mbps_wr_max" : {
5510 "description" : "Maximum unthrottled write pool speed in megabytes per second.",
5511 "format_description" : "mbps",
56122987 5512 "optional" : 1,
44660702 5513 "type" : "number"
56122987 5514 },
7aacca6f 5515 "media" : {
7aacca6f 5516 "default" : "disk",
7aacca6f
DM
5517 "description" : "The drive's media type.",
5518 "enum" : [
5519 "cdrom",
5520 "disk"
44660702 5521 ],
44660702
DM
5522 "optional" : 1,
5523 "type" : "string"
56122987 5524 },
44660702
DM
5525 "model" : {
5526 "description" : "The drive's reported model name, url-encoded, up to 40 bytes long.",
5527 "format" : "urlencoded",
5528 "format_description" : "model",
5529 "maxLength" : 120,
56122987 5530 "optional" : 1,
44660702 5531 "type" : "string"
56122987 5532 },
44660702
DM
5533 "rerror" : {
5534 "description" : "Read error action.",
5535 "enum" : [
5536 "ignore",
5537 "report",
5538 "stop"
5539 ],
56122987 5540 "optional" : 1,
44660702
DM
5541 "type" : "string"
5542 },
5543 "secs" : {
5544 "description" : "Force the drive's physical geometry to have a specific sector count.",
44660702
DM
5545 "optional" : 1,
5546 "type" : "integer"
5547 },
5548 "serial" : {
5549 "description" : "The drive's reported serial number, url-encoded, up to 20 bytes long.",
5550 "format" : "urlencoded",
5551 "format_description" : "serial",
5552 "maxLength" : 60,
5553 "optional" : 1,
5554 "type" : "string"
5555 },
5556 "size" : {
5557 "description" : "Disk size. This is purely informational and has no effect.",
5558 "format" : "disk-size",
f004f5b9 5559 "format_description" : "DiskSize",
44660702
DM
5560 "optional" : 1,
5561 "type" : "string"
5562 },
5563 "snapshot" : {
5564 "description" : "Whether the drive should be included when making snapshots.",
44660702
DM
5565 "optional" : 1,
5566 "type" : "boolean"
5567 },
5568 "trans" : {
5569 "description" : "Force disk geometry bios translation mode.",
5570 "enum" : [
5571 "none",
5572 "lba",
5573 "auto"
5574 ],
44660702
DM
5575 "optional" : 1,
5576 "type" : "string"
5577 },
5578 "volume" : {
5579 "alias" : "file"
5580 },
5581 "werror" : {
5582 "description" : "Write error action.",
5583 "enum" : [
5584 "enospc",
5585 "ignore",
5586 "report",
5587 "stop"
5588 ],
44660702
DM
5589 "optional" : 1,
5590 "type" : "string"
56122987
DM
5591 }
5592 },
44660702 5593 "optional" : 1,
4bd7df8b
DM
5594 "type" : "string",
5595 "typetext" : "[file=]<volume> [,aio=<native|threads>] [,backup=<1|0>] [,bps=<bps>] [,bps_rd=<bps>] [,bps_wr=<bps>] [,cache=<none|writethrough|writeback|unsafe|directsync>] [,cyls=<integer>] [,detect_zeroes=<1|0>] [,discard=<ignore|on>] [,format=<image format>] [,heads=<integer>] [,iops=<iops>] [,iops_max=<iops>] [,iops_rd=<iops>] [,iops_rd_max=<iops>] [,iops_wr=<iops>] [,iops_wr_max=<iops>] [,mbps=<mbps>] [,mbps_max=<mbps>] [,mbps_rd=<mbps>] [,mbps_rd_max=<mbps>] [,mbps_wr=<mbps>] [,mbps_wr_max=<mbps>] [,media=<cdrom|disk>] [,model=<model>] [,rerror=<ignore|report|stop>] [,secs=<integer>] [,serial=<serial>] [,size=<DiskSize>] [,snapshot=<1|0>] [,trans=<none|lba|auto>] [,werror=<enospc|ignore|report|stop>]"
56122987 5596 },
44660702
DM
5597 "keyboard" : {
5598 "default" : "en-us",
c2993fe5 5599 "description" : "Keybord layout for vnc server. Default is read from the '/etc/pve/datacenter.conf' configuration file.",
44660702
DM
5600 "enum" : [
5601 "de",
5602 "de-ch",
5603 "da",
5604 "en-gb",
5605 "en-us",
5606 "es",
5607 "fi",
5608 "fr",
5609 "fr-be",
5610 "fr-ca",
5611 "fr-ch",
5612 "hu",
5613 "is",
5614 "it",
5615 "ja",
5616 "lt",
5617 "mk",
5618 "nl",
5619 "no",
5620 "pl",
5621 "pt",
5622 "pt-br",
5623 "sv",
5624 "sl",
5625 "tr"
5626 ],
56122987 5627 "optional" : 1,
44660702
DM
5628 "type" : "string"
5629 },
5630 "kvm" : {
7aacca6f 5631 "default" : 1,
44660702
DM
5632 "description" : "Enable/disable KVM hardware virtualization.",
5633 "optional" : 1,
5634 "type" : "boolean"
56122987 5635 },
44660702
DM
5636 "localtime" : {
5637 "description" : "Set the real time clock to local time. This is enabled by default if ostype indicates a Microsoft OS.",
56122987 5638 "optional" : 1,
44660702 5639 "type" : "boolean"
56122987 5640 },
44660702
DM
5641 "lock" : {
5642 "description" : "Lock/unlock the VM.",
5643 "enum" : [
5644 "migrate",
5645 "backup",
5646 "snapshot",
5647 "rollback"
5648 ],
7aacca6f 5649 "optional" : 1,
44660702
DM
5650 "type" : "string"
5651 },
5652 "machine" : {
5653 "description" : "Specific the Qemu machine type.",
5654 "maxLength" : 40,
5655 "optional" : 1,
5656 "pattern" : "(pc|pc(-i440fx)?-\\d+\\.\\d+(\\.pxe)?|q35|pc-q35-\\d+\\.\\d+(\\.pxe)?)",
5657 "type" : "string"
5658 },
5659 "memory" : {
5660 "default" : 512,
5661 "description" : "Amount of RAM for the VM in MB. This is the maximum available memory when you use the balloon device.",
5662 "minimum" : 16,
5663 "optional" : 1,
4bd7df8b 5664 "type" : "integer",
2c0dde61 5665 "typetext" : "integer (16 - N)"
44660702
DM
5666 },
5667 "migrate_downtime" : {
5668 "default" : 0.1,
5669 "description" : "Set maximum tolerated downtime (in seconds) for migrations.",
5670 "minimum" : 0,
5671 "optional" : 1,
4bd7df8b 5672 "type" : "number",
2c0dde61 5673 "typetext" : "number (0 - N)"
44660702
DM
5674 },
5675 "migrate_speed" : {
5676 "default" : 0,
5677 "description" : "Set maximum speed (in MB/s) for migrations. Value 0 is no limit.",
5678 "minimum" : 0,
5679 "optional" : 1,
4bd7df8b 5680 "type" : "integer",
2c0dde61 5681 "typetext" : "integer (0 - N)"
44660702
DM
5682 },
5683 "name" : {
5684 "description" : "Set a name for the VM. Only used on the configuration web interface.",
5685 "format" : "dns-name",
5686 "optional" : 1,
5687 "type" : "string"
5688 },
5689 "net[n]" : {
c2993fe5 5690 "description" : "Specify network devices.",
f004f5b9
DM
5691 "format" : {
5692 "bridge" : {
c2993fe5 5693 "description" : "Bridge to attach the network device to. The Proxmox VE standard bridge\nis called 'vmbr0'.\n\nIf you do not specify a bridge, we create a kvm user (NATed) network\ndevice, which provides DHCP and DNS services. The following addresses\nare used:\n\n 10.0.2.2 Gateway\n 10.0.2.3 DNS Server\n 10.0.2.4 SMB Server\n\nThe DHCP server assign addresses to the guest starting from 10.0.2.15.\n",
f004f5b9
DM
5694 "format_description" : "bridge",
5695 "optional" : 1,
5696 "type" : "string"
5697 },
5698 "e1000" : {
5699 "alias" : "macaddr",
5700 "keyAlias" : "model"
5701 },
5702 "e1000-82540em" : {
5703 "alias" : "macaddr",
5704 "keyAlias" : "model"
5705 },
5706 "e1000-82544gc" : {
5707 "alias" : "macaddr",
5708 "keyAlias" : "model"
5709 },
5710 "e1000-82545em" : {
5711 "alias" : "macaddr",
5712 "keyAlias" : "model"
5713 },
5714 "firewall" : {
5715 "description" : "Whether this interface should be protected by the firewall.",
5716 "optional" : 1,
5717 "type" : "boolean"
5718 },
5719 "i82551" : {
5720 "alias" : "macaddr",
5721 "keyAlias" : "model"
5722 },
5723 "i82557b" : {
5724 "alias" : "macaddr",
5725 "keyAlias" : "model"
5726 },
5727 "i82559er" : {
5728 "alias" : "macaddr",
5729 "keyAlias" : "model"
5730 },
5731 "link_down" : {
c2993fe5 5732 "description" : "Whether this interface should be disconnected (like pulling the plug).",
f004f5b9
DM
5733 "optional" : 1,
5734 "type" : "boolean"
5735 },
5736 "macaddr" : {
c2993fe5 5737 "description" : "MAC address. That address must be unique withing your network. This is automatically generated if not specified.",
f004f5b9 5738 "format_description" : "XX:XX:XX:XX:XX:XX",
f004f5b9
DM
5739 "optional" : 1,
5740 "pattern" : "(?^i:[0-9a-f]{2}(?::[0-9a-f]{2}){5})",
5741 "type" : "string"
5742 },
5743 "model" : {
5744 "default_key" : 1,
c2993fe5 5745 "description" : "Network Card Model. The 'virtio' model provides the best performance with very low CPU overhead. If your guest does not support this driver, it is usually best to use 'e1000'.",
f004f5b9
DM
5746 "enum" : [
5747 "rtl8139",
5748 "ne2k_pci",
5749 "e1000",
5750 "pcnet",
5751 "virtio",
5752 "ne2k_isa",
5753 "i82551",
5754 "i82557b",
5755 "i82559er",
5756 "vmxnet3",
5757 "e1000-82540em",
5758 "e1000-82544gc",
5759 "e1000-82545em"
5760 ],
5761 "format_description" : "model",
5762 "type" : "string"
5763 },
5764 "ne2k_isa" : {
5765 "alias" : "macaddr",
5766 "keyAlias" : "model"
5767 },
5768 "ne2k_pci" : {
5769 "alias" : "macaddr",
5770 "keyAlias" : "model"
5771 },
5772 "pcnet" : {
5773 "alias" : "macaddr",
5774 "keyAlias" : "model"
5775 },
5776 "queues" : {
5777 "description" : "Number of packet queues to be used on the device.",
5778 "maximum" : 16,
5779 "minimum" : 0,
5780 "optional" : 1,
5781 "type" : "integer"
5782 },
5783 "rate" : {
c2993fe5 5784 "description" : "Rate limit in mbps (megabytes per second) as floating point number.",
f004f5b9
DM
5785 "minimum" : 0,
5786 "optional" : 1,
5787 "type" : "number"
5788 },
5789 "rtl8139" : {
5790 "alias" : "macaddr",
5791 "keyAlias" : "model"
5792 },
5793 "tag" : {
5794 "description" : "VLAN tag to apply to packets on this interface.",
5795 "maximum" : 4094,
c2993fe5 5796 "minimum" : 1,
f004f5b9
DM
5797 "optional" : 1,
5798 "type" : "integer"
5799 },
5800 "trunks" : {
5801 "description" : "VLAN trunks to pass through this interface.",
5802 "format_description" : "vlanid[;vlanid...]",
5803 "optional" : 1,
5804 "pattern" : "(?^:\\d+(?:-\\d+)?(?:;\\d+(?:-\\d+)?)*)",
5805 "type" : "string"
5806 },
5807 "virtio" : {
5808 "alias" : "macaddr",
5809 "keyAlias" : "model"
5810 },
5811 "vmxnet3" : {
5812 "alias" : "macaddr",
5813 "keyAlias" : "model"
5814 }
5815 },
44660702 5816 "optional" : 1,
4bd7df8b
DM
5817 "type" : "string",
5818 "typetext" : "[model=]<model> [,bridge=<bridge>] [,firewall=<1|0>] [,link_down=<1|0>] [,macaddr=<XX:XX:XX:XX:XX:XX>] [,queues=<integer>] [,rate=<number>] [,tag=<integer>] [,trunks=<vlanid[;vlanid...]>] [,<model>=<macaddr>]"
44660702
DM
5819 },
5820 "node" : {
5821 "description" : "The cluster node name.",
5822 "format" : "pve-node",
5823 "type" : "string"
5824 },
5825 "numa" : {
5826 "default" : 0,
5827 "description" : "Enable/disable NUMA.",
5828 "optional" : 1,
5829 "type" : "boolean"
5830 },
5831 "numa[n]" : {
c2993fe5 5832 "description" : "NUMA topology.",
56122987 5833 "format" : {
7aacca6f 5834 "cpus" : {
c2993fe5 5835 "description" : "CPUs accessing this NUMA node.",
44660702
DM
5836 "format_description" : "id[-id];...",
5837 "pattern" : "(?^:\\d+(?:-\\d+)?(?:;\\d+(?:-\\d+)?)*)",
5838 "type" : "string"
7aacca6f
DM
5839 },
5840 "hostnodes" : {
c2993fe5 5841 "description" : "Host NUMA nodes to use.",
44660702 5842 "format_description" : "id[-id];...",
7aacca6f 5843 "optional" : 1,
7aacca6f 5844 "pattern" : "(?^:\\d+(?:-\\d+)?(?:;\\d+(?:-\\d+)?)*)",
44660702 5845 "type" : "string"
7aacca6f 5846 },
44660702 5847 "memory" : {
c2993fe5 5848 "description" : "Amount of memory this NUMA node provides.",
7aacca6f 5849 "optional" : 1,
44660702
DM
5850 "type" : "number"
5851 },
5852 "policy" : {
c2993fe5 5853 "description" : "NUMA allocation policy.",
7aacca6f
DM
5854 "enum" : [
5855 "preferred",
5856 "bind",
5857 "interleave"
5858 ],
44660702
DM
5859 "optional" : 1,
5860 "type" : "string"
56122987 5861 }
44660702 5862 },
56122987 5863 "optional" : 1,
4bd7df8b
DM
5864 "type" : "string",
5865 "typetext" : "cpus=<id[-id];...> [,hostnodes=<id[-id];...>] [,memory=<number>] [,policy=<preferred|bind|interleave>]"
56122987 5866 },
44660702 5867 "onboot" : {
7aacca6f 5868 "default" : 0,
44660702
DM
5869 "description" : "Specifies whether a VM will be started during system bootup.",
5870 "optional" : 1,
5871 "type" : "boolean"
7aacca6f
DM
5872 },
5873 "ostype" : {
c2993fe5 5874 "description" : "Specify guest operating system.",
7aacca6f
DM
5875 "enum" : [
5876 "other",
5877 "wxp",
5878 "w2k",
5879 "w2k3",
5880 "w2k8",
5881 "wvista",
5882 "win7",
5883 "win8",
5884 "l24",
5885 "l26",
5886 "solaris"
5887 ],
7aacca6f 5888 "optional" : 1,
c2993fe5
DM
5889 "type" : "string",
5890 "verbose_description" : "Specify guest operating system. This is used to enable special\noptimization/features for specific operating systems:\n\n[horizontal]\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"
56122987 5891 },
44660702 5892 "parallel[n]" : {
c2993fe5 5893 "description" : "Map host parallel devices (n is 0 to 2).",
7aacca6f 5894 "optional" : 1,
44660702 5895 "pattern" : "/dev/parport\\d+|/dev/usb/lp\\d+",
c2993fe5
DM
5896 "type" : "string",
5897 "verbose_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\nCAUTION: Experimental! User reported problems with this option.\n"
7aacca6f
DM
5898 },
5899 "protection" : {
5900 "default" : 0,
c2993fe5 5901 "description" : "Sets the protection flag of the VM. This will disable the remove VM and remove disk operations.",
7aacca6f 5902 "optional" : 1,
44660702 5903 "type" : "boolean"
7aacca6f 5904 },
44660702
DM
5905 "reboot" : {
5906 "default" : 1,
5907 "description" : "Allow reboot. If set to '0' the VM exit on reboot.",
7aacca6f 5908 "optional" : 1,
44660702 5909 "type" : "boolean"
7aacca6f 5910 },
44660702
DM
5911 "revert" : {
5912 "description" : "Revert a pending change.",
5913 "format" : "pve-configid-list",
7aacca6f 5914 "optional" : 1,
44660702
DM
5915 "type" : "string"
5916 },
5917 "sata[n]" : {
5918 "description" : "Use volume as SATA hard disk or CD-ROM (n is 0 to 5).",
56122987 5919 "format" : {
44660702
DM
5920 "aio" : {
5921 "description" : "AIO type to use.",
7aacca6f 5922 "enum" : [
44660702
DM
5923 "native",
5924 "threads"
7aacca6f 5925 ],
44660702
DM
5926 "optional" : 1,
5927 "type" : "string"
7aacca6f 5928 },
44660702
DM
5929 "backup" : {
5930 "description" : "Whether the drive should be included when making backups.",
56122987 5931 "optional" : 1,
7aacca6f 5932 "type" : "boolean"
44660702
DM
5933 },
5934 "bps" : {
5935 "description" : "Maximum r/w speed speed in bytes per second.",
5936 "format_description" : "bps",
7aacca6f 5937 "optional" : 1,
44660702 5938 "type" : "integer"
56122987 5939 },
44660702
DM
5940 "bps_rd" : {
5941 "description" : "Maximum read speed speed in bytes per second.",
5942 "format_description" : "bps",
56122987 5943 "optional" : 1,
44660702 5944 "type" : "integer"
56122987 5945 },
44660702
DM
5946 "bps_wr" : {
5947 "description" : "Maximum write speed speed in bytes per second.",
5948 "format_description" : "bps",
56122987 5949 "optional" : 1,
44660702 5950 "type" : "integer"
56122987
DM
5951 },
5952 "cache" : {
44660702 5953 "description" : "The drive's cache mode",
56122987
DM
5954 "enum" : [
5955 "none",
5956 "writethrough",
5957 "writeback",
5958 "unsafe",
5959 "directsync"
5960 ],
56122987 5961 "optional" : 1,
44660702 5962 "type" : "string"
56122987 5963 },
44660702
DM
5964 "cyls" : {
5965 "description" : "Force the drive's physical geometry to have a specific cylinder count.",
7aacca6f 5966 "optional" : 1,
44660702 5967 "type" : "integer"
7aacca6f
DM
5968 },
5969 "detect_zeroes" : {
5970 "description" : "Controls whether to detect and try to optimize writes of zeroes.",
56122987 5971 "optional" : 1,
44660702 5972 "type" : "boolean"
56122987 5973 },
44660702
DM
5974 "discard" : {
5975 "description" : "Controls whether to pass discard/trim requests to the underlying storage.",
5976 "enum" : [
5977 "ignore",
5978 "on"
5979 ],
56122987 5980 "optional" : 1,
44660702 5981 "type" : "string"
7aacca6f 5982 },
44660702
DM
5983 "file" : {
5984 "default_key" : 1,
5985 "description" : "The drive's backing volume.",
5986 "format" : "pve-volume-id-or-qm-path",
5987 "format_description" : "volume",
5988 "type" : "string"
56122987 5989 },
7aacca6f 5990 "format" : {
44660702 5991 "description" : "The drive's backing file's data format.",
7aacca6f
DM
5992 "enum" : [
5993 "raw",
5994 "cow",
5995 "qcow",
5996 "qed",
5997 "qcow2",
5998 "vmdk",
5999 "cloop"
6000 ],
f004f5b9 6001 "format_description" : "image format",
7aacca6f 6002 "optional" : 1,
44660702 6003 "type" : "string"
56122987 6004 },
7aacca6f 6005 "heads" : {
7aacca6f 6006 "description" : "Force the drive's physical geometry to have a specific head count.",
56122987 6007 "optional" : 1,
7aacca6f 6008 "type" : "integer"
56122987 6009 },
44660702
DM
6010 "iops" : {
6011 "description" : "Maximum r/w I/O speed in operations per second.",
6012 "format_description" : "iops",
56122987 6013 "optional" : 1,
44660702 6014 "type" : "integer"
56122987 6015 },
44660702
DM
6016 "iops_max" : {
6017 "description" : "Maximum unthrottled r/w I/O pool speed in operations per second.",
6018 "format_description" : "iops",
56122987 6019 "optional" : 1,
44660702 6020 "type" : "integer"
56122987 6021 },
44660702
DM
6022 "iops_rd" : {
6023 "description" : "Maximum read I/O speed in operations per second.",
6024 "format_description" : "iops",
7aacca6f 6025 "optional" : 1,
44660702 6026 "type" : "integer"
56122987 6027 },
44660702
DM
6028 "iops_rd_max" : {
6029 "description" : "Maximum unthrottled read I/O pool speed in operations per second.",
6030 "format_description" : "iops",
56122987 6031 "optional" : 1,
44660702 6032 "type" : "integer"
7aacca6f 6033 },
44660702
DM
6034 "iops_wr" : {
6035 "description" : "Maximum write I/O speed in operations per second.",
6036 "format_description" : "iops",
56122987 6037 "optional" : 1,
44660702 6038 "type" : "integer"
56122987
DM
6039 },
6040 "iops_wr_max" : {
6041 "description" : "Maximum unthrottled write I/O pool speed in operations per second.",
44660702 6042 "format_description" : "iops",
56122987 6043 "optional" : 1,
44660702 6044 "type" : "integer"
56122987 6045 },
44660702
DM
6046 "mbps" : {
6047 "description" : "Maximum r/w speed speed in megabytes per second.",
6048 "format_description" : "mbps",
56122987 6049 "optional" : 1,
44660702 6050 "type" : "number"
56122987 6051 },
44660702
DM
6052 "mbps_max" : {
6053 "description" : "Maximum unthrottled r/w pool speed in megabytes per second.",
6054 "format_description" : "mbps",
6055 "optional" : 1,
6056 "type" : "number"
56122987 6057 },
44660702
DM
6058 "mbps_rd" : {
6059 "description" : "Maximum read speed speed in megabytes per second.",
6060 "format_description" : "mbps",
56122987 6061 "optional" : 1,
44660702 6062 "type" : "number"
56122987 6063 },
44660702
DM
6064 "mbps_rd_max" : {
6065 "description" : "Maximum unthrottled read pool speed in megabytes per second.",
6066 "format_description" : "mbps",
56122987 6067 "optional" : 1,
44660702 6068 "type" : "number"
56122987 6069 },
44660702
DM
6070 "mbps_wr" : {
6071 "description" : "Maximum write speed speed in megabytes per second.",
56122987 6072 "format_description" : "mbps",
44660702
DM
6073 "optional" : 1,
6074 "type" : "number"
56122987 6075 },
44660702
DM
6076 "mbps_wr_max" : {
6077 "description" : "Maximum unthrottled write pool speed in megabytes per second.",
6078 "format_description" : "mbps",
6079 "optional" : 1,
6080 "type" : "number"
7aacca6f 6081 },
44660702
DM
6082 "media" : {
6083 "default" : "disk",
6084 "description" : "The drive's media type.",
6085 "enum" : [
6086 "cdrom",
6087 "disk"
6088 ],
56122987 6089 "optional" : 1,
44660702
DM
6090 "type" : "string"
6091 },
6092 "rerror" : {
6093 "description" : "Read error action.",
7aacca6f 6094 "enum" : [
44660702
DM
6095 "ignore",
6096 "report",
6097 "stop"
6098 ],
7aacca6f 6099 "optional" : 1,
44660702 6100 "type" : "string"
56122987 6101 },
44660702
DM
6102 "secs" : {
6103 "description" : "Force the drive's physical geometry to have a specific sector count.",
56122987 6104 "optional" : 1,
44660702 6105 "type" : "integer"
56122987 6106 },
44660702
DM
6107 "serial" : {
6108 "description" : "The drive's reported serial number, url-encoded, up to 20 bytes long.",
6109 "format" : "urlencoded",
6110 "format_description" : "serial",
6111 "maxLength" : 60,
56122987 6112 "optional" : 1,
44660702 6113 "type" : "string"
56122987 6114 },
44660702
DM
6115 "size" : {
6116 "description" : "Disk size. This is purely informational and has no effect.",
6117 "format" : "disk-size",
f004f5b9 6118 "format_description" : "DiskSize",
44660702
DM
6119 "optional" : 1,
6120 "type" : "string"
6121 },
6122 "snapshot" : {
6123 "description" : "Whether the drive should be included when making snapshots.",
56122987 6124 "optional" : 1,
44660702
DM
6125 "type" : "boolean"
6126 },
6127 "trans" : {
6128 "description" : "Force disk geometry bios translation mode.",
56122987 6129 "enum" : [
7aacca6f
DM
6130 "none",
6131 "lba",
6132 "auto"
56122987 6133 ],
44660702
DM
6134 "optional" : 1,
6135 "type" : "string"
56122987 6136 },
7aacca6f
DM
6137 "volume" : {
6138 "alias" : "file"
56122987 6139 },
44660702
DM
6140 "werror" : {
6141 "description" : "Write error action.",
6142 "enum" : [
6143 "enospc",
6144 "ignore",
6145 "report",
6146 "stop"
6147 ],
7aacca6f 6148 "optional" : 1,
44660702
DM
6149 "type" : "string"
6150 }
6151 },
6152 "optional" : 1,
4bd7df8b
DM
6153 "type" : "string",
6154 "typetext" : "[file=]<volume> [,aio=<native|threads>] [,backup=<1|0>] [,bps=<bps>] [,bps_rd=<bps>] [,bps_wr=<bps>] [,cache=<none|writethrough|writeback|unsafe|directsync>] [,cyls=<integer>] [,detect_zeroes=<1|0>] [,discard=<ignore|on>] [,format=<image format>] [,heads=<integer>] [,iops=<iops>] [,iops_max=<iops>] [,iops_rd=<iops>] [,iops_rd_max=<iops>] [,iops_wr=<iops>] [,iops_wr_max=<iops>] [,mbps=<mbps>] [,mbps_max=<mbps>] [,mbps_rd=<mbps>] [,mbps_rd_max=<mbps>] [,mbps_wr=<mbps>] [,mbps_wr_max=<mbps>] [,media=<cdrom|disk>] [,rerror=<ignore|report|stop>] [,secs=<integer>] [,serial=<serial>] [,size=<DiskSize>] [,snapshot=<1|0>] [,trans=<none|lba|auto>] [,werror=<enospc|ignore|report|stop>]"
44660702
DM
6155 },
6156 "scsi[n]" : {
6157 "description" : "Use volume as SCSI hard disk or CD-ROM (n is 0 to 13).",
6158 "format" : {
56122987 6159 "aio" : {
56122987
DM
6160 "description" : "AIO type to use.",
6161 "enum" : [
6162 "native",
6163 "threads"
6164 ],
7aacca6f 6165 "optional" : 1,
44660702 6166 "type" : "string"
56122987 6167 },
44660702
DM
6168 "backup" : {
6169 "description" : "Whether the drive should be included when making backups.",
56122987 6170 "optional" : 1,
44660702 6171 "type" : "boolean"
56122987 6172 },
44660702
DM
6173 "bps" : {
6174 "description" : "Maximum r/w speed speed in bytes per second.",
6175 "format_description" : "bps",
56122987 6176 "optional" : 1,
44660702 6177 "type" : "integer"
56122987 6178 },
44660702
DM
6179 "bps_rd" : {
6180 "description" : "Maximum read speed speed in bytes per second.",
6181 "format_description" : "bps",
56122987 6182 "optional" : 1,
44660702 6183 "type" : "integer"
56122987 6184 },
7aacca6f 6185 "bps_wr" : {
44660702 6186 "description" : "Maximum write speed speed in bytes per second.",
7aacca6f 6187 "format_description" : "bps",
56122987 6188 "optional" : 1,
44660702 6189 "type" : "integer"
56122987 6190 },
44660702
DM
6191 "cache" : {
6192 "description" : "The drive's cache mode",
7aacca6f 6193 "enum" : [
44660702
DM
6194 "none",
6195 "writethrough",
6196 "writeback",
6197 "unsafe",
6198 "directsync"
7aacca6f 6199 ],
56122987 6200 "optional" : 1,
44660702 6201 "type" : "string"
56122987 6202 },
44660702
DM
6203 "cyls" : {
6204 "description" : "Force the drive's physical geometry to have a specific cylinder count.",
7aacca6f 6205 "optional" : 1,
44660702 6206 "type" : "integer"
56122987 6207 },
44660702
DM
6208 "detect_zeroes" : {
6209 "description" : "Controls whether to detect and try to optimize writes of zeroes.",
56122987 6210 "optional" : 1,
44660702 6211 "type" : "boolean"
56122987 6212 },
44660702
DM
6213 "discard" : {
6214 "description" : "Controls whether to pass discard/trim requests to the underlying storage.",
6215 "enum" : [
6216 "ignore",
6217 "on"
6218 ],
7aacca6f 6219 "optional" : 1,
44660702 6220 "type" : "string"
56122987 6221 },
44660702
DM
6222 "file" : {
6223 "default_key" : 1,
6224 "description" : "The drive's backing volume.",
6225 "format" : "pve-volume-id-or-qm-path",
6226 "format_description" : "volume",
6227 "type" : "string"
56122987 6228 },
7aacca6f 6229 "format" : {
44660702 6230 "description" : "The drive's backing file's data format.",
56122987 6231 "enum" : [
7aacca6f
DM
6232 "raw",
6233 "cow",
6234 "qcow",
6235 "qed",
6236 "qcow2",
6237 "vmdk",
6238 "cloop"
6239 ],
f004f5b9 6240 "format_description" : "image format",
44660702
DM
6241 "optional" : 1,
6242 "type" : "string"
56122987 6243 },
44660702
DM
6244 "heads" : {
6245 "description" : "Force the drive's physical geometry to have a specific head count.",
56122987 6246 "optional" : 1,
7aacca6f 6247 "type" : "integer"
56122987 6248 },
44660702
DM
6249 "iops" : {
6250 "description" : "Maximum r/w I/O speed in operations per second.",
7aacca6f 6251 "format_description" : "iops",
44660702
DM
6252 "optional" : 1,
6253 "type" : "integer"
7aacca6f 6254 },
44660702
DM
6255 "iops_max" : {
6256 "description" : "Maximum unthrottled r/w I/O pool speed in operations per second.",
6257 "format_description" : "iops",
56122987 6258 "optional" : 1,
44660702 6259 "type" : "integer"
7aacca6f 6260 },
44660702
DM
6261 "iops_rd" : {
6262 "description" : "Maximum read I/O speed in operations per second.",
6263 "format_description" : "iops",
7aacca6f 6264 "optional" : 1,
44660702 6265 "type" : "integer"
56122987 6266 },
44660702
DM
6267 "iops_rd_max" : {
6268 "description" : "Maximum unthrottled read I/O pool speed in operations per second.",
6269 "format_description" : "iops",
6270 "optional" : 1,
6271 "type" : "integer"
6272 },
6273 "iops_wr" : {
6274 "description" : "Maximum write I/O speed in operations per second.",
6275 "format_description" : "iops",
56122987 6276 "optional" : 1,
44660702
DM
6277 "type" : "integer"
6278 },
6279 "iops_wr_max" : {
6280 "description" : "Maximum unthrottled write I/O pool speed in operations per second.",
6281 "format_description" : "iops",
6282 "optional" : 1,
6283 "type" : "integer"
56122987 6284 },
7aacca6f 6285 "iothread" : {
7aacca6f 6286 "description" : "Whether to use iothreads for this drive",
56122987 6287 "optional" : 1,
56122987
DM
6288 "type" : "boolean"
6289 },
44660702
DM
6290 "mbps" : {
6291 "description" : "Maximum r/w speed speed in megabytes per second.",
6292 "format_description" : "mbps",
6293 "optional" : 1,
6294 "type" : "number"
6295 },
6296 "mbps_max" : {
6297 "description" : "Maximum unthrottled r/w pool speed in megabytes per second.",
6298 "format_description" : "mbps",
6299 "optional" : 1,
6300 "type" : "number"
6301 },
6302 "mbps_rd" : {
6303 "description" : "Maximum read speed speed in megabytes per second.",
6304 "format_description" : "mbps",
6305 "optional" : 1,
6306 "type" : "number"
6307 },
6308 "mbps_rd_max" : {
6309 "description" : "Maximum unthrottled read pool speed in megabytes per second.",
6310 "format_description" : "mbps",
6311 "optional" : 1,
6312 "type" : "number"
6313 },
6314 "mbps_wr" : {
6315 "description" : "Maximum write speed speed in megabytes per second.",
6316 "format_description" : "mbps",
6317 "optional" : 1,
6318 "type" : "number"
6319 },
6320 "mbps_wr_max" : {
6321 "description" : "Maximum unthrottled write pool speed in megabytes per second.",
6322 "format_description" : "mbps",
6323 "optional" : 1,
6324 "type" : "number"
6325 },
7aacca6f 6326 "media" : {
44660702
DM
6327 "default" : "disk",
6328 "description" : "The drive's media type.",
7aacca6f
DM
6329 "enum" : [
6330 "cdrom",
6331 "disk"
6332 ],
56122987 6333 "optional" : 1,
44660702
DM
6334 "type" : "string"
6335 },
6336 "queues" : {
6337 "description" : "Number of queues.",
44660702
DM
6338 "minimum" : 2,
6339 "optional" : 1,
6340 "type" : "integer"
6341 },
6342 "secs" : {
6343 "description" : "Force the drive's physical geometry to have a specific sector count.",
44660702
DM
6344 "optional" : 1,
6345 "type" : "integer"
6346 },
6347 "serial" : {
6348 "description" : "The drive's reported serial number, url-encoded, up to 20 bytes long.",
6349 "format" : "urlencoded",
6350 "format_description" : "serial",
6351 "maxLength" : 60,
6352 "optional" : 1,
6353 "type" : "string"
6354 },
6355 "size" : {
6356 "description" : "Disk size. This is purely informational and has no effect.",
6357 "format" : "disk-size",
f004f5b9 6358 "format_description" : "DiskSize",
44660702
DM
6359 "optional" : 1,
6360 "type" : "string"
56122987 6361 },
7aacca6f
DM
6362 "snapshot" : {
6363 "description" : "Whether the drive should be included when making snapshots.",
6364 "optional" : 1,
44660702 6365 "type" : "boolean"
7aacca6f 6366 },
44660702
DM
6367 "trans" : {
6368 "description" : "Force disk geometry bios translation mode.",
6369 "enum" : [
6370 "none",
6371 "lba",
6372 "auto"
6373 ],
44660702
DM
6374 "optional" : 1,
6375 "type" : "string"
6376 },
6377 "volume" : {
6378 "alias" : "file"
6379 },
6380 "werror" : {
6381 "description" : "Write error action.",
6382 "enum" : [
6383 "enospc",
6384 "ignore",
6385 "report",
6386 "stop"
6387 ],
56122987 6388 "optional" : 1,
44660702 6389 "type" : "string"
56122987 6390 }
44660702 6391 },
7aacca6f 6392 "optional" : 1,
4bd7df8b
DM
6393 "type" : "string",
6394 "typetext" : "[file=]<volume> [,aio=<native|threads>] [,backup=<1|0>] [,bps=<bps>] [,bps_rd=<bps>] [,bps_wr=<bps>] [,cache=<none|writethrough|writeback|unsafe|directsync>] [,cyls=<integer>] [,detect_zeroes=<1|0>] [,discard=<ignore|on>] [,format=<image format>] [,heads=<integer>] [,iops=<iops>] [,iops_max=<iops>] [,iops_rd=<iops>] [,iops_rd_max=<iops>] [,iops_wr=<iops>] [,iops_wr_max=<iops>] [,iothread=<1|0>] [,mbps=<mbps>] [,mbps_max=<mbps>] [,mbps_rd=<mbps>] [,mbps_rd_max=<mbps>] [,mbps_wr=<mbps>] [,mbps_wr_max=<mbps>] [,media=<cdrom|disk>] [,queues=<integer>] [,secs=<integer>] [,serial=<serial>] [,size=<DiskSize>] [,snapshot=<1|0>] [,trans=<none|lba|auto>] [,werror=<enospc|ignore|report|stop>]"
44660702
DM
6395 },
6396 "scsihw" : {
6397 "default" : "lsi",
c2993fe5 6398 "description" : "SCSI controller model",
7aacca6f 6399 "enum" : [
44660702
DM
6400 "lsi",
6401 "lsi53c810",
6402 "virtio-scsi-pci",
6403 "virtio-scsi-single",
6404 "megasas",
6405 "pvscsi"
7aacca6f 6406 ],
44660702
DM
6407 "optional" : 1,
6408 "type" : "string"
56122987 6409 },
44660702 6410 "serial[n]" : {
c2993fe5 6411 "description" : "Create a serial device inside the VM (n is 0 to 3)",
7aacca6f 6412 "optional" : 1,
44660702 6413 "pattern" : "(/dev/.+|socket)",
c2993fe5 6414 "type" : "string",
57b78691 6415 "verbose_description" : "Create a serial device inside the VM (n is 0 to 3), and pass through a\nhost serial device (i.e. /dev/ttyS0), or create a unix socket on the\nhost 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\nCAUTION: Experimental! User reported problems with this option.\n"
7aacca6f 6416 },
44660702
DM
6417 "shares" : {
6418 "default" : 1000,
6419 "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",
6420 "maximum" : 50000,
6421 "minimum" : 0,
56122987 6422 "optional" : 1,
4bd7df8b 6423 "type" : "integer",
2c0dde61 6424 "typetext" : "integer (0 - 50000)"
56122987 6425 },
44660702
DM
6426 "skiplock" : {
6427 "description" : "Ignore locks - only root is allowed to use this option.",
7aacca6f 6428 "optional" : 1,
44660702 6429 "type" : "boolean"
56122987 6430 },
44660702
DM
6431 "smbios1" : {
6432 "description" : "Specify SMBIOS type 1 fields.",
6433 "format" : "pve-qm-smbios1",
6434 "maxLength" : 256,
56122987 6435 "optional" : 1,
4bd7df8b
DM
6436 "type" : "string",
6437 "typetext" : "[family=<string>] [,manufacturer=<string>] [,product=<string>] [,serial=<string>] [,sku=<string>] [,uuid=<UUID>] [,version=<string>]"
56122987 6438 },
44660702
DM
6439 "smp" : {
6440 "default" : 1,
6441 "description" : "The number of CPUs. Please use option -sockets instead.",
7aacca6f 6442 "minimum" : 1,
7aacca6f 6443 "optional" : 1,
4bd7df8b 6444 "type" : "integer",
2c0dde61 6445 "typetext" : "integer (1 - N)"
7aacca6f 6446 },
44660702
DM
6447 "sockets" : {
6448 "default" : 1,
6449 "description" : "The number of CPU sockets.",
6450 "minimum" : 1,
7aacca6f 6451 "optional" : 1,
4bd7df8b 6452 "type" : "integer",
2c0dde61 6453 "typetext" : "integer (1 - N)"
56122987 6454 },
44660702
DM
6455 "startdate" : {
6456 "default" : "now",
6457 "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'.",
7aacca6f 6458 "optional" : 1,
44660702 6459 "pattern" : "(now|\\d{4}-\\d{1,2}-\\d{1,2}(T\\d{1,2}:\\d{1,2}:\\d{1,2})?)",
7aacca6f 6460 "type" : "string",
44660702 6461 "typetext" : "(now | YYYY-MM-DD | YYYY-MM-DDTHH:MM:SS)"
56122987 6462 },
7aacca6f 6463 "startup" : {
7aacca6f 6464 "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.",
44660702 6465 "format" : "pve-startup-order",
56122987 6466 "optional" : 1,
44660702
DM
6467 "type" : "string",
6468 "typetext" : "[[order=]\\d+] [,up=\\d+] [,down=\\d+] "
56122987 6469 },
44660702 6470 "tablet" : {
7aacca6f 6471 "default" : 1,
c2993fe5 6472 "description" : "Enable/disable the USB tablet device.",
7aacca6f 6473 "optional" : 1,
c2993fe5
DM
6474 "type" : "boolean",
6475 "verbose_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)."
56122987 6476 },
44660702
DM
6477 "tdf" : {
6478 "default" : 0,
6479 "description" : "Enable/disable time drift fix.",
7aacca6f 6480 "optional" : 1,
44660702 6481 "type" : "boolean"
7aacca6f 6482 },
44660702
DM
6483 "template" : {
6484 "default" : 0,
6485 "description" : "Enable/disable Template.",
7aacca6f 6486 "optional" : 1,
44660702 6487 "type" : "boolean"
7aacca6f 6488 },
44660702 6489 "unused[n]" : {
c2993fe5 6490 "description" : "Reference to unused volumes. This is used internally, and should not be modified manually.",
44660702 6491 "format" : "pve-volume-id",
7aacca6f 6492 "optional" : 1,
44660702 6493 "type" : "string"
7aacca6f 6494 },
44660702 6495 "usb[n]" : {
c2993fe5 6496 "description" : "Configure an USB device (n is 0 to 4).",
44660702
DM
6497 "format" : {
6498 "host" : {
6499 "default_key" : 1,
c2993fe5 6500 "description" : "The Host USB device or port or the value 'spice'. 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",
44660702
DM
6501 "format" : "pve-qm-usb-device",
6502 "format_description" : "HOSTUSBDEVICE|spice",
6503 "type" : "string"
6504 },
6505 "usb3" : {
c2993fe5
DM
6506 "default" : 0,
6507 "description" : "Specifies whether if given host option is a USB3 device or port (this does currently not work reliably with spice redirection and is then ignored).",
44660702
DM
6508 "optional" : 1,
6509 "type" : "boolean"
6510 }
6511 },
7aacca6f 6512 "optional" : 1,
4bd7df8b
DM
6513 "type" : "string",
6514 "typetext" : "[host=]<HOSTUSBDEVICE|spice> [,usb3=<1|0>]"
56122987 6515 },
44660702
DM
6516 "vcpus" : {
6517 "default" : 0,
6518 "description" : "Number of hotplugged vcpus.",
6519 "minimum" : 1,
56122987 6520 "optional" : 1,
4bd7df8b 6521 "type" : "integer",
2c0dde61 6522 "typetext" : "integer (1 - N)"
56122987 6523 },
44660702 6524 "vga" : {
c2993fe5 6525 "description" : "Select the VGA type.",
44660702
DM
6526 "enum" : [
6527 "std",
6528 "cirrus",
6529 "vmware",
6530 "qxl",
6531 "serial0",
6532 "serial1",
6533 "serial2",
6534 "serial3",
6535 "qxl2",
6536 "qxl3",
6537 "qxl4"
6538 ],
56122987 6539 "optional" : 1,
c2993fe5
DM
6540 "type" : "string",
6541 "verbose_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."
56122987 6542 },
44660702
DM
6543 "virtio[n]" : {
6544 "description" : "Use volume as VIRTIO hard disk (n is 0 to 15).",
56122987 6545 "format" : {
44660702
DM
6546 "aio" : {
6547 "description" : "AIO type to use.",
56122987 6548 "enum" : [
44660702
DM
6549 "native",
6550 "threads"
56122987 6551 ],
56122987
DM
6552 "optional" : 1,
6553 "type" : "string"
6554 },
44660702
DM
6555 "backup" : {
6556 "description" : "Whether the drive should be included when making backups.",
44660702
DM
6557 "optional" : 1,
6558 "type" : "boolean"
7aacca6f 6559 },
44660702
DM
6560 "bps" : {
6561 "description" : "Maximum r/w speed speed in bytes per second.",
6562 "format_description" : "bps",
6563 "optional" : 1,
6564 "type" : "integer"
56122987 6565 },
44660702
DM
6566 "bps_rd" : {
6567 "description" : "Maximum read speed speed in bytes per second.",
6568 "format_description" : "bps",
56122987 6569 "optional" : 1,
44660702 6570 "type" : "integer"
56122987 6571 },
44660702
DM
6572 "bps_wr" : {
6573 "description" : "Maximum write speed speed in bytes per second.",
6574 "format_description" : "bps",
56122987 6575 "optional" : 1,
44660702
DM
6576 "type" : "integer"
6577 },
6578 "cache" : {
6579 "description" : "The drive's cache mode",
56122987 6580 "enum" : [
44660702
DM
6581 "none",
6582 "writethrough",
6583 "writeback",
6584 "unsafe",
6585 "directsync"
56122987 6586 ],
56122987 6587 "optional" : 1,
44660702 6588 "type" : "string"
56122987 6589 },
44660702
DM
6590 "cyls" : {
6591 "description" : "Force the drive's physical geometry to have a specific cylinder count.",
56122987 6592 "optional" : 1,
44660702 6593 "type" : "integer"
7aacca6f 6594 },
44660702
DM
6595 "detect_zeroes" : {
6596 "description" : "Controls whether to detect and try to optimize writes of zeroes.",
6597 "optional" : 1,
6598 "type" : "boolean"
7aacca6f 6599 },
44660702
DM
6600 "discard" : {
6601 "description" : "Controls whether to pass discard/trim requests to the underlying storage.",
6602 "enum" : [
6603 "ignore",
6604 "on"
6605 ],
56122987 6606 "optional" : 1,
44660702 6607 "type" : "string"
56122987
DM
6608 },
6609 "file" : {
7aacca6f 6610 "default_key" : 1,
44660702 6611 "description" : "The drive's backing volume.",
7aacca6f 6612 "format" : "pve-volume-id-or-qm-path",
44660702
DM
6613 "format_description" : "volume",
6614 "type" : "string"
7aacca6f
DM
6615 },
6616 "format" : {
7aacca6f
DM
6617 "description" : "The drive's backing file's data format.",
6618 "enum" : [
6619 "raw",
6620 "cow",
6621 "qcow",
6622 "qed",
6623 "qcow2",
6624 "vmdk",
6625 "cloop"
56122987 6626 ],
f004f5b9 6627 "format_description" : "image format",
56122987 6628 "optional" : 1,
56122987
DM
6629 "type" : "string"
6630 },
44660702
DM
6631 "heads" : {
6632 "description" : "Force the drive's physical geometry to have a specific head count.",
56122987 6633 "optional" : 1,
44660702 6634 "type" : "integer"
56122987 6635 },
44660702
DM
6636 "iops" : {
6637 "description" : "Maximum r/w I/O speed in operations per second.",
7aacca6f 6638 "format_description" : "iops",
56122987 6639 "optional" : 1,
44660702 6640 "type" : "integer"
56122987 6641 },
44660702
DM
6642 "iops_max" : {
6643 "description" : "Maximum unthrottled r/w I/O pool speed in operations per second.",
6644 "format_description" : "iops",
56122987 6645 "optional" : 1,
56122987
DM
6646 "type" : "integer"
6647 },
44660702
DM
6648 "iops_rd" : {
6649 "description" : "Maximum read I/O speed in operations per second.",
6650 "format_description" : "iops",
56122987 6651 "optional" : 1,
44660702 6652 "type" : "integer"
56122987 6653 },
44660702
DM
6654 "iops_rd_max" : {
6655 "description" : "Maximum unthrottled read I/O pool speed in operations per second.",
6656 "format_description" : "iops",
7aacca6f 6657 "optional" : 1,
44660702 6658 "type" : "integer"
56122987 6659 },
44660702
DM
6660 "iops_wr" : {
6661 "description" : "Maximum write I/O speed in operations per second.",
6662 "format_description" : "iops",
7aacca6f 6663 "optional" : 1,
44660702 6664 "type" : "integer"
56122987 6665 },
44660702
DM
6666 "iops_wr_max" : {
6667 "description" : "Maximum unthrottled write I/O pool speed in operations per second.",
6668 "format_description" : "iops",
56122987
DM
6669 "optional" : 1,
6670 "type" : "integer"
6671 },
44660702
DM
6672 "iothread" : {
6673 "description" : "Whether to use iothreads for this drive",
44660702
DM
6674 "optional" : 1,
6675 "type" : "boolean"
6676 },
6677 "mbps" : {
6678 "description" : "Maximum r/w speed speed in megabytes per second.",
7aacca6f 6679 "format_description" : "mbps",
44660702
DM
6680 "optional" : 1,
6681 "type" : "number"
6682 },
6683 "mbps_max" : {
7aacca6f 6684 "description" : "Maximum unthrottled r/w pool speed in megabytes per second.",
44660702
DM
6685 "format_description" : "mbps",
6686 "optional" : 1,
6687 "type" : "number"
7aacca6f 6688 },
44660702
DM
6689 "mbps_rd" : {
6690 "description" : "Maximum read speed speed in megabytes per second.",
6691 "format_description" : "mbps",
56122987 6692 "optional" : 1,
44660702 6693 "type" : "number"
56122987 6694 },
44660702
DM
6695 "mbps_rd_max" : {
6696 "description" : "Maximum unthrottled read pool speed in megabytes per second.",
6697 "format_description" : "mbps",
7aacca6f 6698 "optional" : 1,
44660702 6699 "type" : "number"
56122987 6700 },
44660702
DM
6701 "mbps_wr" : {
6702 "description" : "Maximum write speed speed in megabytes per second.",
6703 "format_description" : "mbps",
56122987 6704 "optional" : 1,
44660702 6705 "type" : "number"
56122987 6706 },
44660702
DM
6707 "mbps_wr_max" : {
6708 "description" : "Maximum unthrottled write pool speed in megabytes per second.",
6709 "format_description" : "mbps",
56122987 6710 "optional" : 1,
44660702 6711 "type" : "number"
56122987
DM
6712 },
6713 "media" : {
7aacca6f 6714 "default" : "disk",
44660702 6715 "description" : "The drive's media type.",
56122987
DM
6716 "enum" : [
6717 "cdrom",
6718 "disk"
6719 ],
44660702
DM
6720 "optional" : 1,
6721 "type" : "string"
56122987 6722 },
7aacca6f 6723 "rerror" : {
44660702 6724 "description" : "Read error action.",
56122987 6725 "enum" : [
7aacca6f
DM
6726 "ignore",
6727 "report",
6728 "stop"
56122987 6729 ],
56122987 6730 "optional" : 1,
44660702 6731 "type" : "string"
56122987 6732 },
44660702
DM
6733 "secs" : {
6734 "description" : "Force the drive's physical geometry to have a specific sector count.",
44660702
DM
6735 "optional" : 1,
6736 "type" : "integer"
6737 },
6738 "serial" : {
6739 "description" : "The drive's reported serial number, url-encoded, up to 20 bytes long.",
6740 "format" : "urlencoded",
6741 "format_description" : "serial",
6742 "maxLength" : 60,
56122987 6743 "optional" : 1,
7aacca6f 6744 "type" : "string"
56122987 6745 },
44660702
DM
6746 "size" : {
6747 "description" : "Disk size. This is purely informational and has no effect.",
6748 "format" : "disk-size",
f004f5b9 6749 "format_description" : "DiskSize",
56122987 6750 "optional" : 1,
44660702 6751 "type" : "string"
56122987 6752 },
44660702
DM
6753 "snapshot" : {
6754 "description" : "Whether the drive should be included when making snapshots.",
56122987 6755 "optional" : 1,
44660702 6756 "type" : "boolean"
56122987 6757 },
44660702
DM
6758 "trans" : {
6759 "description" : "Force disk geometry bios translation mode.",
6760 "enum" : [
6761 "none",
6762 "lba",
6763 "auto"
6764 ],
44660702
DM
6765 "optional" : 1,
6766 "type" : "string"
6767 },
6768 "volume" : {
6769 "alias" : "file"
6770 },
6771 "werror" : {
6772 "description" : "Write error action.",
6773 "enum" : [
6774 "enospc",
6775 "ignore",
6776 "report",
6777 "stop"
6778 ],
56122987 6779 "optional" : 1,
44660702 6780 "type" : "string"
56122987 6781 }
44660702 6782 },
56122987 6783 "optional" : 1,
4bd7df8b
DM
6784 "type" : "string",
6785 "typetext" : "[file=]<volume> [,aio=<native|threads>] [,backup=<1|0>] [,bps=<bps>] [,bps_rd=<bps>] [,bps_wr=<bps>] [,cache=<none|writethrough|writeback|unsafe|directsync>] [,cyls=<integer>] [,detect_zeroes=<1|0>] [,discard=<ignore|on>] [,format=<image format>] [,heads=<integer>] [,iops=<iops>] [,iops_max=<iops>] [,iops_rd=<iops>] [,iops_rd_max=<iops>] [,iops_wr=<iops>] [,iops_wr_max=<iops>] [,iothread=<1|0>] [,mbps=<mbps>] [,mbps_max=<mbps>] [,mbps_rd=<mbps>] [,mbps_rd_max=<mbps>] [,mbps_wr=<mbps>] [,mbps_wr_max=<mbps>] [,media=<cdrom|disk>] [,rerror=<ignore|report|stop>] [,secs=<integer>] [,serial=<serial>] [,size=<DiskSize>] [,snapshot=<1|0>] [,trans=<none|lba|auto>] [,werror=<enospc|ignore|report|stop>]"
56122987 6786 },
7aacca6f
DM
6787 "vmid" : {
6788 "description" : "The (unique) ID of the VM.",
7aacca6f 6789 "format" : "pve-vmid",
44660702 6790 "minimum" : 1,
4bd7df8b 6791 "type" : "integer",
2c0dde61 6792 "typetext" : "integer (1 - N)"
56122987 6793 },
44660702 6794 "watchdog" : {
c2993fe5 6795 "description" : "Create a virtual hardware watchdog device.",
44660702 6796 "format" : "pve-qm-watchdog",
56122987 6797 "optional" : 1,
c2993fe5 6798 "type" : "string",
4bd7df8b 6799 "typetext" : "[[model=]<i6300esb|ib700>] [,action=<reset|shutdown|poweroff|pause|debug|none>]",
c2993fe5 6800 "verbose_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)"
56122987 6801 }
44660702 6802 }
56122987 6803 },
7aacca6f
DM
6804 "permissions" : {
6805 "check" : [
6806 "perm",
6807 "/vms/{vmid}",
6808 [
44660702
DM
6809 "VM.Config.Disk",
6810 "VM.Config.CDROM",
6811 "VM.Config.CPU",
6812 "VM.Config.Memory",
6813 "VM.Config.Network",
6814 "VM.Config.HWType",
6815 "VM.Config.Options"
6816 ],
6817 "any",
6818 1
7aacca6f 6819 ]
56122987 6820 },
44660702 6821 "protected" : 1,
7aacca6f 6822 "proxyto" : "node",
44660702
DM
6823 "returns" : {
6824 "optional" : 1,
6825 "type" : "string"
6826 }
56122987 6827 },
7aacca6f 6828 "PUT" : {
44660702
DM
6829 "description" : "Set virtual machine options (synchrounous API) - You should consider using the POST method instead for any actions involving hotplug or storage allocation.",
6830 "method" : "PUT",
6831 "name" : "update_vm",
56122987 6832 "parameters" : {
7aacca6f 6833 "additionalProperties" : 0,
56122987 6834 "properties" : {
44660702
DM
6835 "acpi" : {
6836 "default" : 1,
6837 "description" : "Enable/disable ACPI.",
7aacca6f 6838 "optional" : 1,
44660702 6839 "type" : "boolean"
7aacca6f 6840 },
44660702
DM
6841 "agent" : {
6842 "default" : 0,
6843 "description" : "Enable/disable Qemu GuestAgent.",
7aacca6f 6844 "optional" : 1,
44660702 6845 "type" : "boolean"
56122987 6846 },
44660702 6847 "args" : {
c2993fe5 6848 "description" : "Arbitrary arguments passed to kvm.",
7aacca6f 6849 "optional" : 1,
c2993fe5
DM
6850 "type" : "string",
6851 "verbose_description" : "Arbitrary arguments passed to kvm, for example:\n\nargs: -no-reboot -no-hpet\n\nNOTE: this option is for experts only.\n"
7aacca6f 6852 },
44660702
DM
6853 "autostart" : {
6854 "default" : 0,
6855 "description" : "Automatic restart after crash (currently ignored).",
7aacca6f
DM
6856 "optional" : 1,
6857 "type" : "boolean"
6858 },
44660702
DM
6859 "balloon" : {
6860 "description" : "Amount of target RAM for the VM in MB. Using zero disables the ballon driver.",
6861 "minimum" : 0,
6862 "optional" : 1,
4bd7df8b 6863 "type" : "integer",
2c0dde61 6864 "typetext" : "integer (0 - N)"
44660702
DM
6865 },
6866 "bios" : {
6867 "default" : "seabios",
6868 "description" : "Select BIOS implementation.",
7aacca6f 6869 "enum" : [
44660702
DM
6870 "seabios",
6871 "ovmf"
7aacca6f 6872 ],
56122987 6873 "optional" : 1,
7aacca6f
DM
6874 "type" : "string"
6875 },
44660702
DM
6876 "boot" : {
6877 "default" : "cdn",
6878 "description" : "Boot on floppy (a), hard disk (c), CD-ROM (d), or network (n).",
7aacca6f 6879 "optional" : 1,
44660702
DM
6880 "pattern" : "[acdn]{1,4}",
6881 "type" : "string"
56122987 6882 },
44660702
DM
6883 "bootdisk" : {
6884 "description" : "Enable booting from specified disk.",
6885 "format" : "pve-qm-bootdisk",
6886 "optional" : 1,
6887 "pattern" : "(ide|sata|scsi|virtio)\\d+",
6888 "type" : "string"
6889 },
6890 "cdrom" : {
6891 "description" : "This is an alias for option -ide2",
6892 "format" : "pve-qm-drive",
56122987 6893 "optional" : 1,
7aacca6f 6894 "type" : "string",
44660702
DM
6895 "typetext" : "volume"
6896 },
6897 "cores" : {
6898 "default" : 1,
6899 "description" : "The number of cores per socket.",
6900 "minimum" : 1,
6901 "optional" : 1,
4bd7df8b 6902 "type" : "integer",
2c0dde61 6903 "typetext" : "integer (1 - N)"
44660702
DM
6904 },
6905 "cpu" : {
6906 "description" : "Emulated CPU type.",
6907 "format" : {
6908 "cputype" : {
6909 "default" : "kvm64",
6910 "default_key" : 1,
6911 "description" : "Emulated CPU type.",
6912 "enum" : [
6913 "486",
6914 "athlon",
f004f5b9
DM
6915 "Broadwell",
6916 "Broadwell-noTSX",
6917 "Conroe",
44660702 6918 "core2duo",
f004f5b9
DM
6919 "coreduo",
6920 "Haswell",
6921 "Haswell-noTSX",
6922 "host",
6923 "IvyBridge",
44660702
DM
6924 "kvm32",
6925 "kvm64",
44660702 6926 "Nehalem",
44660702
DM
6927 "Opteron_G1",
6928 "Opteron_G2",
6929 "Opteron_G3",
6930 "Opteron_G4",
6931 "Opteron_G5",
f004f5b9
DM
6932 "Penryn",
6933 "pentium",
6934 "pentium2",
6935 "pentium3",
6936 "phenom",
6937 "qemu32",
6938 "qemu64",
6939 "SandyBridge",
6940 "Westmere"
44660702
DM
6941 ],
6942 "format_description" : "cputype",
6943 "type" : "string"
6944 },
6945 "hidden" : {
6946 "default" : 0,
6947 "description" : "Do not identify as a KVM virtual machine.",
6948 "optional" : 1,
6949 "type" : "boolean"
6950 }
6951 },
6952 "optional" : 1,
4bd7df8b
DM
6953 "type" : "string",
6954 "typetext" : "[cputype=]<cputype> [,hidden=<1|0>]"
44660702
DM
6955 },
6956 "cpulimit" : {
6957 "default" : 0,
c2993fe5 6958 "description" : "Limit of CPU usage.",
44660702
DM
6959 "maximum" : 128,
6960 "minimum" : 0,
6961 "optional" : 1,
c2993fe5 6962 "type" : "number",
2c0dde61 6963 "typetext" : "number (0 - 128)",
c2993fe5 6964 "verbose_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."
44660702
DM
6965 },
6966 "cpuunits" : {
6967 "default" : 1000,
c2993fe5 6968 "description" : "CPU weight for a VM.",
44660702
DM
6969 "maximum" : 500000,
6970 "minimum" : 0,
6971 "optional" : 1,
c2993fe5 6972 "type" : "integer",
2c0dde61 6973 "typetext" : "integer (0 - 500000)",
c2993fe5 6974 "verbose_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."
44660702
DM
6975 },
6976 "delete" : {
6977 "description" : "A list of settings you want to delete.",
6978 "format" : "pve-configid-list",
6979 "optional" : 1,
6980 "type" : "string"
6981 },
6982 "description" : {
6983 "description" : "Description for the VM. Only used on the configuration web interface. This is saved as comment inside the configuration file.",
6984 "optional" : 1,
6985 "type" : "string"
6986 },
6987 "digest" : {
6988 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
6989 "maxLength" : 40,
6990 "optional" : 1,
6991 "type" : "string"
6992 },
6993 "force" : {
6994 "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.",
6995 "optional" : 1,
6996 "requires" : "delete",
6997 "type" : "boolean"
6998 },
6999 "freeze" : {
7000 "description" : "Freeze CPU at startup (use 'c' monitor command to start execution).",
7001 "optional" : 1,
7002 "type" : "boolean"
7003 },
7004 "hostpci[n]" : {
c2993fe5 7005 "description" : "Map host PCI devices into guest.",
44660702
DM
7006 "format" : "pve-qm-hostpci",
7007 "optional" : 1,
57b78691 7008 "type" : "string",
4bd7df8b 7009 "typetext" : "[host=]<HOSTPCIID[;HOSTPCIID2...]> [,pcie=<1|0>] [,rombar=<1|0>] [,x-vga=<1|0>]",
57b78691 7010 "verbose_description" : "Map host PCI devices into guest.\n\nNOTE: This option allows direct access to host hardware. So it is no longer \npossible to migrate such machines - use with special care.\n\nCAUTION: Experimental! User reported problems with this option.\n"
56122987 7011 },
7aacca6f 7012 "hotplug" : {
7aacca6f 7013 "default" : "network,disk,usb",
44660702
DM
7014 "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'.",
7015 "format" : "pve-hotplug-features",
56122987 7016 "optional" : 1,
56122987
DM
7017 "type" : "string"
7018 },
4bd7df8b
DM
7019 "hugepages" : {
7020 "description" : "Enable/disable hugepages memory.",
7021 "enum" : [
7022 "any",
7023 "2",
7024 "1024"
7025 ],
7026 "optional" : 1,
7027 "type" : "string"
7028 },
56122987 7029 "ide[n]" : {
7aacca6f 7030 "description" : "Use volume as IDE hard disk or CD-ROM (n is 0 to 3).",
56122987 7031 "format" : {
44660702
DM
7032 "aio" : {
7033 "description" : "AIO type to use.",
7034 "enum" : [
7035 "native",
7036 "threads"
7037 ],
56122987 7038 "optional" : 1,
44660702 7039 "type" : "string"
56122987 7040 },
44660702
DM
7041 "backup" : {
7042 "description" : "Whether the drive should be included when making backups.",
44660702
DM
7043 "optional" : 1,
7044 "type" : "boolean"
7045 },
7046 "bps" : {
7047 "description" : "Maximum r/w speed speed in bytes per second.",
7048 "format_description" : "bps",
56122987 7049 "optional" : 1,
44660702 7050 "type" : "integer"
56122987 7051 },
44660702
DM
7052 "bps_rd" : {
7053 "description" : "Maximum read speed speed in bytes per second.",
7054 "format_description" : "bps",
56122987 7055 "optional" : 1,
44660702 7056 "type" : "integer"
56122987 7057 },
7aacca6f 7058 "bps_wr" : {
7aacca6f 7059 "description" : "Maximum write speed speed in bytes per second.",
44660702
DM
7060 "format_description" : "bps",
7061 "optional" : 1,
7062 "type" : "integer"
7aacca6f 7063 },
44660702
DM
7064 "cache" : {
7065 "description" : "The drive's cache mode",
7066 "enum" : [
7067 "none",
7068 "writethrough",
7069 "writeback",
7070 "unsafe",
7071 "directsync"
7072 ],
56122987 7073 "optional" : 1,
44660702
DM
7074 "type" : "string"
7075 },
7076 "cyls" : {
7077 "description" : "Force the drive's physical geometry to have a specific cylinder count.",
44660702
DM
7078 "optional" : 1,
7079 "type" : "integer"
7080 },
7081 "detect_zeroes" : {
7082 "description" : "Controls whether to detect and try to optimize writes of zeroes.",
7083 "optional" : 1,
7084 "type" : "boolean"
56122987 7085 },
7aacca6f 7086 "discard" : {
7aacca6f 7087 "description" : "Controls whether to pass discard/trim requests to the underlying storage.",
56122987 7088 "enum" : [
7aacca6f
DM
7089 "ignore",
7090 "on"
56122987
DM
7091 ],
7092 "optional" : 1,
44660702 7093 "type" : "string"
7aacca6f 7094 },
44660702
DM
7095 "file" : {
7096 "default_key" : 1,
7097 "description" : "The drive's backing volume.",
7098 "format" : "pve-volume-id-or-qm-path",
7099 "format_description" : "volume",
7100 "type" : "string"
7aacca6f
DM
7101 },
7102 "format" : {
44660702 7103 "description" : "The drive's backing file's data format.",
7aacca6f
DM
7104 "enum" : [
7105 "raw",
7106 "cow",
7107 "qcow",
7108 "qed",
7109 "qcow2",
7110 "vmdk",
7111 "cloop"
7112 ],
f004f5b9 7113 "format_description" : "image format",
7aacca6f 7114 "optional" : 1,
44660702 7115 "type" : "string"
56122987 7116 },
7aacca6f 7117 "heads" : {
44660702 7118 "description" : "Force the drive's physical geometry to have a specific head count.",
56122987 7119 "optional" : 1,
44660702 7120 "type" : "integer"
7aacca6f 7121 },
44660702
DM
7122 "iops" : {
7123 "description" : "Maximum r/w I/O speed in operations per second.",
7124 "format_description" : "iops",
7aacca6f 7125 "optional" : 1,
44660702 7126 "type" : "integer"
56122987 7127 },
44660702
DM
7128 "iops_max" : {
7129 "description" : "Maximum unthrottled r/w I/O pool speed in operations per second.",
7130 "format_description" : "iops",
56122987 7131 "optional" : 1,
44660702 7132 "type" : "integer"
56122987 7133 },
44660702
DM
7134 "iops_rd" : {
7135 "description" : "Maximum read I/O speed in operations per second.",
7136 "format_description" : "iops",
56122987 7137 "optional" : 1,
44660702 7138 "type" : "integer"
7aacca6f 7139 },
44660702
DM
7140 "iops_rd_max" : {
7141 "description" : "Maximum unthrottled read I/O pool speed in operations per second.",
7142 "format_description" : "iops",
7aacca6f 7143 "optional" : 1,
44660702 7144 "type" : "integer"
7aacca6f 7145 },
44660702
DM
7146 "iops_wr" : {
7147 "description" : "Maximum write I/O speed in operations per second.",
7148 "format_description" : "iops",
7aacca6f 7149 "optional" : 1,
44660702 7150 "type" : "integer"
56122987 7151 },
44660702
DM
7152 "iops_wr_max" : {
7153 "description" : "Maximum unthrottled write I/O pool speed in operations per second.",
7154 "format_description" : "iops",
7aacca6f 7155 "optional" : 1,
44660702 7156 "type" : "integer"
7aacca6f
DM
7157 },
7158 "mbps" : {
44660702 7159 "description" : "Maximum r/w speed speed in megabytes per second.",
7aacca6f 7160 "format_description" : "mbps",
7aacca6f 7161 "optional" : 1,
44660702 7162 "type" : "number"
7aacca6f 7163 },
44660702
DM
7164 "mbps_max" : {
7165 "description" : "Maximum unthrottled r/w pool speed in megabytes per second.",
7166 "format_description" : "mbps",
7aacca6f 7167 "optional" : 1,
44660702 7168 "type" : "number"
7aacca6f 7169 },
44660702
DM
7170 "mbps_rd" : {
7171 "description" : "Maximum read speed speed in megabytes per second.",
7172 "format_description" : "mbps",
7aacca6f 7173 "optional" : 1,
44660702 7174 "type" : "number"
7aacca6f 7175 },
44660702
DM
7176 "mbps_rd_max" : {
7177 "description" : "Maximum unthrottled read pool speed in megabytes per second.",
7178 "format_description" : "mbps",
7179 "optional" : 1,
7180 "type" : "number"
7aacca6f 7181 },
44660702
DM
7182 "mbps_wr" : {
7183 "description" : "Maximum write speed speed in megabytes per second.",
7184 "format_description" : "mbps",
7aacca6f 7185 "optional" : 1,
44660702
DM
7186 "type" : "number"
7187 },
7188 "mbps_wr_max" : {
7189 "description" : "Maximum unthrottled write pool speed in megabytes per second.",
7190 "format_description" : "mbps",
7191 "optional" : 1,
7192 "type" : "number"
7193 },
7194 "media" : {
7195 "default" : "disk",
7196 "description" : "The drive's media type.",
56122987 7197 "enum" : [
44660702
DM
7198 "cdrom",
7199 "disk"
56122987 7200 ],
44660702
DM
7201 "optional" : 1,
7202 "type" : "string"
56122987 7203 },
7aacca6f 7204 "model" : {
44660702 7205 "description" : "The drive's reported model name, url-encoded, up to 40 bytes long.",
56122987 7206 "format" : "urlencoded",
7aacca6f 7207 "format_description" : "model",
44660702 7208 "maxLength" : 120,
56122987 7209 "optional" : 1,
44660702 7210 "type" : "string"
56122987 7211 },
44660702
DM
7212 "rerror" : {
7213 "description" : "Read error action.",
7214 "enum" : [
7215 "ignore",
7216 "report",
7217 "stop"
7218 ],
56122987 7219 "optional" : 1,
44660702 7220 "type" : "string"
56122987 7221 },
44660702
DM
7222 "secs" : {
7223 "description" : "Force the drive's physical geometry to have a specific sector count.",
44660702
DM
7224 "optional" : 1,
7225 "type" : "integer"
56122987 7226 },
44660702
DM
7227 "serial" : {
7228 "description" : "The drive's reported serial number, url-encoded, up to 20 bytes long.",
7229 "format" : "urlencoded",
7230 "format_description" : "serial",
7231 "maxLength" : 60,
56122987 7232 "optional" : 1,
44660702 7233 "type" : "string"
56122987 7234 },
44660702
DM
7235 "size" : {
7236 "description" : "Disk size. This is purely informational and has no effect.",
7237 "format" : "disk-size",
f004f5b9 7238 "format_description" : "DiskSize",
56122987 7239 "optional" : 1,
44660702 7240 "type" : "string"
56122987 7241 },
44660702
DM
7242 "snapshot" : {
7243 "description" : "Whether the drive should be included when making snapshots.",
56122987 7244 "optional" : 1,
44660702 7245 "type" : "boolean"
56122987 7246 },
44660702
DM
7247 "trans" : {
7248 "description" : "Force disk geometry bios translation mode.",
7249 "enum" : [
7250 "none",
7251 "lba",
7252 "auto"
7253 ],
56122987 7254 "optional" : 1,
44660702
DM
7255 "type" : "string"
7256 },
7257 "volume" : {
7258 "alias" : "file"
56122987 7259 },
7aacca6f 7260 "werror" : {
44660702 7261 "description" : "Write error action.",
7aacca6f
DM
7262 "enum" : [
7263 "enospc",
7264 "ignore",
7265 "report",
7266 "stop"
7267 ],
56122987 7268 "optional" : 1,
44660702 7269 "type" : "string"
7aacca6f 7270 }
44660702
DM
7271 },
7272 "optional" : 1,
4bd7df8b
DM
7273 "type" : "string",
7274 "typetext" : "[file=]<volume> [,aio=<native|threads>] [,backup=<1|0>] [,bps=<bps>] [,bps_rd=<bps>] [,bps_wr=<bps>] [,cache=<none|writethrough|writeback|unsafe|directsync>] [,cyls=<integer>] [,detect_zeroes=<1|0>] [,discard=<ignore|on>] [,format=<image format>] [,heads=<integer>] [,iops=<iops>] [,iops_max=<iops>] [,iops_rd=<iops>] [,iops_rd_max=<iops>] [,iops_wr=<iops>] [,iops_wr_max=<iops>] [,mbps=<mbps>] [,mbps_max=<mbps>] [,mbps_rd=<mbps>] [,mbps_rd_max=<mbps>] [,mbps_wr=<mbps>] [,mbps_wr_max=<mbps>] [,media=<cdrom|disk>] [,model=<model>] [,rerror=<ignore|report|stop>] [,secs=<integer>] [,serial=<serial>] [,size=<DiskSize>] [,snapshot=<1|0>] [,trans=<none|lba|auto>] [,werror=<enospc|ignore|report|stop>]"
7aacca6f 7275 },
44660702
DM
7276 "keyboard" : {
7277 "default" : "en-us",
c2993fe5 7278 "description" : "Keybord layout for vnc server. Default is read from the '/etc/pve/datacenter.conf' configuration file.",
44660702
DM
7279 "enum" : [
7280 "de",
7281 "de-ch",
7282 "da",
7283 "en-gb",
7284 "en-us",
7285 "es",
7286 "fi",
7287 "fr",
7288 "fr-be",
7289 "fr-ca",
7290 "fr-ch",
7291 "hu",
7292 "is",
7293 "it",
7294 "ja",
7295 "lt",
7296 "mk",
7297 "nl",
7298 "no",
7299 "pl",
7300 "pt",
7301 "pt-br",
7302 "sv",
7303 "sl",
7304 "tr"
7305 ],
7aacca6f 7306 "optional" : 1,
44660702 7307 "type" : "string"
7aacca6f 7308 },
44660702 7309 "kvm" : {
7aacca6f 7310 "default" : 1,
44660702 7311 "description" : "Enable/disable KVM hardware virtualization.",
7aacca6f 7312 "optional" : 1,
44660702 7313 "type" : "boolean"
7aacca6f 7314 },
44660702
DM
7315 "localtime" : {
7316 "description" : "Set the real time clock to local time. This is enabled by default if ostype indicates a Microsoft OS.",
7aacca6f 7317 "optional" : 1,
44660702 7318 "type" : "boolean"
7aacca6f 7319 },
44660702
DM
7320 "lock" : {
7321 "description" : "Lock/unlock the VM.",
7322 "enum" : [
7323 "migrate",
7324 "backup",
7325 "snapshot",
7326 "rollback"
7327 ],
7aacca6f 7328 "optional" : 1,
44660702 7329 "type" : "string"
7aacca6f 7330 },
44660702
DM
7331 "machine" : {
7332 "description" : "Specific the Qemu machine type.",
7333 "maxLength" : 40,
7aacca6f 7334 "optional" : 1,
44660702
DM
7335 "pattern" : "(pc|pc(-i440fx)?-\\d+\\.\\d+(\\.pxe)?|q35|pc-q35-\\d+\\.\\d+(\\.pxe)?)",
7336 "type" : "string"
7aacca6f 7337 },
44660702
DM
7338 "memory" : {
7339 "default" : 512,
7340 "description" : "Amount of RAM for the VM in MB. This is the maximum available memory when you use the balloon device.",
7341 "minimum" : 16,
7aacca6f 7342 "optional" : 1,
4bd7df8b 7343 "type" : "integer",
2c0dde61 7344 "typetext" : "integer (16 - N)"
7aacca6f 7345 },
44660702
DM
7346 "migrate_downtime" : {
7347 "default" : 0.1,
7348 "description" : "Set maximum tolerated downtime (in seconds) for migrations.",
7349 "minimum" : 0,
7aacca6f 7350 "optional" : 1,
4bd7df8b 7351 "type" : "number",
2c0dde61 7352 "typetext" : "number (0 - N)"
7aacca6f 7353 },
44660702 7354 "migrate_speed" : {
7aacca6f 7355 "default" : 0,
44660702
DM
7356 "description" : "Set maximum speed (in MB/s) for migrations. Value 0 is no limit.",
7357 "minimum" : 0,
7358 "optional" : 1,
4bd7df8b 7359 "type" : "integer",
2c0dde61 7360 "typetext" : "integer (0 - N)"
7aacca6f 7361 },
44660702
DM
7362 "name" : {
7363 "description" : "Set a name for the VM. Only used on the configuration web interface.",
7364 "format" : "dns-name",
7aacca6f 7365 "optional" : 1,
44660702 7366 "type" : "string"
7aacca6f 7367 },
44660702 7368 "net[n]" : {
c2993fe5 7369 "description" : "Specify network devices.",
f004f5b9
DM
7370 "format" : {
7371 "bridge" : {
c2993fe5 7372 "description" : "Bridge to attach the network device to. The Proxmox VE standard bridge\nis called 'vmbr0'.\n\nIf you do not specify a bridge, we create a kvm user (NATed) network\ndevice, which provides DHCP and DNS services. The following addresses\nare used:\n\n 10.0.2.2 Gateway\n 10.0.2.3 DNS Server\n 10.0.2.4 SMB Server\n\nThe DHCP server assign addresses to the guest starting from 10.0.2.15.\n",
f004f5b9
DM
7373 "format_description" : "bridge",
7374 "optional" : 1,
7375 "type" : "string"
7376 },
7377 "e1000" : {
7378 "alias" : "macaddr",
7379 "keyAlias" : "model"
7380 },
7381 "e1000-82540em" : {
7382 "alias" : "macaddr",
7383 "keyAlias" : "model"
7384 },
7385 "e1000-82544gc" : {
7386 "alias" : "macaddr",
7387 "keyAlias" : "model"
7388 },
7389 "e1000-82545em" : {
7390 "alias" : "macaddr",
7391 "keyAlias" : "model"
7392 },
7393 "firewall" : {
7394 "description" : "Whether this interface should be protected by the firewall.",
7395 "optional" : 1,
7396 "type" : "boolean"
7397 },
7398 "i82551" : {
7399 "alias" : "macaddr",
7400 "keyAlias" : "model"
7401 },
7402 "i82557b" : {
7403 "alias" : "macaddr",
7404 "keyAlias" : "model"
7405 },
7406 "i82559er" : {
7407 "alias" : "macaddr",
7408 "keyAlias" : "model"
7409 },
7410 "link_down" : {
c2993fe5 7411 "description" : "Whether this interface should be disconnected (like pulling the plug).",
f004f5b9
DM
7412 "optional" : 1,
7413 "type" : "boolean"
7414 },
7415 "macaddr" : {
c2993fe5 7416 "description" : "MAC address. That address must be unique withing your network. This is automatically generated if not specified.",
f004f5b9 7417 "format_description" : "XX:XX:XX:XX:XX:XX",
f004f5b9
DM
7418 "optional" : 1,
7419 "pattern" : "(?^i:[0-9a-f]{2}(?::[0-9a-f]{2}){5})",
7420 "type" : "string"
7421 },
7422 "model" : {
7423 "default_key" : 1,
c2993fe5 7424 "description" : "Network Card Model. The 'virtio' model provides the best performance with very low CPU overhead. If your guest does not support this driver, it is usually best to use 'e1000'.",
f004f5b9
DM
7425 "enum" : [
7426 "rtl8139",
7427 "ne2k_pci",
7428 "e1000",
7429 "pcnet",
7430 "virtio",
7431 "ne2k_isa",
7432 "i82551",
7433 "i82557b",
7434 "i82559er",
7435 "vmxnet3",
7436 "e1000-82540em",
7437 "e1000-82544gc",
7438 "e1000-82545em"
7439 ],
7440 "format_description" : "model",
7441 "type" : "string"
7442 },
7443 "ne2k_isa" : {
7444 "alias" : "macaddr",
7445 "keyAlias" : "model"
7446 },
7447 "ne2k_pci" : {
7448 "alias" : "macaddr",
7449 "keyAlias" : "model"
7450 },
7451 "pcnet" : {
7452 "alias" : "macaddr",
7453 "keyAlias" : "model"
7454 },
7455 "queues" : {
7456 "description" : "Number of packet queues to be used on the device.",
7457 "maximum" : 16,
7458 "minimum" : 0,
7459 "optional" : 1,
7460 "type" : "integer"
7461 },
7462 "rate" : {
c2993fe5 7463 "description" : "Rate limit in mbps (megabytes per second) as floating point number.",
f004f5b9
DM
7464 "minimum" : 0,
7465 "optional" : 1,
7466 "type" : "number"
7467 },
7468 "rtl8139" : {
7469 "alias" : "macaddr",
7470 "keyAlias" : "model"
7471 },
7472 "tag" : {
7473 "description" : "VLAN tag to apply to packets on this interface.",
7474 "maximum" : 4094,
c2993fe5 7475 "minimum" : 1,
f004f5b9
DM
7476 "optional" : 1,
7477 "type" : "integer"
7478 },
7479 "trunks" : {
7480 "description" : "VLAN trunks to pass through this interface.",
7481 "format_description" : "vlanid[;vlanid...]",
7482 "optional" : 1,
7483 "pattern" : "(?^:\\d+(?:-\\d+)?(?:;\\d+(?:-\\d+)?)*)",
7484 "type" : "string"
7485 },
7486 "virtio" : {
7487 "alias" : "macaddr",
7488 "keyAlias" : "model"
7489 },
7490 "vmxnet3" : {
7491 "alias" : "macaddr",
7492 "keyAlias" : "model"
7493 }
7494 },
7aacca6f 7495 "optional" : 1,
4bd7df8b
DM
7496 "type" : "string",
7497 "typetext" : "[model=]<model> [,bridge=<bridge>] [,firewall=<1|0>] [,link_down=<1|0>] [,macaddr=<XX:XX:XX:XX:XX:XX>] [,queues=<integer>] [,rate=<number>] [,tag=<integer>] [,trunks=<vlanid[;vlanid...]>] [,<model>=<macaddr>]"
7aacca6f 7498 },
44660702
DM
7499 "node" : {
7500 "description" : "The cluster node name.",
7501 "format" : "pve-node",
7502 "type" : "string"
7503 },
7504 "numa" : {
7505 "default" : 0,
7506 "description" : "Enable/disable NUMA.",
7aacca6f
DM
7507 "optional" : 1,
7508 "type" : "boolean"
7509 },
44660702 7510 "numa[n]" : {
c2993fe5 7511 "description" : "NUMA topology.",
44660702
DM
7512 "format" : {
7513 "cpus" : {
c2993fe5 7514 "description" : "CPUs accessing this NUMA node.",
44660702
DM
7515 "format_description" : "id[-id];...",
7516 "pattern" : "(?^:\\d+(?:-\\d+)?(?:;\\d+(?:-\\d+)?)*)",
7517 "type" : "string"
7518 },
7519 "hostnodes" : {
c2993fe5 7520 "description" : "Host NUMA nodes to use.",
44660702
DM
7521 "format_description" : "id[-id];...",
7522 "optional" : 1,
7523 "pattern" : "(?^:\\d+(?:-\\d+)?(?:;\\d+(?:-\\d+)?)*)",
7524 "type" : "string"
7525 },
7526 "memory" : {
c2993fe5 7527 "description" : "Amount of memory this NUMA node provides.",
44660702
DM
7528 "optional" : 1,
7529 "type" : "number"
7530 },
7531 "policy" : {
c2993fe5 7532 "description" : "NUMA allocation policy.",
44660702
DM
7533 "enum" : [
7534 "preferred",
7535 "bind",
7536 "interleave"
7537 ],
44660702
DM
7538 "optional" : 1,
7539 "type" : "string"
7540 }
7541 },
7aacca6f 7542 "optional" : 1,
4bd7df8b
DM
7543 "type" : "string",
7544 "typetext" : "cpus=<id[-id];...> [,hostnodes=<id[-id];...>] [,memory=<number>] [,policy=<preferred|bind|interleave>]"
7aacca6f 7545 },
44660702
DM
7546 "onboot" : {
7547 "default" : 0,
7548 "description" : "Specifies whether a VM will be started during system bootup.",
7aacca6f 7549 "optional" : 1,
44660702 7550 "type" : "boolean"
7aacca6f 7551 },
44660702 7552 "ostype" : {
c2993fe5 7553 "description" : "Specify guest operating system.",
44660702
DM
7554 "enum" : [
7555 "other",
7556 "wxp",
7557 "w2k",
7558 "w2k3",
7559 "w2k8",
7560 "wvista",
7561 "win7",
7562 "win8",
7563 "l24",
7564 "l26",
7565 "solaris"
7566 ],
7aacca6f 7567 "optional" : 1,
c2993fe5
DM
7568 "type" : "string",
7569 "verbose_description" : "Specify guest operating system. This is used to enable special\noptimization/features for specific operating systems:\n\n[horizontal]\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"
7aacca6f 7570 },
44660702 7571 "parallel[n]" : {
c2993fe5 7572 "description" : "Map host parallel devices (n is 0 to 2).",
7aacca6f 7573 "optional" : 1,
44660702 7574 "pattern" : "/dev/parport\\d+|/dev/usb/lp\\d+",
c2993fe5
DM
7575 "type" : "string",
7576 "verbose_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\nCAUTION: Experimental! User reported problems with this option.\n"
7aacca6f 7577 },
44660702
DM
7578 "protection" : {
7579 "default" : 0,
c2993fe5 7580 "description" : "Sets the protection flag of the VM. This will disable the remove VM and remove disk operations.",
7aacca6f 7581 "optional" : 1,
44660702 7582 "type" : "boolean"
7aacca6f 7583 },
44660702
DM
7584 "reboot" : {
7585 "default" : 1,
7586 "description" : "Allow reboot. If set to '0' the VM exit on reboot.",
7aacca6f 7587 "optional" : 1,
44660702 7588 "type" : "boolean"
7aacca6f 7589 },
44660702
DM
7590 "revert" : {
7591 "description" : "Revert a pending change.",
7592 "format" : "pve-configid-list",
7aacca6f 7593 "optional" : 1,
44660702 7594 "type" : "string"
7aacca6f 7595 },
44660702
DM
7596 "sata[n]" : {
7597 "description" : "Use volume as SATA hard disk or CD-ROM (n is 0 to 5).",
7aacca6f 7598 "format" : {
44660702
DM
7599 "aio" : {
7600 "description" : "AIO type to use.",
7601 "enum" : [
7602 "native",
7603 "threads"
7604 ],
44660702
DM
7605 "optional" : 1,
7606 "type" : "string"
7607 },
7608 "backup" : {
7609 "description" : "Whether the drive should be included when making backups.",
44660702
DM
7610 "optional" : 1,
7611 "type" : "boolean"
7612 },
7613 "bps" : {
7614 "description" : "Maximum r/w speed speed in bytes per second.",
7aacca6f 7615 "format_description" : "bps",
7aacca6f
DM
7616 "optional" : 1,
7617 "type" : "integer"
56122987 7618 },
44660702
DM
7619 "bps_rd" : {
7620 "description" : "Maximum read speed speed in bytes per second.",
7621 "format_description" : "bps",
7aacca6f 7622 "optional" : 1,
44660702 7623 "type" : "integer"
7aacca6f 7624 },
44660702
DM
7625 "bps_wr" : {
7626 "description" : "Maximum write speed speed in bytes per second.",
7627 "format_description" : "bps",
7aacca6f 7628 "optional" : 1,
44660702 7629 "type" : "integer"
7aacca6f 7630 },
44660702
DM
7631 "cache" : {
7632 "description" : "The drive's cache mode",
7633 "enum" : [
7634 "none",
7635 "writethrough",
7636 "writeback",
7637 "unsafe",
7638 "directsync"
7639 ],
7aacca6f 7640 "optional" : 1,
44660702 7641 "type" : "string"
7aacca6f 7642 },
44660702
DM
7643 "cyls" : {
7644 "description" : "Force the drive's physical geometry to have a specific cylinder count.",
7aacca6f 7645 "optional" : 1,
44660702 7646 "type" : "integer"
7aacca6f 7647 },
44660702
DM
7648 "detect_zeroes" : {
7649 "description" : "Controls whether to detect and try to optimize writes of zeroes.",
7aacca6f 7650 "optional" : 1,
44660702 7651 "type" : "boolean"
7aacca6f 7652 },
44660702
DM
7653 "discard" : {
7654 "description" : "Controls whether to pass discard/trim requests to the underlying storage.",
7655 "enum" : [
7656 "ignore",
7657 "on"
7658 ],
7aacca6f 7659 "optional" : 1,
44660702
DM
7660 "type" : "string"
7661 },
7662 "file" : {
7663 "default_key" : 1,
7664 "description" : "The drive's backing volume.",
7665 "format" : "pve-volume-id-or-qm-path",
7666 "format_description" : "volume",
7667 "type" : "string"
7aacca6f
DM
7668 },
7669 "format" : {
7aacca6f 7670 "description" : "The drive's backing file's data format.",
56122987
DM
7671 "enum" : [
7672 "raw",
7673 "cow",
7674 "qcow",
7675 "qed",
7676 "qcow2",
7677 "vmdk",
7678 "cloop"
7679 ],
f004f5b9 7680 "format_description" : "image format",
56122987 7681 "optional" : 1,
7aacca6f 7682 "type" : "string"
56122987 7683 },
7aacca6f 7684 "heads" : {
7aacca6f 7685 "description" : "Force the drive's physical geometry to have a specific head count.",
44660702
DM
7686 "optional" : 1,
7687 "type" : "integer"
56122987 7688 },
44660702
DM
7689 "iops" : {
7690 "description" : "Maximum r/w I/O speed in operations per second.",
7691 "format_description" : "iops",
56122987 7692 "optional" : 1,
44660702 7693 "type" : "integer"
7aacca6f 7694 },
44660702
DM
7695 "iops_max" : {
7696 "description" : "Maximum unthrottled r/w I/O pool speed in operations per second.",
7697 "format_description" : "iops",
7aacca6f 7698 "optional" : 1,
44660702 7699 "type" : "integer"
56122987 7700 },
44660702
DM
7701 "iops_rd" : {
7702 "description" : "Maximum read I/O speed in operations per second.",
7703 "format_description" : "iops",
56122987 7704 "optional" : 1,
44660702 7705 "type" : "integer"
7aacca6f 7706 },
44660702
DM
7707 "iops_rd_max" : {
7708 "description" : "Maximum unthrottled read I/O pool speed in operations per second.",
7709 "format_description" : "iops",
56122987 7710 "optional" : 1,
44660702 7711 "type" : "integer"
56122987 7712 },
44660702
DM
7713 "iops_wr" : {
7714 "description" : "Maximum write I/O speed in operations per second.",
7715 "format_description" : "iops",
7716 "optional" : 1,
7717 "type" : "integer"
56122987 7718 },
44660702
DM
7719 "iops_wr_max" : {
7720 "description" : "Maximum unthrottled write I/O pool speed in operations per second.",
7721 "format_description" : "iops",
7722 "optional" : 1,
7723 "type" : "integer"
7724 },
7725 "mbps" : {
7726 "description" : "Maximum r/w speed speed in megabytes per second.",
7727 "format_description" : "mbps",
7728 "optional" : 1,
7729 "type" : "number"
7730 },
7731 "mbps_max" : {
7732 "description" : "Maximum unthrottled r/w pool speed in megabytes per second.",
7733 "format_description" : "mbps",
7734 "optional" : 1,
7735 "type" : "number"
7736 },
7737 "mbps_rd" : {
7738 "description" : "Maximum read speed speed in megabytes per second.",
7739 "format_description" : "mbps",
7740 "optional" : 1,
7741 "type" : "number"
7742 },
7743 "mbps_rd_max" : {
7744 "description" : "Maximum unthrottled read pool speed in megabytes per second.",
7745 "format_description" : "mbps",
7746 "optional" : 1,
7747 "type" : "number"
7748 },
7749 "mbps_wr" : {
7750 "description" : "Maximum write speed speed in megabytes per second.",
7751 "format_description" : "mbps",
7752 "optional" : 1,
7753 "type" : "number"
7754 },
7755 "mbps_wr_max" : {
7756 "description" : "Maximum unthrottled write pool speed in megabytes per second.",
7757 "format_description" : "mbps",
7758 "optional" : 1,
7759 "type" : "number"
7760 },
7761 "media" : {
7762 "default" : "disk",
7763 "description" : "The drive's media type.",
7764 "enum" : [
7765 "cdrom",
7766 "disk"
7767 ],
56122987 7768 "optional" : 1,
44660702
DM
7769 "type" : "string"
7770 },
7771 "rerror" : {
7aacca6f
DM
7772 "description" : "Read error action.",
7773 "enum" : [
7774 "ignore",
7775 "report",
7776 "stop"
44660702 7777 ],
56122987 7778 "optional" : 1,
44660702 7779 "type" : "string"
56122987 7780 },
7aacca6f 7781 "secs" : {
44660702 7782 "description" : "Force the drive's physical geometry to have a specific sector count.",
56122987 7783 "optional" : 1,
44660702 7784 "type" : "integer"
56122987 7785 },
44660702
DM
7786 "serial" : {
7787 "description" : "The drive's reported serial number, url-encoded, up to 20 bytes long.",
7788 "format" : "urlencoded",
7789 "format_description" : "serial",
7790 "maxLength" : 60,
56122987 7791 "optional" : 1,
44660702 7792 "type" : "string"
56122987 7793 },
44660702
DM
7794 "size" : {
7795 "description" : "Disk size. This is purely informational and has no effect.",
7796 "format" : "disk-size",
f004f5b9 7797 "format_description" : "DiskSize",
56122987 7798 "optional" : 1,
44660702 7799 "type" : "string"
56122987
DM
7800 },
7801 "snapshot" : {
7aacca6f 7802 "description" : "Whether the drive should be included when making snapshots.",
56122987 7803 "optional" : 1,
44660702 7804 "type" : "boolean"
56122987 7805 },
56122987 7806 "trans" : {
7aacca6f 7807 "description" : "Force disk geometry bios translation mode.",
56122987
DM
7808 "enum" : [
7809 "none",
7810 "lba",
7811 "auto"
7812 ],
7813 "optional" : 1,
44660702 7814 "type" : "string"
56122987 7815 },
44660702
DM
7816 "volume" : {
7817 "alias" : "file"
56122987 7818 },
7aacca6f 7819 "werror" : {
44660702 7820 "description" : "Write error action.",
56122987 7821 "enum" : [
7aacca6f 7822 "enospc",
56122987 7823 "ignore",
7aacca6f
DM
7824 "report",
7825 "stop"
7826 ],
7aacca6f 7827 "optional" : 1,
44660702
DM
7828 "type" : "string"
7829 }
7830 },
7831 "optional" : 1,
4bd7df8b
DM
7832 "type" : "string",
7833 "typetext" : "[file=]<volume> [,aio=<native|threads>] [,backup=<1|0>] [,bps=<bps>] [,bps_rd=<bps>] [,bps_wr=<bps>] [,cache=<none|writethrough|writeback|unsafe|directsync>] [,cyls=<integer>] [,detect_zeroes=<1|0>] [,discard=<ignore|on>] [,format=<image format>] [,heads=<integer>] [,iops=<iops>] [,iops_max=<iops>] [,iops_rd=<iops>] [,iops_rd_max=<iops>] [,iops_wr=<iops>] [,iops_wr_max=<iops>] [,mbps=<mbps>] [,mbps_max=<mbps>] [,mbps_rd=<mbps>] [,mbps_rd_max=<mbps>] [,mbps_wr=<mbps>] [,mbps_wr_max=<mbps>] [,media=<cdrom|disk>] [,rerror=<ignore|report|stop>] [,secs=<integer>] [,serial=<serial>] [,size=<DiskSize>] [,snapshot=<1|0>] [,trans=<none|lba|auto>] [,werror=<enospc|ignore|report|stop>]"
44660702
DM
7834 },
7835 "scsi[n]" : {
7836 "description" : "Use volume as SCSI hard disk or CD-ROM (n is 0 to 13).",
7837 "format" : {
7838 "aio" : {
7aacca6f 7839 "description" : "AIO type to use.",
56122987
DM
7840 "enum" : [
7841 "native",
7842 "threads"
44660702 7843 ],
56122987 7844 "optional" : 1,
44660702 7845 "type" : "string"
56122987 7846 },
7aacca6f 7847 "backup" : {
7aacca6f 7848 "description" : "Whether the drive should be included when making backups.",
7aacca6f 7849 "optional" : 1,
44660702 7850 "type" : "boolean"
56122987 7851 },
44660702
DM
7852 "bps" : {
7853 "description" : "Maximum r/w speed speed in bytes per second.",
7854 "format_description" : "bps",
7aacca6f 7855 "optional" : 1,
44660702 7856 "type" : "integer"
7aacca6f 7857 },
44660702
DM
7858 "bps_rd" : {
7859 "description" : "Maximum read speed speed in bytes per second.",
7860 "format_description" : "bps",
56122987 7861 "optional" : 1,
44660702 7862 "type" : "integer"
56122987 7863 },
44660702
DM
7864 "bps_wr" : {
7865 "description" : "Maximum write speed speed in bytes per second.",
7866 "format_description" : "bps",
56122987 7867 "optional" : 1,
44660702 7868 "type" : "integer"
56122987 7869 },
44660702
DM
7870 "cache" : {
7871 "description" : "The drive's cache mode",
7872 "enum" : [
7873 "none",
7874 "writethrough",
7875 "writeback",
7876 "unsafe",
7877 "directsync"
7878 ],
56122987 7879 "optional" : 1,
44660702
DM
7880 "type" : "string"
7881 },
7882 "cyls" : {
7883 "description" : "Force the drive's physical geometry to have a specific cylinder count.",
44660702
DM
7884 "optional" : 1,
7885 "type" : "integer"
7886 },
7887 "detect_zeroes" : {
7888 "description" : "Controls whether to detect and try to optimize writes of zeroes.",
7889 "optional" : 1,
7890 "type" : "boolean"
7891 },
7892 "discard" : {
7893 "description" : "Controls whether to pass discard/trim requests to the underlying storage.",
7894 "enum" : [
7895 "ignore",
7896 "on"
7897 ],
44660702
DM
7898 "optional" : 1,
7899 "type" : "string"
7900 },
7901 "file" : {
7902 "default_key" : 1,
7903 "description" : "The drive's backing volume.",
7904 "format" : "pve-volume-id-or-qm-path",
7905 "format_description" : "volume",
7906 "type" : "string"
56122987 7907 },
7aacca6f 7908 "format" : {
44660702 7909 "description" : "The drive's backing file's data format.",
7aacca6f
DM
7910 "enum" : [
7911 "raw",
7912 "cow",
7913 "qcow",
7914 "qed",
7915 "qcow2",
7916 "vmdk",
7917 "cloop"
7918 ],
f004f5b9 7919 "format_description" : "image format",
56122987 7920 "optional" : 1,
44660702 7921 "type" : "string"
56122987 7922 },
44660702
DM
7923 "heads" : {
7924 "description" : "Force the drive's physical geometry to have a specific head count.",
56122987 7925 "optional" : 1,
44660702 7926 "type" : "integer"
56122987 7927 },
44660702
DM
7928 "iops" : {
7929 "description" : "Maximum r/w I/O speed in operations per second.",
7930 "format_description" : "iops",
7aacca6f 7931 "optional" : 1,
44660702 7932 "type" : "integer"
56122987 7933 },
44660702
DM
7934 "iops_max" : {
7935 "description" : "Maximum unthrottled r/w I/O pool speed in operations per second.",
7aacca6f 7936 "format_description" : "iops",
7aacca6f 7937 "optional" : 1,
44660702 7938 "type" : "integer"
56122987 7939 },
44660702
DM
7940 "iops_rd" : {
7941 "description" : "Maximum read I/O speed in operations per second.",
7942 "format_description" : "iops",
56122987 7943 "optional" : 1,
44660702 7944 "type" : "integer"
56122987 7945 },
44660702
DM
7946 "iops_rd_max" : {
7947 "description" : "Maximum unthrottled read I/O pool speed in operations per second.",
7948 "format_description" : "iops",
56122987 7949 "optional" : 1,
44660702 7950 "type" : "integer"
56122987 7951 },
44660702
DM
7952 "iops_wr" : {
7953 "description" : "Maximum write I/O speed in operations per second.",
7954 "format_description" : "iops",
56122987 7955 "optional" : 1,
44660702 7956 "type" : "integer"
56122987 7957 },
44660702
DM
7958 "iops_wr_max" : {
7959 "description" : "Maximum unthrottled write I/O pool speed in operations per second.",
7aacca6f 7960 "format_description" : "iops",
44660702
DM
7961 "optional" : 1,
7962 "type" : "integer"
7aacca6f
DM
7963 },
7964 "iothread" : {
44660702 7965 "description" : "Whether to use iothreads for this drive",
56122987 7966 "optional" : 1,
44660702 7967 "type" : "boolean"
56122987 7968 },
44660702
DM
7969 "mbps" : {
7970 "description" : "Maximum r/w speed speed in megabytes per second.",
7971 "format_description" : "mbps",
56122987 7972 "optional" : 1,
44660702 7973 "type" : "number"
56122987 7974 },
44660702
DM
7975 "mbps_max" : {
7976 "description" : "Maximum unthrottled r/w pool speed in megabytes per second.",
7977 "format_description" : "mbps",
56122987 7978 "optional" : 1,
44660702 7979 "type" : "number"
56122987 7980 },
44660702
DM
7981 "mbps_rd" : {
7982 "description" : "Maximum read speed speed in megabytes per second.",
7983 "format_description" : "mbps",
7aacca6f 7984 "optional" : 1,
44660702 7985 "type" : "number"
56122987 7986 },
44660702
DM
7987 "mbps_rd_max" : {
7988 "description" : "Maximum unthrottled read pool speed in megabytes per second.",
7989 "format_description" : "mbps",
7aacca6f 7990 "optional" : 1,
44660702 7991 "type" : "number"
7aacca6f 7992 },
44660702
DM
7993 "mbps_wr" : {
7994 "description" : "Maximum write speed speed in megabytes per second.",
7995 "format_description" : "mbps",
56122987 7996 "optional" : 1,
44660702 7997 "type" : "number"
56122987 7998 },
44660702
DM
7999 "mbps_wr_max" : {
8000 "description" : "Maximum unthrottled write pool speed in megabytes per second.",
8001 "format_description" : "mbps",
56122987 8002 "optional" : 1,
44660702
DM
8003 "type" : "number"
8004 },
8005 "media" : {
8006 "default" : "disk",
8007 "description" : "The drive's media type.",
7aacca6f 8008 "enum" : [
44660702
DM
8009 "cdrom",
8010 "disk"
7aacca6f 8011 ],
56122987 8012 "optional" : 1,
44660702 8013 "type" : "string"
56122987 8014 },
7aacca6f 8015 "queues" : {
44660702 8016 "description" : "Number of queues.",
7aacca6f 8017 "minimum" : 2,
7aacca6f
DM
8018 "optional" : 1,
8019 "type" : "integer"
56122987 8020 },
44660702
DM
8021 "secs" : {
8022 "description" : "Force the drive's physical geometry to have a specific sector count.",
56122987 8023 "optional" : 1,
44660702 8024 "type" : "integer"
56122987 8025 },
44660702
DM
8026 "serial" : {
8027 "description" : "The drive's reported serial number, url-encoded, up to 20 bytes long.",
8028 "format" : "urlencoded",
8029 "format_description" : "serial",
8030 "maxLength" : 60,
56122987 8031 "optional" : 1,
44660702 8032 "type" : "string"
56122987 8033 },
44660702
DM
8034 "size" : {
8035 "description" : "Disk size. This is purely informational and has no effect.",
8036 "format" : "disk-size",
f004f5b9 8037 "format_description" : "DiskSize",
44660702
DM
8038 "optional" : 1,
8039 "type" : "string"
8040 },
8041 "snapshot" : {
8042 "description" : "Whether the drive should be included when making snapshots.",
56122987 8043 "optional" : 1,
44660702
DM
8044 "type" : "boolean"
8045 },
8046 "trans" : {
8047 "description" : "Force disk geometry bios translation mode.",
56122987 8048 "enum" : [
44660702
DM
8049 "none",
8050 "lba",
8051 "auto"
56122987 8052 ],
44660702
DM
8053 "optional" : 1,
8054 "type" : "string"
8055 },
8056 "volume" : {
8057 "alias" : "file"
56122987 8058 },
7aacca6f 8059 "werror" : {
7aacca6f
DM
8060 "description" : "Write error action.",
8061 "enum" : [
8062 "enospc",
8063 "ignore",
8064 "report",
8065 "stop"
44660702 8066 ],
56122987 8067 "optional" : 1,
7aacca6f 8068 "type" : "string"
56122987 8069 }
44660702 8070 },
56122987 8071 "optional" : 1,
4bd7df8b
DM
8072 "type" : "string",
8073 "typetext" : "[file=]<volume> [,aio=<native|threads>] [,backup=<1|0>] [,bps=<bps>] [,bps_rd=<bps>] [,bps_wr=<bps>] [,cache=<none|writethrough|writeback|unsafe|directsync>] [,cyls=<integer>] [,detect_zeroes=<1|0>] [,discard=<ignore|on>] [,format=<image format>] [,heads=<integer>] [,iops=<iops>] [,iops_max=<iops>] [,iops_rd=<iops>] [,iops_rd_max=<iops>] [,iops_wr=<iops>] [,iops_wr_max=<iops>] [,iothread=<1|0>] [,mbps=<mbps>] [,mbps_max=<mbps>] [,mbps_rd=<mbps>] [,mbps_rd_max=<mbps>] [,mbps_wr=<mbps>] [,mbps_wr_max=<mbps>] [,media=<cdrom|disk>] [,queues=<integer>] [,secs=<integer>] [,serial=<serial>] [,size=<DiskSize>] [,snapshot=<1|0>] [,trans=<none|lba|auto>] [,werror=<enospc|ignore|report|stop>]"
56122987
DM
8074 },
8075 "scsihw" : {
44660702 8076 "default" : "lsi",
c2993fe5 8077 "description" : "SCSI controller model",
56122987
DM
8078 "enum" : [
8079 "lsi",
8080 "lsi53c810",
8081 "virtio-scsi-pci",
8082 "virtio-scsi-single",
8083 "megasas",
8084 "pvscsi"
8085 ],
8086 "optional" : 1,
56122987
DM
8087 "type" : "string"
8088 },
44660702 8089 "serial[n]" : {
c2993fe5 8090 "description" : "Create a serial device inside the VM (n is 0 to 3)",
56122987 8091 "optional" : 1,
44660702 8092 "pattern" : "(/dev/.+|socket)",
c2993fe5 8093 "type" : "string",
57b78691 8094 "verbose_description" : "Create a serial device inside the VM (n is 0 to 3), and pass through a\nhost serial device (i.e. /dev/ttyS0), or create a unix socket on the\nhost 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\nCAUTION: Experimental! User reported problems with this option.\n"
56122987 8095 },
44660702
DM
8096 "shares" : {
8097 "default" : 1000,
8098 "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",
8099 "maximum" : 50000,
8100 "minimum" : 0,
7aacca6f 8101 "optional" : 1,
4bd7df8b 8102 "type" : "integer",
2c0dde61 8103 "typetext" : "integer (0 - 50000)"
56122987 8104 },
7aacca6f
DM
8105 "skiplock" : {
8106 "description" : "Ignore locks - only root is allowed to use this option.",
44660702
DM
8107 "optional" : 1,
8108 "type" : "boolean"
56122987 8109 },
44660702
DM
8110 "smbios1" : {
8111 "description" : "Specify SMBIOS type 1 fields.",
8112 "format" : "pve-qm-smbios1",
8113 "maxLength" : 256,
56122987 8114 "optional" : 1,
4bd7df8b
DM
8115 "type" : "string",
8116 "typetext" : "[family=<string>] [,manufacturer=<string>] [,product=<string>] [,serial=<string>] [,sku=<string>] [,uuid=<UUID>] [,version=<string>]"
56122987 8117 },
44660702
DM
8118 "smp" : {
8119 "default" : 1,
8120 "description" : "The number of CPUs. Please use option -sockets instead.",
8121 "minimum" : 1,
56122987 8122 "optional" : 1,
4bd7df8b 8123 "type" : "integer",
2c0dde61 8124 "typetext" : "integer (1 - N)"
56122987 8125 },
44660702
DM
8126 "sockets" : {
8127 "default" : 1,
8128 "description" : "The number of CPU sockets.",
8129 "minimum" : 1,
56122987 8130 "optional" : 1,
4bd7df8b 8131 "type" : "integer",
2c0dde61 8132 "typetext" : "integer (1 - N)"
56122987 8133 },
44660702
DM
8134 "startdate" : {
8135 "default" : "now",
8136 "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'.",
8137 "optional" : 1,
8138 "pattern" : "(now|\\d{4}-\\d{1,2}-\\d{1,2}(T\\d{1,2}:\\d{1,2}:\\d{1,2})?)",
7aacca6f 8139 "type" : "string",
44660702
DM
8140 "typetext" : "(now | YYYY-MM-DD | YYYY-MM-DDTHH:MM:SS)"
8141 },
8142 "startup" : {
8143 "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.",
8144 "format" : "pve-startup-order",
7aacca6f 8145 "optional" : 1,
44660702
DM
8146 "type" : "string",
8147 "typetext" : "[[order=]\\d+] [,up=\\d+] [,down=\\d+] "
7aacca6f 8148 },
44660702
DM
8149 "tablet" : {
8150 "default" : 1,
c2993fe5 8151 "description" : "Enable/disable the USB tablet device.",
7aacca6f 8152 "optional" : 1,
c2993fe5
DM
8153 "type" : "boolean",
8154 "verbose_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)."
7aacca6f 8155 },
44660702
DM
8156 "tdf" : {
8157 "default" : 0,
8158 "description" : "Enable/disable time drift fix.",
7aacca6f 8159 "optional" : 1,
44660702 8160 "type" : "boolean"
7aacca6f 8161 },
44660702
DM
8162 "template" : {
8163 "default" : 0,
8164 "description" : "Enable/disable Template.",
7aacca6f 8165 "optional" : 1,
44660702 8166 "type" : "boolean"
7aacca6f 8167 },
44660702 8168 "unused[n]" : {
c2993fe5 8169 "description" : "Reference to unused volumes. This is used internally, and should not be modified manually.",
44660702 8170 "format" : "pve-volume-id",
7aacca6f
DM
8171 "optional" : 1,
8172 "type" : "string"
8173 },
44660702 8174 "usb[n]" : {
c2993fe5 8175 "description" : "Configure an USB device (n is 0 to 4).",
56122987 8176 "format" : {
44660702
DM
8177 "host" : {
8178 "default_key" : 1,
c2993fe5 8179 "description" : "The Host USB device or port or the value 'spice'. 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",
44660702
DM
8180 "format" : "pve-qm-usb-device",
8181 "format_description" : "HOSTUSBDEVICE|spice",
8182 "type" : "string"
7aacca6f 8183 },
44660702 8184 "usb3" : {
c2993fe5
DM
8185 "default" : 0,
8186 "description" : "Specifies whether if given host option is a USB3 device or port (this does currently not work reliably with spice redirection and is then ignored).",
7aacca6f 8187 "optional" : 1,
44660702 8188 "type" : "boolean"
7aacca6f 8189 }
44660702 8190 },
7aacca6f 8191 "optional" : 1,
4bd7df8b
DM
8192 "type" : "string",
8193 "typetext" : "[host=]<HOSTUSBDEVICE|spice> [,usb3=<1|0>]"
7aacca6f 8194 },
44660702 8195 "vcpus" : {
7aacca6f 8196 "default" : 0,
44660702
DM
8197 "description" : "Number of hotplugged vcpus.",
8198 "minimum" : 1,
7aacca6f 8199 "optional" : 1,
4bd7df8b 8200 "type" : "integer",
2c0dde61 8201 "typetext" : "integer (1 - N)"
7aacca6f 8202 },
44660702 8203 "vga" : {
c2993fe5 8204 "description" : "Select the VGA type.",
44660702
DM
8205 "enum" : [
8206 "std",
8207 "cirrus",
8208 "vmware",
8209 "qxl",
8210 "serial0",
8211 "serial1",
8212 "serial2",
8213 "serial3",
8214 "qxl2",
8215 "qxl3",
8216 "qxl4"
8217 ],
7aacca6f 8218 "optional" : 1,
c2993fe5
DM
8219 "type" : "string",
8220 "verbose_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."
7aacca6f 8221 },
44660702
DM
8222 "virtio[n]" : {
8223 "description" : "Use volume as VIRTIO hard disk (n is 0 to 15).",
7aacca6f 8224 "format" : {
7aacca6f 8225 "aio" : {
7aacca6f 8226 "description" : "AIO type to use.",
56122987 8227 "enum" : [
7aacca6f
DM
8228 "native",
8229 "threads"
7aacca6f 8230 ],
44660702
DM
8231 "optional" : 1,
8232 "type" : "string"
56122987 8233 },
44660702
DM
8234 "backup" : {
8235 "description" : "Whether the drive should be included when making backups.",
56122987 8236 "optional" : 1,
44660702 8237 "type" : "boolean"
7aacca6f 8238 },
44660702
DM
8239 "bps" : {
8240 "description" : "Maximum r/w speed speed in bytes per second.",
8241 "format_description" : "bps",
7aacca6f 8242 "optional" : 1,
44660702 8243 "type" : "integer"
56122987
DM
8244 },
8245 "bps_rd" : {
7aacca6f 8246 "description" : "Maximum read speed speed in bytes per second.",
44660702 8247 "format_description" : "bps",
56122987 8248 "optional" : 1,
7aacca6f 8249 "type" : "integer"
56122987 8250 },
44660702
DM
8251 "bps_wr" : {
8252 "description" : "Maximum write speed speed in bytes per second.",
8253 "format_description" : "bps",
56122987 8254 "optional" : 1,
7aacca6f 8255 "type" : "integer"
56122987 8256 },
7aacca6f 8257 "cache" : {
44660702 8258 "description" : "The drive's cache mode",
7aacca6f
DM
8259 "enum" : [
8260 "none",
8261 "writethrough",
8262 "writeback",
8263 "unsafe",
8264 "directsync"
8265 ],
56122987 8266 "optional" : 1,
44660702 8267 "type" : "string"
7aacca6f 8268 },
44660702
DM
8269 "cyls" : {
8270 "description" : "Force the drive's physical geometry to have a specific cylinder count.",
44660702
DM
8271 "optional" : 1,
8272 "type" : "integer"
8273 },
8274 "detect_zeroes" : {
8275 "description" : "Controls whether to detect and try to optimize writes of zeroes.",
8276 "optional" : 1,
8277 "type" : "boolean"
8278 },
8279 "discard" : {
8280 "description" : "Controls whether to pass discard/trim requests to the underlying storage.",
56122987 8281 "enum" : [
44660702
DM
8282 "ignore",
8283 "on"
56122987
DM
8284 ],
8285 "optional" : 1,
44660702 8286 "type" : "string"
56122987 8287 },
44660702
DM
8288 "file" : {
8289 "default_key" : 1,
8290 "description" : "The drive's backing volume.",
8291 "format" : "pve-volume-id-or-qm-path",
8292 "format_description" : "volume",
8293 "type" : "string"
8294 },
8295 "format" : {
8296 "description" : "The drive's backing file's data format.",
8297 "enum" : [
8298 "raw",
8299 "cow",
8300 "qcow",
8301 "qed",
8302 "qcow2",
8303 "vmdk",
8304 "cloop"
8305 ],
f004f5b9 8306 "format_description" : "image format",
56122987 8307 "optional" : 1,
44660702 8308 "type" : "string"
56122987 8309 },
44660702
DM
8310 "heads" : {
8311 "description" : "Force the drive's physical geometry to have a specific head count.",
44660702
DM
8312 "optional" : 1,
8313 "type" : "integer"
8314 },
8315 "iops" : {
8316 "description" : "Maximum r/w I/O speed in operations per second.",
8317 "format_description" : "iops",
56122987 8318 "optional" : 1,
44660702
DM
8319 "type" : "integer"
8320 },
8321 "iops_max" : {
7aacca6f 8322 "description" : "Maximum unthrottled r/w I/O pool speed in operations per second.",
44660702
DM
8323 "format_description" : "iops",
8324 "optional" : 1,
8325 "type" : "integer"
56122987 8326 },
7aacca6f 8327 "iops_rd" : {
44660702 8328 "description" : "Maximum read I/O speed in operations per second.",
7aacca6f 8329 "format_description" : "iops",
7aacca6f 8330 "optional" : 1,
44660702 8331 "type" : "integer"
56122987 8332 },
44660702
DM
8333 "iops_rd_max" : {
8334 "description" : "Maximum unthrottled read I/O pool speed in operations per second.",
8335 "format_description" : "iops",
8336 "optional" : 1,
8337 "type" : "integer"
8338 },
8339 "iops_wr" : {
8340 "description" : "Maximum write I/O speed in operations per second.",
8341 "format_description" : "iops",
8342 "optional" : 1,
8343 "type" : "integer"
8344 },
8345 "iops_wr_max" : {
8346 "description" : "Maximum unthrottled write I/O pool speed in operations per second.",
8347 "format_description" : "iops",
8348 "optional" : 1,
8349 "type" : "integer"
8350 },
8351 "iothread" : {
8352 "description" : "Whether to use iothreads for this drive",
44660702
DM
8353 "optional" : 1,
8354 "type" : "boolean"
8355 },
8356 "mbps" : {
8357 "description" : "Maximum r/w speed speed in megabytes per second.",
8358 "format_description" : "mbps",
7aacca6f 8359 "optional" : 1,
44660702 8360 "type" : "number"
7aacca6f
DM
8361 },
8362 "mbps_max" : {
8363 "description" : "Maximum unthrottled r/w pool speed in megabytes per second.",
44660702 8364 "format_description" : "mbps",
56122987 8365 "optional" : 1,
44660702 8366 "type" : "number"
56122987 8367 },
44660702
DM
8368 "mbps_rd" : {
8369 "description" : "Maximum read speed speed in megabytes per second.",
8370 "format_description" : "mbps",
56122987 8371 "optional" : 1,
44660702 8372 "type" : "number"
56122987 8373 },
44660702
DM
8374 "mbps_rd_max" : {
8375 "description" : "Maximum unthrottled read pool speed in megabytes per second.",
8376 "format_description" : "mbps",
8377 "optional" : 1,
8378 "type" : "number"
8379 },
8380 "mbps_wr" : {
8381 "description" : "Maximum write speed speed in megabytes per second.",
8382 "format_description" : "mbps",
8383 "optional" : 1,
8384 "type" : "number"
8385 },
8386 "mbps_wr_max" : {
8387 "description" : "Maximum unthrottled write pool speed in megabytes per second.",
8388 "format_description" : "mbps",
8389 "optional" : 1,
8390 "type" : "number"
8391 },
8392 "media" : {
8393 "default" : "disk",
8394 "description" : "The drive's media type.",
56122987 8395 "enum" : [
44660702
DM
8396 "cdrom",
8397 "disk"
56122987
DM
8398 ],
8399 "optional" : 1,
44660702 8400 "type" : "string"
56122987 8401 },
44660702
DM
8402 "rerror" : {
8403 "description" : "Read error action.",
8404 "enum" : [
8405 "ignore",
8406 "report",
8407 "stop"
8408 ],
56122987 8409 "optional" : 1,
44660702 8410 "type" : "string"
56122987 8411 },
44660702
DM
8412 "secs" : {
8413 "description" : "Force the drive's physical geometry to have a specific sector count.",
56122987 8414 "optional" : 1,
44660702 8415 "type" : "integer"
56122987 8416 },
7aacca6f
DM
8417 "serial" : {
8418 "description" : "The drive's reported serial number, url-encoded, up to 20 bytes long.",
7aacca6f 8419 "format" : "urlencoded",
44660702 8420 "format_description" : "serial",
7aacca6f 8421 "maxLength" : 60,
44660702
DM
8422 "optional" : 1,
8423 "type" : "string"
56122987 8424 },
44660702
DM
8425 "size" : {
8426 "description" : "Disk size. This is purely informational and has no effect.",
8427 "format" : "disk-size",
f004f5b9 8428 "format_description" : "DiskSize",
44660702
DM
8429 "optional" : 1,
8430 "type" : "string"
56122987 8431 },
44660702
DM
8432 "snapshot" : {
8433 "description" : "Whether the drive should be included when making snapshots.",
56122987 8434 "optional" : 1,
44660702 8435 "type" : "boolean"
56122987 8436 },
44660702
DM
8437 "trans" : {
8438 "description" : "Force disk geometry bios translation mode.",
8439 "enum" : [
8440 "none",
8441 "lba",
8442 "auto"
8443 ],
7aacca6f 8444 "optional" : 1,
44660702 8445 "type" : "string"
7aacca6f 8446 },
44660702
DM
8447 "volume" : {
8448 "alias" : "file"
8449 },
8450 "werror" : {
8451 "description" : "Write error action.",
8452 "enum" : [
8453 "enospc",
8454 "ignore",
8455 "report",
8456 "stop"
8457 ],
7aacca6f 8458 "optional" : 1,
44660702 8459 "type" : "string"
56122987
DM
8460 }
8461 },
7aacca6f 8462 "optional" : 1,
4bd7df8b
DM
8463 "type" : "string",
8464 "typetext" : "[file=]<volume> [,aio=<native|threads>] [,backup=<1|0>] [,bps=<bps>] [,bps_rd=<bps>] [,bps_wr=<bps>] [,cache=<none|writethrough|writeback|unsafe|directsync>] [,cyls=<integer>] [,detect_zeroes=<1|0>] [,discard=<ignore|on>] [,format=<image format>] [,heads=<integer>] [,iops=<iops>] [,iops_max=<iops>] [,iops_rd=<iops>] [,iops_rd_max=<iops>] [,iops_wr=<iops>] [,iops_wr_max=<iops>] [,iothread=<1|0>] [,mbps=<mbps>] [,mbps_max=<mbps>] [,mbps_rd=<mbps>] [,mbps_rd_max=<mbps>] [,mbps_wr=<mbps>] [,mbps_wr_max=<mbps>] [,media=<cdrom|disk>] [,rerror=<ignore|report|stop>] [,secs=<integer>] [,serial=<serial>] [,size=<DiskSize>] [,snapshot=<1|0>] [,trans=<none|lba|auto>] [,werror=<enospc|ignore|report|stop>]"
7aacca6f 8465 },
44660702
DM
8466 "vmid" : {
8467 "description" : "The (unique) ID of the VM.",
8468 "format" : "pve-vmid",
8469 "minimum" : 1,
4bd7df8b 8470 "type" : "integer",
2c0dde61 8471 "typetext" : "integer (1 - N)"
56122987 8472 },
44660702 8473 "watchdog" : {
c2993fe5 8474 "description" : "Create a virtual hardware watchdog device.",
44660702 8475 "format" : "pve-qm-watchdog",
56122987 8476 "optional" : 1,
c2993fe5 8477 "type" : "string",
4bd7df8b 8478 "typetext" : "[[model=]<i6300esb|ib700>] [,action=<reset|shutdown|poweroff|pause|debug|none>]",
c2993fe5 8479 "verbose_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)"
56122987 8480 }
7aacca6f 8481 }
56122987 8482 },
56122987
DM
8483 "permissions" : {
8484 "check" : [
8485 "perm",
8486 "/vms/{vmid}",
8487 [
8488 "VM.Config.Disk",
8489 "VM.Config.CDROM",
8490 "VM.Config.CPU",
8491 "VM.Config.Memory",
8492 "VM.Config.Network",
8493 "VM.Config.HWType",
8494 "VM.Config.Options"
8495 ],
8496 "any",
8497 1
8498 ]
8499 },
44660702 8500 "protected" : 1,
7aacca6f 8501 "proxyto" : "node",
56122987 8502 "returns" : {
7aacca6f
DM
8503 "type" : "null"
8504 }
8505 }
8506 },
44660702
DM
8507 "leaf" : 1,
8508 "path" : "/nodes/{node}/qemu/{vmid}/config",
7aacca6f
DM
8509 "text" : "config"
8510 },
8511 {
8512 "info" : {
56122987 8513 "GET" : {
44660702 8514 "description" : "Get virtual machine configuration, including pending changes.",
56122987 8515 "method" : "GET",
44660702 8516 "name" : "vm_pending",
7aacca6f 8517 "parameters" : {
44660702 8518 "additionalProperties" : 0,
7aacca6f
DM
8519 "properties" : {
8520 "node" : {
7aacca6f 8521 "description" : "The cluster node name.",
44660702 8522 "format" : "pve-node",
7aacca6f
DM
8523 "type" : "string"
8524 },
8525 "vmid" : {
44660702 8526 "description" : "The (unique) ID of the VM.",
7aacca6f 8527 "format" : "pve-vmid",
44660702 8528 "minimum" : 1,
4bd7df8b 8529 "type" : "integer",
2c0dde61 8530 "typetext" : "integer (1 - N)"
7aacca6f 8531 }
44660702 8532 }
7aacca6f 8533 },
56122987
DM
8534 "permissions" : {
8535 "check" : [
8536 "perm",
8537 "/vms/{vmid}",
8538 [
8539 "VM.Audit"
8540 ]
8541 ]
8542 },
7aacca6f 8543 "proxyto" : "node",
44660702
DM
8544 "returns" : {
8545 "items" : {
8546 "properties" : {
8547 "delete" : {
8548 "description" : "Indicates a pending delete request if present and not 0. The value 2 indicates a force-delete request.",
8549 "maximum" : 2,
8550 "minimum" : 0,
8551 "optional" : 1,
8552 "type" : "integer"
8553 },
8554 "key" : {
8555 "description" : "Configuration option name.",
8556 "type" : "string"
8557 },
8558 "pending" : {
8559 "description" : "Pending value.",
8560 "optional" : 1,
8561 "type" : "string"
8562 },
8563 "value" : {
8564 "description" : "Current value.",
8565 "optional" : 1,
8566 "type" : "string"
8567 }
8568 },
8569 "type" : "object"
8570 },
8571 "type" : "array"
8572 }
56122987
DM
8573 }
8574 },
7aacca6f 8575 "leaf" : 1,
44660702
DM
8576 "path" : "/nodes/{node}/qemu/{vmid}/pending",
8577 "text" : "pending"
56122987
DM
8578 },
8579 {
56122987
DM
8580 "info" : {
8581 "PUT" : {
7aacca6f 8582 "description" : "Unlink/delete disk images.",
7aacca6f 8583 "method" : "PUT",
7aacca6f 8584 "name" : "unlink",
56122987 8585 "parameters" : {
44660702 8586 "additionalProperties" : 0,
56122987 8587 "properties" : {
7aacca6f 8588 "force" : {
44660702 8589 "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.",
7aacca6f 8590 "optional" : 1,
44660702 8591 "type" : "boolean"
7aacca6f 8592 },
56122987
DM
8593 "idlist" : {
8594 "description" : "A list of disk IDs you want to delete.",
44660702
DM
8595 "format" : "pve-configid-list",
8596 "type" : "string"
8597 },
8598 "node" : {
8599 "description" : "The cluster node name.",
8600 "format" : "pve-node",
8601 "type" : "string"
56122987
DM
8602 },
8603 "vmid" : {
7aacca6f 8604 "description" : "The (unique) ID of the VM.",
44660702 8605 "format" : "pve-vmid",
7aacca6f 8606 "minimum" : 1,
4bd7df8b 8607 "type" : "integer",
2c0dde61 8608 "typetext" : "integer (1 - N)"
56122987 8609 }
44660702
DM
8610 }
8611 },
8612 "permissions" : {
8613 "check" : [
8614 "perm",
8615 "/vms/{vmid}",
8616 [
8617 "VM.Config.Disk"
8618 ]
8619 ]
8620 },
8621 "protected" : 1,
8622 "proxyto" : "node",
8623 "returns" : {
8624 "type" : "null"
7aacca6f 8625 }
56122987 8626 }
7aacca6f 8627 },
44660702 8628 "leaf" : 1,
7aacca6f 8629 "path" : "/nodes/{node}/qemu/{vmid}/unlink",
44660702 8630 "text" : "unlink"
56122987
DM
8631 },
8632 {
56122987
DM
8633 "info" : {
8634 "POST" : {
7aacca6f 8635 "description" : "Creates a TCP VNC proxy connections.",
44660702
DM
8636 "method" : "POST",
8637 "name" : "vncproxy",
56122987 8638 "parameters" : {
44660702 8639 "additionalProperties" : 0,
56122987 8640 "properties" : {
44660702
DM
8641 "node" : {
8642 "description" : "The cluster node name.",
8643 "format" : "pve-node",
8644 "type" : "string"
8645 },
56122987 8646 "vmid" : {
7aacca6f 8647 "description" : "The (unique) ID of the VM.",
44660702 8648 "format" : "pve-vmid",
56122987 8649 "minimum" : 1,
4bd7df8b 8650 "type" : "integer",
2c0dde61 8651 "typetext" : "integer (1 - N)"
7aacca6f
DM
8652 },
8653 "websocket" : {
8654 "description" : "starts websockify instead of vncproxy",
44660702
DM
8655 "optional" : 1,
8656 "type" : "boolean"
56122987 8657 }
44660702 8658 }
56122987 8659 },
44660702
DM
8660 "permissions" : {
8661 "check" : [
8662 "perm",
8663 "/vms/{vmid}",
8664 [
8665 "VM.Console"
8666 ]
8667 ]
8668 },
8669 "protected" : 1,
56122987 8670 "returns" : {
7aacca6f 8671 "additionalProperties" : 0,
56122987 8672 "properties" : {
7aacca6f 8673 "cert" : {
56122987
DM
8674 "type" : "string"
8675 },
56122987
DM
8676 "port" : {
8677 "type" : "integer"
8678 },
7aacca6f
DM
8679 "ticket" : {
8680 "type" : "string"
8681 },
44660702
DM
8682 "upid" : {
8683 "type" : "string"
8684 },
7aacca6f 8685 "user" : {
56122987
DM
8686 "type" : "string"
8687 }
7aacca6f 8688 }
56122987
DM
8689 }
8690 }
8691 },
44660702
DM
8692 "leaf" : 1,
8693 "path" : "/nodes/{node}/qemu/{vmid}/vncproxy",
7aacca6f 8694 "text" : "vncproxy"
56122987
DM
8695 },
8696 {
56122987
DM
8697 "info" : {
8698 "GET" : {
44660702
DM
8699 "description" : "Opens a weksocket for VNC traffic.",
8700 "method" : "GET",
8701 "name" : "vncwebsocket",
56122987 8702 "parameters" : {
44660702 8703 "additionalProperties" : 0,
56122987 8704 "properties" : {
7aacca6f 8705 "node" : {
7aacca6f 8706 "description" : "The cluster node name.",
44660702 8707 "format" : "pve-node",
7aacca6f
DM
8708 "type" : "string"
8709 },
44660702
DM
8710 "port" : {
8711 "description" : "Port number returned by previous vncproxy call.",
8712 "maximum" : 5999,
8713 "minimum" : 5900,
4bd7df8b 8714 "type" : "integer",
2c0dde61 8715 "typetext" : "integer (5900 - 5999)"
56122987 8716 },
7aacca6f 8717 "vmid" : {
44660702 8718 "description" : "The (unique) ID of the VM.",
7aacca6f
DM
8719 "format" : "pve-vmid",
8720 "minimum" : 1,
4bd7df8b 8721 "type" : "integer",
2c0dde61 8722 "typetext" : "integer (1 - N)"
44660702
DM
8723 },
8724 "vncticket" : {
8725 "description" : "Ticket from previous call to vncproxy.",
8726 "maxLength" : 512,
8727 "type" : "string"
56122987 8728 }
44660702
DM
8729 }
8730 },
8731 "permissions" : {
8732 "check" : [
8733 "perm",
8734 "/vms/{vmid}",
8735 [
8736 "VM.Console"
8737 ]
8738 ],
8739 "description" : "You also need to pass a valid ticket (vncticket)."
56122987 8740 },
7aacca6f
DM
8741 "returns" : {
8742 "properties" : {
8743 "port" : {
8744 "type" : "string"
8745 }
8746 },
8747 "type" : "object"
8748 }
56122987
DM
8749 }
8750 },
7aacca6f 8751 "leaf" : 1,
44660702
DM
8752 "path" : "/nodes/{node}/qemu/{vmid}/vncwebsocket",
8753 "text" : "vncwebsocket"
56122987
DM
8754 },
8755 {
8756 "info" : {
8757 "POST" : {
44660702
DM
8758 "description" : "Returns a SPICE configuration to connect to the VM.",
8759 "method" : "POST",
7aacca6f
DM
8760 "name" : "spiceproxy",
8761 "parameters" : {
44660702 8762 "additionalProperties" : 0,
56122987 8763 "properties" : {
44660702
DM
8764 "node" : {
8765 "description" : "The cluster node name.",
8766 "format" : "pve-node",
8767 "type" : "string"
8768 },
7aacca6f 8769 "proxy" : {
44660702 8770 "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).",
7aacca6f 8771 "format" : "address",
7aacca6f 8772 "optional" : 1,
44660702 8773 "type" : "string"
56122987 8774 },
7aacca6f 8775 "vmid" : {
44660702 8776 "description" : "The (unique) ID of the VM.",
7aacca6f
DM
8777 "format" : "pve-vmid",
8778 "minimum" : 1,
4bd7df8b 8779 "type" : "integer",
2c0dde61 8780 "typetext" : "integer (1 - N)"
56122987 8781 }
44660702 8782 }
56122987 8783 },
56122987
DM
8784 "permissions" : {
8785 "check" : [
8786 "perm",
8787 "/vms/{vmid}",
8788 [
8789 "VM.Console"
8790 ]
8791 ]
8792 },
44660702
DM
8793 "protected" : 1,
8794 "proxyto" : "node",
7aacca6f 8795 "returns" : {
44660702
DM
8796 "additionalProperties" : 1,
8797 "description" : "Returned values can be directly passed to the 'remote-viewer' application.",
56122987 8798 "properties" : {
44660702 8799 "host" : {
7aacca6f
DM
8800 "type" : "string"
8801 },
7aacca6f
DM
8802 "password" : {
8803 "type" : "string"
8804 },
44660702 8805 "proxy" : {
7aacca6f
DM
8806 "type" : "string"
8807 },
44660702
DM
8808 "tls-port" : {
8809 "type" : "integer"
8810 },
8811 "type" : {
7aacca6f
DM
8812 "type" : "string"
8813 }
44660702 8814 }
7aacca6f
DM
8815 }
8816 }
8817 },
44660702
DM
8818 "leaf" : 1,
8819 "path" : "/nodes/{node}/qemu/{vmid}/spiceproxy",
7aacca6f
DM
8820 "text" : "spiceproxy"
8821 },
8822 {
56122987
DM
8823 "children" : [
8824 {
56122987
DM
8825 "info" : {
8826 "GET" : {
44660702
DM
8827 "description" : "Get virtual machine status.",
8828 "method" : "GET",
8829 "name" : "vm_status",
56122987 8830 "parameters" : {
44660702 8831 "additionalProperties" : 0,
56122987 8832 "properties" : {
44660702
DM
8833 "node" : {
8834 "description" : "The cluster node name.",
8835 "format" : "pve-node",
8836 "type" : "string"
8837 },
56122987 8838 "vmid" : {
44660702 8839 "description" : "The (unique) ID of the VM.",
7aacca6f 8840 "format" : "pve-vmid",
56122987 8841 "minimum" : 1,
4bd7df8b 8842 "type" : "integer",
2c0dde61 8843 "typetext" : "integer (1 - N)"
56122987 8844 }
44660702 8845 }
56122987
DM
8846 },
8847 "permissions" : {
8848 "check" : [
8849 "perm",
8850 "/vms/{vmid}",
8851 [
8852 "VM.Audit"
8853 ]
8854 ]
8855 },
44660702 8856 "protected" : 1,
7aacca6f 8857 "proxyto" : "node",
56122987
DM
8858 "returns" : {
8859 "type" : "object"
7aacca6f 8860 }
56122987 8861 }
7aacca6f 8862 },
7aacca6f 8863 "leaf" : 1,
44660702
DM
8864 "path" : "/nodes/{node}/qemu/{vmid}/status/current",
8865 "text" : "current"
56122987
DM
8866 },
8867 {
56122987
DM
8868 "info" : {
8869 "POST" : {
44660702 8870 "description" : "Start virtual machine.",
56122987 8871 "method" : "POST",
44660702 8872 "name" : "vm_start",
56122987 8873 "parameters" : {
44660702 8874 "additionalProperties" : 0,
56122987 8875 "properties" : {
44660702
DM
8876 "machine" : {
8877 "description" : "Specific the Qemu machine type.",
8878 "maxLength" : 40,
8879 "optional" : 1,
8880 "pattern" : "(pc|pc(-i440fx)?-\\d+\\.\\d+(\\.pxe)?|q35|pc-q35-\\d+\\.\\d+(\\.pxe)?)",
8881 "type" : "string"
8882 },
8883 "migratedfrom" : {
8884 "description" : "The cluster node name.",
8885 "format" : "pve-node",
56122987 8886 "optional" : 1,
44660702 8887 "type" : "string"
56122987 8888 },
7aacca6f 8889 "node" : {
7aacca6f 8890 "description" : "The cluster node name.",
44660702
DM
8891 "format" : "pve-node",
8892 "type" : "string"
7aacca6f 8893 },
44660702
DM
8894 "skiplock" : {
8895 "description" : "Ignore locks - only root is allowed to use this option.",
7aacca6f 8896 "optional" : 1,
44660702 8897 "type" : "boolean"
56122987 8898 },
44660702
DM
8899 "stateuri" : {
8900 "description" : "Some command save/restore state from this location.",
8901 "maxLength" : 128,
56122987 8902 "optional" : 1,
44660702 8903 "type" : "string"
56122987
DM
8904 },
8905 "vmid" : {
7aacca6f 8906 "description" : "The (unique) ID of the VM.",
44660702
DM
8907 "format" : "pve-vmid",
8908 "minimum" : 1,
4bd7df8b 8909 "type" : "integer",
2c0dde61 8910 "typetext" : "integer (1 - N)"
56122987 8911 }
44660702 8912 }
7aacca6f 8913 },
56122987
DM
8914 "permissions" : {
8915 "check" : [
8916 "perm",
8917 "/vms/{vmid}",
8918 [
8919 "VM.PowerMgmt"
8920 ]
8921 ]
44660702
DM
8922 },
8923 "protected" : 1,
8924 "proxyto" : "node",
8925 "returns" : {
8926 "type" : "string"
56122987
DM
8927 }
8928 }
44660702
DM
8929 },
8930 "leaf" : 1,
8931 "path" : "/nodes/{node}/qemu/{vmid}/status/start",
8932 "text" : "start"
56122987
DM
8933 },
8934 {
56122987
DM
8935 "info" : {
8936 "POST" : {
7aacca6f 8937 "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",
44660702
DM
8938 "method" : "POST",
8939 "name" : "vm_stop",
56122987 8940 "parameters" : {
44660702 8941 "additionalProperties" : 0,
56122987 8942 "properties" : {
44660702
DM
8943 "keepActive" : {
8944 "default" : 0,
8945 "description" : "Do not decativate storage volumes.",
56122987 8946 "optional" : 1,
44660702 8947 "type" : "boolean"
56122987
DM
8948 },
8949 "migratedfrom" : {
56122987 8950 "description" : "The cluster node name.",
44660702 8951 "format" : "pve-node",
7aacca6f 8952 "optional" : 1,
44660702 8953 "type" : "string"
7aacca6f 8954 },
44660702
DM
8955 "node" : {
8956 "description" : "The cluster node name.",
8957 "format" : "pve-node",
8958 "type" : "string"
56122987
DM
8959 },
8960 "skiplock" : {
8961 "description" : "Ignore locks - only root is allowed to use this option.",
8962 "optional" : 1,
8963 "type" : "boolean"
8964 },
44660702
DM
8965 "timeout" : {
8966 "description" : "Wait maximal timeout seconds.",
8967 "minimum" : 0,
56122987 8968 "optional" : 1,
4bd7df8b 8969 "type" : "integer",
2c0dde61 8970 "typetext" : "integer (0 - N)"
7aacca6f 8971 },
44660702
DM
8972 "vmid" : {
8973 "description" : "The (unique) ID of the VM.",
8974 "format" : "pve-vmid",
8975 "minimum" : 1,
4bd7df8b 8976 "type" : "integer",
2c0dde61 8977 "typetext" : "integer (1 - N)"
56122987 8978 }
44660702 8979 }
56122987 8980 },
56122987
DM
8981 "permissions" : {
8982 "check" : [
8983 "perm",
8984 "/vms/{vmid}",
8985 [
8986 "VM.PowerMgmt"
8987 ]
8988 ]
8989 },
44660702
DM
8990 "protected" : 1,
8991 "proxyto" : "node",
7aacca6f
DM
8992 "returns" : {
8993 "type" : "string"
44660702
DM
8994 }
8995 }
8996 },
8997 "leaf" : 1,
8998 "path" : "/nodes/{node}/qemu/{vmid}/status/stop",
8999 "text" : "stop"
9000 },
9001 {
9002 "info" : {
9003 "POST" : {
9004 "description" : "Reset virtual machine.",
9005 "method" : "POST",
9006 "name" : "vm_reset",
56122987 9007 "parameters" : {
7aacca6f 9008 "additionalProperties" : 0,
56122987 9009 "properties" : {
56122987
DM
9010 "node" : {
9011 "description" : "The cluster node name.",
44660702
DM
9012 "format" : "pve-node",
9013 "type" : "string"
56122987
DM
9014 },
9015 "skiplock" : {
44660702 9016 "description" : "Ignore locks - only root is allowed to use this option.",
7aacca6f 9017 "optional" : 1,
44660702 9018 "type" : "boolean"
7aacca6f
DM
9019 },
9020 "vmid" : {
44660702 9021 "description" : "The (unique) ID of the VM.",
7aacca6f
DM
9022 "format" : "pve-vmid",
9023 "minimum" : 1,
4bd7df8b 9024 "type" : "integer",
2c0dde61 9025 "typetext" : "integer (1 - N)"
56122987 9026 }
7aacca6f 9027 }
56122987 9028 },
7aacca6f
DM
9029 "permissions" : {
9030 "check" : [
9031 "perm",
9032 "/vms/{vmid}",
9033 [
9034 "VM.PowerMgmt"
9035 ]
9036 ]
9037 },
44660702 9038 "protected" : 1,
7aacca6f 9039 "proxyto" : "node",
56122987
DM
9040 "returns" : {
9041 "type" : "string"
44660702
DM
9042 }
9043 }
9044 },
9045 "leaf" : 1,
9046 "path" : "/nodes/{node}/qemu/{vmid}/status/reset",
9047 "text" : "reset"
9048 },
9049 {
9050 "info" : {
9051 "POST" : {
9052 "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.",
9053 "method" : "POST",
56122987 9054 "name" : "vm_shutdown",
56122987 9055 "parameters" : {
7aacca6f 9056 "additionalProperties" : 0,
56122987 9057 "properties" : {
56122987 9058 "forceStop" : {
56122987 9059 "default" : 0,
44660702 9060 "description" : "Make sure the VM stops.",
7aacca6f 9061 "optional" : 1,
44660702 9062 "type" : "boolean"
56122987
DM
9063 },
9064 "keepActive" : {
7aacca6f 9065 "default" : 0,
44660702
DM
9066 "description" : "Do not decativate storage volumes.",
9067 "optional" : 1,
9068 "type" : "boolean"
9069 },
9070 "node" : {
9071 "description" : "The cluster node name.",
9072 "format" : "pve-node",
9073 "type" : "string"
9074 },
9075 "skiplock" : {
9076 "description" : "Ignore locks - only root is allowed to use this option.",
9077 "optional" : 1,
9078 "type" : "boolean"
56122987 9079 },
7aacca6f 9080 "timeout" : {
7aacca6f 9081 "description" : "Wait maximal timeout seconds.",
44660702 9082 "minimum" : 0,
7aacca6f 9083 "optional" : 1,
4bd7df8b 9084 "type" : "integer",
2c0dde61 9085 "typetext" : "integer (0 - N)"
7aacca6f 9086 },
56122987 9087 "vmid" : {
7aacca6f 9088 "description" : "The (unique) ID of the VM.",
44660702
DM
9089 "format" : "pve-vmid",
9090 "minimum" : 1,
4bd7df8b 9091 "type" : "integer",
2c0dde61 9092 "typetext" : "integer (1 - N)"
56122987 9093 }
7aacca6f 9094 }
56122987 9095 },
44660702
DM
9096 "permissions" : {
9097 "check" : [
9098 "perm",
9099 "/vms/{vmid}",
9100 [
9101 "VM.PowerMgmt"
9102 ]
9103 ]
9104 },
7aacca6f 9105 "protected" : 1,
44660702
DM
9106 "proxyto" : "node",
9107 "returns" : {
9108 "type" : "string"
9109 }
56122987
DM
9110 }
9111 },
44660702 9112 "leaf" : 1,
7aacca6f 9113 "path" : "/nodes/{node}/qemu/{vmid}/status/shutdown",
44660702 9114 "text" : "shutdown"
56122987
DM
9115 },
9116 {
56122987
DM
9117 "info" : {
9118 "POST" : {
44660702 9119 "description" : "Suspend virtual machine.",
56122987 9120 "method" : "POST",
44660702 9121 "name" : "vm_suspend",
7aacca6f 9122 "parameters" : {
44660702 9123 "additionalProperties" : 0,
7aacca6f
DM
9124 "properties" : {
9125 "node" : {
7aacca6f 9126 "description" : "The cluster node name.",
44660702
DM
9127 "format" : "pve-node",
9128 "type" : "string"
7aacca6f
DM
9129 },
9130 "skiplock" : {
9131 "description" : "Ignore locks - only root is allowed to use this option.",
44660702
DM
9132 "optional" : 1,
9133 "type" : "boolean"
9134 },
9135 "vmid" : {
9136 "description" : "The (unique) ID of the VM.",
9137 "format" : "pve-vmid",
9138 "minimum" : 1,
4bd7df8b 9139 "type" : "integer",
2c0dde61 9140 "typetext" : "integer (1 - N)"
44660702
DM
9141 }
9142 }
56122987
DM
9143 },
9144 "permissions" : {
9145 "check" : [
9146 "perm",
9147 "/vms/{vmid}",
9148 [
9149 "VM.PowerMgmt"
9150 ]
9151 ]
9152 },
44660702
DM
9153 "protected" : 1,
9154 "proxyto" : "node",
9155 "returns" : {
9156 "type" : "string"
9157 }
56122987
DM
9158 }
9159 },
44660702 9160 "leaf" : 1,
7aacca6f 9161 "path" : "/nodes/{node}/qemu/{vmid}/status/suspend",
44660702 9162 "text" : "suspend"
56122987
DM
9163 },
9164 {
56122987
DM
9165 "info" : {
9166 "POST" : {
44660702
DM
9167 "description" : "Resume virtual machine.",
9168 "method" : "POST",
7aacca6f 9169 "name" : "vm_resume",
56122987
DM
9170 "parameters" : {
9171 "additionalProperties" : 0,
9172 "properties" : {
44660702
DM
9173 "nocheck" : {
9174 "optional" : 1,
9175 "type" : "boolean"
9176 },
7aacca6f 9177 "node" : {
44660702 9178 "description" : "The cluster node name.",
7aacca6f 9179 "format" : "pve-node",
44660702 9180 "type" : "string"
56122987
DM
9181 },
9182 "skiplock" : {
56122987 9183 "description" : "Ignore locks - only root is allowed to use this option.",
44660702
DM
9184 "optional" : 1,
9185 "type" : "boolean"
56122987 9186 },
7aacca6f 9187 "vmid" : {
7aacca6f
DM
9188 "description" : "The (unique) ID of the VM.",
9189 "format" : "pve-vmid",
44660702 9190 "minimum" : 1,
4bd7df8b 9191 "type" : "integer",
2c0dde61 9192 "typetext" : "integer (1 - N)"
56122987
DM
9193 }
9194 }
9195 },
9196 "permissions" : {
9197 "check" : [
9198 "perm",
9199 "/vms/{vmid}",
9200 [
9201 "VM.PowerMgmt"
9202 ]
9203 ]
9204 },
44660702
DM
9205 "protected" : 1,
9206 "proxyto" : "node",
56122987
DM
9207 "returns" : {
9208 "type" : "string"
7aacca6f 9209 }
56122987
DM
9210 }
9211 },
44660702
DM
9212 "leaf" : 1,
9213 "path" : "/nodes/{node}/qemu/{vmid}/status/resume",
7aacca6f 9214 "text" : "resume"
56122987
DM
9215 }
9216 ],
9217 "info" : {
44660702
DM
9218 "GET" : {
9219 "description" : "Directory index",
9220 "method" : "GET",
9221 "name" : "vmcmdidx",
56122987 9222 "parameters" : {
44660702 9223 "additionalProperties" : 0,
56122987 9224 "properties" : {
44660702
DM
9225 "node" : {
9226 "description" : "The cluster node name.",
9227 "format" : "pve-node",
7aacca6f
DM
9228 "type" : "string"
9229 },
56122987 9230 "vmid" : {
7aacca6f 9231 "description" : "The (unique) ID of the VM.",
44660702
DM
9232 "format" : "pve-vmid",
9233 "minimum" : 1,
4bd7df8b 9234 "type" : "integer",
2c0dde61 9235 "typetext" : "integer (1 - N)"
56122987 9236 }
44660702 9237 }
56122987 9238 },
44660702
DM
9239 "permissions" : {
9240 "user" : "all"
9241 },
9242 "proxyto" : "node",
9243 "returns" : {
9244 "items" : {
9245 "properties" : {
9246 "subdir" : {
9247 "type" : "string"
9248 }
9249 },
9250 "type" : "object"
9251 },
9252 "links" : [
9253 {
9254 "href" : "{subdir}",
9255 "rel" : "child"
9256 }
9257 ],
9258 "type" : "array"
9259 }
56122987 9260 }
7aacca6f 9261 },
44660702
DM
9262 "leaf" : 0,
9263 "path" : "/nodes/{node}/qemu/{vmid}/status",
9264 "text" : "status"
56122987
DM
9265 },
9266 {
56122987 9267 "info" : {
44660702
DM
9268 "PUT" : {
9269 "description" : "Send key event to virtual machine.",
9270 "method" : "PUT",
9271 "name" : "vm_sendkey",
9272 "parameters" : {
9273 "additionalProperties" : 0,
56122987 9274 "properties" : {
44660702
DM
9275 "key" : {
9276 "description" : "The key (qemu monitor encoding).",
9277 "type" : "string"
9278 },
9279 "node" : {
9280 "description" : "The cluster node name.",
9281 "format" : "pve-node",
9282 "type" : "string"
9283 },
9284 "skiplock" : {
9285 "description" : "Ignore locks - only root is allowed to use this option.",
9286 "optional" : 1,
56122987 9287 "type" : "boolean"
7aacca6f 9288 },
44660702
DM
9289 "vmid" : {
9290 "description" : "The (unique) ID of the VM.",
9291 "format" : "pve-vmid",
9292 "minimum" : 1,
4bd7df8b 9293 "type" : "integer",
2c0dde61 9294 "typetext" : "integer (1 - N)"
56122987 9295 }
7aacca6f 9296 }
56122987 9297 },
56122987
DM
9298 "permissions" : {
9299 "check" : [
9300 "perm",
9301 "/vms/{vmid}",
9302 [
44660702 9303 "VM.Console"
56122987
DM
9304 ]
9305 ]
9306 },
7aacca6f 9307 "protected" : 1,
44660702
DM
9308 "proxyto" : "node",
9309 "returns" : {
9310 "type" : "null"
9311 }
9312 }
9313 },
9314 "leaf" : 1,
9315 "path" : "/nodes/{node}/qemu/{vmid}/sendkey",
9316 "text" : "sendkey"
9317 },
9318 {
9319 "info" : {
9320 "GET" : {
9321 "description" : "Check if feature for virtual machine is available.",
9322 "method" : "GET",
7aacca6f 9323 "name" : "vm_feature",
56122987 9324 "parameters" : {
44660702 9325 "additionalProperties" : 0,
56122987 9326 "properties" : {
56122987 9327 "feature" : {
44660702 9328 "description" : "Feature to check.",
56122987
DM
9329 "enum" : [
9330 "snapshot",
9331 "clone",
9332 "copy"
9333 ],
44660702
DM
9334 "type" : "string"
9335 },
9336 "node" : {
9337 "description" : "The cluster node name.",
9338 "format" : "pve-node",
7aacca6f 9339 "type" : "string"
56122987
DM
9340 },
9341 "snapname" : {
56122987 9342 "description" : "The name of the snapshot.",
44660702
DM
9343 "format" : "pve-configid",
9344 "maxLength" : 40,
7aacca6f
DM
9345 "optional" : 1,
9346 "type" : "string"
9347 },
44660702
DM
9348 "vmid" : {
9349 "description" : "The (unique) ID of the VM.",
9350 "format" : "pve-vmid",
9351 "minimum" : 1,
4bd7df8b 9352 "type" : "integer",
2c0dde61 9353 "typetext" : "integer (1 - N)"
44660702
DM
9354 }
9355 }
9356 },
9357 "permissions" : {
9358 "check" : [
9359 "perm",
9360 "/vms/{vmid}",
9361 [
9362 "VM.Audit"
9363 ]
9364 ]
9365 },
9366 "protected" : 1,
9367 "proxyto" : "node",
9368 "returns" : {
9369 "properties" : {
9370 "hasFeature" : {
9371 "type" : "boolean"
9372 },
9373 "nodes" : {
9374 "items" : {
9375 "type" : "string"
9376 },
9377 "type" : "array"
56122987
DM
9378 }
9379 },
44660702 9380 "type" : "object"
56122987
DM
9381 }
9382 }
9383 },
7aacca6f 9384 "leaf" : 1,
44660702
DM
9385 "path" : "/nodes/{node}/qemu/{vmid}/feature",
9386 "text" : "feature"
56122987
DM
9387 },
9388 {
56122987
DM
9389 "info" : {
9390 "POST" : {
44660702 9391 "description" : "Create a copy of virtual machine/template.",
56122987 9392 "method" : "POST",
7aacca6f 9393 "name" : "clone_vm",
56122987
DM
9394 "parameters" : {
9395 "additionalProperties" : 0,
9396 "properties" : {
44660702
DM
9397 "description" : {
9398 "description" : "Description for the new VM.",
56122987 9399 "optional" : 1,
7aacca6f 9400 "type" : "string"
56122987 9401 },
44660702
DM
9402 "format" : {
9403 "description" : "Target format for file storage.",
9404 "enum" : [
9405 "raw",
9406 "qcow2",
9407 "vmdk"
9408 ],
9409 "optional" : 1,
9410 "requires" : "full",
56122987
DM
9411 "type" : "string"
9412 },
44660702
DM
9413 "full" : {
9414 "default" : 0,
9415 "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.",
7aacca6f 9416 "optional" : 1,
44660702
DM
9417 "type" : "boolean"
9418 },
9419 "name" : {
56122987 9420 "description" : "Set a name for the new VM.",
44660702
DM
9421 "format" : "dns-name",
9422 "optional" : 1,
9423 "type" : "string"
9424 },
9425 "newid" : {
9426 "description" : "VMID for the clone.",
9427 "format" : "pve-vmid",
9428 "minimum" : 1,
4bd7df8b 9429 "type" : "integer",
2c0dde61 9430 "typetext" : "integer (1 - N)"
44660702
DM
9431 },
9432 "node" : {
9433 "description" : "The cluster node name.",
9434 "format" : "pve-node",
9435 "type" : "string"
7aacca6f
DM
9436 },
9437 "pool" : {
9438 "description" : "Add the new VM to the specified pool.",
44660702 9439 "format" : "pve-poolid",
56122987 9440 "optional" : 1,
44660702 9441 "type" : "string"
56122987 9442 },
44660702
DM
9443 "snapname" : {
9444 "description" : "The name of the snapshot.",
9445 "format" : "pve-configid",
9446 "maxLength" : 40,
7aacca6f
DM
9447 "optional" : 1,
9448 "type" : "string"
56122987 9449 },
44660702
DM
9450 "storage" : {
9451 "description" : "Target storage for full clone.",
9452 "format" : "pve-storage-id",
7aacca6f 9453 "optional" : 1,
44660702
DM
9454 "requires" : "full",
9455 "type" : "string"
56122987 9456 },
44660702
DM
9457 "target" : {
9458 "description" : "Target node. Only allowed if the original VM is on shared storage.",
9459 "format" : "pve-node",
56122987 9460 "optional" : 1,
56122987 9461 "type" : "string"
44660702
DM
9462 },
9463 "vmid" : {
9464 "description" : "The (unique) ID of the VM.",
9465 "format" : "pve-vmid",
9466 "minimum" : 1,
4bd7df8b 9467 "type" : "integer",
2c0dde61 9468 "typetext" : "integer (1 - N)"
56122987
DM
9469 }
9470 }
9471 },
56122987
DM
9472 "permissions" : {
9473 "check" : [
9474 "and",
9475 [
9476 "perm",
9477 "/vms/{vmid}",
9478 [
9479 "VM.Clone"
9480 ]
9481 ],
9482 [
9483 "or",
9484 [
9485 "perm",
9486 "/vms/{newid}",
9487 [
9488 "VM.Allocate"
9489 ]
9490 ],
9491 [
9492 "perm",
9493 "/pool/{pool}",
9494 [
9495 "VM.Allocate"
9496 ],
9497 "require_param",
9498 "pool"
9499 ]
9500 ]
44660702
DM
9501 ],
9502 "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."
9503 },
9504 "protected" : 1,
9505 "proxyto" : "node",
9506 "returns" : {
9507 "type" : "string"
56122987
DM
9508 }
9509 }
9510 },
44660702
DM
9511 "leaf" : 1,
9512 "path" : "/nodes/{node}/qemu/{vmid}/clone",
56122987
DM
9513 "text" : "clone"
9514 },
9515 {
56122987
DM
9516 "info" : {
9517 "POST" : {
7aacca6f 9518 "description" : "Move volume to different storage.",
44660702
DM
9519 "method" : "POST",
9520 "name" : "move_vm_disk",
56122987
DM
9521 "parameters" : {
9522 "additionalProperties" : 0,
9523 "properties" : {
9524 "delete" : {
44660702 9525 "default" : 0,
56122987 9526 "description" : "Delete the original disk after successful copy. By default the original disk is kept as unused disk.",
7aacca6f 9527 "optional" : 1,
44660702 9528 "type" : "boolean"
56122987 9529 },
44660702
DM
9530 "digest" : {
9531 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
9532 "maxLength" : 40,
9533 "optional" : 1,
9534 "type" : "string"
56122987 9535 },
56122987 9536 "disk" : {
56122987
DM
9537 "description" : "The disk you want to move.",
9538 "enum" : [
9539 "ide0",
9540 "ide1",
9541 "ide2",
9542 "ide3",
9543 "scsi0",
9544 "scsi1",
9545 "scsi2",
9546 "scsi3",
9547 "scsi4",
9548 "scsi5",
9549 "scsi6",
9550 "scsi7",
9551 "scsi8",
9552 "scsi9",
9553 "scsi10",
9554 "scsi11",
9555 "scsi12",
9556 "scsi13",
9557 "virtio0",
9558 "virtio1",
9559 "virtio2",
9560 "virtio3",
9561 "virtio4",
9562 "virtio5",
9563 "virtio6",
9564 "virtio7",
9565 "virtio8",
9566 "virtio9",
9567 "virtio10",
9568 "virtio11",
9569 "virtio12",
9570 "virtio13",
9571 "virtio14",
9572 "virtio15",
9573 "sata0",
9574 "sata1",
9575 "sata2",
9576 "sata3",
9577 "sata4",
2c0dde61
DM
9578 "sata5",
9579 "efidisk0"
44660702
DM
9580 ],
9581 "type" : "string"
7aacca6f
DM
9582 },
9583 "format" : {
9584 "description" : "Target Format.",
9585 "enum" : [
9586 "raw",
9587 "qcow2",
9588 "vmdk"
9589 ],
9590 "optional" : 1,
9591 "type" : "string"
44660702
DM
9592 },
9593 "node" : {
9594 "description" : "The cluster node name.",
9595 "format" : "pve-node",
9596 "type" : "string"
9597 },
9598 "storage" : {
9599 "description" : "Target storage.",
9600 "format" : "pve-storage-id",
9601 "type" : "string"
9602 },
9603 "vmid" : {
9604 "description" : "The (unique) ID of the VM.",
9605 "format" : "pve-vmid",
9606 "minimum" : 1,
4bd7df8b 9607 "type" : "integer",
2c0dde61 9608 "typetext" : "integer (1 - N)"
56122987
DM
9609 }
9610 }
9611 },
44660702
DM
9612 "permissions" : {
9613 "check" : [
9614 "and",
9615 [
9616 "perm",
9617 "/vms/{vmid}",
9618 [
9619 "VM.Config.Disk"
9620 ]
9621 ],
9622 [
9623 "perm",
9624 "/storage/{storage}",
9625 [
9626 "Datastore.AllocateSpace"
9627 ]
9628 ]
9629 ],
9630 "description" : "You need 'VM.Config.Disk' permissions on /vms/{vmid}, and 'Datastore.AllocateSpace' permissions on the storage."
9631 },
9632 "protected" : 1,
9633 "proxyto" : "node",
9634 "returns" : {
9635 "description" : "the task ID.",
9636 "type" : "string"
9637 }
56122987 9638 }
7aacca6f 9639 },
44660702 9640 "leaf" : 1,
7aacca6f 9641 "path" : "/nodes/{node}/qemu/{vmid}/move_disk",
44660702 9642 "text" : "move_disk"
56122987
DM
9643 },
9644 {
56122987
DM
9645 "info" : {
9646 "POST" : {
7aacca6f 9647 "description" : "Migrate virtual machine. Creates a new migration task.",
44660702 9648 "method" : "POST",
7aacca6f 9649 "name" : "migrate_vm",
56122987 9650 "parameters" : {
44660702 9651 "additionalProperties" : 0,
56122987 9652 "properties" : {
44660702
DM
9653 "force" : {
9654 "description" : "Allow to migrate VMs which use local devices. Only root may use this option.",
9655 "optional" : 1,
9656 "type" : "boolean"
9657 },
7aacca6f 9658 "node" : {
44660702 9659 "description" : "The cluster node name.",
7aacca6f 9660 "format" : "pve-node",
44660702 9661 "type" : "string"
56122987
DM
9662 },
9663 "online" : {
44660702 9664 "description" : "Use online/live migration.",
56122987 9665 "optional" : 1,
44660702 9666 "type" : "boolean"
56122987 9667 },
44660702
DM
9668 "target" : {
9669 "description" : "Target node.",
9670 "format" : "pve-node",
9671 "type" : "string"
56122987 9672 },
7aacca6f 9673 "vmid" : {
7aacca6f 9674 "description" : "The (unique) ID of the VM.",
44660702 9675 "format" : "pve-vmid",
7aacca6f 9676 "minimum" : 1,
4bd7df8b 9677 "type" : "integer",
2c0dde61 9678 "typetext" : "integer (1 - N)"
56122987 9679 }
44660702
DM
9680 }
9681 },
9682 "permissions" : {
9683 "check" : [
9684 "perm",
9685 "/vms/{vmid}",
9686 [
9687 "VM.Migrate"
9688 ]
9689 ]
56122987
DM
9690 },
9691 "protected" : 1,
44660702
DM
9692 "proxyto" : "node",
9693 "returns" : {
9694 "description" : "the task ID.",
9695 "type" : "string"
9696 }
56122987 9697 }
7aacca6f 9698 },
44660702
DM
9699 "leaf" : 1,
9700 "path" : "/nodes/{node}/qemu/{vmid}/migrate",
7aacca6f 9701 "text" : "migrate"
56122987
DM
9702 },
9703 {
9704 "info" : {
9705 "POST" : {
44660702 9706 "description" : "Execute Qemu monitor commands.",
56122987 9707 "method" : "POST",
44660702 9708 "name" : "monitor",
56122987 9709 "parameters" : {
7aacca6f 9710 "additionalProperties" : 0,
56122987 9711 "properties" : {
44660702
DM
9712 "command" : {
9713 "description" : "The monitor command.",
9714 "type" : "string"
9715 },
56122987 9716 "node" : {
44660702 9717 "description" : "The cluster node name.",
7aacca6f 9718 "format" : "pve-node",
44660702 9719 "type" : "string"
56122987
DM
9720 },
9721 "vmid" : {
44660702 9722 "description" : "The (unique) ID of the VM.",
56122987 9723 "format" : "pve-vmid",
7aacca6f 9724 "minimum" : 1,
4bd7df8b 9725 "type" : "integer",
2c0dde61 9726 "typetext" : "integer (1 - N)"
56122987 9727 }
7aacca6f 9728 }
56122987 9729 },
56122987
DM
9730 "permissions" : {
9731 "check" : [
9732 "perm",
9733 "/vms/{vmid}",
9734 [
9735 "VM.Monitor"
9736 ]
9737 ]
7aacca6f 9738 },
44660702
DM
9739 "protected" : 1,
9740 "proxyto" : "node",
9741 "returns" : {
9742 "type" : "string"
9743 }
56122987 9744 }
44660702
DM
9745 },
9746 "leaf" : 1,
9747 "path" : "/nodes/{node}/qemu/{vmid}/monitor",
9748 "text" : "monitor"
56122987
DM
9749 },
9750 {
56122987
DM
9751 "info" : {
9752 "PUT" : {
44660702
DM
9753 "description" : "Extend volume size.",
9754 "method" : "PUT",
9755 "name" : "resize_vm",
56122987 9756 "parameters" : {
44660702 9757 "additionalProperties" : 0,
56122987 9758 "properties" : {
44660702
DM
9759 "digest" : {
9760 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
9761 "maxLength" : 40,
9762 "optional" : 1,
56122987
DM
9763 "type" : "string"
9764 },
56122987
DM
9765 "disk" : {
9766 "description" : "The disk you want to resize.",
9767 "enum" : [
9768 "ide0",
9769 "ide1",
9770 "ide2",
9771 "ide3",
9772 "scsi0",
9773 "scsi1",
9774 "scsi2",
9775 "scsi3",
9776 "scsi4",
9777 "scsi5",
9778 "scsi6",
9779 "scsi7",
9780 "scsi8",
9781 "scsi9",
9782 "scsi10",
9783 "scsi11",
9784 "scsi12",
9785 "scsi13",
9786 "virtio0",
9787 "virtio1",
9788 "virtio2",
9789 "virtio3",
9790 "virtio4",
9791 "virtio5",
9792 "virtio6",
9793 "virtio7",
9794 "virtio8",
9795 "virtio9",
9796 "virtio10",
9797 "virtio11",
9798 "virtio12",
9799 "virtio13",
9800 "virtio14",
9801 "virtio15",
9802 "sata0",
9803 "sata1",
9804 "sata2",
9805 "sata3",
9806 "sata4",
2c0dde61
DM
9807 "sata5",
9808 "efidisk0"
44660702
DM
9809 ],
9810 "type" : "string"
56122987 9811 },
44660702
DM
9812 "node" : {
9813 "description" : "The cluster node name.",
9814 "format" : "pve-node",
9815 "type" : "string"
7aacca6f 9816 },
44660702
DM
9817 "size" : {
9818 "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.",
9819 "pattern" : "\\+?\\d+(\\.\\d+)?[KMGT]?",
9820 "type" : "string"
56122987
DM
9821 },
9822 "skiplock" : {
9823 "description" : "Ignore locks - only root is allowed to use this option.",
9824 "optional" : 1,
9825 "type" : "boolean"
56122987
DM
9826 },
9827 "vmid" : {
7aacca6f 9828 "description" : "The (unique) ID of the VM.",
56122987 9829 "format" : "pve-vmid",
44660702 9830 "minimum" : 1,
4bd7df8b 9831 "type" : "integer",
2c0dde61 9832 "typetext" : "integer (1 - N)"
56122987
DM
9833 }
9834 }
9835 },
9836 "permissions" : {
9837 "check" : [
9838 "perm",
9839 "/vms/{vmid}",
9840 [
44660702 9841 "VM.Config.Disk"
56122987
DM
9842 ]
9843 ]
9844 },
7aacca6f 9845 "protected" : 1,
7aacca6f 9846 "proxyto" : "node",
44660702
DM
9847 "returns" : {
9848 "type" : "null"
9849 }
7aacca6f
DM
9850 }
9851 },
44660702
DM
9852 "leaf" : 1,
9853 "path" : "/nodes/{node}/qemu/{vmid}/resize",
9854 "text" : "resize"
9855 },
9856 {
56122987
DM
9857 "children" : [
9858 {
9859 "children" : [
9860 {
56122987 9861 "info" : {
44660702
DM
9862 "GET" : {
9863 "description" : "Get snapshot configuration",
9864 "method" : "GET",
9865 "name" : "get_snapshot_config",
56122987 9866 "parameters" : {
44660702 9867 "additionalProperties" : 0,
56122987 9868 "properties" : {
56122987 9869 "node" : {
44660702 9870 "description" : "The cluster node name.",
56122987 9871 "format" : "pve-node",
44660702 9872 "type" : "string"
7aacca6f
DM
9873 },
9874 "snapname" : {
44660702 9875 "description" : "The name of the snapshot.",
7aacca6f 9876 "format" : "pve-configid",
44660702
DM
9877 "maxLength" : 40,
9878 "type" : "string"
7aacca6f
DM
9879 },
9880 "vmid" : {
44660702 9881 "description" : "The (unique) ID of the VM.",
7aacca6f
DM
9882 "format" : "pve-vmid",
9883 "minimum" : 1,
4bd7df8b 9884 "type" : "integer",
2c0dde61 9885 "typetext" : "integer (1 - N)"
56122987 9886 }
44660702 9887 }
56122987
DM
9888 },
9889 "permissions" : {
9890 "check" : [
9891 "perm",
9892 "/vms/{vmid}",
9893 [
9894 "VM.Snapshot"
9895 ]
9896 ]
9897 },
44660702 9898 "proxyto" : "node",
56122987 9899 "returns" : {
44660702 9900 "type" : "object"
7aacca6f
DM
9901 }
9902 },
44660702
DM
9903 "PUT" : {
9904 "description" : "Update snapshot metadata.",
9905 "method" : "PUT",
9906 "name" : "update_snapshot_config",
56122987 9907 "parameters" : {
44660702 9908 "additionalProperties" : 0,
56122987 9909 "properties" : {
44660702
DM
9910 "description" : {
9911 "description" : "A textual description or comment.",
9912 "optional" : 1,
9913 "type" : "string"
9914 },
56122987 9915 "node" : {
7aacca6f 9916 "description" : "The cluster node name.",
44660702
DM
9917 "format" : "pve-node",
9918 "type" : "string"
56122987 9919 },
56122987
DM
9920 "snapname" : {
9921 "description" : "The name of the snapshot.",
44660702 9922 "format" : "pve-configid",
7aacca6f 9923 "maxLength" : 40,
44660702 9924 "type" : "string"
7aacca6f
DM
9925 },
9926 "vmid" : {
9927 "description" : "The (unique) ID of the VM.",
44660702 9928 "format" : "pve-vmid",
7aacca6f 9929 "minimum" : 1,
4bd7df8b 9930 "type" : "integer",
2c0dde61 9931 "typetext" : "integer (1 - N)"
56122987 9932 }
44660702 9933 }
56122987 9934 },
7aacca6f
DM
9935 "permissions" : {
9936 "check" : [
9937 "perm",
9938 "/vms/{vmid}",
9939 [
9940 "VM.Snapshot"
9941 ]
9942 ]
44660702
DM
9943 },
9944 "protected" : 1,
9945 "proxyto" : "node",
9946 "returns" : {
9947 "type" : "null"
7aacca6f 9948 }
56122987
DM
9949 }
9950 },
44660702 9951 "leaf" : 1,
7aacca6f 9952 "path" : "/nodes/{node}/qemu/{vmid}/snapshot/{snapname}/config",
44660702 9953 "text" : "config"
56122987
DM
9954 },
9955 {
56122987
DM
9956 "info" : {
9957 "POST" : {
44660702 9958 "description" : "Rollback VM state to specified snapshot.",
7aacca6f 9959 "method" : "POST",
44660702 9960 "name" : "rollback",
56122987
DM
9961 "parameters" : {
9962 "additionalProperties" : 0,
9963 "properties" : {
44660702
DM
9964 "node" : {
9965 "description" : "The cluster node name.",
9966 "format" : "pve-node",
9967 "type" : "string"
9968 },
56122987 9969 "snapname" : {
44660702 9970 "description" : "The name of the snapshot.",
56122987
DM
9971 "format" : "pve-configid",
9972 "maxLength" : 40,
7aacca6f
DM
9973 "type" : "string"
9974 },
56122987 9975 "vmid" : {
7aacca6f 9976 "description" : "The (unique) ID of the VM.",
44660702 9977 "format" : "pve-vmid",
56122987 9978 "minimum" : 1,
4bd7df8b 9979 "type" : "integer",
2c0dde61 9980 "typetext" : "integer (1 - N)"
56122987
DM
9981 }
9982 }
9983 },
7aacca6f 9984 "permissions" : {
56122987
DM
9985 "check" : [
9986 "perm",
9987 "/vms/{vmid}",
9988 [
9989 "VM.Snapshot"
9990 ]
9991 ]
9992 },
44660702 9993 "protected" : 1,
7aacca6f 9994 "proxyto" : "node",
44660702
DM
9995 "returns" : {
9996 "description" : "the task ID.",
9997 "type" : "string"
9998 }
56122987
DM
9999 }
10000 },
44660702
DM
10001 "leaf" : 1,
10002 "path" : "/nodes/{node}/qemu/{vmid}/snapshot/{snapname}/rollback",
7aacca6f 10003 "text" : "rollback"
56122987 10004 }
44660702
DM
10005 ],
10006 "info" : {
10007 "DELETE" : {
10008 "description" : "Delete a VM snapshot.",
10009 "method" : "DELETE",
10010 "name" : "delsnapshot",
10011 "parameters" : {
10012 "additionalProperties" : 0,
10013 "properties" : {
10014 "force" : {
10015 "description" : "For removal from config file, even if removing disk snapshots fails.",
10016 "optional" : 1,
10017 "type" : "boolean"
10018 },
10019 "node" : {
10020 "description" : "The cluster node name.",
10021 "format" : "pve-node",
10022 "type" : "string"
10023 },
10024 "snapname" : {
10025 "description" : "The name of the snapshot.",
10026 "format" : "pve-configid",
10027 "maxLength" : 40,
10028 "type" : "string"
10029 },
10030 "vmid" : {
10031 "description" : "The (unique) ID of the VM.",
10032 "format" : "pve-vmid",
10033 "minimum" : 1,
4bd7df8b 10034 "type" : "integer",
2c0dde61 10035 "typetext" : "integer (1 - N)"
44660702
DM
10036 }
10037 }
10038 },
10039 "permissions" : {
10040 "check" : [
10041 "perm",
10042 "/vms/{vmid}",
10043 [
10044 "VM.Snapshot"
10045 ]
10046 ]
10047 },
10048 "protected" : 1,
10049 "proxyto" : "node",
10050 "returns" : {
10051 "description" : "the task ID.",
10052 "type" : "string"
10053 }
10054 },
10055 "GET" : {
10056 "description" : "",
10057 "method" : "GET",
10058 "name" : "snapshot_cmd_idx",
10059 "parameters" : {
10060 "additionalProperties" : 0,
10061 "properties" : {
10062 "node" : {
10063 "description" : "The cluster node name.",
10064 "format" : "pve-node",
10065 "type" : "string"
10066 },
10067 "snapname" : {
10068 "description" : "The name of the snapshot.",
10069 "format" : "pve-configid",
10070 "maxLength" : 40,
10071 "type" : "string"
10072 },
10073 "vmid" : {
10074 "description" : "The (unique) ID of the VM.",
10075 "format" : "pve-vmid",
10076 "minimum" : 1,
4bd7df8b 10077 "type" : "integer",
2c0dde61 10078 "typetext" : "integer (1 - N)"
44660702
DM
10079 }
10080 }
10081 },
10082 "permissions" : {
10083 "user" : "all"
10084 },
10085 "returns" : {
10086 "items" : {
10087 "properties" : {},
10088 "type" : "object"
10089 },
10090 "links" : [
10091 {
10092 "href" : "{cmd}",
10093 "rel" : "child"
10094 }
10095 ],
10096 "type" : "array"
10097 }
10098 }
10099 },
10100 "leaf" : 0,
10101 "path" : "/nodes/{node}/qemu/{vmid}/snapshot/{snapname}",
10102 "text" : "{snapname}"
56122987
DM
10103 }
10104 ],
44660702
DM
10105 "info" : {
10106 "GET" : {
10107 "description" : "List all snapshots.",
10108 "method" : "GET",
10109 "name" : "snapshot_list",
10110 "parameters" : {
10111 "additionalProperties" : 0,
10112 "properties" : {
10113 "node" : {
10114 "description" : "The cluster node name.",
10115 "format" : "pve-node",
10116 "type" : "string"
10117 },
10118 "vmid" : {
10119 "description" : "The (unique) ID of the VM.",
10120 "format" : "pve-vmid",
10121 "minimum" : 1,
4bd7df8b 10122 "type" : "integer",
2c0dde61 10123 "typetext" : "integer (1 - N)"
44660702
DM
10124 }
10125 }
10126 },
10127 "permissions" : {
10128 "check" : [
10129 "perm",
10130 "/vms/{vmid}",
10131 [
10132 "VM.Audit"
10133 ]
10134 ]
10135 },
10136 "protected" : 1,
10137 "proxyto" : "node",
10138 "returns" : {
10139 "items" : {
10140 "properties" : {},
10141 "type" : "object"
10142 },
10143 "links" : [
10144 {
10145 "href" : "{name}",
10146 "rel" : "child"
10147 }
10148 ],
10149 "type" : "array"
10150 }
10151 },
10152 "POST" : {
10153 "description" : "Snapshot a VM.",
10154 "method" : "POST",
10155 "name" : "snapshot",
10156 "parameters" : {
10157 "additionalProperties" : 0,
10158 "properties" : {
10159 "description" : {
10160 "description" : "A textual description or comment.",
10161 "optional" : 1,
10162 "type" : "string"
10163 },
10164 "node" : {
10165 "description" : "The cluster node name.",
10166 "format" : "pve-node",
10167 "type" : "string"
10168 },
10169 "snapname" : {
10170 "description" : "The name of the snapshot.",
10171 "format" : "pve-configid",
10172 "maxLength" : 40,
10173 "type" : "string"
10174 },
10175 "vmid" : {
10176 "description" : "The (unique) ID of the VM.",
10177 "format" : "pve-vmid",
10178 "minimum" : 1,
4bd7df8b 10179 "type" : "integer",
2c0dde61 10180 "typetext" : "integer (1 - N)"
44660702
DM
10181 },
10182 "vmstate" : {
10183 "description" : "Save the vmstate",
10184 "optional" : 1,
10185 "type" : "boolean"
10186 }
10187 }
10188 },
10189 "permissions" : {
10190 "check" : [
10191 "perm",
10192 "/vms/{vmid}",
10193 [
10194 "VM.Snapshot"
10195 ]
10196 ]
10197 },
10198 "protected" : 1,
10199 "proxyto" : "node",
10200 "returns" : {
10201 "description" : "the task ID.",
10202 "type" : "string"
10203 }
10204 }
10205 },
10206 "leaf" : 0,
10207 "path" : "/nodes/{node}/qemu/{vmid}/snapshot",
7aacca6f 10208 "text" : "snapshot"
56122987
DM
10209 },
10210 {
56122987
DM
10211 "info" : {
10212 "POST" : {
44660702
DM
10213 "description" : "Create a Template.",
10214 "method" : "POST",
56122987 10215 "name" : "template",
56122987 10216 "parameters" : {
7aacca6f 10217 "additionalProperties" : 0,
56122987 10218 "properties" : {
56122987 10219 "disk" : {
56122987
DM
10220 "description" : "If you want to convert only 1 disk to base image.",
10221 "enum" : [
10222 "ide0",
10223 "ide1",
10224 "ide2",
10225 "ide3",
10226 "scsi0",
10227 "scsi1",
10228 "scsi2",
10229 "scsi3",
10230 "scsi4",
10231 "scsi5",
10232 "scsi6",
10233 "scsi7",
10234 "scsi8",
10235 "scsi9",
10236 "scsi10",
10237 "scsi11",
10238 "scsi12",
10239 "scsi13",
10240 "virtio0",
10241 "virtio1",
10242 "virtio2",
10243 "virtio3",
10244 "virtio4",
10245 "virtio5",
10246 "virtio6",
10247 "virtio7",
10248 "virtio8",
10249 "virtio9",
10250 "virtio10",
10251 "virtio11",
10252 "virtio12",
10253 "virtio13",
10254 "virtio14",
10255 "virtio15",
10256 "sata0",
10257 "sata1",
10258 "sata2",
10259 "sata3",
10260 "sata4",
2c0dde61
DM
10261 "sata5",
10262 "efidisk0"
56122987 10263 ],
7aacca6f 10264 "optional" : 1,
56122987
DM
10265 "type" : "string"
10266 },
44660702
DM
10267 "node" : {
10268 "description" : "The cluster node name.",
10269 "format" : "pve-node",
10270 "type" : "string"
10271 },
10272 "vmid" : {
10273 "description" : "The (unique) ID of the VM.",
7aacca6f 10274 "format" : "pve-vmid",
44660702 10275 "minimum" : 1,
4bd7df8b 10276 "type" : "integer",
2c0dde61 10277 "typetext" : "integer (1 - N)"
56122987 10278 }
7aacca6f 10279 }
56122987 10280 },
7aacca6f
DM
10281 "permissions" : {
10282 "check" : [
10283 "perm",
10284 "/vms/{vmid}",
10285 [
10286 "VM.Allocate"
10287 ]
10288 ],
10289 "description" : "You need 'VM.Allocate' permissions on /vms/{vmid}"
10290 },
44660702 10291 "protected" : 1,
7aacca6f 10292 "proxyto" : "node",
7aacca6f
DM
10293 "returns" : {
10294 "type" : "null"
10295 }
56122987
DM
10296 }
10297 },
44660702 10298 "leaf" : 1,
7aacca6f 10299 "path" : "/nodes/{node}/qemu/{vmid}/template",
44660702 10300 "text" : "template"
56122987
DM
10301 }
10302 ],
7aacca6f 10303 "info" : {
44660702
DM
10304 "DELETE" : {
10305 "description" : "Destroy the vm (also delete all used/owned volumes).",
10306 "method" : "DELETE",
10307 "name" : "destroy_vm",
7aacca6f 10308 "parameters" : {
44660702 10309 "additionalProperties" : 0,
7aacca6f
DM
10310 "properties" : {
10311 "node" : {
44660702 10312 "description" : "The cluster node name.",
7aacca6f 10313 "format" : "pve-node",
44660702
DM
10314 "type" : "string"
10315 },
10316 "skiplock" : {
10317 "description" : "Ignore locks - only root is allowed to use this option.",
10318 "optional" : 1,
10319 "type" : "boolean"
7aacca6f
DM
10320 },
10321 "vmid" : {
44660702 10322 "description" : "The (unique) ID of the VM.",
7aacca6f 10323 "format" : "pve-vmid",
44660702 10324 "minimum" : 1,
4bd7df8b 10325 "type" : "integer",
2c0dde61 10326 "typetext" : "integer (1 - N)"
7aacca6f 10327 }
44660702 10328 }
7aacca6f 10329 },
7aacca6f
DM
10330 "permissions" : {
10331 "check" : [
10332 "perm",
10333 "/vms/{vmid}",
10334 [
10335 "VM.Allocate"
10336 ]
10337 ]
10338 },
44660702
DM
10339 "protected" : 1,
10340 "proxyto" : "node",
7aacca6f
DM
10341 "returns" : {
10342 "type" : "string"
44660702
DM
10343 }
10344 },
10345 "GET" : {
10346 "description" : "Directory index",
10347 "method" : "GET",
10348 "name" : "vmdiridx",
7aacca6f 10349 "parameters" : {
44660702 10350 "additionalProperties" : 0,
7aacca6f 10351 "properties" : {
7aacca6f 10352 "node" : {
7aacca6f 10353 "description" : "The cluster node name.",
44660702
DM
10354 "format" : "pve-node",
10355 "type" : "string"
10356 },
10357 "vmid" : {
10358 "description" : "The (unique) ID of the VM.",
10359 "format" : "pve-vmid",
10360 "minimum" : 1,
4bd7df8b 10361 "type" : "integer",
2c0dde61 10362 "typetext" : "integer (1 - N)"
7aacca6f 10363 }
44660702 10364 }
7aacca6f 10365 },
44660702
DM
10366 "permissions" : {
10367 "user" : "all"
10368 },
10369 "proxyto" : "node",
10370 "returns" : {
10371 "items" : {
10372 "properties" : {
10373 "subdir" : {
10374 "type" : "string"
10375 }
10376 },
10377 "type" : "object"
10378 },
10379 "links" : [
10380 {
10381 "href" : "{subdir}",
10382 "rel" : "child"
10383 }
10384 ],
10385 "type" : "array"
10386 }
7aacca6f 10387 }
44660702
DM
10388 },
10389 "leaf" : 0,
10390 "path" : "/nodes/{node}/qemu/{vmid}",
10391 "text" : "{vmid}"
56122987
DM
10392 }
10393 ],
10394 "info" : {
44660702
DM
10395 "GET" : {
10396 "description" : "Virtual machine index (per node).",
10397 "method" : "GET",
10398 "name" : "vmlist",
56122987 10399 "parameters" : {
44660702 10400 "additionalProperties" : 0,
56122987 10401 "properties" : {
44660702
DM
10402 "full" : {
10403 "description" : "Determine the full status of active VMs.",
56122987 10404 "optional" : 1,
44660702 10405 "type" : "boolean"
56122987 10406 },
44660702
DM
10407 "node" : {
10408 "description" : "The cluster node name.",
10409 "format" : "pve-node",
7aacca6f 10410 "type" : "string"
44660702
DM
10411 }
10412 }
10413 },
10414 "permissions" : {
10415 "description" : "Only list VMs where you have VM.Audit permissons on /vms/<vmid>.",
10416 "user" : "all"
10417 },
10418 "protected" : 1,
10419 "proxyto" : "node",
10420 "returns" : {
10421 "items" : {
10422 "properties" : {},
10423 "type" : "object"
10424 },
10425 "links" : [
10426 {
10427 "href" : "{vmid}",
10428 "rel" : "child"
10429 }
10430 ],
10431 "type" : "array"
10432 }
10433 },
10434 "POST" : {
10435 "description" : "Create or restore a virtual machine.",
10436 "method" : "POST",
10437 "name" : "create_vm",
10438 "parameters" : {
10439 "additionalProperties" : 0,
10440 "properties" : {
7aacca6f 10441 "acpi" : {
7aacca6f 10442 "default" : 1,
44660702 10443 "description" : "Enable/disable ACPI.",
56122987 10444 "optional" : 1,
7aacca6f 10445 "type" : "boolean"
56122987 10446 },
44660702
DM
10447 "agent" : {
10448 "default" : 0,
10449 "description" : "Enable/disable Qemu GuestAgent.",
7aacca6f 10450 "optional" : 1,
44660702 10451 "type" : "boolean"
56122987 10452 },
44660702
DM
10453 "archive" : {
10454 "description" : "The backup file.",
10455 "maxLength" : 255,
56122987 10456 "optional" : 1,
44660702 10457 "type" : "string"
56122987 10458 },
44660702 10459 "args" : {
c2993fe5 10460 "description" : "Arbitrary arguments passed to kvm.",
56122987 10461 "optional" : 1,
c2993fe5
DM
10462 "type" : "string",
10463 "verbose_description" : "Arbitrary arguments passed to kvm, for example:\n\nargs: -no-reboot -no-hpet\n\nNOTE: this option is for experts only.\n"
56122987 10464 },
44660702 10465 "autostart" : {
7aacca6f 10466 "default" : 0,
44660702
DM
10467 "description" : "Automatic restart after crash (currently ignored).",
10468 "optional" : 1,
10469 "type" : "boolean"
7aacca6f 10470 },
44660702
DM
10471 "balloon" : {
10472 "description" : "Amount of target RAM for the VM in MB. Using zero disables the ballon driver.",
10473 "minimum" : 0,
56122987 10474 "optional" : 1,
4bd7df8b 10475 "type" : "integer",
2c0dde61 10476 "typetext" : "integer (0 - N)"
56122987 10477 },
44660702
DM
10478 "bios" : {
10479 "default" : "seabios",
10480 "description" : "Select BIOS implementation.",
10481 "enum" : [
10482 "seabios",
10483 "ovmf"
10484 ],
56122987 10485 "optional" : 1,
44660702 10486 "type" : "string"
56122987 10487 },
44660702
DM
10488 "boot" : {
10489 "default" : "cdn",
10490 "description" : "Boot on floppy (a), hard disk (c), CD-ROM (d), or network (n).",
56122987 10491 "optional" : 1,
44660702
DM
10492 "pattern" : "[acdn]{1,4}",
10493 "type" : "string"
56122987 10494 },
7aacca6f
DM
10495 "bootdisk" : {
10496 "description" : "Enable booting from specified disk.",
44660702
DM
10497 "format" : "pve-qm-bootdisk",
10498 "optional" : 1,
7aacca6f 10499 "pattern" : "(ide|sata|scsi|virtio)\\d+",
44660702
DM
10500 "type" : "string"
10501 },
10502 "cdrom" : {
10503 "description" : "This is an alias for option -ide2",
10504 "format" : "pve-qm-drive",
56122987 10505 "optional" : 1,
44660702
DM
10506 "type" : "string",
10507 "typetext" : "volume"
56122987 10508 },
44660702
DM
10509 "cores" : {
10510 "default" : 1,
10511 "description" : "The number of cores per socket.",
7aacca6f 10512 "minimum" : 1,
44660702 10513 "optional" : 1,
4bd7df8b 10514 "type" : "integer",
2c0dde61 10515 "typetext" : "integer (1 - N)"
7aacca6f 10516 },
44660702
DM
10517 "cpu" : {
10518 "description" : "Emulated CPU type.",
10519 "format" : {
10520 "cputype" : {
10521 "default" : "kvm64",
10522 "default_key" : 1,
10523 "description" : "Emulated CPU type.",
10524 "enum" : [
10525 "486",
10526 "athlon",
f004f5b9
DM
10527 "Broadwell",
10528 "Broadwell-noTSX",
10529 "Conroe",
44660702 10530 "core2duo",
f004f5b9
DM
10531 "coreduo",
10532 "Haswell",
10533 "Haswell-noTSX",
10534 "host",
10535 "IvyBridge",
44660702
DM
10536 "kvm32",
10537 "kvm64",
44660702 10538 "Nehalem",
44660702
DM
10539 "Opteron_G1",
10540 "Opteron_G2",
10541 "Opteron_G3",
10542 "Opteron_G4",
10543 "Opteron_G5",
f004f5b9
DM
10544 "Penryn",
10545 "pentium",
10546 "pentium2",
10547 "pentium3",
10548 "phenom",
10549 "qemu32",
10550 "qemu64",
10551 "SandyBridge",
10552 "Westmere"
44660702
DM
10553 ],
10554 "format_description" : "cputype",
10555 "type" : "string"
10556 },
10557 "hidden" : {
10558 "default" : 0,
10559 "description" : "Do not identify as a KVM virtual machine.",
10560 "optional" : 1,
10561 "type" : "boolean"
10562 }
10563 },
56122987 10564 "optional" : 1,
4bd7df8b
DM
10565 "type" : "string",
10566 "typetext" : "[cputype=]<cputype> [,hidden=<1|0>]"
56122987 10567 },
44660702 10568 "cpulimit" : {
7aacca6f 10569 "default" : 0,
c2993fe5 10570 "description" : "Limit of CPU usage.",
44660702
DM
10571 "maximum" : 128,
10572 "minimum" : 0,
7aacca6f 10573 "optional" : 1,
c2993fe5 10574 "type" : "number",
2c0dde61 10575 "typetext" : "number (0 - 128)",
c2993fe5 10576 "verbose_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."
7aacca6f
DM
10577 },
10578 "cpuunits" : {
7aacca6f 10579 "default" : 1000,
c2993fe5 10580 "description" : "CPU weight for a VM.",
7aacca6f 10581 "maximum" : 500000,
44660702
DM
10582 "minimum" : 0,
10583 "optional" : 1,
c2993fe5 10584 "type" : "integer",
2c0dde61 10585 "typetext" : "integer (0 - 500000)",
c2993fe5 10586 "verbose_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."
44660702
DM
10587 },
10588 "description" : {
10589 "description" : "Description for the VM. Only used on the configuration web interface. This is saved as comment inside the configuration file.",
56122987 10590 "optional" : 1,
44660702
DM
10591 "type" : "string"
10592 },
10593 "force" : {
10594 "description" : "Allow to overwrite existing VM.",
10595 "optional" : 1,
10596 "requires" : "archive",
10597 "type" : "boolean"
10598 },
10599 "freeze" : {
10600 "description" : "Freeze CPU at startup (use 'c' monitor command to start execution).",
10601 "optional" : 1,
10602 "type" : "boolean"
10603 },
10604 "hostpci[n]" : {
c2993fe5 10605 "description" : "Map host PCI devices into guest.",
44660702
DM
10606 "format" : "pve-qm-hostpci",
10607 "optional" : 1,
57b78691 10608 "type" : "string",
4bd7df8b 10609 "typetext" : "[host=]<HOSTPCIID[;HOSTPCIID2...]> [,pcie=<1|0>] [,rombar=<1|0>] [,x-vga=<1|0>]",
57b78691 10610 "verbose_description" : "Map host PCI devices into guest.\n\nNOTE: This option allows direct access to host hardware. So it is no longer \npossible to migrate such machines - use with special care.\n\nCAUTION: Experimental! User reported problems with this option.\n"
44660702
DM
10611 },
10612 "hotplug" : {
10613 "default" : "network,disk,usb",
10614 "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'.",
10615 "format" : "pve-hotplug-features",
10616 "optional" : 1,
10617 "type" : "string"
7aacca6f 10618 },
4bd7df8b
DM
10619 "hugepages" : {
10620 "description" : "Enable/disable hugepages memory.",
10621 "enum" : [
10622 "any",
10623 "2",
10624 "1024"
10625 ],
10626 "optional" : 1,
10627 "type" : "string"
10628 },
7aacca6f 10629 "ide[n]" : {
44660702 10630 "description" : "Use volume as IDE hard disk or CD-ROM (n is 0 to 3).",
56122987 10631 "format" : {
44660702
DM
10632 "aio" : {
10633 "description" : "AIO type to use.",
10634 "enum" : [
10635 "native",
10636 "threads"
10637 ],
44660702
DM
10638 "optional" : 1,
10639 "type" : "string"
10640 },
10641 "backup" : {
10642 "description" : "Whether the drive should be included when making backups.",
44660702
DM
10643 "optional" : 1,
10644 "type" : "boolean"
10645 },
10646 "bps" : {
10647 "description" : "Maximum r/w speed speed in bytes per second.",
7aacca6f 10648 "format_description" : "bps",
56122987 10649 "optional" : 1,
44660702 10650 "type" : "integer"
56122987 10651 },
44660702
DM
10652 "bps_rd" : {
10653 "description" : "Maximum read speed speed in bytes per second.",
10654 "format_description" : "bps",
56122987 10655 "optional" : 1,
44660702 10656 "type" : "integer"
56122987 10657 },
44660702
DM
10658 "bps_wr" : {
10659 "description" : "Maximum write speed speed in bytes per second.",
10660 "format_description" : "bps",
56122987 10661 "optional" : 1,
44660702 10662 "type" : "integer"
56122987 10663 },
44660702
DM
10664 "cache" : {
10665 "description" : "The drive's cache mode",
56122987 10666 "enum" : [
7aacca6f 10667 "none",
44660702
DM
10668 "writethrough",
10669 "writeback",
10670 "unsafe",
10671 "directsync"
56122987 10672 ],
56122987 10673 "optional" : 1,
44660702 10674 "type" : "string"
56122987 10675 },
44660702
DM
10676 "cyls" : {
10677 "description" : "Force the drive's physical geometry to have a specific cylinder count.",
44660702
DM
10678 "optional" : 1,
10679 "type" : "integer"
7aacca6f 10680 },
44660702
DM
10681 "detect_zeroes" : {
10682 "description" : "Controls whether to detect and try to optimize writes of zeroes.",
56122987 10683 "optional" : 1,
44660702 10684 "type" : "boolean"
56122987 10685 },
44660702
DM
10686 "discard" : {
10687 "description" : "Controls whether to pass discard/trim requests to the underlying storage.",
10688 "enum" : [
10689 "ignore",
10690 "on"
10691 ],
56122987 10692 "optional" : 1,
44660702 10693 "type" : "string"
56122987 10694 },
7aacca6f 10695 "file" : {
44660702 10696 "default_key" : 1,
7aacca6f 10697 "description" : "The drive's backing volume.",
7aacca6f
DM
10698 "format" : "pve-volume-id-or-qm-path",
10699 "format_description" : "volume",
7aacca6f 10700 "type" : "string"
56122987 10701 },
44660702
DM
10702 "format" : {
10703 "description" : "The drive's backing file's data format.",
56122987 10704 "enum" : [
44660702
DM
10705 "raw",
10706 "cow",
10707 "qcow",
10708 "qed",
10709 "qcow2",
10710 "vmdk",
10711 "cloop"
7aacca6f 10712 ],
f004f5b9 10713 "format_description" : "image format",
7aacca6f
DM
10714 "optional" : 1,
10715 "type" : "string"
56122987 10716 },
44660702
DM
10717 "heads" : {
10718 "description" : "Force the drive's physical geometry to have a specific head count.",
56122987 10719 "optional" : 1,
44660702 10720 "type" : "integer"
56122987 10721 },
44660702
DM
10722 "iops" : {
10723 "description" : "Maximum r/w I/O speed in operations per second.",
7aacca6f 10724 "format_description" : "iops",
56122987 10725 "optional" : 1,
44660702 10726 "type" : "integer"
56122987 10727 },
44660702
DM
10728 "iops_max" : {
10729 "description" : "Maximum unthrottled r/w I/O pool speed in operations per second.",
10730 "format_description" : "iops",
56122987 10731 "optional" : 1,
44660702 10732 "type" : "integer"
56122987 10733 },
7aacca6f 10734 "iops_rd" : {
7aacca6f 10735 "description" : "Maximum read I/O speed in operations per second.",
44660702
DM
10736 "format_description" : "iops",
10737 "optional" : 1,
10738 "type" : "integer"
7aacca6f 10739 },
44660702
DM
10740 "iops_rd_max" : {
10741 "description" : "Maximum unthrottled read I/O pool speed in operations per second.",
10742 "format_description" : "iops",
56122987 10743 "optional" : 1,
44660702 10744 "type" : "integer"
56122987 10745 },
44660702
DM
10746 "iops_wr" : {
10747 "description" : "Maximum write I/O speed in operations per second.",
10748 "format_description" : "iops",
56122987 10749 "optional" : 1,
44660702 10750 "type" : "integer"
7aacca6f 10751 },
44660702
DM
10752 "iops_wr_max" : {
10753 "description" : "Maximum unthrottled write I/O pool speed in operations per second.",
10754 "format_description" : "iops",
7aacca6f 10755 "optional" : 1,
44660702 10756 "type" : "integer"
56122987 10757 },
44660702
DM
10758 "mbps" : {
10759 "description" : "Maximum r/w speed speed in megabytes per second.",
10760 "format_description" : "mbps",
7aacca6f 10761 "optional" : 1,
44660702 10762 "type" : "number"
56122987 10763 },
44660702
DM
10764 "mbps_max" : {
10765 "description" : "Maximum unthrottled r/w pool speed in megabytes per second.",
7aacca6f 10766 "format_description" : "mbps",
56122987 10767 "optional" : 1,
44660702 10768 "type" : "number"
56122987 10769 },
44660702
DM
10770 "mbps_rd" : {
10771 "description" : "Maximum read speed speed in megabytes per second.",
10772 "format_description" : "mbps",
7aacca6f 10773 "optional" : 1,
44660702 10774 "type" : "number"
7aacca6f 10775 },
44660702
DM
10776 "mbps_rd_max" : {
10777 "description" : "Maximum unthrottled read pool speed in megabytes per second.",
10778 "format_description" : "mbps",
56122987 10779 "optional" : 1,
44660702 10780 "type" : "number"
56122987 10781 },
44660702
DM
10782 "mbps_wr" : {
10783 "description" : "Maximum write speed speed in megabytes per second.",
10784 "format_description" : "mbps",
7aacca6f 10785 "optional" : 1,
44660702 10786 "type" : "number"
56122987 10787 },
44660702
DM
10788 "mbps_wr_max" : {
10789 "description" : "Maximum unthrottled write pool speed in megabytes per second.",
10790 "format_description" : "mbps",
56122987 10791 "optional" : 1,
44660702 10792 "type" : "number"
7aacca6f
DM
10793 },
10794 "media" : {
44660702
DM
10795 "default" : "disk",
10796 "description" : "The drive's media type.",
56122987 10797 "enum" : [
7aacca6f
DM
10798 "cdrom",
10799 "disk"
56122987 10800 ],
56122987 10801 "optional" : 1,
44660702 10802 "type" : "string"
56122987 10803 },
44660702
DM
10804 "model" : {
10805 "description" : "The drive's reported model name, url-encoded, up to 40 bytes long.",
10806 "format" : "urlencoded",
10807 "format_description" : "model",
10808 "maxLength" : 120,
56122987 10809 "optional" : 1,
44660702 10810 "type" : "string"
56122987 10811 },
7aacca6f 10812 "rerror" : {
7aacca6f
DM
10813 "description" : "Read error action.",
10814 "enum" : [
10815 "ignore",
10816 "report",
10817 "stop"
44660702 10818 ],
44660702
DM
10819 "optional" : 1,
10820 "type" : "string"
56122987 10821 },
44660702
DM
10822 "secs" : {
10823 "description" : "Force the drive's physical geometry to have a specific sector count.",
56122987 10824 "optional" : 1,
44660702
DM
10825 "type" : "integer"
10826 },
10827 "serial" : {
10828 "description" : "The drive's reported serial number, url-encoded, up to 20 bytes long.",
10829 "format" : "urlencoded",
10830 "format_description" : "serial",
10831 "maxLength" : 60,
10832 "optional" : 1,
10833 "type" : "string"
10834 },
10835 "size" : {
10836 "description" : "Disk size. This is purely informational and has no effect.",
10837 "format" : "disk-size",
f004f5b9 10838 "format_description" : "DiskSize",
44660702
DM
10839 "optional" : 1,
10840 "type" : "string"
7aacca6f
DM
10841 },
10842 "snapshot" : {
44660702 10843 "description" : "Whether the drive should be included when making snapshots.",
7aacca6f 10844 "optional" : 1,
44660702 10845 "type" : "boolean"
7aacca6f 10846 },
44660702
DM
10847 "trans" : {
10848 "description" : "Force disk geometry bios translation mode.",
10849 "enum" : [
10850 "none",
10851 "lba",
10852 "auto"
10853 ],
7aacca6f 10854 "optional" : 1,
44660702
DM
10855 "type" : "string"
10856 },
10857 "volume" : {
10858 "alias" : "file"
10859 },
10860 "werror" : {
10861 "description" : "Write error action.",
10862 "enum" : [
10863 "enospc",
10864 "ignore",
10865 "report",
10866 "stop"
10867 ],
44660702
DM
10868 "optional" : 1,
10869 "type" : "string"
56122987
DM
10870 }
10871 },
56122987 10872 "optional" : 1,
4bd7df8b
DM
10873 "type" : "string",
10874 "typetext" : "[file=]<volume> [,aio=<native|threads>] [,backup=<1|0>] [,bps=<bps>] [,bps_rd=<bps>] [,bps_wr=<bps>] [,cache=<none|writethrough|writeback|unsafe|directsync>] [,cyls=<integer>] [,detect_zeroes=<1|0>] [,discard=<ignore|on>] [,format=<image format>] [,heads=<integer>] [,iops=<iops>] [,iops_max=<iops>] [,iops_rd=<iops>] [,iops_rd_max=<iops>] [,iops_wr=<iops>] [,iops_wr_max=<iops>] [,mbps=<mbps>] [,mbps_max=<mbps>] [,mbps_rd=<mbps>] [,mbps_rd_max=<mbps>] [,mbps_wr=<mbps>] [,mbps_wr_max=<mbps>] [,media=<cdrom|disk>] [,model=<model>] [,rerror=<ignore|report|stop>] [,secs=<integer>] [,serial=<serial>] [,size=<DiskSize>] [,snapshot=<1|0>] [,trans=<none|lba|auto>] [,werror=<enospc|ignore|report|stop>]"
56122987 10875 },
56122987 10876 "keyboard" : {
44660702 10877 "default" : "en-us",
c2993fe5 10878 "description" : "Keybord layout for vnc server. Default is read from the '/etc/pve/datacenter.conf' configuration file.",
56122987 10879 "enum" : [
44660702
DM
10880 "de",
10881 "de-ch",
7aacca6f 10882 "da",
56122987 10883 "en-gb",
44660702
DM
10884 "en-us",
10885 "es",
10886 "fi",
10887 "fr",
10888 "fr-be",
10889 "fr-ca",
10890 "fr-ch",
10891 "hu",
7aacca6f 10892 "is",
44660702
DM
10893 "it",
10894 "ja",
10895 "lt",
56122987 10896 "mk",
7aacca6f 10897 "nl",
56122987 10898 "no",
44660702 10899 "pl",
7aacca6f 10900 "pt",
44660702
DM
10901 "pt-br",
10902 "sv",
10903 "sl",
10904 "tr"
56122987 10905 ],
44660702
DM
10906 "optional" : 1,
10907 "type" : "string"
56122987 10908 },
44660702
DM
10909 "kvm" : {
10910 "default" : 1,
10911 "description" : "Enable/disable KVM hardware virtualization.",
7aacca6f 10912 "optional" : 1,
44660702 10913 "type" : "boolean"
7aacca6f 10914 },
44660702
DM
10915 "localtime" : {
10916 "description" : "Set the real time clock to local time. This is enabled by default if ostype indicates a Microsoft OS.",
56122987 10917 "optional" : 1,
44660702
DM
10918 "type" : "boolean"
10919 },
10920 "lock" : {
10921 "description" : "Lock/unlock the VM.",
7aacca6f
DM
10922 "enum" : [
10923 "migrate",
10924 "backup",
10925 "snapshot",
10926 "rollback"
10927 ],
44660702
DM
10928 "optional" : 1,
10929 "type" : "string"
56122987 10930 },
44660702
DM
10931 "machine" : {
10932 "description" : "Specific the Qemu machine type.",
10933 "maxLength" : 40,
10934 "optional" : 1,
10935 "pattern" : "(pc|pc(-i440fx)?-\\d+\\.\\d+(\\.pxe)?|q35|pc-q35-\\d+\\.\\d+(\\.pxe)?)",
10936 "type" : "string"
10937 },
10938 "memory" : {
10939 "default" : 512,
10940 "description" : "Amount of RAM for the VM in MB. This is the maximum available memory when you use the balloon device.",
10941 "minimum" : 16,
10942 "optional" : 1,
4bd7df8b 10943 "type" : "integer",
2c0dde61 10944 "typetext" : "integer (16 - N)"
44660702
DM
10945 },
10946 "migrate_downtime" : {
10947 "default" : 0.1,
10948 "description" : "Set maximum tolerated downtime (in seconds) for migrations.",
10949 "minimum" : 0,
10950 "optional" : 1,
4bd7df8b 10951 "type" : "number",
2c0dde61 10952 "typetext" : "number (0 - N)"
44660702
DM
10953 },
10954 "migrate_speed" : {
56122987 10955 "default" : 0,
44660702
DM
10956 "description" : "Set maximum speed (in MB/s) for migrations. Value 0 is no limit.",
10957 "minimum" : 0,
56122987 10958 "optional" : 1,
4bd7df8b 10959 "type" : "integer",
2c0dde61 10960 "typetext" : "integer (0 - N)"
56122987 10961 },
44660702
DM
10962 "name" : {
10963 "description" : "Set a name for the VM. Only used on the configuration web interface.",
10964 "format" : "dns-name",
10965 "optional" : 1,
10966 "type" : "string"
10967 },
10968 "net[n]" : {
c2993fe5 10969 "description" : "Specify network devices.",
f004f5b9
DM
10970 "format" : {
10971 "bridge" : {
c2993fe5 10972 "description" : "Bridge to attach the network device to. The Proxmox VE standard bridge\nis called 'vmbr0'.\n\nIf you do not specify a bridge, we create a kvm user (NATed) network\ndevice, which provides DHCP and DNS services. The following addresses\nare used:\n\n 10.0.2.2 Gateway\n 10.0.2.3 DNS Server\n 10.0.2.4 SMB Server\n\nThe DHCP server assign addresses to the guest starting from 10.0.2.15.\n",
f004f5b9
DM
10973 "format_description" : "bridge",
10974 "optional" : 1,
10975 "type" : "string"
10976 },
10977 "e1000" : {
10978 "alias" : "macaddr",
10979 "keyAlias" : "model"
10980 },
10981 "e1000-82540em" : {
10982 "alias" : "macaddr",
10983 "keyAlias" : "model"
10984 },
10985 "e1000-82544gc" : {
10986 "alias" : "macaddr",
10987 "keyAlias" : "model"
10988 },
10989 "e1000-82545em" : {
10990 "alias" : "macaddr",
10991 "keyAlias" : "model"
10992 },
10993 "firewall" : {
10994 "description" : "Whether this interface should be protected by the firewall.",
10995 "optional" : 1,
10996 "type" : "boolean"
10997 },
10998 "i82551" : {
10999 "alias" : "macaddr",
11000 "keyAlias" : "model"
11001 },
11002 "i82557b" : {
11003 "alias" : "macaddr",
11004 "keyAlias" : "model"
11005 },
11006 "i82559er" : {
11007 "alias" : "macaddr",
11008 "keyAlias" : "model"
11009 },
11010 "link_down" : {
c2993fe5 11011 "description" : "Whether this interface should be disconnected (like pulling the plug).",
f004f5b9
DM
11012 "optional" : 1,
11013 "type" : "boolean"
11014 },
11015 "macaddr" : {
c2993fe5 11016 "description" : "MAC address. That address must be unique withing your network. This is automatically generated if not specified.",
f004f5b9 11017 "format_description" : "XX:XX:XX:XX:XX:XX",
f004f5b9
DM
11018 "optional" : 1,
11019 "pattern" : "(?^i:[0-9a-f]{2}(?::[0-9a-f]{2}){5})",
11020 "type" : "string"
11021 },
11022 "model" : {
11023 "default_key" : 1,
c2993fe5 11024 "description" : "Network Card Model. The 'virtio' model provides the best performance with very low CPU overhead. If your guest does not support this driver, it is usually best to use 'e1000'.",
f004f5b9
DM
11025 "enum" : [
11026 "rtl8139",
11027 "ne2k_pci",
11028 "e1000",
11029 "pcnet",
11030 "virtio",
11031 "ne2k_isa",
11032 "i82551",
11033 "i82557b",
11034 "i82559er",
11035 "vmxnet3",
11036 "e1000-82540em",
11037 "e1000-82544gc",
11038 "e1000-82545em"
11039 ],
11040 "format_description" : "model",
11041 "type" : "string"
11042 },
11043 "ne2k_isa" : {
11044 "alias" : "macaddr",
11045 "keyAlias" : "model"
11046 },
11047 "ne2k_pci" : {
11048 "alias" : "macaddr",
11049 "keyAlias" : "model"
11050 },
11051 "pcnet" : {
11052 "alias" : "macaddr",
11053 "keyAlias" : "model"
11054 },
11055 "queues" : {
11056 "description" : "Number of packet queues to be used on the device.",
11057 "maximum" : 16,
11058 "minimum" : 0,
11059 "optional" : 1,
11060 "type" : "integer"
11061 },
11062 "rate" : {
c2993fe5 11063 "description" : "Rate limit in mbps (megabytes per second) as floating point number.",
f004f5b9
DM
11064 "minimum" : 0,
11065 "optional" : 1,
11066 "type" : "number"
11067 },
11068 "rtl8139" : {
11069 "alias" : "macaddr",
11070 "keyAlias" : "model"
11071 },
11072 "tag" : {
11073 "description" : "VLAN tag to apply to packets on this interface.",
11074 "maximum" : 4094,
c2993fe5 11075 "minimum" : 1,
f004f5b9
DM
11076 "optional" : 1,
11077 "type" : "integer"
11078 },
11079 "trunks" : {
11080 "description" : "VLAN trunks to pass through this interface.",
11081 "format_description" : "vlanid[;vlanid...]",
11082 "optional" : 1,
11083 "pattern" : "(?^:\\d+(?:-\\d+)?(?:;\\d+(?:-\\d+)?)*)",
11084 "type" : "string"
11085 },
11086 "virtio" : {
11087 "alias" : "macaddr",
11088 "keyAlias" : "model"
11089 },
11090 "vmxnet3" : {
11091 "alias" : "macaddr",
11092 "keyAlias" : "model"
11093 }
11094 },
44660702 11095 "optional" : 1,
4bd7df8b
DM
11096 "type" : "string",
11097 "typetext" : "[model=]<model> [,bridge=<bridge>] [,firewall=<1|0>] [,link_down=<1|0>] [,macaddr=<XX:XX:XX:XX:XX:XX>] [,queues=<integer>] [,rate=<number>] [,tag=<integer>] [,trunks=<vlanid[;vlanid...]>] [,<model>=<macaddr>]"
44660702
DM
11098 },
11099 "node" : {
11100 "description" : "The cluster node name.",
11101 "format" : "pve-node",
11102 "type" : "string"
11103 },
11104 "numa" : {
7aacca6f 11105 "default" : 0,
44660702
DM
11106 "description" : "Enable/disable NUMA.",
11107 "optional" : 1,
11108 "type" : "boolean"
56122987 11109 },
7aacca6f 11110 "numa[n]" : {
c2993fe5 11111 "description" : "NUMA topology.",
7aacca6f 11112 "format" : {
44660702 11113 "cpus" : {
c2993fe5 11114 "description" : "CPUs accessing this NUMA node.",
44660702
DM
11115 "format_description" : "id[-id];...",
11116 "pattern" : "(?^:\\d+(?:-\\d+)?(?:;\\d+(?:-\\d+)?)*)",
11117 "type" : "string"
11118 },
7aacca6f 11119 "hostnodes" : {
c2993fe5 11120 "description" : "Host NUMA nodes to use.",
44660702 11121 "format_description" : "id[-id];...",
7aacca6f 11122 "optional" : 1,
44660702
DM
11123 "pattern" : "(?^:\\d+(?:-\\d+)?(?:;\\d+(?:-\\d+)?)*)",
11124 "type" : "string"
7aacca6f 11125 },
44660702 11126 "memory" : {
c2993fe5 11127 "description" : "Amount of memory this NUMA node provides.",
44660702
DM
11128 "optional" : 1,
11129 "type" : "number"
7aacca6f
DM
11130 },
11131 "policy" : {
c2993fe5 11132 "description" : "NUMA allocation policy.",
7aacca6f
DM
11133 "enum" : [
11134 "preferred",
11135 "bind",
11136 "interleave"
11137 ],
7aacca6f 11138 "optional" : 1,
44660702 11139 "type" : "string"
7aacca6f
DM
11140 }
11141 },
56122987 11142 "optional" : 1,
4bd7df8b
DM
11143 "type" : "string",
11144 "typetext" : "cpus=<id[-id];...> [,hostnodes=<id[-id];...>] [,memory=<number>] [,policy=<preferred|bind|interleave>]"
56122987 11145 },
44660702
DM
11146 "onboot" : {
11147 "default" : 0,
11148 "description" : "Specifies whether a VM will be started during system bootup.",
56122987 11149 "optional" : 1,
44660702 11150 "type" : "boolean"
56122987
DM
11151 },
11152 "ostype" : {
c2993fe5 11153 "description" : "Specify guest operating system.",
56122987
DM
11154 "enum" : [
11155 "other",
11156 "wxp",
11157 "w2k",
11158 "w2k3",
11159 "w2k8",
11160 "wvista",
11161 "win7",
11162 "win8",
11163 "l24",
11164 "l26",
11165 "solaris"
44660702 11166 ],
56122987 11167 "optional" : 1,
c2993fe5
DM
11168 "type" : "string",
11169 "verbose_description" : "Specify guest operating system. This is used to enable special\noptimization/features for specific operating systems:\n\n[horizontal]\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"
56122987 11170 },
44660702 11171 "parallel[n]" : {
c2993fe5 11172 "description" : "Map host parallel devices (n is 0 to 2).",
56122987 11173 "optional" : 1,
44660702 11174 "pattern" : "/dev/parport\\d+|/dev/usb/lp\\d+",
c2993fe5
DM
11175 "type" : "string",
11176 "verbose_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\nCAUTION: Experimental! User reported problems with this option.\n"
56122987 11177 },
44660702
DM
11178 "pool" : {
11179 "description" : "Add the VM to the specified pool.",
11180 "format" : "pve-poolid",
56122987 11181 "optional" : 1,
44660702 11182 "type" : "string"
56122987 11183 },
44660702
DM
11184 "protection" : {
11185 "default" : 0,
c2993fe5 11186 "description" : "Sets the protection flag of the VM. This will disable the remove VM and remove disk operations.",
56122987 11187 "optional" : 1,
44660702 11188 "type" : "boolean"
56122987 11189 },
44660702 11190 "reboot" : {
7aacca6f 11191 "default" : 1,
44660702
DM
11192 "description" : "Allow reboot. If set to '0' the VM exit on reboot.",
11193 "optional" : 1,
11194 "type" : "boolean"
56122987 11195 },
56122987 11196 "sata[n]" : {
44660702 11197 "description" : "Use volume as SATA hard disk or CD-ROM (n is 0 to 5).",
56122987 11198 "format" : {
7aacca6f 11199 "aio" : {
44660702 11200 "description" : "AIO type to use.",
56122987 11201 "enum" : [
7aacca6f
DM
11202 "native",
11203 "threads"
56122987 11204 ],
7aacca6f 11205 "optional" : 1,
44660702 11206 "type" : "string"
7aacca6f
DM
11207 },
11208 "backup" : {
7aacca6f 11209 "description" : "Whether the drive should be included when making backups.",
7aacca6f 11210 "optional" : 1,
44660702 11211 "type" : "boolean"
56122987 11212 },
44660702
DM
11213 "bps" : {
11214 "description" : "Maximum r/w speed speed in bytes per second.",
11215 "format_description" : "bps",
7aacca6f 11216 "optional" : 1,
44660702 11217 "type" : "integer"
56122987 11218 },
44660702
DM
11219 "bps_rd" : {
11220 "description" : "Maximum read speed speed in bytes per second.",
11221 "format_description" : "bps",
56122987 11222 "optional" : 1,
44660702 11223 "type" : "integer"
7aacca6f 11224 },
44660702
DM
11225 "bps_wr" : {
11226 "description" : "Maximum write speed speed in bytes per second.",
11227 "format_description" : "bps",
56122987 11228 "optional" : 1,
44660702 11229 "type" : "integer"
56122987 11230 },
7aacca6f 11231 "cache" : {
7aacca6f
DM
11232 "description" : "The drive's cache mode",
11233 "enum" : [
11234 "none",
11235 "writethrough",
11236 "writeback",
11237 "unsafe",
11238 "directsync"
11239 ],
44660702
DM
11240 "optional" : 1,
11241 "type" : "string"
56122987 11242 },
44660702
DM
11243 "cyls" : {
11244 "description" : "Force the drive's physical geometry to have a specific cylinder count.",
56122987 11245 "optional" : 1,
7aacca6f 11246 "type" : "integer"
56122987 11247 },
7aacca6f
DM
11248 "detect_zeroes" : {
11249 "description" : "Controls whether to detect and try to optimize writes of zeroes.",
56122987 11250 "optional" : 1,
7aacca6f 11251 "type" : "boolean"
56122987 11252 },
44660702
DM
11253 "discard" : {
11254 "description" : "Controls whether to pass discard/trim requests to the underlying storage.",
11255 "enum" : [
11256 "ignore",
11257 "on"
11258 ],
56122987 11259 "optional" : 1,
44660702 11260 "type" : "string"
56122987 11261 },
44660702
DM
11262 "file" : {
11263 "default_key" : 1,
11264 "description" : "The drive's backing volume.",
11265 "format" : "pve-volume-id-or-qm-path",
11266 "format_description" : "volume",
11267 "type" : "string"
56122987
DM
11268 },
11269 "format" : {
44660702 11270 "description" : "The drive's backing file's data format.",
56122987
DM
11271 "enum" : [
11272 "raw",
11273 "cow",
11274 "qcow",
11275 "qed",
11276 "qcow2",
11277 "vmdk",
11278 "cloop"
11279 ],
f004f5b9 11280 "format_description" : "image format",
56122987 11281 "optional" : 1,
44660702 11282 "type" : "string"
56122987 11283 },
7aacca6f 11284 "heads" : {
7aacca6f 11285 "description" : "Force the drive's physical geometry to have a specific head count.",
44660702
DM
11286 "optional" : 1,
11287 "type" : "integer"
56122987 11288 },
44660702
DM
11289 "iops" : {
11290 "description" : "Maximum r/w I/O speed in operations per second.",
11291 "format_description" : "iops",
11292 "optional" : 1,
11293 "type" : "integer"
56122987 11294 },
44660702
DM
11295 "iops_max" : {
11296 "description" : "Maximum unthrottled r/w I/O pool speed in operations per second.",
11297 "format_description" : "iops",
56122987 11298 "optional" : 1,
44660702 11299 "type" : "integer"
56122987 11300 },
44660702
DM
11301 "iops_rd" : {
11302 "description" : "Maximum read I/O speed in operations per second.",
11303 "format_description" : "iops",
56122987 11304 "optional" : 1,
44660702 11305 "type" : "integer"
56122987 11306 },
44660702
DM
11307 "iops_rd_max" : {
11308 "description" : "Maximum unthrottled read I/O pool speed in operations per second.",
7aacca6f 11309 "format_description" : "iops",
56122987 11310 "optional" : 1,
44660702 11311 "type" : "integer"
56122987 11312 },
44660702
DM
11313 "iops_wr" : {
11314 "description" : "Maximum write I/O speed in operations per second.",
11315 "format_description" : "iops",
7aacca6f 11316 "optional" : 1,
44660702 11317 "type" : "integer"
7aacca6f 11318 },
44660702
DM
11319 "iops_wr_max" : {
11320 "description" : "Maximum unthrottled write I/O pool speed in operations per second.",
11321 "format_description" : "iops",
56122987 11322 "optional" : 1,
7aacca6f 11323 "type" : "integer"
56122987 11324 },
44660702
DM
11325 "mbps" : {
11326 "description" : "Maximum r/w speed speed in megabytes per second.",
11327 "format_description" : "mbps",
56122987 11328 "optional" : 1,
44660702 11329 "type" : "number"
56122987 11330 },
44660702
DM
11331 "mbps_max" : {
11332 "description" : "Maximum unthrottled r/w pool speed in megabytes per second.",
11333 "format_description" : "mbps",
7aacca6f 11334 "optional" : 1,
44660702 11335 "type" : "number"
7aacca6f 11336 },
44660702
DM
11337 "mbps_rd" : {
11338 "description" : "Maximum read speed speed in megabytes per second.",
11339 "format_description" : "mbps",
7aacca6f 11340 "optional" : 1,
44660702 11341 "type" : "number"
7aacca6f 11342 },
44660702
DM
11343 "mbps_rd_max" : {
11344 "description" : "Maximum unthrottled read pool speed in megabytes per second.",
11345 "format_description" : "mbps",
7aacca6f 11346 "optional" : 1,
44660702 11347 "type" : "number"
7aacca6f 11348 },
44660702
DM
11349 "mbps_wr" : {
11350 "description" : "Maximum write speed speed in megabytes per second.",
11351 "format_description" : "mbps",
7aacca6f 11352 "optional" : 1,
44660702 11353 "type" : "number"
7aacca6f
DM
11354 },
11355 "mbps_wr_max" : {
7aacca6f 11356 "description" : "Maximum unthrottled write pool speed in megabytes per second.",
44660702 11357 "format_description" : "mbps",
7aacca6f 11358 "optional" : 1,
44660702 11359 "type" : "number"
7aacca6f 11360 },
44660702
DM
11361 "media" : {
11362 "default" : "disk",
11363 "description" : "The drive's media type.",
56122987 11364 "enum" : [
44660702
DM
11365 "cdrom",
11366 "disk"
56122987 11367 ],
56122987 11368 "optional" : 1,
44660702 11369 "type" : "string"
56122987 11370 },
44660702
DM
11371 "rerror" : {
11372 "description" : "Read error action.",
7aacca6f
DM
11373 "enum" : [
11374 "ignore",
44660702
DM
11375 "report",
11376 "stop"
7aacca6f 11377 ],
56122987 11378 "optional" : 1,
44660702 11379 "type" : "string"
56122987 11380 },
44660702
DM
11381 "secs" : {
11382 "description" : "Force the drive's physical geometry to have a specific sector count.",
56122987 11383 "optional" : 1,
44660702 11384 "type" : "integer"
56122987 11385 },
44660702
DM
11386 "serial" : {
11387 "description" : "The drive's reported serial number, url-encoded, up to 20 bytes long.",
11388 "format" : "urlencoded",
11389 "format_description" : "serial",
11390 "maxLength" : 60,
11391 "optional" : 1,
11392 "type" : "string"
7aacca6f
DM
11393 },
11394 "size" : {
11395 "description" : "Disk size. This is purely informational and has no effect.",
44660702 11396 "format" : "disk-size",
f004f5b9 11397 "format_description" : "DiskSize",
56122987 11398 "optional" : 1,
44660702 11399 "type" : "string"
56122987 11400 },
44660702
DM
11401 "snapshot" : {
11402 "description" : "Whether the drive should be included when making snapshots.",
56122987 11403 "optional" : 1,
44660702 11404 "type" : "boolean"
56122987 11405 },
44660702
DM
11406 "trans" : {
11407 "description" : "Force disk geometry bios translation mode.",
56122987 11408 "enum" : [
44660702
DM
11409 "none",
11410 "lba",
11411 "auto"
7aacca6f 11412 ],
44660702
DM
11413 "optional" : 1,
11414 "type" : "string"
11415 },
11416 "volume" : {
11417 "alias" : "file"
56122987
DM
11418 },
11419 "werror" : {
56122987
DM
11420 "description" : "Write error action.",
11421 "enum" : [
11422 "enospc",
11423 "ignore",
11424 "report",
11425 "stop"
11426 ],
56122987 11427 "optional" : 1,
44660702
DM
11428 "type" : "string"
11429 }
11430 },
11431 "optional" : 1,
4bd7df8b
DM
11432 "type" : "string",
11433 "typetext" : "[file=]<volume> [,aio=<native|threads>] [,backup=<1|0>] [,bps=<bps>] [,bps_rd=<bps>] [,bps_wr=<bps>] [,cache=<none|writethrough|writeback|unsafe|directsync>] [,cyls=<integer>] [,detect_zeroes=<1|0>] [,discard=<ignore|on>] [,format=<image format>] [,heads=<integer>] [,iops=<iops>] [,iops_max=<iops>] [,iops_rd=<iops>] [,iops_rd_max=<iops>] [,iops_wr=<iops>] [,iops_wr_max=<iops>] [,mbps=<mbps>] [,mbps_max=<mbps>] [,mbps_rd=<mbps>] [,mbps_rd_max=<mbps>] [,mbps_wr=<mbps>] [,mbps_wr_max=<mbps>] [,media=<cdrom|disk>] [,rerror=<ignore|report|stop>] [,secs=<integer>] [,serial=<serial>] [,size=<DiskSize>] [,snapshot=<1|0>] [,trans=<none|lba|auto>] [,werror=<enospc|ignore|report|stop>]"
44660702
DM
11434 },
11435 "scsi[n]" : {
11436 "description" : "Use volume as SCSI hard disk or CD-ROM (n is 0 to 13).",
11437 "format" : {
11438 "aio" : {
11439 "description" : "AIO type to use.",
11440 "enum" : [
11441 "native",
11442 "threads"
11443 ],
44660702
DM
11444 "optional" : 1,
11445 "type" : "string"
56122987 11446 },
7aacca6f 11447 "backup" : {
44660702 11448 "description" : "Whether the drive should be included when making backups.",
7aacca6f 11449 "optional" : 1,
44660702 11450 "type" : "boolean"
7aacca6f 11451 },
44660702
DM
11452 "bps" : {
11453 "description" : "Maximum r/w speed speed in bytes per second.",
11454 "format_description" : "bps",
7aacca6f 11455 "optional" : 1,
44660702 11456 "type" : "integer"
7aacca6f 11457 },
44660702
DM
11458 "bps_rd" : {
11459 "description" : "Maximum read speed speed in bytes per second.",
11460 "format_description" : "bps",
56122987 11461 "optional" : 1,
44660702 11462 "type" : "integer"
56122987 11463 },
44660702
DM
11464 "bps_wr" : {
11465 "description" : "Maximum write speed speed in bytes per second.",
11466 "format_description" : "bps",
7aacca6f 11467 "optional" : 1,
44660702 11468 "type" : "integer"
56122987 11469 },
44660702
DM
11470 "cache" : {
11471 "description" : "The drive's cache mode",
7aacca6f
DM
11472 "enum" : [
11473 "none",
44660702
DM
11474 "writethrough",
11475 "writeback",
11476 "unsafe",
11477 "directsync"
7aacca6f 11478 ],
56122987 11479 "optional" : 1,
44660702 11480 "type" : "string"
56122987 11481 },
7aacca6f
DM
11482 "cyls" : {
11483 "description" : "Force the drive's physical geometry to have a specific cylinder count.",
11484 "optional" : 1,
44660702 11485 "type" : "integer"
7aacca6f 11486 },
44660702
DM
11487 "detect_zeroes" : {
11488 "description" : "Controls whether to detect and try to optimize writes of zeroes.",
56122987 11489 "optional" : 1,
44660702 11490 "type" : "boolean"
56122987 11491 },
44660702
DM
11492 "discard" : {
11493 "description" : "Controls whether to pass discard/trim requests to the underlying storage.",
7aacca6f 11494 "enum" : [
44660702
DM
11495 "ignore",
11496 "on"
7aacca6f 11497 ],
7aacca6f 11498 "optional" : 1,
44660702 11499 "type" : "string"
56122987
DM
11500 },
11501 "file" : {
7aacca6f
DM
11502 "default_key" : 1,
11503 "description" : "The drive's backing volume.",
44660702
DM
11504 "format" : "pve-volume-id-or-qm-path",
11505 "format_description" : "volume",
7aacca6f 11506 "type" : "string"
56122987 11507 },
7aacca6f 11508 "format" : {
44660702 11509 "description" : "The drive's backing file's data format.",
56122987 11510 "enum" : [
7aacca6f
DM
11511 "raw",
11512 "cow",
11513 "qcow",
11514 "qed",
11515 "qcow2",
11516 "vmdk",
11517 "cloop"
56122987 11518 ],
f004f5b9 11519 "format_description" : "image format",
44660702
DM
11520 "optional" : 1,
11521 "type" : "string"
56122987 11522 },
44660702
DM
11523 "heads" : {
11524 "description" : "Force the drive's physical geometry to have a specific head count.",
44660702
DM
11525 "optional" : 1,
11526 "type" : "integer"
11527 },
11528 "iops" : {
11529 "description" : "Maximum r/w I/O speed in operations per second.",
7aacca6f 11530 "format_description" : "iops",
56122987 11531 "optional" : 1,
44660702 11532 "type" : "integer"
56122987 11533 },
44660702
DM
11534 "iops_max" : {
11535 "description" : "Maximum unthrottled r/w I/O pool speed in operations per second.",
11536 "format_description" : "iops",
7aacca6f 11537 "optional" : 1,
44660702 11538 "type" : "integer"
56122987 11539 },
44660702
DM
11540 "iops_rd" : {
11541 "description" : "Maximum read I/O speed in operations per second.",
11542 "format_description" : "iops",
56122987 11543 "optional" : 1,
44660702 11544 "type" : "integer"
56122987 11545 },
44660702
DM
11546 "iops_rd_max" : {
11547 "description" : "Maximum unthrottled read I/O pool speed in operations per second.",
11548 "format_description" : "iops",
11549 "optional" : 1,
11550 "type" : "integer"
56122987 11551 },
44660702
DM
11552 "iops_wr" : {
11553 "description" : "Maximum write I/O speed in operations per second.",
11554 "format_description" : "iops",
56122987 11555 "optional" : 1,
44660702 11556 "type" : "integer"
56122987 11557 },
44660702
DM
11558 "iops_wr_max" : {
11559 "description" : "Maximum unthrottled write I/O pool speed in operations per second.",
11560 "format_description" : "iops",
56122987 11561 "optional" : 1,
56122987
DM
11562 "type" : "integer"
11563 },
44660702
DM
11564 "iothread" : {
11565 "description" : "Whether to use iothreads for this drive",
44660702
DM
11566 "optional" : 1,
11567 "type" : "boolean"
11568 },
11569 "mbps" : {
11570 "description" : "Maximum r/w speed speed in megabytes per second.",
11571 "format_description" : "mbps",
11572 "optional" : 1,
11573 "type" : "number"
11574 },
7aacca6f
DM
11575 "mbps_max" : {
11576 "description" : "Maximum unthrottled r/w pool speed in megabytes per second.",
44660702 11577 "format_description" : "mbps",
56122987 11578 "optional" : 1,
44660702 11579 "type" : "number"
56122987 11580 },
44660702
DM
11581 "mbps_rd" : {
11582 "description" : "Maximum read speed speed in megabytes per second.",
11583 "format_description" : "mbps",
11584 "optional" : 1,
11585 "type" : "number"
56122987 11586 },
44660702
DM
11587 "mbps_rd_max" : {
11588 "description" : "Maximum unthrottled read pool speed in megabytes per second.",
11589 "format_description" : "mbps",
56122987 11590 "optional" : 1,
44660702 11591 "type" : "number"
56122987 11592 },
44660702
DM
11593 "mbps_wr" : {
11594 "description" : "Maximum write speed speed in megabytes per second.",
11595 "format_description" : "mbps",
56122987 11596 "optional" : 1,
44660702 11597 "type" : "number"
56122987 11598 },
44660702
DM
11599 "mbps_wr_max" : {
11600 "description" : "Maximum unthrottled write pool speed in megabytes per second.",
11601 "format_description" : "mbps",
7aacca6f 11602 "optional" : 1,
44660702 11603 "type" : "number"
56122987 11604 },
7aacca6f 11605 "media" : {
44660702 11606 "default" : "disk",
7aacca6f
DM
11607 "description" : "The drive's media type.",
11608 "enum" : [
11609 "cdrom",
11610 "disk"
11611 ],
56122987 11612 "optional" : 1,
44660702 11613 "type" : "string"
56122987 11614 },
44660702
DM
11615 "queues" : {
11616 "description" : "Number of queues.",
44660702
DM
11617 "minimum" : 2,
11618 "optional" : 1,
11619 "type" : "integer"
56122987 11620 },
7aacca6f 11621 "secs" : {
7aacca6f 11622 "description" : "Force the drive's physical geometry to have a specific sector count.",
44660702
DM
11623 "optional" : 1,
11624 "type" : "integer"
11625 },
11626 "serial" : {
11627 "description" : "The drive's reported serial number, url-encoded, up to 20 bytes long.",
11628 "format" : "urlencoded",
11629 "format_description" : "serial",
11630 "maxLength" : 60,
11631 "optional" : 1,
11632 "type" : "string"
11633 },
11634 "size" : {
11635 "description" : "Disk size. This is purely informational and has no effect.",
11636 "format" : "disk-size",
f004f5b9 11637 "format_description" : "DiskSize",
44660702
DM
11638 "optional" : 1,
11639 "type" : "string"
11640 },
11641 "snapshot" : {
11642 "description" : "Whether the drive should be included when making snapshots.",
44660702
DM
11643 "optional" : 1,
11644 "type" : "boolean"
11645 },
11646 "trans" : {
11647 "description" : "Force disk geometry bios translation mode.",
11648 "enum" : [
11649 "none",
11650 "lba",
11651 "auto"
11652 ],
44660702
DM
11653 "optional" : 1,
11654 "type" : "string"
11655 },
11656 "volume" : {
11657 "alias" : "file"
11658 },
11659 "werror" : {
11660 "description" : "Write error action.",
11661 "enum" : [
11662 "enospc",
11663 "ignore",
11664 "report",
11665 "stop"
11666 ],
44660702
DM
11667 "optional" : 1,
11668 "type" : "string"
56122987
DM
11669 }
11670 },
7aacca6f 11671 "optional" : 1,
4bd7df8b
DM
11672 "type" : "string",
11673 "typetext" : "[file=]<volume> [,aio=<native|threads>] [,backup=<1|0>] [,bps=<bps>] [,bps_rd=<bps>] [,bps_wr=<bps>] [,cache=<none|writethrough|writeback|unsafe|directsync>] [,cyls=<integer>] [,detect_zeroes=<1|0>] [,discard=<ignore|on>] [,format=<image format>] [,heads=<integer>] [,iops=<iops>] [,iops_max=<iops>] [,iops_rd=<iops>] [,iops_rd_max=<iops>] [,iops_wr=<iops>] [,iops_wr_max=<iops>] [,iothread=<1|0>] [,mbps=<mbps>] [,mbps_max=<mbps>] [,mbps_rd=<mbps>] [,mbps_rd_max=<mbps>] [,mbps_wr=<mbps>] [,mbps_wr_max=<mbps>] [,media=<cdrom|disk>] [,queues=<integer>] [,secs=<integer>] [,serial=<serial>] [,size=<DiskSize>] [,snapshot=<1|0>] [,trans=<none|lba|auto>] [,werror=<enospc|ignore|report|stop>]"
56122987 11674 },
44660702
DM
11675 "scsihw" : {
11676 "default" : "lsi",
c2993fe5 11677 "description" : "SCSI controller model",
44660702
DM
11678 "enum" : [
11679 "lsi",
11680 "lsi53c810",
11681 "virtio-scsi-pci",
11682 "virtio-scsi-single",
11683 "megasas",
11684 "pvscsi"
11685 ],
7aacca6f 11686 "optional" : 1,
44660702 11687 "type" : "string"
7aacca6f 11688 },
44660702 11689 "serial[n]" : {
c2993fe5 11690 "description" : "Create a serial device inside the VM (n is 0 to 3)",
44660702
DM
11691 "optional" : 1,
11692 "pattern" : "(/dev/.+|socket)",
c2993fe5 11693 "type" : "string",
57b78691 11694 "verbose_description" : "Create a serial device inside the VM (n is 0 to 3), and pass through a\nhost serial device (i.e. /dev/ttyS0), or create a unix socket on the\nhost 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\nCAUTION: Experimental! User reported problems with this option.\n"
44660702
DM
11695 },
11696 "shares" : {
11697 "default" : 1000,
11698 "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",
11699 "maximum" : 50000,
11700 "minimum" : 0,
11701 "optional" : 1,
4bd7df8b 11702 "type" : "integer",
2c0dde61 11703 "typetext" : "integer (0 - 50000)"
44660702
DM
11704 },
11705 "smbios1" : {
11706 "description" : "Specify SMBIOS type 1 fields.",
11707 "format" : "pve-qm-smbios1",
11708 "maxLength" : 256,
7aacca6f 11709 "optional" : 1,
4bd7df8b
DM
11710 "type" : "string",
11711 "typetext" : "[family=<string>] [,manufacturer=<string>] [,product=<string>] [,serial=<string>] [,sku=<string>] [,uuid=<UUID>] [,version=<string>]"
7aacca6f
DM
11712 },
11713 "smp" : {
44660702 11714 "default" : 1,
7aacca6f 11715 "description" : "The number of CPUs. Please use option -sockets instead.",
44660702 11716 "minimum" : 1,
56122987 11717 "optional" : 1,
4bd7df8b 11718 "type" : "integer",
2c0dde61 11719 "typetext" : "integer (1 - N)"
44660702
DM
11720 },
11721 "sockets" : {
7aacca6f 11722 "default" : 1,
44660702
DM
11723 "description" : "The number of CPU sockets.",
11724 "minimum" : 1,
11725 "optional" : 1,
4bd7df8b 11726 "type" : "integer",
2c0dde61 11727 "typetext" : "integer (1 - N)"
7aacca6f 11728 },
44660702
DM
11729 "startdate" : {
11730 "default" : "now",
11731 "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'.",
11732 "optional" : 1,
11733 "pattern" : "(now|\\d{4}-\\d{1,2}-\\d{1,2}(T\\d{1,2}:\\d{1,2}:\\d{1,2})?)",
11734 "type" : "string",
11735 "typetext" : "(now | YYYY-MM-DD | YYYY-MM-DDTHH:MM:SS)"
11736 },
11737 "startup" : {
11738 "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.",
11739 "format" : "pve-startup-order",
11740 "optional" : 1,
11741 "type" : "string",
11742 "typetext" : "[[order=]\\d+] [,up=\\d+] [,down=\\d+] "
11743 },
11744 "storage" : {
11745 "description" : "Default storage.",
11746 "format" : "pve-storage-id",
7aacca6f 11747 "optional" : 1,
56122987
DM
11748 "type" : "string"
11749 },
44660702
DM
11750 "tablet" : {
11751 "default" : 1,
c2993fe5 11752 "description" : "Enable/disable the USB tablet device.",
56122987 11753 "optional" : 1,
c2993fe5
DM
11754 "type" : "boolean",
11755 "verbose_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)."
44660702
DM
11756 },
11757 "tdf" : {
11758 "default" : 0,
11759 "description" : "Enable/disable time drift fix.",
11760 "optional" : 1,
11761 "type" : "boolean"
7aacca6f
DM
11762 },
11763 "template" : {
7aacca6f 11764 "default" : 0,
44660702 11765 "description" : "Enable/disable Template.",
7aacca6f
DM
11766 "optional" : 1,
11767 "type" : "boolean"
11768 },
44660702
DM
11769 "unique" : {
11770 "description" : "Assign a unique random ethernet address.",
7aacca6f 11771 "optional" : 1,
44660702
DM
11772 "requires" : "archive",
11773 "type" : "boolean"
56122987 11774 },
44660702 11775 "unused[n]" : {
c2993fe5 11776 "description" : "Reference to unused volumes. This is used internally, and should not be modified manually.",
44660702 11777 "format" : "pve-volume-id",
7aacca6f 11778 "optional" : 1,
44660702
DM
11779 "type" : "string"
11780 },
11781 "usb[n]" : {
c2993fe5 11782 "description" : "Configure an USB device (n is 0 to 4).",
56122987 11783 "format" : {
7aacca6f
DM
11784 "host" : {
11785 "default_key" : 1,
c2993fe5 11786 "description" : "The Host USB device or port or the value 'spice'. 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",
7aacca6f 11787 "format" : "pve-qm-usb-device",
44660702
DM
11788 "format_description" : "HOSTUSBDEVICE|spice",
11789 "type" : "string"
7aacca6f 11790 },
56122987 11791 "usb3" : {
c2993fe5
DM
11792 "default" : 0,
11793 "description" : "Specifies whether if given host option is a USB3 device or port (this does currently not work reliably with spice redirection and is then ignored).",
56122987 11794 "optional" : 1,
56122987 11795 "type" : "boolean"
7aacca6f 11796 }
56122987 11797 },
56122987 11798 "optional" : 1,
4bd7df8b
DM
11799 "type" : "string",
11800 "typetext" : "[host=]<HOSTUSBDEVICE|spice> [,usb3=<1|0>]"
56122987 11801 },
44660702
DM
11802 "vcpus" : {
11803 "default" : 0,
11804 "description" : "Number of hotplugged vcpus.",
11805 "minimum" : 1,
56122987 11806 "optional" : 1,
4bd7df8b 11807 "type" : "integer",
2c0dde61 11808 "typetext" : "integer (1 - N)"
7aacca6f 11809 },
44660702 11810 "vga" : {
c2993fe5 11811 "description" : "Select the VGA type.",
44660702
DM
11812 "enum" : [
11813 "std",
11814 "cirrus",
11815 "vmware",
11816 "qxl",
11817 "serial0",
11818 "serial1",
11819 "serial2",
11820 "serial3",
11821 "qxl2",
11822 "qxl3",
11823 "qxl4"
11824 ],
11825 "optional" : 1,
c2993fe5
DM
11826 "type" : "string",
11827 "verbose_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."
7aacca6f 11828 },
44660702
DM
11829 "virtio[n]" : {
11830 "description" : "Use volume as VIRTIO hard disk (n is 0 to 15).",
11831 "format" : {
11832 "aio" : {
11833 "description" : "AIO type to use.",
11834 "enum" : [
11835 "native",
11836 "threads"
11837 ],
44660702
DM
11838 "optional" : 1,
11839 "type" : "string"
11840 },
11841 "backup" : {
11842 "description" : "Whether the drive should be included when making backups.",
44660702
DM
11843 "optional" : 1,
11844 "type" : "boolean"
11845 },
11846 "bps" : {
11847 "description" : "Maximum r/w speed speed in bytes per second.",
11848 "format_description" : "bps",
11849 "optional" : 1,
11850 "type" : "integer"
11851 },
11852 "bps_rd" : {
11853 "description" : "Maximum read speed speed in bytes per second.",
11854 "format_description" : "bps",
11855 "optional" : 1,
11856 "type" : "integer"
11857 },
11858 "bps_wr" : {
11859 "description" : "Maximum write speed speed in bytes per second.",
11860 "format_description" : "bps",
11861 "optional" : 1,
11862 "type" : "integer"
11863 },
11864 "cache" : {
11865 "description" : "The drive's cache mode",
11866 "enum" : [
11867 "none",
11868 "writethrough",
11869 "writeback",
11870 "unsafe",
11871 "directsync"
11872 ],
44660702
DM
11873 "optional" : 1,
11874 "type" : "string"
11875 },
11876 "cyls" : {
11877 "description" : "Force the drive's physical geometry to have a specific cylinder count.",
44660702
DM
11878 "optional" : 1,
11879 "type" : "integer"
11880 },
11881 "detect_zeroes" : {
11882 "description" : "Controls whether to detect and try to optimize writes of zeroes.",
11883 "optional" : 1,
11884 "type" : "boolean"
11885 },
11886 "discard" : {
11887 "description" : "Controls whether to pass discard/trim requests to the underlying storage.",
11888 "enum" : [
11889 "ignore",
11890 "on"
11891 ],
44660702
DM
11892 "optional" : 1,
11893 "type" : "string"
11894 },
11895 "file" : {
11896 "default_key" : 1,
11897 "description" : "The drive's backing volume.",
11898 "format" : "pve-volume-id-or-qm-path",
11899 "format_description" : "volume",
11900 "type" : "string"
11901 },
11902 "format" : {
11903 "description" : "The drive's backing file's data format.",
11904 "enum" : [
11905 "raw",
11906 "cow",
11907 "qcow",
11908 "qed",
11909 "qcow2",
11910 "vmdk",
11911 "cloop"
11912 ],
f004f5b9 11913 "format_description" : "image format",
44660702
DM
11914 "optional" : 1,
11915 "type" : "string"
11916 },
11917 "heads" : {
11918 "description" : "Force the drive's physical geometry to have a specific head count.",
44660702
DM
11919 "optional" : 1,
11920 "type" : "integer"
11921 },
11922 "iops" : {
11923 "description" : "Maximum r/w I/O speed in operations per second.",
11924 "format_description" : "iops",
11925 "optional" : 1,
11926 "type" : "integer"
11927 },
11928 "iops_max" : {
11929 "description" : "Maximum unthrottled r/w I/O pool speed in operations per second.",
11930 "format_description" : "iops",
11931 "optional" : 1,
11932 "type" : "integer"
11933 },
11934 "iops_rd" : {
11935 "description" : "Maximum read I/O speed in operations per second.",
11936 "format_description" : "iops",
11937 "optional" : 1,
11938 "type" : "integer"
11939 },
11940 "iops_rd_max" : {
11941 "description" : "Maximum unthrottled read I/O pool speed in operations per second.",
11942 "format_description" : "iops",
11943 "optional" : 1,
11944 "type" : "integer"
11945 },
11946 "iops_wr" : {
11947 "description" : "Maximum write I/O speed in operations per second.",
11948 "format_description" : "iops",
11949 "optional" : 1,
11950 "type" : "integer"
11951 },
11952 "iops_wr_max" : {
11953 "description" : "Maximum unthrottled write I/O pool speed in operations per second.",
11954 "format_description" : "iops",
11955 "optional" : 1,
11956 "type" : "integer"
11957 },
11958 "iothread" : {
11959 "description" : "Whether to use iothreads for this drive",
44660702
DM
11960 "optional" : 1,
11961 "type" : "boolean"
11962 },
11963 "mbps" : {
11964 "description" : "Maximum r/w speed speed in megabytes per second.",
11965 "format_description" : "mbps",
11966 "optional" : 1,
11967 "type" : "number"
11968 },
11969 "mbps_max" : {
11970 "description" : "Maximum unthrottled r/w pool speed in megabytes per second.",
11971 "format_description" : "mbps",
11972 "optional" : 1,
11973 "type" : "number"
11974 },
11975 "mbps_rd" : {
11976 "description" : "Maximum read speed speed in megabytes per second.",
11977 "format_description" : "mbps",
11978 "optional" : 1,
11979 "type" : "number"
11980 },
11981 "mbps_rd_max" : {
11982 "description" : "Maximum unthrottled read pool speed in megabytes per second.",
11983 "format_description" : "mbps",
11984 "optional" : 1,
11985 "type" : "number"
11986 },
11987 "mbps_wr" : {
11988 "description" : "Maximum write speed speed in megabytes per second.",
11989 "format_description" : "mbps",
11990 "optional" : 1,
11991 "type" : "number"
11992 },
11993 "mbps_wr_max" : {
11994 "description" : "Maximum unthrottled write pool speed in megabytes per second.",
11995 "format_description" : "mbps",
11996 "optional" : 1,
11997 "type" : "number"
11998 },
11999 "media" : {
12000 "default" : "disk",
12001 "description" : "The drive's media type.",
12002 "enum" : [
12003 "cdrom",
12004 "disk"
12005 ],
44660702
DM
12006 "optional" : 1,
12007 "type" : "string"
12008 },
12009 "rerror" : {
12010 "description" : "Read error action.",
12011 "enum" : [
12012 "ignore",
12013 "report",
12014 "stop"
12015 ],
44660702
DM
12016 "optional" : 1,
12017 "type" : "string"
12018 },
12019 "secs" : {
12020 "description" : "Force the drive's physical geometry to have a specific sector count.",
44660702
DM
12021 "optional" : 1,
12022 "type" : "integer"
12023 },
12024 "serial" : {
12025 "description" : "The drive's reported serial number, url-encoded, up to 20 bytes long.",
12026 "format" : "urlencoded",
12027 "format_description" : "serial",
12028 "maxLength" : 60,
12029 "optional" : 1,
12030 "type" : "string"
12031 },
12032 "size" : {
12033 "description" : "Disk size. This is purely informational and has no effect.",
12034 "format" : "disk-size",
f004f5b9 12035 "format_description" : "DiskSize",
44660702
DM
12036 "optional" : 1,
12037 "type" : "string"
12038 },
12039 "snapshot" : {
12040 "description" : "Whether the drive should be included when making snapshots.",
44660702
DM
12041 "optional" : 1,
12042 "type" : "boolean"
12043 },
12044 "trans" : {
12045 "description" : "Force disk geometry bios translation mode.",
12046 "enum" : [
12047 "none",
12048 "lba",
12049 "auto"
12050 ],
44660702
DM
12051 "optional" : 1,
12052 "type" : "string"
12053 },
12054 "volume" : {
12055 "alias" : "file"
12056 },
12057 "werror" : {
12058 "description" : "Write error action.",
12059 "enum" : [
12060 "enospc",
12061 "ignore",
12062 "report",
12063 "stop"
12064 ],
44660702
DM
12065 "optional" : 1,
12066 "type" : "string"
12067 }
12068 },
12069 "optional" : 1,
4bd7df8b
DM
12070 "type" : "string",
12071 "typetext" : "[file=]<volume> [,aio=<native|threads>] [,backup=<1|0>] [,bps=<bps>] [,bps_rd=<bps>] [,bps_wr=<bps>] [,cache=<none|writethrough|writeback|unsafe|directsync>] [,cyls=<integer>] [,detect_zeroes=<1|0>] [,discard=<ignore|on>] [,format=<image format>] [,heads=<integer>] [,iops=<iops>] [,iops_max=<iops>] [,iops_rd=<iops>] [,iops_rd_max=<iops>] [,iops_wr=<iops>] [,iops_wr_max=<iops>] [,iothread=<1|0>] [,mbps=<mbps>] [,mbps_max=<mbps>] [,mbps_rd=<mbps>] [,mbps_rd_max=<mbps>] [,mbps_wr=<mbps>] [,mbps_wr_max=<mbps>] [,media=<cdrom|disk>] [,rerror=<ignore|report|stop>] [,secs=<integer>] [,serial=<serial>] [,size=<DiskSize>] [,snapshot=<1|0>] [,trans=<none|lba|auto>] [,werror=<enospc|ignore|report|stop>]"
7aacca6f 12072 },
44660702
DM
12073 "vmid" : {
12074 "description" : "The (unique) ID of the VM.",
12075 "format" : "pve-vmid",
12076 "minimum" : 1,
4bd7df8b 12077 "type" : "integer",
2c0dde61 12078 "typetext" : "integer (1 - N)"
44660702
DM
12079 },
12080 "watchdog" : {
c2993fe5 12081 "description" : "Create a virtual hardware watchdog device.",
44660702 12082 "format" : "pve-qm-watchdog",
7aacca6f 12083 "optional" : 1,
c2993fe5 12084 "type" : "string",
4bd7df8b 12085 "typetext" : "[[model=]<i6300esb|ib700>] [,action=<reset|shutdown|poweroff|pause|debug|none>]",
c2993fe5 12086 "verbose_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)"
56122987 12087 }
44660702 12088 }
56122987 12089 },
56122987 12090 "permissions" : {
44660702
DM
12091 "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.",
12092 "user" : "all"
56122987 12093 },
44660702
DM
12094 "protected" : 1,
12095 "proxyto" : "node",
56122987 12096 "returns" : {
44660702 12097 "type" : "string"
7aacca6f 12098 }
56122987 12099 }
7aacca6f 12100 },
44660702 12101 "leaf" : 0,
7aacca6f 12102 "path" : "/nodes/{node}/qemu",
44660702 12103 "text" : "qemu"
56122987
DM
12104 },
12105 {
12106 "children" : [
12107 {
56122987
DM
12108 "children" : [
12109 {
56122987 12110 "info" : {
44660702
DM
12111 "GET" : {
12112 "description" : "Get container configuration.",
12113 "method" : "GET",
12114 "name" : "vm_config",
12115 "parameters" : {
12116 "additionalProperties" : 0,
12117 "properties" : {
12118 "node" : {
12119 "description" : "The cluster node name.",
12120 "format" : "pve-node",
12121 "type" : "string"
12122 },
12123 "vmid" : {
12124 "description" : "The (unique) ID of the VM.",
12125 "format" : "pve-vmid",
12126 "minimum" : 1,
4bd7df8b 12127 "type" : "integer",
2c0dde61 12128 "typetext" : "integer (1 - N)"
44660702
DM
12129 }
12130 }
12131 },
12132 "permissions" : {
12133 "check" : [
12134 "perm",
12135 "/vms/{vmid}",
12136 [
12137 "VM.Audit"
12138 ]
12139 ]
12140 },
12141 "proxyto" : "node",
12142 "returns" : {
12143 "properties" : {
12144 "digest" : {
12145 "description" : "SHA1 digest of configuration file. This can be used to prevent concurrent modifications.",
12146 "type" : "string"
12147 }
12148 },
12149 "type" : "object"
12150 }
12151 },
56122987 12152 "PUT" : {
44660702
DM
12153 "description" : "Set container options.",
12154 "method" : "PUT",
12155 "name" : "update_vm",
56122987 12156 "parameters" : {
44660702 12157 "additionalProperties" : 0,
56122987 12158 "properties" : {
44660702
DM
12159 "arch" : {
12160 "default" : "amd64",
12161 "description" : "OS architecture type.",
12162 "enum" : [
12163 "amd64",
12164 "i386"
12165 ],
7aacca6f 12166 "optional" : 1,
44660702
DM
12167 "type" : "string"
12168 },
12169 "cmode" : {
7aacca6f 12170 "default" : "tty",
44660702 12171 "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).",
7aacca6f
DM
12172 "enum" : [
12173 "shell",
12174 "console",
12175 "tty"
12176 ],
44660702
DM
12177 "optional" : 1,
12178 "type" : "string"
7aacca6f 12179 },
44660702
DM
12180 "console" : {
12181 "default" : 1,
12182 "description" : "Attach a console device (/dev/console) to the container.",
7aacca6f 12183 "optional" : 1,
44660702 12184 "type" : "boolean"
7aacca6f 12185 },
44660702
DM
12186 "cpulimit" : {
12187 "default" : 0,
12188 "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.",
12189 "maximum" : 128,
7aacca6f 12190 "minimum" : 0,
7aacca6f 12191 "optional" : 1,
4bd7df8b 12192 "type" : "number",
2c0dde61 12193 "typetext" : "number (0 - 128)"
7aacca6f 12194 },
44660702
DM
12195 "cpuunits" : {
12196 "default" : 1024,
12197 "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.",
12198 "maximum" : 500000,
12199 "minimum" : 0,
12200 "optional" : 1,
4bd7df8b 12201 "type" : "integer",
2c0dde61 12202 "typetext" : "integer (0 - 500000)"
7aacca6f 12203 },
44660702
DM
12204 "delete" : {
12205 "description" : "A list of settings you want to delete.",
12206 "format" : "pve-configid-list",
7aacca6f 12207 "optional" : 1,
44660702 12208 "type" : "string"
7aacca6f 12209 },
44660702
DM
12210 "description" : {
12211 "description" : "Container description. Only used on the configuration web interface.",
7aacca6f 12212 "optional" : 1,
44660702 12213 "type" : "string"
7aacca6f 12214 },
44660702
DM
12215 "digest" : {
12216 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
12217 "maxLength" : 40,
7aacca6f 12218 "optional" : 1,
44660702 12219 "type" : "string"
7aacca6f 12220 },
44660702
DM
12221 "hostname" : {
12222 "description" : "Set a host name for the container.",
12223 "format" : "dns-name",
12224 "maxLength" : 255,
56122987 12225 "optional" : 1,
44660702
DM
12226 "type" : "string"
12227 },
12228 "lock" : {
12229 "description" : "Lock/unlock the VM.",
12230 "enum" : [
12231 "migrate",
12232 "backup",
12233 "snapshot",
12234 "rollback"
12235 ],
12236 "optional" : 1,
12237 "type" : "string"
12238 },
12239 "memory" : {
12240 "default" : 512,
12241 "description" : "Amount of RAM for the VM in MB.",
12242 "minimum" : 16,
12243 "optional" : 1,
4bd7df8b 12244 "type" : "integer",
2c0dde61 12245 "typetext" : "integer (16 - N)"
7aacca6f
DM
12246 },
12247 "mp[n]" : {
c2993fe5 12248 "description" : "Use volume as container mount point.",
7aacca6f 12249 "format" : {
7aacca6f
DM
12250 "acl" : {
12251 "description" : "Explicitly enable or disable ACL support.",
7aacca6f 12252 "optional" : 1,
44660702 12253 "type" : "boolean"
7aacca6f
DM
12254 },
12255 "backup" : {
12256 "description" : "Whether to include the mountpoint in backups.",
12257 "optional" : 1,
4bd7df8b
DM
12258 "type" : "boolean",
12259 "verbose_description" : "Whether to include the mountpoint in backups (only used for volume mountpoints)."
7aacca6f
DM
12260 },
12261 "mp" : {
4bd7df8b 12262 "description" : "Path to the mountpoint as seen from inside the container (must not contain symlinks).",
7aacca6f 12263 "format" : "pve-lxc-mp-string",
44660702 12264 "format_description" : "Path",
4bd7df8b
DM
12265 "type" : "string",
12266 "verbose_description" : "Path to the mountpoint as seen from inside the container.\n\nNOTE: Must not contain any symlinks for security reasons."
44660702
DM
12267 },
12268 "quota" : {
12269 "description" : "Enable user quotas inside the container (not supported with zfs subvolumes)",
44660702
DM
12270 "optional" : 1,
12271 "type" : "boolean"
12272 },
12273 "ro" : {
4bd7df8b 12274 "description" : "Read-only mountpoint",
44660702
DM
12275 "optional" : 1,
12276 "type" : "boolean"
12277 },
12278 "size" : {
12279 "description" : "Volume size (read only value).",
12280 "format" : "disk-size",
12281 "format_description" : "DiskSize",
12282 "optional" : 1,
12283 "type" : "string"
12284 },
12285 "volume" : {
12286 "default_key" : 1,
12287 "description" : "Volume, device or directory to mount into the container.",
12288 "format" : "pve-lxc-mp-string",
12289 "format_description" : "volume",
12290 "type" : "string"
12291 }
12292 },
7aacca6f 12293 "optional" : 1,
4bd7df8b
DM
12294 "type" : "string",
12295 "typetext" : "[volume=]<volume> ,mp=<Path> [,acl=<1|0>] [,backup=<1|0>] [,quota=<1|0>] [,ro=<1|0>] [,size=<DiskSize>]"
56122987 12296 },
44660702
DM
12297 "nameserver" : {
12298 "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.",
12299 "format" : "address-list",
56122987 12300 "optional" : 1,
44660702 12301 "type" : "string"
56122987
DM
12302 },
12303 "net[n]" : {
44660702 12304 "description" : "Specifies network interfaces for the container.",
56122987 12305 "format" : {
44660702
DM
12306 "bridge" : {
12307 "description" : "Bridge to attach the network device to.",
f004f5b9 12308 "format_description" : "bridge",
56122987 12309 "optional" : 1,
44660702
DM
12310 "pattern" : "[-_.\\w\\d]+",
12311 "type" : "string"
56122987 12312 },
44660702
DM
12313 "firewall" : {
12314 "description" : "Controls whether this interface's firewall rules should be used.",
56122987 12315 "optional" : 1,
44660702 12316 "type" : "boolean"
56122987 12317 },
44660702
DM
12318 "gw" : {
12319 "description" : "Default gateway for IPv4 traffic.",
12320 "format" : "ipv4",
12321 "format_description" : "GatewayIPv4",
56122987 12322 "optional" : 1,
44660702 12323 "type" : "string"
56122987
DM
12324 },
12325 "gw6" : {
7aacca6f 12326 "description" : "Default gateway for IPv6 traffic.",
44660702
DM
12327 "format" : "ipv6",
12328 "format_description" : "GatewayIPv6",
7aacca6f 12329 "optional" : 1,
56122987
DM
12330 "type" : "string"
12331 },
44660702 12332 "hwaddr" : {
f004f5b9
DM
12333 "description" : "The interface MAC address. This is dynamically allocated by default, but you can set that statically if needed, for example to always have the same link-local IPv6 address. (lxc.network.hwaddr)",
12334 "format_description" : "XX:XX:XX:XX:XX:XX",
44660702
DM
12335 "optional" : 1,
12336 "pattern" : "(?^i:(?:[a-f0-9]{2}:){5}[a-f0-9]{2})",
12337 "type" : "string"
12338 },
12339 "ip" : {
12340 "description" : "IPv4 address in CIDR format.",
12341 "format" : "pve-ipv4-config",
12342 "format_description" : "IPv4Format/CIDR",
56122987 12343 "optional" : 1,
44660702 12344 "type" : "string"
56122987 12345 },
7aacca6f 12346 "ip6" : {
7aacca6f
DM
12347 "description" : "IPv6 address in CIDR format.",
12348 "format" : "pve-ipv6-config",
44660702 12349 "format_description" : "IPv6Format/CIDR",
7aacca6f 12350 "optional" : 1,
44660702 12351 "type" : "string"
56122987 12352 },
44660702
DM
12353 "mtu" : {
12354 "description" : "Maximum transfer unit of the interface. (lxc.network.mtu)",
44660702 12355 "minimum" : 64,
56122987 12356 "optional" : 1,
44660702 12357 "type" : "integer"
56122987
DM
12358 },
12359 "name" : {
44660702 12360 "description" : "Name of the network device as seen from inside the container. (lxc.network.name)",
f004f5b9 12361 "format_description" : "string",
56122987 12362 "pattern" : "[-_.\\w\\d]+",
44660702 12363 "type" : "string"
56122987 12364 },
44660702
DM
12365 "rate" : {
12366 "description" : "Apply rate limiting to the interface",
12367 "format_description" : "mbps",
56122987 12368 "optional" : 1,
44660702 12369 "type" : "number"
7aacca6f 12370 },
44660702
DM
12371 "tag" : {
12372 "description" : "VLAN tag for this interface.",
4bd7df8b
DM
12373 "maximum" : 4094,
12374 "minimum" : 1,
56122987 12375 "optional" : 1,
7aacca6f 12376 "type" : "integer"
56122987 12377 },
44660702
DM
12378 "trunks" : {
12379 "description" : "VLAN ids to pass through the interface",
12380 "format_description" : "vlanid[;vlanid...]",
12381 "optional" : 1,
12382 "pattern" : "(?^:\\d+(?:;\\d+)*)",
12383 "type" : "string"
12384 },
12385 "type" : {
12386 "description" : "Network interface type.",
12387 "enum" : [
12388 "veth"
12389 ],
56122987 12390 "optional" : 1,
44660702 12391 "type" : "string"
56122987
DM
12392 }
12393 },
7aacca6f 12394 "optional" : 1,
4bd7df8b
DM
12395 "type" : "string",
12396 "typetext" : "name=<string> [,bridge=<bridge>] [,firewall=<1|0>] [,gw=<GatewayIPv4>] [,gw6=<GatewayIPv6>] [,hwaddr=<XX:XX:XX:XX:XX:XX>] [,ip=<IPv4Format/CIDR>] [,ip6=<IPv6Format/CIDR>] [,mtu=<integer>] [,rate=<mbps>] [,tag=<integer>] [,trunks=<vlanid[;vlanid...]>] [,type=<veth>]"
56122987 12397 },
44660702
DM
12398 "node" : {
12399 "description" : "The cluster node name.",
12400 "format" : "pve-node",
12401 "type" : "string"
56122987 12402 },
44660702
DM
12403 "onboot" : {
12404 "default" : 0,
12405 "description" : "Specifies whether a VM will be started during system bootup.",
56122987 12406 "optional" : 1,
44660702 12407 "type" : "boolean"
56122987 12408 },
44660702
DM
12409 "ostype" : {
12410 "description" : "OS type. This is used to setup configuration inside the container, and corresponds to lxc setup scripts in /usr/share/lxc/config/<ostype>.common.conf. Value 'unmanaged' can be used to skip and OS specific setup.",
12411 "enum" : [
12412 "debian",
12413 "ubuntu",
12414 "centos",
12415 "fedora",
12416 "opensuse",
12417 "archlinux",
12418 "alpine",
57b78691 12419 "gentoo",
44660702
DM
12420 "unmanaged"
12421 ],
56122987 12422 "optional" : 1,
44660702 12423 "type" : "string"
56122987 12424 },
44660702
DM
12425 "protection" : {
12426 "default" : 0,
12427 "description" : "Sets the protection flag of the container. This will prevent the CT or CT's disk remove/update operation.",
56122987 12428 "optional" : 1,
44660702 12429 "type" : "boolean"
56122987 12430 },
7aacca6f
DM
12431 "rootfs" : {
12432 "description" : "Use volume as container root.",
56122987
DM
12433 "format" : {
12434 "acl" : {
44660702 12435 "description" : "Explicitly enable or disable ACL support.",
7aacca6f
DM
12436 "optional" : 1,
12437 "type" : "boolean"
56122987 12438 },
44660702
DM
12439 "quota" : {
12440 "description" : "Enable user quotas inside the container (not supported with zfs subvolumes)",
44660702
DM
12441 "optional" : 1,
12442 "type" : "boolean"
12443 },
12444 "ro" : {
4bd7df8b 12445 "description" : "Read-only mountpoint",
56122987 12446 "optional" : 1,
44660702
DM
12447 "type" : "boolean"
12448 },
12449 "size" : {
7aacca6f 12450 "description" : "Volume size (read only value).",
44660702 12451 "format" : "disk-size",
56122987 12452 "format_description" : "DiskSize",
56122987 12453 "optional" : 1,
44660702 12454 "type" : "string"
7aacca6f
DM
12455 },
12456 "volume" : {
7aacca6f
DM
12457 "default_key" : 1,
12458 "description" : "Volume, device or directory to mount into the container.",
44660702
DM
12459 "format" : "pve-lxc-mp-string",
12460 "format_description" : "volume",
7aacca6f 12461 "type" : "string"
56122987 12462 }
44660702
DM
12463 },
12464 "optional" : 1,
4bd7df8b
DM
12465 "type" : "string",
12466 "typetext" : "[volume=]<volume> [,acl=<1|0>] [,quota=<1|0>] [,ro=<1|0>] [,size=<DiskSize>]"
44660702
DM
12467 },
12468 "searchdomain" : {
12469 "description" : "Sets DNS search domains for a container. Create will automatically use the setting from the host if you neither set searchdomain nor nameserver.",
12470 "format" : "dns-name-list",
12471 "optional" : 1,
12472 "type" : "string"
12473 },
12474 "startup" : {
12475 "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.",
12476 "format" : "pve-startup-order",
12477 "optional" : 1,
12478 "type" : "string",
12479 "typetext" : "[[order=]\\d+] [,up=\\d+] [,down=\\d+] "
12480 },
12481 "swap" : {
12482 "default" : 512,
12483 "description" : "Amount of SWAP for the VM in MB.",
12484 "minimum" : 0,
12485 "optional" : 1,
4bd7df8b 12486 "type" : "integer",
2c0dde61 12487 "typetext" : "integer (0 - N)"
56122987 12488 },
56122987 12489 "template" : {
44660702 12490 "default" : 0,
7aacca6f 12491 "description" : "Enable/disable Template.",
56122987 12492 "optional" : 1,
44660702 12493 "type" : "boolean"
56122987 12494 },
44660702
DM
12495 "tty" : {
12496 "default" : 2,
12497 "description" : "Specify the number of tty available to the container",
12498 "maximum" : 6,
12499 "minimum" : 0,
12500 "optional" : 1,
4bd7df8b 12501 "type" : "integer",
2c0dde61 12502 "typetext" : "integer (0 - 6)"
56122987 12503 },
44660702
DM
12504 "unprivileged" : {
12505 "default" : 0,
12506 "description" : "Makes the container run as unprivileged user. (Should not be modified manually.)",
56122987 12507 "optional" : 1,
44660702 12508 "type" : "boolean"
56122987 12509 },
44660702 12510 "unused[n]" : {
c2993fe5 12511 "description" : "Reference to unused volumes. This is used internally, and should not be modified manually.",
44660702 12512 "format" : "pve-volume-id",
56122987 12513 "optional" : 1,
44660702
DM
12514 "type" : "string"
12515 },
12516 "vmid" : {
12517 "description" : "The (unique) ID of the VM.",
12518 "format" : "pve-vmid",
12519 "minimum" : 1,
4bd7df8b 12520 "type" : "integer",
2c0dde61 12521 "typetext" : "integer (1 - N)"
56122987 12522 }
44660702 12523 }
56122987 12524 },
56122987
DM
12525 "permissions" : {
12526 "check" : [
12527 "perm",
12528 "/vms/{vmid}",
12529 [
12530 "VM.Config.Disk",
12531 "VM.Config.CPU",
12532 "VM.Config.Memory",
12533 "VM.Config.Network",
12534 "VM.Config.Options"
12535 ],
12536 "any",
12537 1
12538 ]
12539 },
44660702
DM
12540 "protected" : 1,
12541 "proxyto" : "node",
56122987
DM
12542 "returns" : {
12543 "type" : "null"
7aacca6f 12544 }
56122987 12545 }
7aacca6f 12546 },
44660702 12547 "leaf" : 1,
7aacca6f 12548 "path" : "/nodes/{node}/lxc/{vmid}/config",
44660702 12549 "text" : "config"
56122987
DM
12550 },
12551 {
56122987
DM
12552 "children" : [
12553 {
12554 "info" : {
12555 "GET" : {
44660702 12556 "description" : "Get virtual machine status.",
7aacca6f 12557 "method" : "GET",
44660702 12558 "name" : "vm_status",
56122987 12559 "parameters" : {
44660702 12560 "additionalProperties" : 0,
56122987 12561 "properties" : {
56122987 12562 "node" : {
44660702 12563 "description" : "The cluster node name.",
56122987 12564 "format" : "pve-node",
44660702 12565 "type" : "string"
7aacca6f
DM
12566 },
12567 "vmid" : {
12568 "description" : "The (unique) ID of the VM.",
44660702 12569 "format" : "pve-vmid",
7aacca6f 12570 "minimum" : 1,
4bd7df8b 12571 "type" : "integer",
2c0dde61 12572 "typetext" : "integer (1 - N)"
56122987 12573 }
44660702 12574 }
7aacca6f
DM
12575 },
12576 "permissions" : {
12577 "check" : [
12578 "perm",
12579 "/vms/{vmid}",
12580 [
12581 "VM.Audit"
12582 ]
12583 ]
12584 },
44660702 12585 "protected" : 1,
7aacca6f 12586 "proxyto" : "node",
44660702
DM
12587 "returns" : {
12588 "type" : "object"
12589 }
56122987
DM
12590 }
12591 },
44660702
DM
12592 "leaf" : 1,
12593 "path" : "/nodes/{node}/lxc/{vmid}/status/current",
56122987
DM
12594 "text" : "current"
12595 },
12596 {
56122987
DM
12597 "info" : {
12598 "POST" : {
7aacca6f 12599 "description" : "Start the container.",
44660702 12600 "method" : "POST",
7aacca6f 12601 "name" : "vm_start",
56122987
DM
12602 "parameters" : {
12603 "additionalProperties" : 0,
12604 "properties" : {
56122987 12605 "node" : {
7aacca6f 12606 "description" : "The cluster node name.",
44660702
DM
12607 "format" : "pve-node",
12608 "type" : "string"
56122987 12609 },
7aacca6f 12610 "skiplock" : {
44660702 12611 "description" : "Ignore locks - only root is allowed to use this option.",
7aacca6f 12612 "optional" : 1,
44660702 12613 "type" : "boolean"
7aacca6f 12614 },
56122987 12615 "vmid" : {
7aacca6f 12616 "description" : "The (unique) ID of the VM.",
44660702 12617 "format" : "pve-vmid",
56122987 12618 "minimum" : 1,
4bd7df8b 12619 "type" : "integer",
2c0dde61 12620 "typetext" : "integer (1 - N)"
56122987
DM
12621 }
12622 }
12623 },
12624 "permissions" : {
12625 "check" : [
12626 "perm",
12627 "/vms/{vmid}",
12628 [
12629 "VM.PowerMgmt"
12630 ]
12631 ]
12632 },
44660702 12633 "protected" : 1,
7aacca6f 12634 "proxyto" : "node",
44660702
DM
12635 "returns" : {
12636 "type" : "string"
12637 }
12638 }
12639 },
12640 "leaf" : 1,
12641 "path" : "/nodes/{node}/lxc/{vmid}/status/start",
12642 "text" : "start"
12643 },
12644 {
12645 "info" : {
12646 "POST" : {
12647 "description" : "Stop the container. This will abruptly stop all processes running in the container.",
7aacca6f
DM
12648 "method" : "POST",
12649 "name" : "vm_stop",
12650 "parameters" : {
44660702 12651 "additionalProperties" : 0,
7aacca6f 12652 "properties" : {
44660702
DM
12653 "node" : {
12654 "description" : "The cluster node name.",
12655 "format" : "pve-node",
12656 "type" : "string"
12657 },
7aacca6f
DM
12658 "skiplock" : {
12659 "description" : "Ignore locks - only root is allowed to use this option.",
44660702
DM
12660 "optional" : 1,
12661 "type" : "boolean"
7aacca6f
DM
12662 },
12663 "vmid" : {
44660702 12664 "description" : "The (unique) ID of the VM.",
7aacca6f
DM
12665 "format" : "pve-vmid",
12666 "minimum" : 1,
4bd7df8b 12667 "type" : "integer",
2c0dde61 12668 "typetext" : "integer (1 - N)"
7aacca6f 12669 }
44660702
DM
12670 }
12671 },
12672 "permissions" : {
12673 "check" : [
12674 "perm",
12675 "/vms/{vmid}",
12676 [
12677 "VM.PowerMgmt"
12678 ]
12679 ]
7aacca6f 12680 },
44660702
DM
12681 "protected" : 1,
12682 "proxyto" : "node",
12683 "returns" : {
12684 "type" : "string"
12685 }
56122987 12686 }
7aacca6f 12687 },
7aacca6f 12688 "leaf" : 1,
44660702
DM
12689 "path" : "/nodes/{node}/lxc/{vmid}/status/stop",
12690 "text" : "stop"
56122987
DM
12691 },
12692 {
56122987
DM
12693 "info" : {
12694 "POST" : {
44660702
DM
12695 "description" : "Shutdown the container. This will trigger a clean shutdown of the container, see lxc-stop(1) for details.",
12696 "method" : "POST",
7aacca6f 12697 "name" : "vm_shutdown",
56122987 12698 "parameters" : {
44660702 12699 "additionalProperties" : 0,
56122987 12700 "properties" : {
7aacca6f 12701 "forceStop" : {
44660702 12702 "default" : 0,
7aacca6f
DM
12703 "description" : "Make sure the Container stops.",
12704 "optional" : 1,
44660702
DM
12705 "type" : "boolean"
12706 },
12707 "node" : {
12708 "description" : "The cluster node name.",
12709 "format" : "pve-node",
12710 "type" : "string"
7aacca6f
DM
12711 },
12712 "timeout" : {
7aacca6f 12713 "default" : 60,
44660702
DM
12714 "description" : "Wait maximal timeout seconds.",
12715 "minimum" : 0,
56122987 12716 "optional" : 1,
4bd7df8b 12717 "type" : "integer",
2c0dde61 12718 "typetext" : "integer (0 - N)"
56122987
DM
12719 },
12720 "vmid" : {
7aacca6f 12721 "description" : "The (unique) ID of the VM.",
44660702
DM
12722 "format" : "pve-vmid",
12723 "minimum" : 1,
4bd7df8b 12724 "type" : "integer",
2c0dde61 12725 "typetext" : "integer (1 - N)"
56122987 12726 }
44660702 12727 }
56122987
DM
12728 },
12729 "permissions" : {
12730 "check" : [
12731 "perm",
12732 "/vms/{vmid}",
12733 [
12734 "VM.PowerMgmt"
12735 ]
12736 ]
12737 },
44660702
DM
12738 "protected" : 1,
12739 "proxyto" : "node",
7aacca6f
DM
12740 "returns" : {
12741 "type" : "string"
12742 }
56122987
DM
12743 }
12744 },
44660702
DM
12745 "leaf" : 1,
12746 "path" : "/nodes/{node}/lxc/{vmid}/status/shutdown",
7aacca6f 12747 "text" : "shutdown"
56122987
DM
12748 },
12749 {
56122987
DM
12750 "info" : {
12751 "POST" : {
7aacca6f 12752 "description" : "Suspend the container.",
7aacca6f 12753 "method" : "POST",
7aacca6f 12754 "name" : "vm_suspend",
56122987
DM
12755 "parameters" : {
12756 "additionalProperties" : 0,
12757 "properties" : {
44660702
DM
12758 "node" : {
12759 "description" : "The cluster node name.",
12760 "format" : "pve-node",
12761 "type" : "string"
12762 },
7aacca6f 12763 "vmid" : {
7aacca6f
DM
12764 "description" : "The (unique) ID of the VM.",
12765 "format" : "pve-vmid",
44660702 12766 "minimum" : 1,
4bd7df8b 12767 "type" : "integer",
2c0dde61 12768 "typetext" : "integer (1 - N)"
56122987
DM
12769 }
12770 }
7aacca6f 12771 },
56122987
DM
12772 "permissions" : {
12773 "check" : [
12774 "perm",
12775 "/vms/{vmid}",
12776 [
12777 "VM.PowerMgmt"
12778 ]
12779 ]
12780 },
7aacca6f 12781 "protected" : 1,
44660702
DM
12782 "proxyto" : "node",
12783 "returns" : {
12784 "type" : "string"
12785 }
12786 }
12787 },
12788 "leaf" : 1,
12789 "path" : "/nodes/{node}/lxc/{vmid}/status/suspend",
12790 "text" : "suspend"
12791 },
12792 {
12793 "info" : {
12794 "POST" : {
12795 "description" : "Resume the container.",
12796 "method" : "POST",
12797 "name" : "vm_resume",
56122987 12798 "parameters" : {
44660702 12799 "additionalProperties" : 0,
56122987
DM
12800 "properties" : {
12801 "node" : {
7aacca6f 12802 "description" : "The cluster node name.",
44660702
DM
12803 "format" : "pve-node",
12804 "type" : "string"
56122987
DM
12805 },
12806 "vmid" : {
7aacca6f 12807 "description" : "The (unique) ID of the VM.",
56122987 12808 "format" : "pve-vmid",
44660702 12809 "minimum" : 1,
4bd7df8b 12810 "type" : "integer",
2c0dde61 12811 "typetext" : "integer (1 - N)"
56122987 12812 }
44660702
DM
12813 }
12814 },
12815 "permissions" : {
12816 "check" : [
12817 "perm",
12818 "/vms/{vmid}",
12819 [
12820 "VM.PowerMgmt"
12821 ]
12822 ]
56122987 12823 },
44660702
DM
12824 "protected" : 1,
12825 "proxyto" : "node",
12826 "returns" : {
12827 "type" : "string"
12828 }
7aacca6f
DM
12829 }
12830 },
44660702
DM
12831 "leaf" : 1,
12832 "path" : "/nodes/{node}/lxc/{vmid}/status/resume",
7aacca6f
DM
12833 "text" : "resume"
12834 }
12835 ],
12836 "info" : {
12837 "GET" : {
7aacca6f 12838 "description" : "Directory index",
44660702 12839 "method" : "GET",
7aacca6f 12840 "name" : "vmcmdidx",
7aacca6f
DM
12841 "parameters" : {
12842 "additionalProperties" : 0,
12843 "properties" : {
12844 "node" : {
12845 "description" : "The cluster node name.",
44660702
DM
12846 "format" : "pve-node",
12847 "type" : "string"
56122987 12848 },
7aacca6f 12849 "vmid" : {
44660702 12850 "description" : "The (unique) ID of the VM.",
7aacca6f
DM
12851 "format" : "pve-vmid",
12852 "minimum" : 1,
4bd7df8b 12853 "type" : "integer",
2c0dde61 12854 "typetext" : "integer (1 - N)"
7aacca6f 12855 }
56122987
DM
12856 }
12857 },
44660702
DM
12858 "permissions" : {
12859 "user" : "all"
12860 },
12861 "proxyto" : "node",
7aacca6f 12862 "returns" : {
7aacca6f
DM
12863 "items" : {
12864 "properties" : {
12865 "subdir" : {
12866 "type" : "string"
12867 }
12868 },
12869 "type" : "object"
12870 },
12871 "links" : [
12872 {
44660702
DM
12873 "href" : "{subdir}",
12874 "rel" : "child"
7aacca6f 12875 }
44660702
DM
12876 ],
12877 "type" : "array"
7aacca6f
DM
12878 }
12879 }
44660702
DM
12880 },
12881 "leaf" : 0,
12882 "path" : "/nodes/{node}/lxc/{vmid}/status",
12883 "text" : "status"
7aacca6f
DM
12884 },
12885 {
7aacca6f 12886 "children" : [
56122987 12887 {
7aacca6f
DM
12888 "children" : [
12889 {
12890 "info" : {
12891 "POST" : {
7aacca6f 12892 "description" : "Rollback LXC state to specified snapshot.",
7aacca6f 12893 "method" : "POST",
44660702 12894 "name" : "rollback",
7aacca6f 12895 "parameters" : {
44660702 12896 "additionalProperties" : 0,
7aacca6f 12897 "properties" : {
44660702
DM
12898 "node" : {
12899 "description" : "The cluster node name.",
12900 "format" : "pve-node",
12901 "type" : "string"
12902 },
7aacca6f 12903 "snapname" : {
44660702 12904 "description" : "The name of the snapshot.",
7aacca6f
DM
12905 "format" : "pve-configid",
12906 "maxLength" : 40,
7aacca6f
DM
12907 "type" : "string"
12908 },
7aacca6f 12909 "vmid" : {
44660702 12910 "description" : "The (unique) ID of the VM.",
7aacca6f 12911 "format" : "pve-vmid",
44660702 12912 "minimum" : 1,
4bd7df8b 12913 "type" : "integer",
2c0dde61 12914 "typetext" : "integer (1 - N)"
7aacca6f 12915 }
44660702
DM
12916 }
12917 },
12918 "permissions" : {
12919 "check" : [
12920 "perm",
12921 "/vms/{vmid}",
12922 [
12923 "VM.Snapshot"
12924 ]
12925 ]
7aacca6f 12926 },
44660702
DM
12927 "protected" : 1,
12928 "proxyto" : "node",
12929 "returns" : {
12930 "description" : "the task ID.",
12931 "type" : "string"
12932 }
7aacca6f
DM
12933 }
12934 },
7aacca6f 12935 "leaf" : 1,
44660702
DM
12936 "path" : "/nodes/{node}/lxc/{vmid}/snapshot/{snapname}/rollback",
12937 "text" : "rollback"
7aacca6f
DM
12938 },
12939 {
7aacca6f
DM
12940 "info" : {
12941 "GET" : {
7aacca6f 12942 "description" : "Get snapshot configuration",
44660702
DM
12943 "method" : "GET",
12944 "name" : "get_snapshot_config",
7aacca6f
DM
12945 "parameters" : {
12946 "additionalProperties" : 0,
12947 "properties" : {
7aacca6f 12948 "node" : {
7aacca6f 12949 "description" : "The cluster node name.",
44660702 12950 "format" : "pve-node",
7aacca6f
DM
12951 "type" : "string"
12952 },
12953 "snapname" : {
44660702 12954 "description" : "The name of the snapshot.",
7aacca6f
DM
12955 "format" : "pve-configid",
12956 "maxLength" : 40,
44660702
DM
12957 "type" : "string"
12958 },
12959 "vmid" : {
12960 "description" : "The (unique) ID of the VM.",
12961 "format" : "pve-vmid",
12962 "minimum" : 1,
4bd7df8b 12963 "type" : "integer",
2c0dde61 12964 "typetext" : "integer (1 - N)"
7aacca6f
DM
12965 }
12966 }
12967 },
12968 "permissions" : {
12969 "check" : [
12970 "perm",
12971 "/vms/{vmid}",
12972 [
12973 "VM.Snapshot"
12974 ]
12975 ]
12976 },
44660702
DM
12977 "proxyto" : "node",
12978 "returns" : {
12979 "type" : "object"
12980 }
7aacca6f
DM
12981 },
12982 "PUT" : {
44660702
DM
12983 "description" : "Update snapshot metadata.",
12984 "method" : "PUT",
7aacca6f
DM
12985 "name" : "update_snapshot_config",
12986 "parameters" : {
12987 "additionalProperties" : 0,
12988 "properties" : {
44660702
DM
12989 "description" : {
12990 "description" : "A textual description or comment.",
12991 "optional" : 1,
12992 "type" : "string"
12993 },
7aacca6f 12994 "node" : {
7aacca6f 12995 "description" : "The cluster node name.",
44660702
DM
12996 "format" : "pve-node",
12997 "type" : "string"
7aacca6f
DM
12998 },
12999 "snapname" : {
13000 "description" : "The name of the snapshot.",
7aacca6f 13001 "format" : "pve-configid",
44660702
DM
13002 "maxLength" : 40,
13003 "type" : "string"
7aacca6f
DM
13004 },
13005 "vmid" : {
44660702 13006 "description" : "The (unique) ID of the VM.",
7aacca6f 13007 "format" : "pve-vmid",
44660702 13008 "minimum" : 1,
4bd7df8b 13009 "type" : "integer",
2c0dde61 13010 "typetext" : "integer (1 - N)"
7aacca6f
DM
13011 }
13012 }
13013 },
7aacca6f
DM
13014 "permissions" : {
13015 "check" : [
13016 "perm",
13017 "/vms/{vmid}",
13018 [
13019 "VM.Snapshot"
13020 ]
13021 ]
13022 },
44660702
DM
13023 "protected" : 1,
13024 "proxyto" : "node",
7aacca6f
DM
13025 "returns" : {
13026 "type" : "null"
13027 }
13028 }
13029 },
44660702 13030 "leaf" : 1,
7aacca6f 13031 "path" : "/nodes/{node}/lxc/{vmid}/snapshot/{snapname}/config",
44660702 13032 "text" : "config"
7aacca6f
DM
13033 }
13034 ],
56122987 13035 "info" : {
44660702
DM
13036 "DELETE" : {
13037 "description" : "Delete a LXC snapshot.",
13038 "method" : "DELETE",
13039 "name" : "delsnapshot",
56122987 13040 "parameters" : {
44660702 13041 "additionalProperties" : 0,
56122987 13042 "properties" : {
44660702
DM
13043 "force" : {
13044 "description" : "For removal from config file, even if removing disk snapshots fails.",
13045 "optional" : 1,
13046 "type" : "boolean"
13047 },
13048 "node" : {
13049 "description" : "The cluster node name.",
13050 "format" : "pve-node",
13051 "type" : "string"
7aacca6f
DM
13052 },
13053 "snapname" : {
7aacca6f
DM
13054 "description" : "The name of the snapshot.",
13055 "format" : "pve-configid",
44660702 13056 "maxLength" : 40,
7aacca6f 13057 "type" : "string"
44660702
DM
13058 },
13059 "vmid" : {
13060 "description" : "The (unique) ID of the VM.",
13061 "format" : "pve-vmid",
13062 "minimum" : 1,
4bd7df8b 13063 "type" : "integer",
2c0dde61 13064 "typetext" : "integer (1 - N)"
56122987 13065 }
44660702 13066 }
7aacca6f 13067 },
56122987
DM
13068 "permissions" : {
13069 "check" : [
13070 "perm",
13071 "/vms/{vmid}",
13072 [
7aacca6f 13073 "VM.Snapshot"
56122987
DM
13074 ]
13075 ]
13076 },
44660702 13077 "protected" : 1,
7aacca6f 13078 "proxyto" : "node",
56122987 13079 "returns" : {
7aacca6f 13080 "description" : "the task ID.",
56122987 13081 "type" : "string"
44660702
DM
13082 }
13083 },
13084 "GET" : {
13085 "description" : "",
13086 "method" : "GET",
13087 "name" : "snapshot_cmd_idx",
7aacca6f
DM
13088 "parameters" : {
13089 "additionalProperties" : 0,
13090 "properties" : {
7aacca6f 13091 "node" : {
44660702 13092 "description" : "The cluster node name.",
7aacca6f 13093 "format" : "pve-node",
44660702 13094 "type" : "string"
7aacca6f
DM
13095 },
13096 "snapname" : {
44660702 13097 "description" : "The name of the snapshot.",
7aacca6f 13098 "format" : "pve-configid",
44660702
DM
13099 "maxLength" : 40,
13100 "type" : "string"
13101 },
13102 "vmid" : {
13103 "description" : "The (unique) ID of the VM.",
13104 "format" : "pve-vmid",
13105 "minimum" : 1,
4bd7df8b 13106 "type" : "integer",
2c0dde61 13107 "typetext" : "integer (1 - N)"
7aacca6f
DM
13108 }
13109 }
13110 },
44660702
DM
13111 "permissions" : {
13112 "user" : "all"
13113 },
13114 "returns" : {
13115 "items" : {
13116 "properties" : {},
13117 "type" : "object"
13118 },
13119 "links" : [
13120 {
13121 "href" : "{cmd}",
13122 "rel" : "child"
13123 }
13124 ],
13125 "type" : "array"
13126 }
13127 }
13128 },
13129 "leaf" : 0,
13130 "path" : "/nodes/{node}/lxc/{vmid}/snapshot/{snapname}",
13131 "text" : "{snapname}"
13132 }
13133 ],
13134 "info" : {
13135 "GET" : {
13136 "description" : "List all snapshots.",
13137 "method" : "GET",
13138 "name" : "list",
13139 "parameters" : {
13140 "additionalProperties" : 0,
13141 "properties" : {
13142 "node" : {
13143 "description" : "The cluster node name.",
13144 "format" : "pve-node",
13145 "type" : "string"
13146 },
13147 "vmid" : {
13148 "description" : "The (unique) ID of the VM.",
13149 "format" : "pve-vmid",
13150 "minimum" : 1,
4bd7df8b 13151 "type" : "integer",
2c0dde61 13152 "typetext" : "integer (1 - N)"
44660702 13153 }
56122987
DM
13154 }
13155 },
56122987 13156 "permissions" : {
7aacca6f
DM
13157 "check" : [
13158 "perm",
13159 "/vms/{vmid}",
13160 [
13161 "VM.Audit"
13162 ]
13163 ]
13164 },
44660702 13165 "protected" : 1,
56122987 13166 "proxyto" : "node",
7aacca6f 13167 "returns" : {
44660702
DM
13168 "items" : {
13169 "properties" : {},
13170 "type" : "object"
13171 },
7aacca6f
DM
13172 "links" : [
13173 {
13174 "href" : "{name}",
13175 "rel" : "child"
13176 }
13177 ],
7aacca6f 13178 "type" : "array"
44660702 13179 }
7aacca6f
DM
13180 },
13181 "POST" : {
44660702
DM
13182 "description" : "Snapshot a container.",
13183 "method" : "POST",
13184 "name" : "snapshot",
56122987
DM
13185 "parameters" : {
13186 "additionalProperties" : 0,
13187 "properties" : {
7aacca6f 13188 "description" : {
44660702 13189 "description" : "A textual description or comment.",
7aacca6f 13190 "optional" : 1,
44660702
DM
13191 "type" : "string"
13192 },
13193 "node" : {
13194 "description" : "The cluster node name.",
13195 "format" : "pve-node",
13196 "type" : "string"
56122987
DM
13197 },
13198 "snapname" : {
56122987 13199 "description" : "The name of the snapshot.",
44660702 13200 "format" : "pve-configid",
7aacca6f 13201 "maxLength" : 40,
44660702 13202 "type" : "string"
56122987 13203 },
44660702
DM
13204 "vmid" : {
13205 "description" : "The (unique) ID of the VM.",
13206 "format" : "pve-vmid",
13207 "minimum" : 1,
4bd7df8b 13208 "type" : "integer",
2c0dde61 13209 "typetext" : "integer (1 - N)"
56122987 13210 }
7aacca6f 13211 }
56122987 13212 },
56122987
DM
13213 "permissions" : {
13214 "check" : [
13215 "perm",
13216 "/vms/{vmid}",
13217 [
7aacca6f 13218 "VM.Snapshot"
56122987
DM
13219 ]
13220 ]
7aacca6f 13221 },
44660702 13222 "protected" : 1,
7aacca6f
DM
13223 "proxyto" : "node",
13224 "returns" : {
13225 "description" : "the task ID.",
13226 "type" : "string"
56122987
DM
13227 }
13228 }
44660702
DM
13229 },
13230 "leaf" : 0,
13231 "path" : "/nodes/{node}/lxc/{vmid}/snapshot",
13232 "text" : "snapshot"
7aacca6f
DM
13233 },
13234 {
56122987
DM
13235 "children" : [
13236 {
56122987
DM
13237 "children" : [
13238 {
56122987 13239 "info" : {
44660702
DM
13240 "DELETE" : {
13241 "description" : "Delete rule.",
13242 "method" : "DELETE",
13243 "name" : "delete_rule",
56122987 13244 "parameters" : {
44660702 13245 "additionalProperties" : 0,
56122987 13246 "properties" : {
44660702
DM
13247 "digest" : {
13248 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
13249 "maxLength" : 40,
7aacca6f 13250 "optional" : 1,
44660702 13251 "type" : "string"
7aacca6f
DM
13252 },
13253 "node" : {
44660702 13254 "description" : "The cluster node name.",
7aacca6f 13255 "format" : "pve-node",
44660702
DM
13256 "type" : "string"
13257 },
13258 "pos" : {
13259 "description" : "Update rule at position <pos>.",
13260 "minimum" : 0,
13261 "optional" : 1,
4bd7df8b 13262 "type" : "integer",
2c0dde61 13263 "typetext" : "integer (0 - N)"
44660702
DM
13264 },
13265 "vmid" : {
13266 "description" : "The (unique) ID of the VM.",
13267 "format" : "pve-vmid",
13268 "minimum" : 1,
4bd7df8b 13269 "type" : "integer",
2c0dde61 13270 "typetext" : "integer (1 - N)"
56122987 13271 }
44660702 13272 }
56122987 13273 },
56122987
DM
13274 "permissions" : {
13275 "check" : [
13276 "perm",
13277 "/vms/{vmid}",
13278 [
44660702 13279 "VM.Config.Network"
56122987
DM
13280 ]
13281 ]
13282 },
44660702 13283 "protected" : 1,
7aacca6f 13284 "proxyto" : null,
44660702
DM
13285 "returns" : {
13286 "type" : "null"
13287 }
7aacca6f 13288 },
44660702
DM
13289 "GET" : {
13290 "description" : "Get single rule data.",
13291 "method" : "GET",
13292 "name" : "get_rule",
56122987 13293 "parameters" : {
44660702 13294 "additionalProperties" : 0,
56122987 13295 "properties" : {
7aacca6f 13296 "node" : {
7aacca6f 13297 "description" : "The cluster node name.",
44660702 13298 "format" : "pve-node",
56122987
DM
13299 "type" : "string"
13300 },
7aacca6f 13301 "pos" : {
7aacca6f 13302 "description" : "Update rule at position <pos>.",
44660702 13303 "minimum" : 0,
7aacca6f 13304 "optional" : 1,
4bd7df8b 13305 "type" : "integer",
2c0dde61 13306 "typetext" : "integer (0 - N)"
56122987 13307 },
7aacca6f 13308 "vmid" : {
44660702 13309 "description" : "The (unique) ID of the VM.",
7aacca6f
DM
13310 "format" : "pve-vmid",
13311 "minimum" : 1,
4bd7df8b 13312 "type" : "integer",
2c0dde61 13313 "typetext" : "integer (1 - N)"
56122987 13314 }
44660702 13315 }
56122987 13316 },
7aacca6f
DM
13317 "permissions" : {
13318 "check" : [
13319 "perm",
13320 "/vms/{vmid}",
13321 [
44660702 13322 "VM.Audit"
7aacca6f
DM
13323 ]
13324 ]
13325 },
7aacca6f
DM
13326 "proxyto" : null,
13327 "returns" : {
44660702
DM
13328 "properties" : {
13329 "pos" : {
13330 "type" : "integer"
13331 }
13332 },
13333 "type" : "object"
7aacca6f 13334 }
56122987 13335 },
44660702
DM
13336 "PUT" : {
13337 "description" : "Modify rule data.",
13338 "method" : "PUT",
13339 "name" : "update_rule",
56122987
DM
13340 "parameters" : {
13341 "additionalProperties" : 0,
13342 "properties" : {
44660702
DM
13343 "action" : {
13344 "description" : "Rule action ('ACCEPT', 'DROP', 'REJECT') or security group name.",
13345 "maxLength" : 20,
13346 "minLength" : 2,
13347 "optional" : 1,
13348 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
13349 "type" : "string"
13350 },
13351 "comment" : {
e94f0d56 13352 "description" : "Descriptive comment.",
44660702
DM
13353 "optional" : 1,
13354 "type" : "string"
13355 },
13356 "delete" : {
13357 "description" : "A list of settings you want to delete.",
13358 "format" : "pve-configid-list",
13359 "optional" : 1,
13360 "type" : "string"
13361 },
13362 "dest" : {
13363 "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.",
13364 "format" : "pve-fw-addr-spec",
13365 "optional" : 1,
13366 "type" : "string"
13367 },
13368 "digest" : {
13369 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
13370 "maxLength" : 40,
13371 "optional" : 1,
13372 "type" : "string"
13373 },
13374 "dport" : {
13375 "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.",
13376 "format" : "pve-fw-dport-spec",
13377 "optional" : 1,
13378 "type" : "string"
13379 },
13380 "enable" : {
e94f0d56 13381 "description" : "Flag to enable/disable a rule.",
44660702
DM
13382 "minimum" : 0,
13383 "optional" : 1,
4bd7df8b 13384 "type" : "integer",
2c0dde61 13385 "typetext" : "integer (0 - N)"
44660702
DM
13386 },
13387 "iface" : {
13388 "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.",
13389 "format" : "pve-iface",
13390 "maxLength" : 20,
13391 "minLength" : 2,
13392 "optional" : 1,
13393 "type" : "string"
13394 },
13395 "macro" : {
e94f0d56 13396 "description" : "Use predefined standard macro.",
44660702
DM
13397 "maxLength" : 128,
13398 "optional" : 1,
13399 "type" : "string"
13400 },
13401 "moveto" : {
13402 "description" : "Move rule to new position <moveto>. Other arguments are ignored.",
13403 "minimum" : 0,
13404 "optional" : 1,
4bd7df8b 13405 "type" : "integer",
2c0dde61 13406 "typetext" : "integer (0 - N)"
44660702 13407 },
7aacca6f
DM
13408 "node" : {
13409 "description" : "The cluster node name.",
44660702
DM
13410 "format" : "pve-node",
13411 "type" : "string"
56122987
DM
13412 },
13413 "pos" : {
44660702 13414 "description" : "Update rule at position <pos>.",
56122987 13415 "minimum" : 0,
7aacca6f 13416 "optional" : 1,
4bd7df8b 13417 "type" : "integer",
2c0dde61 13418 "typetext" : "integer (0 - N)"
56122987 13419 },
44660702
DM
13420 "proto" : {
13421 "description" : "IP protocol. You can use protocol names ('tcp'/'udp') or simple numbers, as defined in '/etc/protocols'.",
13422 "format" : "pve-fw-protocol-spec",
13423 "optional" : 1,
13424 "type" : "string"
7aacca6f 13425 },
44660702
DM
13426 "source" : {
13427 "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.",
13428 "format" : "pve-fw-addr-spec",
13429 "optional" : 1,
13430 "type" : "string"
13431 },
13432 "sport" : {
13433 "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.",
13434 "format" : "pve-fw-sport-spec",
13435 "optional" : 1,
13436 "type" : "string"
13437 },
13438 "type" : {
e94f0d56 13439 "description" : "Rule type.",
44660702
DM
13440 "enum" : [
13441 "in",
13442 "out",
13443 "group"
13444 ],
7aacca6f 13445 "optional" : 1,
44660702
DM
13446 "type" : "string"
13447 },
13448 "vmid" : {
13449 "description" : "The (unique) ID of the VM.",
13450 "format" : "pve-vmid",
13451 "minimum" : 1,
4bd7df8b 13452 "type" : "integer",
2c0dde61 13453 "typetext" : "integer (1 - N)"
56122987
DM
13454 }
13455 }
13456 },
56122987
DM
13457 "permissions" : {
13458 "check" : [
13459 "perm",
13460 "/vms/{vmid}",
13461 [
7aacca6f 13462 "VM.Config.Network"
56122987
DM
13463 ]
13464 ]
13465 },
44660702 13466 "protected" : 1,
56122987 13467 "proxyto" : null,
56122987 13468 "returns" : {
7aacca6f
DM
13469 "type" : "null"
13470 }
56122987 13471 }
44660702
DM
13472 },
13473 "leaf" : 1,
13474 "path" : "/nodes/{node}/lxc/{vmid}/firewall/rules/{pos}",
13475 "text" : "{pos}"
56122987
DM
13476 }
13477 ],
13478 "info" : {
7aacca6f 13479 "GET" : {
44660702
DM
13480 "description" : "List rules.",
13481 "method" : "GET",
13482 "name" : "get_rules",
7aacca6f 13483 "parameters" : {
44660702 13484 "additionalProperties" : 0,
7aacca6f
DM
13485 "properties" : {
13486 "node" : {
7aacca6f 13487 "description" : "The cluster node name.",
44660702
DM
13488 "format" : "pve-node",
13489 "type" : "string"
7aacca6f
DM
13490 },
13491 "vmid" : {
13492 "description" : "The (unique) ID of the VM.",
44660702 13493 "format" : "pve-vmid",
7aacca6f 13494 "minimum" : 1,
4bd7df8b 13495 "type" : "integer",
2c0dde61 13496 "typetext" : "integer (1 - N)"
7aacca6f 13497 }
44660702 13498 }
56122987 13499 },
56122987
DM
13500 "permissions" : {
13501 "check" : [
13502 "perm",
13503 "/vms/{vmid}",
13504 [
7aacca6f 13505 "VM.Audit"
56122987
DM
13506 ]
13507 ]
13508 },
13509 "proxyto" : null,
7aacca6f 13510 "returns" : {
7aacca6f
DM
13511 "items" : {
13512 "properties" : {
13513 "pos" : {
13514 "type" : "integer"
13515 }
13516 },
13517 "type" : "object"
13518 },
13519 "links" : [
13520 {
44660702
DM
13521 "href" : "{pos}",
13522 "rel" : "child"
7aacca6f 13523 }
44660702
DM
13524 ],
13525 "type" : "array"
13526 }
7aacca6f
DM
13527 },
13528 "POST" : {
44660702
DM
13529 "description" : "Create new rule.",
13530 "method" : "POST",
7aacca6f 13531 "name" : "create_rule",
56122987 13532 "parameters" : {
44660702 13533 "additionalProperties" : 0,
56122987 13534 "properties" : {
7aacca6f 13535 "action" : {
44660702 13536 "description" : "Rule action ('ACCEPT', 'DROP', 'REJECT') or security group name.",
7aacca6f 13537 "maxLength" : 20,
44660702 13538 "minLength" : 2,
7aacca6f
DM
13539 "optional" : 0,
13540 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
56122987
DM
13541 "type" : "string"
13542 },
44660702 13543 "comment" : {
e94f0d56 13544 "description" : "Descriptive comment.",
7aacca6f 13545 "optional" : 1,
44660702 13546 "type" : "string"
56122987 13547 },
44660702
DM
13548 "dest" : {
13549 "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.",
13550 "format" : "pve-fw-addr-spec",
56122987 13551 "optional" : 1,
44660702 13552 "type" : "string"
56122987 13553 },
44660702
DM
13554 "digest" : {
13555 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
13556 "maxLength" : 40,
56122987 13557 "optional" : 1,
44660702 13558 "type" : "string"
56122987 13559 },
44660702
DM
13560 "dport" : {
13561 "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.",
13562 "format" : "pve-fw-dport-spec",
56122987 13563 "optional" : 1,
44660702 13564 "type" : "string"
56122987 13565 },
44660702 13566 "enable" : {
e94f0d56 13567 "description" : "Flag to enable/disable a rule.",
44660702 13568 "minimum" : 0,
56122987 13569 "optional" : 1,
4bd7df8b 13570 "type" : "integer",
2c0dde61 13571 "typetext" : "integer (0 - N)"
56122987 13572 },
44660702
DM
13573 "iface" : {
13574 "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.",
13575 "format" : "pve-iface",
13576 "maxLength" : 20,
13577 "minLength" : 2,
7aacca6f 13578 "optional" : 1,
56122987 13579 "type" : "string"
56122987 13580 },
44660702 13581 "macro" : {
e94f0d56 13582 "description" : "Use predefined standard macro.",
44660702 13583 "maxLength" : 128,
56122987
DM
13584 "optional" : 1,
13585 "type" : "string"
13586 },
13587 "node" : {
7aacca6f 13588 "description" : "The cluster node name.",
44660702
DM
13589 "format" : "pve-node",
13590 "type" : "string"
7aacca6f 13591 },
44660702
DM
13592 "pos" : {
13593 "description" : "Update rule at position <pos>.",
13594 "minimum" : 0,
13595 "optional" : 1,
4bd7df8b 13596 "type" : "integer",
2c0dde61 13597 "typetext" : "integer (0 - N)"
44660702
DM
13598 },
13599 "proto" : {
13600 "description" : "IP protocol. You can use protocol names ('tcp'/'udp') or simple numbers, as defined in '/etc/protocols'.",
13601 "format" : "pve-fw-protocol-spec",
7aacca6f
DM
13602 "optional" : 1,
13603 "type" : "string"
7aacca6f 13604 },
44660702
DM
13605 "source" : {
13606 "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.",
13607 "format" : "pve-fw-addr-spec",
13608 "optional" : 1,
13609 "type" : "string"
56122987 13610 },
44660702
DM
13611 "sport" : {
13612 "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.",
13613 "format" : "pve-fw-sport-spec",
13614 "optional" : 1,
13615 "type" : "string"
7aacca6f 13616 },
44660702 13617 "type" : {
e94f0d56 13618 "description" : "Rule type.",
44660702
DM
13619 "enum" : [
13620 "in",
13621 "out",
13622 "group"
13623 ],
13624 "optional" : 0,
13625 "type" : "string"
13626 },
13627 "vmid" : {
13628 "description" : "The (unique) ID of the VM.",
13629 "format" : "pve-vmid",
13630 "minimum" : 1,
4bd7df8b 13631 "type" : "integer",
2c0dde61 13632 "typetext" : "integer (1 - N)"
44660702
DM
13633 }
13634 }
13635 },
13636 "permissions" : {
13637 "check" : [
13638 "perm",
13639 "/vms/{vmid}",
13640 [
13641 "VM.Config.Network"
13642 ]
13643 ]
13644 },
13645 "protected" : 1,
13646 "proxyto" : null,
13647 "returns" : {
13648 "type" : "null"
13649 }
13650 }
13651 },
13652 "leaf" : 0,
13653 "path" : "/nodes/{node}/lxc/{vmid}/firewall/rules",
13654 "text" : "rules"
13655 },
13656 {
13657 "children" : [
13658 {
13659 "info" : {
13660 "DELETE" : {
13661 "description" : "Remove IP or Network alias.",
13662 "method" : "DELETE",
13663 "name" : "remove_alias",
56122987 13664 "parameters" : {
44660702 13665 "additionalProperties" : 0,
56122987 13666 "properties" : {
44660702
DM
13667 "digest" : {
13668 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
13669 "maxLength" : 40,
56122987
DM
13670 "optional" : 1,
13671 "type" : "string"
13672 },
7aacca6f 13673 "name" : {
44660702 13674 "description" : "Alias name.",
7aacca6f 13675 "maxLength" : 64,
7aacca6f
DM
13676 "minLength" : 2,
13677 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
44660702 13678 "type" : "string"
7aacca6f
DM
13679 },
13680 "node" : {
44660702 13681 "description" : "The cluster node name.",
56122987 13682 "format" : "pve-node",
44660702 13683 "type" : "string"
7aacca6f 13684 },
56122987 13685 "vmid" : {
44660702 13686 "description" : "The (unique) ID of the VM.",
56122987 13687 "format" : "pve-vmid",
44660702 13688 "minimum" : 1,
4bd7df8b 13689 "type" : "integer",
2c0dde61 13690 "typetext" : "integer (1 - N)"
56122987 13691 }
44660702 13692 }
56122987 13693 },
56122987
DM
13694 "permissions" : {
13695 "check" : [
13696 "perm",
13697 "/vms/{vmid}",
13698 [
7aacca6f 13699 "VM.Config.Network"
56122987
DM
13700 ]
13701 ]
13702 },
44660702 13703 "protected" : 1,
56122987 13704 "returns" : {
7aacca6f 13705 "type" : "null"
44660702 13706 }
56122987 13707 },
44660702
DM
13708 "GET" : {
13709 "description" : "Read alias.",
13710 "method" : "GET",
13711 "name" : "read_alias",
13712 "parameters" : {
13713 "additionalProperties" : 0,
13714 "properties" : {
13715 "name" : {
13716 "description" : "Alias name.",
13717 "maxLength" : 64,
13718 "minLength" : 2,
13719 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
13720 "type" : "string"
13721 },
13722 "node" : {
13723 "description" : "The cluster node name.",
13724 "format" : "pve-node",
13725 "type" : "string"
13726 },
13727 "vmid" : {
13728 "description" : "The (unique) ID of the VM.",
13729 "format" : "pve-vmid",
13730 "minimum" : 1,
4bd7df8b 13731 "type" : "integer",
2c0dde61 13732 "typetext" : "integer (1 - N)"
44660702
DM
13733 }
13734 }
56122987 13735 },
7aacca6f
DM
13736 "permissions" : {
13737 "check" : [
13738 "perm",
13739 "/vms/{vmid}",
13740 [
44660702 13741 "VM.Audit"
7aacca6f
DM
13742 ]
13743 ]
13744 },
44660702
DM
13745 "returns" : {
13746 "type" : "object"
13747 }
13748 },
13749 "PUT" : {
13750 "description" : "Update IP or Network alias.",
13751 "method" : "PUT",
13752 "name" : "update_alias",
56122987
DM
13753 "parameters" : {
13754 "additionalProperties" : 0,
13755 "properties" : {
44660702
DM
13756 "cidr" : {
13757 "description" : "Network/IP specification in CIDR format.",
13758 "format" : "IPorCIDR",
13759 "type" : "string"
13760 },
13761 "comment" : {
13762 "optional" : 1,
13763 "type" : "string"
13764 },
13765 "digest" : {
13766 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
13767 "maxLength" : 40,
13768 "optional" : 1,
13769 "type" : "string"
13770 },
56122987 13771 "name" : {
7aacca6f 13772 "description" : "Alias name.",
44660702
DM
13773 "maxLength" : 64,
13774 "minLength" : 2,
7aacca6f 13775 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
44660702 13776 "type" : "string"
56122987
DM
13777 },
13778 "node" : {
13779 "description" : "The cluster node name.",
44660702
DM
13780 "format" : "pve-node",
13781 "type" : "string"
13782 },
13783 "rename" : {
13784 "description" : "Rename an existing alias.",
13785 "maxLength" : 64,
13786 "minLength" : 2,
13787 "optional" : 1,
13788 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
13789 "type" : "string"
56122987 13790 },
7aacca6f 13791 "vmid" : {
7aacca6f 13792 "description" : "The (unique) ID of the VM.",
44660702 13793 "format" : "pve-vmid",
7aacca6f 13794 "minimum" : 1,
4bd7df8b 13795 "type" : "integer",
2c0dde61 13796 "typetext" : "integer (1 - N)"
56122987
DM
13797 }
13798 }
13799 },
44660702
DM
13800 "permissions" : {
13801 "check" : [
13802 "perm",
13803 "/vms/{vmid}",
13804 [
13805 "VM.Config.Network"
13806 ]
13807 ]
7aacca6f 13808 },
44660702
DM
13809 "protected" : 1,
13810 "returns" : {
13811 "type" : "null"
7aacca6f
DM
13812 }
13813 }
13814 },
44660702
DM
13815 "leaf" : 1,
13816 "path" : "/nodes/{node}/lxc/{vmid}/firewall/aliases/{name}",
13817 "text" : "{name}"
13818 }
13819 ],
13820 "info" : {
13821 "GET" : {
13822 "description" : "List aliases",
13823 "method" : "GET",
13824 "name" : "get_aliases",
56122987
DM
13825 "parameters" : {
13826 "additionalProperties" : 0,
13827 "properties" : {
13828 "node" : {
44660702 13829 "description" : "The cluster node name.",
56122987 13830 "format" : "pve-node",
44660702 13831 "type" : "string"
56122987
DM
13832 },
13833 "vmid" : {
7aacca6f 13834 "description" : "The (unique) ID of the VM.",
44660702 13835 "format" : "pve-vmid",
7aacca6f 13836 "minimum" : 1,
4bd7df8b 13837 "type" : "integer",
2c0dde61 13838 "typetext" : "integer (1 - N)"
56122987
DM
13839 }
13840 }
13841 },
44660702
DM
13842 "permissions" : {
13843 "check" : [
13844 "perm",
13845 "/vms/{vmid}",
13846 [
13847 "VM.Audit"
13848 ]
13849 ]
13850 },
56122987
DM
13851 "returns" : {
13852 "items" : {
56122987 13853 "properties" : {
44660702
DM
13854 "cidr" : {
13855 "type" : "string"
7aacca6f 13856 },
44660702
DM
13857 "comment" : {
13858 "optional" : 1,
56122987
DM
13859 "type" : "string"
13860 },
56122987 13861 "digest" : {
56122987 13862 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
44660702
DM
13863 "maxLength" : 40,
13864 "optional" : 0,
13865 "type" : "string"
13866 },
13867 "name" : {
13868 "type" : "string"
56122987 13869 }
44660702
DM
13870 },
13871 "type" : "object"
13872 },
13873 "links" : [
13874 {
13875 "href" : "{name}",
13876 "rel" : "child"
56122987 13877 }
44660702
DM
13878 ],
13879 "type" : "array"
7aacca6f
DM
13880 }
13881 },
13882 "POST" : {
44660702 13883 "description" : "Create IP or Network Alias.",
7aacca6f 13884 "method" : "POST",
44660702 13885 "name" : "create_alias",
7aacca6f
DM
13886 "parameters" : {
13887 "additionalProperties" : 0,
13888 "properties" : {
44660702
DM
13889 "cidr" : {
13890 "description" : "Network/IP specification in CIDR format.",
13891 "format" : "IPorCIDR",
7aacca6f
DM
13892 "type" : "string"
13893 },
13894 "comment" : {
13895 "optional" : 1,
13896 "type" : "string"
13897 },
44660702
DM
13898 "name" : {
13899 "description" : "Alias name.",
13900 "maxLength" : 64,
7aacca6f
DM
13901 "minLength" : 2,
13902 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
44660702 13903 "type" : "string"
7aacca6f
DM
13904 },
13905 "node" : {
44660702 13906 "description" : "The cluster node name.",
7aacca6f 13907 "format" : "pve-node",
44660702 13908 "type" : "string"
7aacca6f 13909 },
44660702
DM
13910 "vmid" : {
13911 "description" : "The (unique) ID of the VM.",
13912 "format" : "pve-vmid",
13913 "minimum" : 1,
4bd7df8b 13914 "type" : "integer",
2c0dde61 13915 "typetext" : "integer (1 - N)"
7aacca6f
DM
13916 }
13917 }
13918 },
44660702
DM
13919 "permissions" : {
13920 "check" : [
13921 "perm",
13922 "/vms/{vmid}",
13923 [
13924 "VM.Config.Network"
13925 ]
13926 ]
13927 },
13928 "protected" : 1,
13929 "returns" : {
13930 "type" : "null"
13931 }
56122987
DM
13932 }
13933 },
44660702
DM
13934 "leaf" : 0,
13935 "path" : "/nodes/{node}/lxc/{vmid}/firewall/aliases",
13936 "text" : "aliases"
13937 },
13938 {
56122987
DM
13939 "children" : [
13940 {
56122987
DM
13941 "children" : [
13942 {
13943 "info" : {
13944 "DELETE" : {
44660702 13945 "description" : "Remove IP or Network from IPSet.",
7aacca6f 13946 "method" : "DELETE",
44660702 13947 "name" : "remove_ip",
56122987
DM
13948 "parameters" : {
13949 "additionalProperties" : 0,
13950 "properties" : {
44660702
DM
13951 "cidr" : {
13952 "description" : "Network/IP specification in CIDR format.",
13953 "format" : "IPorCIDRorAlias",
13954 "type" : "string"
56122987
DM
13955 },
13956 "digest" : {
44660702 13957 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
56122987 13958 "maxLength" : 40,
7aacca6f 13959 "optional" : 1,
44660702 13960 "type" : "string"
56122987 13961 },
56122987 13962 "name" : {
44660702 13963 "description" : "IP set name.",
56122987 13964 "maxLength" : 64,
7aacca6f 13965 "minLength" : 2,
56122987 13966 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
56122987 13967 "type" : "string"
7aacca6f
DM
13968 },
13969 "node" : {
7aacca6f 13970 "description" : "The cluster node name.",
44660702
DM
13971 "format" : "pve-node",
13972 "type" : "string"
13973 },
13974 "vmid" : {
13975 "description" : "The (unique) ID of the VM.",
13976 "format" : "pve-vmid",
13977 "minimum" : 1,
4bd7df8b 13978 "type" : "integer",
2c0dde61 13979 "typetext" : "integer (1 - N)"
56122987
DM
13980 }
13981 }
13982 },
44660702
DM
13983 "permissions" : {
13984 "check" : [
13985 "perm",
13986 "/vms/{vmid}",
13987 [
13988 "VM.Config.Network"
13989 ]
13990 ]
13991 },
7aacca6f 13992 "protected" : 1,
56122987
DM
13993 "returns" : {
13994 "type" : "null"
44660702
DM
13995 }
13996 },
13997 "GET" : {
13998 "description" : "Read IP or Network settings from IPSet.",
13999 "method" : "GET",
14000 "name" : "read_ip",
56122987
DM
14001 "parameters" : {
14002 "additionalProperties" : 0,
14003 "properties" : {
7aacca6f 14004 "cidr" : {
7aacca6f 14005 "description" : "Network/IP specification in CIDR format.",
44660702 14006 "format" : "IPorCIDRorAlias",
56122987
DM
14007 "type" : "string"
14008 },
7aacca6f 14009 "name" : {
44660702 14010 "description" : "IP set name.",
7aacca6f
DM
14011 "maxLength" : 64,
14012 "minLength" : 2,
7aacca6f
DM
14013 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
14014 "type" : "string"
56122987 14015 },
44660702
DM
14016 "node" : {
14017 "description" : "The cluster node name.",
14018 "format" : "pve-node",
14019 "type" : "string"
14020 },
14021 "vmid" : {
14022 "description" : "The (unique) ID of the VM.",
14023 "format" : "pve-vmid",
14024 "minimum" : 1,
4bd7df8b 14025 "type" : "integer",
2c0dde61 14026 "typetext" : "integer (1 - N)"
56122987
DM
14027 }
14028 }
14029 },
56122987
DM
14030 "permissions" : {
14031 "check" : [
14032 "perm",
14033 "/vms/{vmid}",
14034 [
44660702 14035 "VM.Audit"
56122987
DM
14036 ]
14037 ]
7aacca6f 14038 },
44660702 14039 "protected" : 1,
7aacca6f
DM
14040 "returns" : {
14041 "type" : "object"
44660702
DM
14042 }
14043 },
14044 "PUT" : {
14045 "description" : "Update IP or Network settings",
14046 "method" : "PUT",
14047 "name" : "update_ip",
7aacca6f 14048 "parameters" : {
44660702 14049 "additionalProperties" : 0,
7aacca6f
DM
14050 "properties" : {
14051 "cidr" : {
44660702 14052 "description" : "Network/IP specification in CIDR format.",
7aacca6f 14053 "format" : "IPorCIDRorAlias",
44660702 14054 "type" : "string"
7aacca6f 14055 },
44660702
DM
14056 "comment" : {
14057 "optional" : 1,
14058 "type" : "string"
14059 },
14060 "digest" : {
14061 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
14062 "maxLength" : 40,
14063 "optional" : 1,
14064 "type" : "string"
14065 },
14066 "name" : {
14067 "description" : "IP set name.",
14068 "maxLength" : 64,
14069 "minLength" : 2,
14070 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
14071 "type" : "string"
7aacca6f
DM
14072 },
14073 "node" : {
7aacca6f 14074 "description" : "The cluster node name.",
44660702 14075 "format" : "pve-node",
7aacca6f
DM
14076 "type" : "string"
14077 },
44660702
DM
14078 "nomatch" : {
14079 "optional" : 1,
14080 "type" : "boolean"
14081 },
14082 "vmid" : {
14083 "description" : "The (unique) ID of the VM.",
14084 "format" : "pve-vmid",
14085 "minimum" : 1,
4bd7df8b 14086 "type" : "integer",
2c0dde61 14087 "typetext" : "integer (1 - N)"
7aacca6f 14088 }
44660702
DM
14089 }
14090 },
14091 "permissions" : {
14092 "check" : [
14093 "perm",
14094 "/vms/{vmid}",
14095 [
14096 "VM.Config.Network"
14097 ]
14098 ]
7aacca6f
DM
14099 },
14100 "protected" : 1,
44660702
DM
14101 "returns" : {
14102 "type" : "null"
14103 }
56122987
DM
14104 }
14105 },
56122987 14106 "leaf" : 1,
44660702
DM
14107 "path" : "/nodes/{node}/lxc/{vmid}/firewall/ipset/{name}/{cidr}",
14108 "text" : "{cidr}"
56122987
DM
14109 }
14110 ],
14111 "info" : {
44660702
DM
14112 "DELETE" : {
14113 "description" : "Delete IPSet",
14114 "method" : "DELETE",
14115 "name" : "delete_ipset",
14116 "parameters" : {
14117 "additionalProperties" : 0,
14118 "properties" : {
14119 "name" : {
14120 "description" : "IP set name.",
14121 "maxLength" : 64,
14122 "minLength" : 2,
14123 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
14124 "type" : "string"
14125 },
14126 "node" : {
14127 "description" : "The cluster node name.",
14128 "format" : "pve-node",
14129 "type" : "string"
14130 },
14131 "vmid" : {
14132 "description" : "The (unique) ID of the VM.",
14133 "format" : "pve-vmid",
14134 "minimum" : 1,
4bd7df8b 14135 "type" : "integer",
2c0dde61 14136 "typetext" : "integer (1 - N)"
44660702
DM
14137 }
14138 }
14139 },
14140 "permissions" : {
14141 "check" : [
14142 "perm",
14143 "/vms/{vmid}",
14144 [
14145 "VM.Config.Network"
14146 ]
14147 ]
14148 },
14149 "protected" : 1,
14150 "returns" : {
14151 "type" : "null"
14152 }
14153 },
56122987 14154 "GET" : {
7aacca6f 14155 "description" : "List IPSet content",
44660702
DM
14156 "method" : "GET",
14157 "name" : "get_ipset",
7aacca6f
DM
14158 "parameters" : {
14159 "additionalProperties" : 0,
14160 "properties" : {
14161 "name" : {
14162 "description" : "IP set name.",
44660702 14163 "maxLength" : 64,
7aacca6f 14164 "minLength" : 2,
44660702
DM
14165 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
14166 "type" : "string"
7aacca6f
DM
14167 },
14168 "node" : {
7aacca6f 14169 "description" : "The cluster node name.",
44660702 14170 "format" : "pve-node",
7aacca6f
DM
14171 "type" : "string"
14172 },
14173 "vmid" : {
14174 "description" : "The (unique) ID of the VM.",
44660702 14175 "format" : "pve-vmid",
7aacca6f 14176 "minimum" : 1,
4bd7df8b 14177 "type" : "integer",
2c0dde61 14178 "typetext" : "integer (1 - N)"
56122987 14179 }
7aacca6f
DM
14180 }
14181 },
7aacca6f
DM
14182 "permissions" : {
14183 "check" : [
14184 "perm",
14185 "/vms/{vmid}",
14186 [
14187 "VM.Audit"
14188 ]
14189 ]
14190 },
14191 "returns" : {
56122987
DM
14192 "items" : {
14193 "properties" : {
14194 "cidr" : {
14195 "type" : "string"
14196 },
44660702
DM
14197 "comment" : {
14198 "optional" : 1,
14199 "type" : "string"
14200 },
56122987 14201 "digest" : {
56122987 14202 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
44660702 14203 "maxLength" : 40,
7aacca6f 14204 "optional" : 0,
56122987 14205 "type" : "string"
7aacca6f
DM
14206 },
14207 "nomatch" : {
44660702
DM
14208 "optional" : 1,
14209 "type" : "boolean"
56122987 14210 }
44660702
DM
14211 },
14212 "type" : "object"
56122987 14213 },
7aacca6f
DM
14214 "links" : [
14215 {
44660702
DM
14216 "href" : "{cidr}",
14217 "rel" : "child"
56122987 14218 }
44660702
DM
14219 ],
14220 "type" : "array"
14221 }
56122987 14222 },
7aacca6f
DM
14223 "POST" : {
14224 "description" : "Add IP or Network to IPSet.",
44660702 14225 "method" : "POST",
7aacca6f 14226 "name" : "create_ip",
56122987 14227 "parameters" : {
44660702 14228 "additionalProperties" : 0,
56122987 14229 "properties" : {
44660702
DM
14230 "cidr" : {
14231 "description" : "Network/IP specification in CIDR format.",
14232 "format" : "IPorCIDRorAlias",
14233 "type" : "string"
14234 },
14235 "comment" : {
14236 "optional" : 1,
14237 "type" : "string"
56122987
DM
14238 },
14239 "name" : {
56122987 14240 "description" : "IP set name.",
44660702 14241 "maxLength" : 64,
7aacca6f 14242 "minLength" : 2,
44660702 14243 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
7aacca6f 14244 "type" : "string"
56122987 14245 },
7aacca6f 14246 "node" : {
7aacca6f 14247 "description" : "The cluster node name.",
44660702 14248 "format" : "pve-node",
56122987
DM
14249 "type" : "string"
14250 },
44660702
DM
14251 "nomatch" : {
14252 "optional" : 1,
14253 "type" : "boolean"
7aacca6f
DM
14254 },
14255 "vmid" : {
44660702 14256 "description" : "The (unique) ID of the VM.",
7aacca6f
DM
14257 "format" : "pve-vmid",
14258 "minimum" : 1,
4bd7df8b 14259 "type" : "integer",
2c0dde61 14260 "typetext" : "integer (1 - N)"
56122987 14261 }
44660702
DM
14262 }
14263 },
14264 "permissions" : {
14265 "check" : [
14266 "perm",
14267 "/vms/{vmid}",
14268 [
14269 "VM.Config.Network"
14270 ]
14271 ]
14272 },
14273 "protected" : 1,
14274 "returns" : {
14275 "type" : "null"
14276 }
14277 }
14278 },
14279 "leaf" : 0,
14280 "path" : "/nodes/{node}/lxc/{vmid}/firewall/ipset/{name}",
14281 "text" : "{name}"
14282 }
14283 ],
14284 "info" : {
14285 "GET" : {
14286 "description" : "List IPSets",
14287 "method" : "GET",
14288 "name" : "ipset_index",
14289 "parameters" : {
14290 "additionalProperties" : 0,
14291 "properties" : {
14292 "node" : {
14293 "description" : "The cluster node name.",
14294 "format" : "pve-node",
14295 "type" : "string"
14296 },
14297 "vmid" : {
14298 "description" : "The (unique) ID of the VM.",
14299 "format" : "pve-vmid",
14300 "minimum" : 1,
4bd7df8b 14301 "type" : "integer",
2c0dde61 14302 "typetext" : "integer (1 - N)"
44660702
DM
14303 }
14304 }
14305 },
14306 "permissions" : {
14307 "check" : [
14308 "perm",
14309 "/vms/{vmid}",
14310 [
14311 "VM.Audit"
14312 ]
14313 ]
14314 },
14315 "returns" : {
14316 "items" : {
14317 "properties" : {
14318 "comment" : {
14319 "optional" : 1,
14320 "type" : "string"
14321 },
14322 "digest" : {
14323 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
14324 "maxLength" : 40,
14325 "optional" : 0,
14326 "type" : "string"
7aacca6f 14327 },
44660702
DM
14328 "name" : {
14329 "description" : "IP set name.",
14330 "maxLength" : 64,
14331 "minLength" : 2,
14332 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
14333 "type" : "string"
14334 }
14335 },
14336 "type" : "object"
14337 },
14338 "links" : [
14339 {
14340 "href" : "{name}",
14341 "rel" : "child"
14342 }
14343 ],
14344 "type" : "array"
14345 }
14346 },
14347 "POST" : {
14348 "description" : "Create new IPSet",
14349 "method" : "POST",
14350 "name" : "create_ipset",
14351 "parameters" : {
14352 "additionalProperties" : 0,
14353 "properties" : {
14354 "comment" : {
14355 "optional" : 1,
14356 "type" : "string"
14357 },
14358 "digest" : {
14359 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
14360 "maxLength" : 40,
14361 "optional" : 1,
14362 "type" : "string"
56122987 14363 },
44660702
DM
14364 "name" : {
14365 "description" : "IP set name.",
14366 "maxLength" : 64,
14367 "minLength" : 2,
14368 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
14369 "type" : "string"
14370 },
14371 "node" : {
14372 "description" : "The cluster node name.",
14373 "format" : "pve-node",
14374 "type" : "string"
7aacca6f 14375 },
44660702
DM
14376 "rename" : {
14377 "description" : "Rename an existing IPSet. You can set 'rename' to the same value as 'name' to update the 'comment' of an existing IPSet.",
14378 "maxLength" : 64,
14379 "minLength" : 2,
14380 "optional" : 1,
14381 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
14382 "type" : "string"
14383 },
14384 "vmid" : {
14385 "description" : "The (unique) ID of the VM.",
14386 "format" : "pve-vmid",
14387 "minimum" : 1,
4bd7df8b 14388 "type" : "integer",
2c0dde61 14389 "typetext" : "integer (1 - N)"
44660702 14390 }
56122987 14391 }
44660702
DM
14392 },
14393 "permissions" : {
14394 "check" : [
14395 "perm",
14396 "/vms/{vmid}",
14397 [
14398 "VM.Config.Network"
14399 ]
14400 ]
14401 },
14402 "protected" : 1,
14403 "returns" : {
14404 "type" : "null"
56122987
DM
14405 }
14406 }
44660702
DM
14407 },
14408 "leaf" : 0,
14409 "path" : "/nodes/{node}/lxc/{vmid}/firewall/ipset",
14410 "text" : "ipset"
56122987
DM
14411 },
14412 {
56122987 14413 "info" : {
7aacca6f 14414 "GET" : {
44660702 14415 "description" : "Get VM firewall options.",
7aacca6f 14416 "method" : "GET",
44660702
DM
14417 "name" : "get_options",
14418 "parameters" : {
14419 "additionalProperties" : 0,
14420 "properties" : {
14421 "node" : {
14422 "description" : "The cluster node name.",
14423 "format" : "pve-node",
14424 "type" : "string"
14425 },
14426 "vmid" : {
14427 "description" : "The (unique) ID of the VM.",
14428 "format" : "pve-vmid",
14429 "minimum" : 1,
4bd7df8b 14430 "type" : "integer",
2c0dde61 14431 "typetext" : "integer (1 - N)"
44660702
DM
14432 }
14433 }
14434 },
14435 "permissions" : {
14436 "check" : [
14437 "perm",
14438 "/vms/{vmid}",
14439 [
14440 "VM.Audit"
14441 ]
14442 ]
14443 },
14444 "proxyto" : "node",
56122987 14445 "returns" : {
56122987 14446 "properties" : {
44660702
DM
14447 "dhcp" : {
14448 "description" : "Enable DHCP.",
14449 "optional" : 1,
14450 "type" : "boolean"
14451 },
14452 "enable" : {
14453 "description" : "Enable/disable firewall rules.",
14454 "optional" : 1,
14455 "type" : "boolean"
14456 },
14457 "ipfilter" : {
14458 "description" : "Enable default IP filters. This is equivalent to adding an empty ipfilter-net<id> ipset for every interface. Such ipsets implicitly contain sane default restrictions such as restricting IPv6 link local addresses to the one derived from the interface's MAC address. For containers the configured IP addresses will be implicitly added.",
7aacca6f 14459 "optional" : 1,
44660702
DM
14460 "type" : "boolean"
14461 },
14462 "log_level_in" : {
7aacca6f
DM
14463 "description" : "Log level for incoming traffic.",
14464 "enum" : [
14465 "emerg",
14466 "alert",
14467 "crit",
14468 "err",
14469 "warning",
14470 "notice",
14471 "info",
14472 "debug",
14473 "nolog"
44660702
DM
14474 ],
14475 "optional" : 1,
14476 "type" : "string"
56122987 14477 },
44660702
DM
14478 "log_level_out" : {
14479 "description" : "Log level for outgoing traffic.",
56122987 14480 "enum" : [
44660702
DM
14481 "emerg",
14482 "alert",
14483 "crit",
14484 "err",
14485 "warning",
14486 "notice",
14487 "info",
14488 "debug",
14489 "nolog"
7aacca6f 14490 ],
7aacca6f
DM
14491 "optional" : 1,
14492 "type" : "string"
56122987 14493 },
44660702
DM
14494 "macfilter" : {
14495 "description" : "Enable/disable MAC address filter.",
14496 "optional" : 1,
14497 "type" : "boolean"
7aacca6f 14498 },
44660702
DM
14499 "ndp" : {
14500 "description" : "Enable NDP.",
56122987 14501 "optional" : 1,
44660702 14502 "type" : "boolean"
56122987
DM
14503 },
14504 "policy_in" : {
7aacca6f 14505 "description" : "Input policy.",
56122987
DM
14506 "enum" : [
14507 "ACCEPT",
14508 "REJECT",
14509 "DROP"
14510 ],
7aacca6f 14511 "optional" : 1,
44660702 14512 "type" : "string"
56122987 14513 },
44660702
DM
14514 "policy_out" : {
14515 "description" : "Output policy.",
56122987 14516 "enum" : [
44660702
DM
14517 "ACCEPT",
14518 "REJECT",
14519 "DROP"
56122987 14520 ],
7aacca6f 14521 "optional" : 1,
56122987
DM
14522 "type" : "string"
14523 },
44660702
DM
14524 "radv" : {
14525 "description" : "Allow sending Router Advertisement.",
56122987 14526 "optional" : 1,
7aacca6f
DM
14527 "type" : "boolean"
14528 }
7aacca6f 14529 },
44660702
DM
14530 "type" : "object"
14531 }
7aacca6f
DM
14532 },
14533 "PUT" : {
44660702
DM
14534 "description" : "Set Firewall options.",
14535 "method" : "PUT",
7aacca6f
DM
14536 "name" : "set_options",
14537 "parameters" : {
44660702 14538 "additionalProperties" : 0,
7aacca6f 14539 "properties" : {
44660702
DM
14540 "delete" : {
14541 "description" : "A list of settings you want to delete.",
14542 "format" : "pve-configid-list",
14543 "optional" : 1,
14544 "type" : "string"
14545 },
14546 "dhcp" : {
14547 "description" : "Enable DHCP.",
14548 "optional" : 1,
14549 "type" : "boolean"
14550 },
14551 "digest" : {
14552 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
14553 "maxLength" : 40,
14554 "optional" : 1,
14555 "type" : "string"
14556 },
7aacca6f
DM
14557 "enable" : {
14558 "description" : "Enable/disable firewall rules.",
56122987 14559 "optional" : 1,
7aacca6f 14560 "type" : "boolean"
56122987 14561 },
44660702
DM
14562 "ipfilter" : {
14563 "description" : "Enable default IP filters. This is equivalent to adding an empty ipfilter-net<id> ipset for every interface. Such ipsets implicitly contain sane default restrictions such as restricting IPv6 link local addresses to the one derived from the interface's MAC address. For containers the configured IP addresses will be implicitly added.",
14564 "optional" : 1,
14565 "type" : "boolean"
14566 },
14567 "log_level_in" : {
14568 "description" : "Log level for incoming traffic.",
56122987
DM
14569 "enum" : [
14570 "emerg",
14571 "alert",
14572 "crit",
14573 "err",
14574 "warning",
14575 "notice",
14576 "info",
14577 "debug",
14578 "nolog"
14579 ],
56122987 14580 "optional" : 1,
44660702 14581 "type" : "string"
56122987 14582 },
44660702
DM
14583 "log_level_out" : {
14584 "description" : "Log level for outgoing traffic.",
56122987
DM
14585 "enum" : [
14586 "emerg",
14587 "alert",
14588 "crit",
14589 "err",
14590 "warning",
14591 "notice",
14592 "info",
14593 "debug",
14594 "nolog"
14595 ],
44660702
DM
14596 "optional" : 1,
14597 "type" : "string"
56122987 14598 },
44660702
DM
14599 "macfilter" : {
14600 "description" : "Enable/disable MAC address filter.",
14601 "optional" : 1,
14602 "type" : "boolean"
14603 },
14604 "ndp" : {
14605 "description" : "Enable NDP.",
56122987 14606 "optional" : 1,
56122987
DM
14607 "type" : "boolean"
14608 },
7aacca6f
DM
14609 "node" : {
14610 "description" : "The cluster node name.",
44660702
DM
14611 "format" : "pve-node",
14612 "type" : "string"
7aacca6f 14613 },
44660702
DM
14614 "policy_in" : {
14615 "description" : "Input policy.",
14616 "enum" : [
14617 "ACCEPT",
14618 "REJECT",
14619 "DROP"
14620 ],
7aacca6f 14621 "optional" : 1,
44660702 14622 "type" : "string"
7aacca6f 14623 },
44660702
DM
14624 "policy_out" : {
14625 "description" : "Output policy.",
56122987 14626 "enum" : [
7aacca6f
DM
14627 "ACCEPT",
14628 "REJECT",
14629 "DROP"
56122987
DM
14630 ],
14631 "optional" : 1,
56122987 14632 "type" : "string"
7aacca6f 14633 },
44660702
DM
14634 "radv" : {
14635 "description" : "Allow sending Router Advertisement.",
7aacca6f 14636 "optional" : 1,
44660702
DM
14637 "type" : "boolean"
14638 },
14639 "vmid" : {
14640 "description" : "The (unique) ID of the VM.",
14641 "format" : "pve-vmid",
14642 "minimum" : 1,
4bd7df8b 14643 "type" : "integer",
2c0dde61 14644 "typetext" : "integer (1 - N)"
56122987 14645 }
44660702 14646 }
56122987 14647 },
7aacca6f
DM
14648 "permissions" : {
14649 "check" : [
14650 "perm",
14651 "/vms/{vmid}",
14652 [
14653 "VM.Config.Network"
14654 ]
14655 ]
14656 },
44660702
DM
14657 "protected" : 1,
14658 "proxyto" : "node",
7aacca6f
DM
14659 "returns" : {
14660 "type" : "null"
56122987
DM
14661 }
14662 }
14663 },
44660702 14664 "leaf" : 1,
7aacca6f 14665 "path" : "/nodes/{node}/lxc/{vmid}/firewall/options",
44660702 14666 "text" : "options"
56122987
DM
14667 },
14668 {
56122987
DM
14669 "info" : {
14670 "GET" : {
44660702 14671 "description" : "Read firewall log",
56122987 14672 "method" : "GET",
7aacca6f 14673 "name" : "log",
56122987
DM
14674 "parameters" : {
14675 "additionalProperties" : 0,
14676 "properties" : {
44660702
DM
14677 "limit" : {
14678 "minimum" : 0,
14679 "optional" : 1,
4bd7df8b 14680 "type" : "integer",
2c0dde61 14681 "typetext" : "integer (0 - N)"
44660702 14682 },
56122987
DM
14683 "node" : {
14684 "description" : "The cluster node name.",
44660702
DM
14685 "format" : "pve-node",
14686 "type" : "string"
56122987 14687 },
44660702
DM
14688 "start" : {
14689 "minimum" : 0,
7aacca6f 14690 "optional" : 1,
4bd7df8b 14691 "type" : "integer",
2c0dde61 14692 "typetext" : "integer (0 - N)"
56122987
DM
14693 },
14694 "vmid" : {
44660702 14695 "description" : "The (unique) ID of the VM.",
7aacca6f 14696 "format" : "pve-vmid",
56122987 14697 "minimum" : 1,
4bd7df8b 14698 "type" : "integer",
2c0dde61 14699 "typetext" : "integer (1 - N)"
56122987
DM
14700 }
14701 }
14702 },
44660702
DM
14703 "permissions" : {
14704 "check" : [
14705 "perm",
14706 "/vms/{vmid}",
14707 [
14708 "VM.Console"
14709 ]
14710 ]
14711 },
56122987 14712 "protected" : 1,
44660702 14713 "proxyto" : "node",
7aacca6f
DM
14714 "returns" : {
14715 "items" : {
14716 "properties" : {
7aacca6f
DM
14717 "n" : {
14718 "description" : "Line number",
14719 "type" : "integer"
44660702
DM
14720 },
14721 "t" : {
14722 "description" : "Line text",
14723 "type" : "string"
7aacca6f
DM
14724 }
14725 },
14726 "type" : "object"
14727 },
14728 "type" : "array"
44660702 14729 }
56122987
DM
14730 }
14731 },
7aacca6f 14732 "leaf" : 1,
44660702
DM
14733 "path" : "/nodes/{node}/lxc/{vmid}/firewall/log",
14734 "text" : "log"
56122987
DM
14735 },
14736 {
56122987
DM
14737 "info" : {
14738 "GET" : {
7aacca6f 14739 "description" : "Lists possible IPSet/Alias reference which are allowed in source/dest properties.",
44660702
DM
14740 "method" : "GET",
14741 "name" : "refs",
56122987 14742 "parameters" : {
7aacca6f 14743 "additionalProperties" : 0,
56122987 14744 "properties" : {
44660702
DM
14745 "node" : {
14746 "description" : "The cluster node name.",
14747 "format" : "pve-node",
14748 "type" : "string"
7aacca6f 14749 },
56122987 14750 "type" : {
44660702 14751 "description" : "Only list references of specified type.",
56122987
DM
14752 "enum" : [
14753 "alias",
14754 "ipset"
14755 ],
44660702
DM
14756 "optional" : 1,
14757 "type" : "string"
56122987 14758 },
44660702
DM
14759 "vmid" : {
14760 "description" : "The (unique) ID of the VM.",
14761 "format" : "pve-vmid",
14762 "minimum" : 1,
4bd7df8b 14763 "type" : "integer",
2c0dde61 14764 "typetext" : "integer (1 - N)"
56122987 14765 }
7aacca6f 14766 }
56122987 14767 },
44660702
DM
14768 "permissions" : {
14769 "check" : [
14770 "perm",
14771 "/vms/{vmid}",
14772 [
14773 "VM.Audit"
14774 ]
14775 ]
14776 },
56122987 14777 "returns" : {
56122987 14778 "items" : {
56122987 14779 "properties" : {
44660702
DM
14780 "comment" : {
14781 "optional" : 1,
14782 "type" : "string"
14783 },
14784 "name" : {
14785 "type" : "string"
14786 },
56122987 14787 "type" : {
56122987
DM
14788 "enum" : [
14789 "alias",
14790 "ipset"
44660702 14791 ],
7aacca6f 14792 "type" : "string"
56122987 14793 }
44660702
DM
14794 },
14795 "type" : "object"
14796 },
14797 "type" : "array"
56122987
DM
14798 }
14799 }
14800 },
44660702 14801 "leaf" : 1,
7aacca6f 14802 "path" : "/nodes/{node}/lxc/{vmid}/firewall/refs",
44660702 14803 "text" : "refs"
56122987
DM
14804 }
14805 ],
56122987
DM
14806 "info" : {
14807 "GET" : {
7aacca6f 14808 "description" : "Directory index.",
44660702
DM
14809 "method" : "GET",
14810 "name" : "index",
56122987 14811 "parameters" : {
44660702 14812 "additionalProperties" : 0,
56122987 14813 "properties" : {
56122987 14814 "node" : {
44660702 14815 "description" : "The cluster node name.",
56122987 14816 "format" : "pve-node",
44660702
DM
14817 "type" : "string"
14818 },
14819 "vmid" : {
14820 "description" : "The (unique) ID of the VM.",
14821 "format" : "pve-vmid",
14822 "minimum" : 1,
4bd7df8b 14823 "type" : "integer",
2c0dde61 14824 "typetext" : "integer (1 - N)"
56122987 14825 }
44660702
DM
14826 }
14827 },
14828 "permissions" : {
14829 "user" : "all"
56122987
DM
14830 },
14831 "returns" : {
7aacca6f 14832 "items" : {
44660702
DM
14833 "properties" : {},
14834 "type" : "object"
7aacca6f 14835 },
56122987
DM
14836 "links" : [
14837 {
44660702
DM
14838 "href" : "{name}",
14839 "rel" : "child"
56122987 14840 }
44660702
DM
14841 ],
14842 "type" : "array"
56122987
DM
14843 }
14844 }
14845 },
44660702 14846 "leaf" : 0,
7aacca6f 14847 "path" : "/nodes/{node}/lxc/{vmid}/firewall",
44660702 14848 "text" : "firewall"
56122987
DM
14849 },
14850 {
56122987
DM
14851 "info" : {
14852 "GET" : {
56122987 14853 "description" : "Read VM RRD statistics (returns PNG)",
44660702 14854 "method" : "GET",
7aacca6f 14855 "name" : "rrd",
56122987 14856 "parameters" : {
7aacca6f 14857 "additionalProperties" : 0,
56122987 14858 "properties" : {
44660702
DM
14859 "cf" : {
14860 "description" : "The RRD consolidation function",
14861 "enum" : [
14862 "AVERAGE",
14863 "MAX"
14864 ],
14865 "optional" : 1,
14866 "type" : "string"
14867 },
14868 "ds" : {
14869 "description" : "The list of datasources you want to display.",
14870 "format" : "pve-configid-list",
14871 "type" : "string"
14872 },
7aacca6f
DM
14873 "node" : {
14874 "description" : "The cluster node name.",
44660702
DM
14875 "format" : "pve-node",
14876 "type" : "string"
56122987
DM
14877 },
14878 "timeframe" : {
14879 "description" : "Specify the time frame you are interested in.",
14880 "enum" : [
14881 "hour",
14882 "day",
14883 "week",
14884 "month",
14885 "year"
7aacca6f 14886 ],
44660702 14887 "type" : "string"
7aacca6f
DM
14888 },
14889 "vmid" : {
44660702 14890 "description" : "The (unique) ID of the VM.",
7aacca6f
DM
14891 "format" : "pve-vmid",
14892 "minimum" : 1,
4bd7df8b 14893 "type" : "integer",
2c0dde61 14894 "typetext" : "integer (1 - N)"
56122987 14895 }
7aacca6f
DM
14896 }
14897 },
14898 "permissions" : {
14899 "check" : [
14900 "perm",
14901 "/vms/{vmid}",
14902 [
14903 "VM.Audit"
14904 ]
14905 ]
56122987 14906 },
44660702 14907 "protected" : 1,
7aacca6f
DM
14908 "returns" : {
14909 "properties" : {
14910 "filename" : {
14911 "type" : "string"
14912 }
14913 },
14914 "type" : "object"
14915 }
56122987 14916 }
7aacca6f 14917 },
44660702 14918 "leaf" : 1,
7aacca6f 14919 "path" : "/nodes/{node}/lxc/{vmid}/rrd",
44660702 14920 "text" : "rrd"
56122987
DM
14921 },
14922 {
56122987
DM
14923 "info" : {
14924 "GET" : {
44660702
DM
14925 "description" : "Read VM RRD statistics",
14926 "method" : "GET",
14927 "name" : "rrddata",
56122987 14928 "parameters" : {
7aacca6f 14929 "additionalProperties" : 0,
56122987 14930 "properties" : {
44660702
DM
14931 "cf" : {
14932 "description" : "The RRD consolidation function",
14933 "enum" : [
14934 "AVERAGE",
14935 "MAX"
14936 ],
14937 "optional" : 1,
14938 "type" : "string"
14939 },
7aacca6f 14940 "node" : {
44660702 14941 "description" : "The cluster node name.",
7aacca6f 14942 "format" : "pve-node",
44660702 14943 "type" : "string"
7aacca6f 14944 },
56122987
DM
14945 "timeframe" : {
14946 "description" : "Specify the time frame you are interested in.",
14947 "enum" : [
14948 "hour",
14949 "day",
14950 "week",
14951 "month",
14952 "year"
44660702
DM
14953 ],
14954 "type" : "string"
7aacca6f
DM
14955 },
14956 "vmid" : {
14957 "description" : "The (unique) ID of the VM.",
44660702 14958 "format" : "pve-vmid",
7aacca6f 14959 "minimum" : 1,
4bd7df8b 14960 "type" : "integer",
2c0dde61 14961 "typetext" : "integer (1 - N)"
56122987 14962 }
56122987
DM
14963 }
14964 },
56122987
DM
14965 "permissions" : {
14966 "check" : [
14967 "perm",
14968 "/vms/{vmid}",
14969 [
14970 "VM.Audit"
14971 ]
14972 ]
14973 },
7aacca6f
DM
14974 "protected" : 1,
14975 "returns" : {
7aacca6f
DM
14976 "items" : {
14977 "properties" : {},
14978 "type" : "object"
44660702
DM
14979 },
14980 "type" : "array"
14981 }
56122987
DM
14982 }
14983 },
44660702 14984 "leaf" : 1,
7aacca6f 14985 "path" : "/nodes/{node}/lxc/{vmid}/rrddata",
44660702 14986 "text" : "rrddata"
56122987
DM
14987 },
14988 {
14989 "info" : {
14990 "POST" : {
14991 "description" : "Creates a TCP VNC proxy connections.",
44660702
DM
14992 "method" : "POST",
14993 "name" : "vncproxy",
7aacca6f 14994 "parameters" : {
44660702 14995 "additionalProperties" : 0,
7aacca6f 14996 "properties" : {
44660702
DM
14997 "node" : {
14998 "description" : "The cluster node name.",
14999 "format" : "pve-node",
15000 "type" : "string"
15001 },
7aacca6f 15002 "vmid" : {
44660702 15003 "description" : "The (unique) ID of the VM.",
7aacca6f
DM
15004 "format" : "pve-vmid",
15005 "minimum" : 1,
4bd7df8b 15006 "type" : "integer",
2c0dde61 15007 "typetext" : "integer (1 - N)"
7aacca6f
DM
15008 },
15009 "websocket" : {
44660702 15010 "description" : "use websocket instead of standard VNC.",
7aacca6f 15011 "optional" : 1,
44660702 15012 "type" : "boolean"
7aacca6f 15013 }
44660702 15014 }
7aacca6f 15015 },
56122987
DM
15016 "permissions" : {
15017 "check" : [
15018 "perm",
15019 "/vms/{vmid}",
15020 [
15021 "VM.Console"
15022 ]
15023 ]
15024 },
44660702 15025 "protected" : 1,
56122987 15026 "returns" : {
7aacca6f 15027 "additionalProperties" : 0,
56122987 15028 "properties" : {
7aacca6f 15029 "cert" : {
56122987
DM
15030 "type" : "string"
15031 },
44660702
DM
15032 "port" : {
15033 "type" : "integer"
56122987 15034 },
44660702 15035 "ticket" : {
56122987
DM
15036 "type" : "string"
15037 },
44660702 15038 "upid" : {
56122987
DM
15039 "type" : "string"
15040 },
44660702
DM
15041 "user" : {
15042 "type" : "string"
56122987 15043 }
7aacca6f 15044 }
56122987
DM
15045 }
15046 }
15047 },
44660702 15048 "leaf" : 1,
56122987 15049 "path" : "/nodes/{node}/lxc/{vmid}/vncproxy",
44660702 15050 "text" : "vncproxy"
56122987
DM
15051 },
15052 {
56122987
DM
15053 "info" : {
15054 "GET" : {
44660702
DM
15055 "description" : "Opens a weksocket for VNC traffic.",
15056 "method" : "GET",
15057 "name" : "vncwebsocket",
56122987 15058 "parameters" : {
44660702 15059 "additionalProperties" : 0,
56122987 15060 "properties" : {
56122987
DM
15061 "node" : {
15062 "description" : "The cluster node name.",
44660702 15063 "format" : "pve-node",
56122987 15064 "type" : "string"
7aacca6f 15065 },
44660702
DM
15066 "port" : {
15067 "description" : "Port number returned by previous vncproxy call.",
15068 "maximum" : 5999,
15069 "minimum" : 5900,
4bd7df8b 15070 "type" : "integer",
2c0dde61 15071 "typetext" : "integer (5900 - 5999)"
44660702 15072 },
7aacca6f
DM
15073 "vmid" : {
15074 "description" : "The (unique) ID of the VM.",
7aacca6f 15075 "format" : "pve-vmid",
44660702 15076 "minimum" : 1,
4bd7df8b 15077 "type" : "integer",
2c0dde61 15078 "typetext" : "integer (1 - N)"
44660702
DM
15079 },
15080 "vncticket" : {
15081 "description" : "Ticket from previous call to vncproxy.",
15082 "maxLength" : 512,
15083 "type" : "string"
56122987 15084 }
44660702 15085 }
7aacca6f 15086 },
7aacca6f
DM
15087 "permissions" : {
15088 "check" : [
15089 "perm",
15090 "/vms/{vmid}",
15091 [
15092 "VM.Console"
15093 ]
15094 ],
15095 "description" : "You also need to pass a valid ticket (vncticket)."
56122987
DM
15096 },
15097 "returns" : {
56122987
DM
15098 "properties" : {
15099 "port" : {
15100 "type" : "string"
15101 }
44660702
DM
15102 },
15103 "type" : "object"
15104 }
56122987
DM
15105 }
15106 },
44660702 15107 "leaf" : 1,
7aacca6f 15108 "path" : "/nodes/{node}/lxc/{vmid}/vncwebsocket",
44660702 15109 "text" : "vncwebsocket"
56122987
DM
15110 },
15111 {
56122987
DM
15112 "info" : {
15113 "POST" : {
44660702
DM
15114 "description" : "Returns a SPICE configuration to connect to the CT.",
15115 "method" : "POST",
15116 "name" : "spiceproxy",
56122987
DM
15117 "parameters" : {
15118 "additionalProperties" : 0,
15119 "properties" : {
44660702
DM
15120 "node" : {
15121 "description" : "The cluster node name.",
15122 "format" : "pve-node",
15123 "type" : "string"
56122987
DM
15124 },
15125 "proxy" : {
7aacca6f 15126 "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).",
44660702
DM
15127 "format" : "address",
15128 "optional" : 1,
7aacca6f 15129 "type" : "string"
44660702
DM
15130 },
15131 "vmid" : {
15132 "description" : "The (unique) ID of the VM.",
15133 "format" : "pve-vmid",
15134 "minimum" : 1,
4bd7df8b 15135 "type" : "integer",
2c0dde61 15136 "typetext" : "integer (1 - N)"
56122987
DM
15137 }
15138 }
15139 },
56122987
DM
15140 "permissions" : {
15141 "check" : [
15142 "perm",
15143 "/vms/{vmid}",
15144 [
15145 "VM.Console"
15146 ]
15147 ]
15148 },
44660702
DM
15149 "protected" : 1,
15150 "proxyto" : "node",
56122987 15151 "returns" : {
7aacca6f 15152 "additionalProperties" : 1,
44660702 15153 "description" : "Returned values can be directly passed to the 'remote-viewer' application.",
56122987 15154 "properties" : {
44660702 15155 "host" : {
56122987
DM
15156 "type" : "string"
15157 },
44660702 15158 "password" : {
56122987
DM
15159 "type" : "string"
15160 },
15161 "proxy" : {
15162 "type" : "string"
15163 },
56122987
DM
15164 "tls-port" : {
15165 "type" : "integer"
7aacca6f 15166 },
44660702 15167 "type" : {
7aacca6f 15168 "type" : "string"
56122987 15169 }
7aacca6f
DM
15170 }
15171 }
56122987 15172 }
44660702
DM
15173 },
15174 "leaf" : 1,
15175 "path" : "/nodes/{node}/lxc/{vmid}/spiceproxy",
15176 "text" : "spiceproxy"
56122987
DM
15177 },
15178 {
56122987
DM
15179 "info" : {
15180 "POST" : {
44660702 15181 "description" : "Migrate the container to another node. Creates a new migration task.",
7aacca6f 15182 "method" : "POST",
44660702 15183 "name" : "migrate_vm",
56122987 15184 "parameters" : {
44660702 15185 "additionalProperties" : 0,
56122987 15186 "properties" : {
44660702
DM
15187 "force" : {
15188 "description" : "Force migration despite local bind / device mounts. WARNING: identical bind / device mounts need to be available on the target node.",
15189 "optional" : 1,
15190 "type" : "boolean"
15191 },
15192 "node" : {
15193 "description" : "The cluster node name.",
7aacca6f 15194 "format" : "pve-node",
7aacca6f
DM
15195 "type" : "string"
15196 },
56122987 15197 "online" : {
56122987 15198 "description" : "Use online/live migration.",
44660702
DM
15199 "optional" : 1,
15200 "type" : "boolean"
56122987 15201 },
44660702
DM
15202 "target" : {
15203 "description" : "Target node.",
56122987 15204 "format" : "pve-node",
44660702 15205 "type" : "string"
56122987 15206 },
44660702
DM
15207 "vmid" : {
15208 "description" : "The (unique) ID of the VM.",
15209 "format" : "pve-vmid",
15210 "minimum" : 1,
4bd7df8b 15211 "type" : "integer",
2c0dde61 15212 "typetext" : "integer (1 - N)"
56122987 15213 }
44660702 15214 }
7aacca6f 15215 },
56122987
DM
15216 "permissions" : {
15217 "check" : [
15218 "perm",
15219 "/vms/{vmid}",
15220 [
15221 "VM.Migrate"
15222 ]
15223 ]
15224 },
44660702 15225 "protected" : 1,
7aacca6f 15226 "proxyto" : "node",
44660702
DM
15227 "returns" : {
15228 "description" : "the task ID.",
15229 "type" : "string"
15230 }
56122987
DM
15231 }
15232 },
44660702
DM
15233 "leaf" : 1,
15234 "path" : "/nodes/{node}/lxc/{vmid}/migrate",
7aacca6f 15235 "text" : "migrate"
56122987
DM
15236 },
15237 {
56122987
DM
15238 "info" : {
15239 "GET" : {
44660702
DM
15240 "description" : "Check if feature for virtual machine is available.",
15241 "method" : "GET",
56122987 15242 "name" : "vm_feature",
56122987 15243 "parameters" : {
7aacca6f 15244 "additionalProperties" : 0,
56122987 15245 "properties" : {
44660702
DM
15246 "feature" : {
15247 "description" : "Feature to check.",
15248 "enum" : [
15249 "snapshot"
15250 ],
15251 "type" : "string"
15252 },
7aacca6f 15253 "node" : {
44660702 15254 "description" : "The cluster node name.",
7aacca6f 15255 "format" : "pve-node",
44660702 15256 "type" : "string"
7aacca6f 15257 },
56122987 15258 "snapname" : {
7aacca6f
DM
15259 "description" : "The name of the snapshot.",
15260 "format" : "pve-configid",
44660702
DM
15261 "maxLength" : 40,
15262 "optional" : 1,
56122987
DM
15263 "type" : "string"
15264 },
15265 "vmid" : {
7aacca6f 15266 "description" : "The (unique) ID of the VM.",
44660702 15267 "format" : "pve-vmid",
7aacca6f 15268 "minimum" : 1,
4bd7df8b 15269 "type" : "integer",
2c0dde61 15270 "typetext" : "integer (1 - N)"
56122987 15271 }
7aacca6f 15272 }
56122987
DM
15273 },
15274 "permissions" : {
15275 "check" : [
15276 "perm",
15277 "/vms/{vmid}",
15278 [
15279 "VM.Audit"
15280 ]
15281 ]
15282 },
44660702 15283 "protected" : 1,
7aacca6f 15284 "proxyto" : "node",
7aacca6f
DM
15285 "returns" : {
15286 "properties" : {
15287 "hasFeature" : {
15288 "type" : "boolean"
15289 }
15290 },
15291 "type" : "object"
15292 }
56122987
DM
15293 }
15294 },
7aacca6f 15295 "leaf" : 1,
44660702
DM
15296 "path" : "/nodes/{node}/lxc/{vmid}/feature",
15297 "text" : "feature"
56122987
DM
15298 },
15299 {
56122987
DM
15300 "info" : {
15301 "POST" : {
44660702
DM
15302 "description" : "Create a Template.",
15303 "method" : "POST",
56122987 15304 "name" : "template",
56122987
DM
15305 "parameters" : {
15306 "additionalProperties" : 0,
15307 "properties" : {
44660702
DM
15308 "experimental" : {
15309 "default" : 0,
15310 "description" : "The template feature is experimental, set this flag if you know what you are doing.",
15311 "type" : "boolean"
7aacca6f
DM
15312 },
15313 "node" : {
7aacca6f 15314 "description" : "The cluster node name.",
44660702 15315 "format" : "pve-node",
7aacca6f 15316 "type" : "string"
56122987 15317 },
44660702
DM
15318 "vmid" : {
15319 "description" : "The (unique) ID of the VM.",
15320 "format" : "pve-vmid",
15321 "minimum" : 1,
4bd7df8b 15322 "type" : "integer",
2c0dde61 15323 "typetext" : "integer (1 - N)"
56122987
DM
15324 }
15325 }
15326 },
56122987 15327 "permissions" : {
56122987
DM
15328 "check" : [
15329 "perm",
15330 "/vms/{vmid}",
15331 [
15332 "VM.Allocate"
15333 ]
44660702
DM
15334 ],
15335 "description" : "You need 'VM.Allocate' permissions on /vms/{vmid}"
7aacca6f 15336 },
44660702 15337 "protected" : 1,
7aacca6f
DM
15338 "proxyto" : "node",
15339 "returns" : {
15340 "type" : "null"
56122987
DM
15341 }
15342 }
15343 },
44660702 15344 "leaf" : 1,
7aacca6f 15345 "path" : "/nodes/{node}/lxc/{vmid}/template",
44660702 15346 "text" : "template"
56122987
DM
15347 },
15348 {
56122987
DM
15349 "info" : {
15350 "POST" : {
44660702
DM
15351 "description" : "Create a container clone/copy",
15352 "method" : "POST",
56122987 15353 "name" : "clone_vm",
7aacca6f
DM
15354 "parameters" : {
15355 "additionalProperties" : 0,
15356 "properties" : {
44660702
DM
15357 "description" : {
15358 "description" : "Description for the new CT.",
7aacca6f 15359 "optional" : 1,
44660702 15360 "type" : "string"
7aacca6f
DM
15361 },
15362 "experimental" : {
7aacca6f 15363 "default" : 0,
44660702
DM
15364 "description" : "The clone feature is experimental, set this flag if you know what you are doing.",
15365 "type" : "boolean"
7aacca6f 15366 },
44660702
DM
15367 "full" : {
15368 "default" : 0,
15369 "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.",
7aacca6f 15370 "optional" : 1,
44660702 15371 "type" : "boolean"
7aacca6f
DM
15372 },
15373 "hostname" : {
44660702 15374 "description" : "Set a hostname for the new CT.",
7aacca6f 15375 "format" : "dns-name",
7aacca6f 15376 "optional" : 1,
44660702 15377 "type" : "string"
7aacca6f 15378 },
44660702
DM
15379 "newid" : {
15380 "description" : "VMID for the clone.",
7aacca6f 15381 "format" : "pve-vmid",
44660702 15382 "minimum" : 1,
4bd7df8b 15383 "type" : "integer",
2c0dde61 15384 "typetext" : "integer (1 - N)"
7aacca6f
DM
15385 },
15386 "node" : {
15387 "description" : "The cluster node name.",
44660702
DM
15388 "format" : "pve-node",
15389 "type" : "string"
15390 },
15391 "pool" : {
15392 "description" : "Add the new CT to the specified pool.",
15393 "format" : "pve-poolid",
15394 "optional" : 1,
15395 "type" : "string"
7aacca6f
DM
15396 },
15397 "snapname" : {
44660702 15398 "description" : "The name of the snapshot.",
7aacca6f
DM
15399 "format" : "pve-configid",
15400 "maxLength" : 40,
7aacca6f 15401 "optional" : 1,
44660702 15402 "type" : "string"
7aacca6f
DM
15403 },
15404 "storage" : {
44660702 15405 "description" : "Target storage for full clone.",
7aacca6f
DM
15406 "format" : "pve-storage-id",
15407 "optional" : 1,
7aacca6f 15408 "requires" : "full",
44660702
DM
15409 "type" : "string"
15410 },
15411 "vmid" : {
15412 "description" : "The (unique) ID of the VM.",
15413 "format" : "pve-vmid",
15414 "minimum" : 1,
4bd7df8b 15415 "type" : "integer",
2c0dde61 15416 "typetext" : "integer (1 - N)"
7aacca6f
DM
15417 }
15418 }
56122987
DM
15419 },
15420 "permissions" : {
56122987
DM
15421 "check" : [
15422 "and",
15423 [
15424 "perm",
15425 "/vms/{vmid}",
15426 [
15427 "VM.Clone"
15428 ]
15429 ],
15430 [
15431 "or",
15432 [
15433 "perm",
15434 "/vms/{newid}",
15435 [
15436 "VM.Allocate"
15437 ]
15438 ],
15439 [
15440 "perm",
15441 "/pool/{pool}",
15442 [
15443 "VM.Allocate"
15444 ],
15445 "require_param",
15446 "pool"
15447 ]
15448 ]
7aacca6f
DM
15449 ],
15450 "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."
56122987 15451 },
44660702 15452 "protected" : 1,
56122987 15453 "proxyto" : "node",
7aacca6f
DM
15454 "returns" : {
15455 "type" : "string"
56122987
DM
15456 }
15457 }
44660702
DM
15458 },
15459 "leaf" : 1,
15460 "path" : "/nodes/{node}/lxc/{vmid}/clone",
15461 "text" : "clone"
56122987
DM
15462 },
15463 {
56122987
DM
15464 "info" : {
15465 "PUT" : {
44660702
DM
15466 "description" : "Resize a container mountpoint.",
15467 "method" : "PUT",
15468 "name" : "resize_vm",
56122987 15469 "parameters" : {
44660702 15470 "additionalProperties" : 0,
56122987 15471 "properties" : {
44660702
DM
15472 "digest" : {
15473 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
15474 "maxLength" : 40,
15475 "optional" : 1,
15476 "type" : "string"
56122987
DM
15477 },
15478 "disk" : {
7aacca6f 15479 "description" : "The disk you want to resize.",
56122987
DM
15480 "enum" : [
15481 "rootfs",
15482 "mp0",
15483 "mp1",
15484 "mp2",
15485 "mp3",
15486 "mp4",
15487 "mp5",
15488 "mp6",
15489 "mp7",
15490 "mp8",
15491 "mp9"
15492 ],
7aacca6f
DM
15493 "type" : "string"
15494 },
44660702
DM
15495 "node" : {
15496 "description" : "The cluster node name.",
15497 "format" : "pve-node",
15498 "type" : "string"
15499 },
15500 "size" : {
15501 "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.",
15502 "pattern" : "\\+?\\d+(\\.\\d+)?[KMGT]?",
15503 "type" : "string"
15504 },
15505 "vmid" : {
15506 "description" : "The (unique) ID of the VM.",
15507 "format" : "pve-vmid",
15508 "minimum" : 1,
4bd7df8b 15509 "type" : "integer",
2c0dde61 15510 "typetext" : "integer (1 - N)"
56122987 15511 }
44660702 15512 }
56122987 15513 },
7aacca6f
DM
15514 "permissions" : {
15515 "check" : [
15516 "perm",
15517 "/vms/{vmid}",
15518 [
15519 "VM.Config.Disk"
15520 ],
15521 "any",
15522 1
15523 ]
15524 },
44660702 15525 "protected" : 1,
7aacca6f
DM
15526 "proxyto" : "node",
15527 "returns" : {
15528 "description" : "the task ID.",
15529 "type" : "string"
15530 }
56122987
DM
15531 }
15532 },
44660702 15533 "leaf" : 1,
7aacca6f 15534 "path" : "/nodes/{node}/lxc/{vmid}/resize",
44660702 15535 "text" : "resize"
56122987
DM
15536 }
15537 ],
15538 "info" : {
15539 "DELETE" : {
7aacca6f 15540 "description" : "Destroy the container (also delete all uses files).",
44660702
DM
15541 "method" : "DELETE",
15542 "name" : "destroy_vm",
15543 "parameters" : {
15544 "additionalProperties" : 0,
15545 "properties" : {
15546 "node" : {
15547 "description" : "The cluster node name.",
15548 "format" : "pve-node",
15549 "type" : "string"
15550 },
15551 "vmid" : {
15552 "description" : "The (unique) ID of the VM.",
15553 "format" : "pve-vmid",
15554 "minimum" : 1,
4bd7df8b 15555 "type" : "integer",
2c0dde61 15556 "typetext" : "integer (1 - N)"
44660702
DM
15557 }
15558 }
15559 },
7aacca6f
DM
15560 "permissions" : {
15561 "check" : [
15562 "perm",
15563 "/vms/{vmid}",
15564 [
15565 "VM.Allocate"
15566 ]
15567 ]
15568 },
44660702
DM
15569 "protected" : 1,
15570 "proxyto" : "node",
56122987
DM
15571 "returns" : {
15572 "type" : "string"
44660702 15573 }
56122987
DM
15574 },
15575 "GET" : {
7aacca6f 15576 "description" : "Directory index",
44660702 15577 "method" : "GET",
7aacca6f 15578 "name" : "vmdiridx",
56122987 15579 "parameters" : {
7aacca6f 15580 "additionalProperties" : 0,
56122987
DM
15581 "properties" : {
15582 "node" : {
7aacca6f 15583 "description" : "The cluster node name.",
44660702
DM
15584 "format" : "pve-node",
15585 "type" : "string"
56122987
DM
15586 },
15587 "vmid" : {
15588 "description" : "The (unique) ID of the VM.",
56122987 15589 "format" : "pve-vmid",
44660702 15590 "minimum" : 1,
4bd7df8b 15591 "type" : "integer",
2c0dde61 15592 "typetext" : "integer (1 - N)"
56122987 15593 }
7aacca6f 15594 }
56122987 15595 },
56122987
DM
15596 "permissions" : {
15597 "user" : "all"
44660702
DM
15598 },
15599 "proxyto" : "node",
15600 "returns" : {
15601 "items" : {
15602 "properties" : {
15603 "subdir" : {
15604 "type" : "string"
15605 }
15606 },
15607 "type" : "object"
15608 },
15609 "links" : [
15610 {
15611 "href" : "{subdir}",
15612 "rel" : "child"
15613 }
15614 ],
15615 "type" : "array"
56122987
DM
15616 }
15617 }
44660702
DM
15618 },
15619 "leaf" : 0,
15620 "path" : "/nodes/{node}/lxc/{vmid}",
15621 "text" : "{vmid}"
56122987
DM
15622 }
15623 ],
56122987 15624 "info" : {
44660702
DM
15625 "GET" : {
15626 "description" : "LXC container index (per node).",
15627 "method" : "GET",
15628 "name" : "vmlist",
15629 "parameters" : {
15630 "additionalProperties" : 0,
15631 "properties" : {
15632 "node" : {
15633 "description" : "The cluster node name.",
15634 "format" : "pve-node",
15635 "type" : "string"
15636 }
15637 }
15638 },
15639 "permissions" : {
15640 "description" : "Only list CTs where you have VM.Audit permissons on /vms/<vmid>.",
15641 "user" : "all"
15642 },
15643 "protected" : 1,
15644 "proxyto" : "node",
15645 "returns" : {
15646 "items" : {
15647 "properties" : {},
15648 "type" : "object"
15649 },
15650 "links" : [
15651 {
15652 "href" : "{vmid}",
15653 "rel" : "child"
15654 }
15655 ],
15656 "type" : "array"
15657 }
15658 },
56122987 15659 "POST" : {
44660702 15660 "description" : "Create or restore a container.",
7aacca6f
DM
15661 "method" : "POST",
15662 "name" : "create_vm",
56122987 15663 "parameters" : {
7aacca6f 15664 "additionalProperties" : 0,
56122987 15665 "properties" : {
44660702
DM
15666 "arch" : {
15667 "default" : "amd64",
15668 "description" : "OS architecture type.",
15669 "enum" : [
15670 "amd64",
15671 "i386"
15672 ],
7aacca6f 15673 "optional" : 1,
44660702 15674 "type" : "string"
7aacca6f 15675 },
44660702
DM
15676 "cmode" : {
15677 "default" : "tty",
15678 "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).",
15679 "enum" : [
15680 "shell",
15681 "console",
15682 "tty"
15683 ],
7aacca6f 15684 "optional" : 1,
44660702 15685 "type" : "string"
7aacca6f
DM
15686 },
15687 "console" : {
7aacca6f 15688 "default" : 1,
44660702 15689 "description" : "Attach a console device (/dev/console) to the container.",
56122987 15690 "optional" : 1,
7aacca6f 15691 "type" : "boolean"
56122987 15692 },
44660702
DM
15693 "cpulimit" : {
15694 "default" : 0,
15695 "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.",
15696 "maximum" : 128,
15697 "minimum" : 0,
56122987 15698 "optional" : 1,
4bd7df8b 15699 "type" : "number",
2c0dde61 15700 "typetext" : "number (0 - 128)"
56122987 15701 },
44660702
DM
15702 "cpuunits" : {
15703 "default" : 1024,
15704 "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.",
15705 "maximum" : 500000,
15706 "minimum" : 0,
56122987 15707 "optional" : 1,
4bd7df8b 15708 "type" : "integer",
2c0dde61 15709 "typetext" : "integer (0 - 500000)"
7aacca6f
DM
15710 },
15711 "description" : {
44660702 15712 "description" : "Container description. Only used on the configuration web interface.",
7aacca6f 15713 "optional" : 1,
44660702 15714 "type" : "string"
7aacca6f 15715 },
44660702
DM
15716 "force" : {
15717 "description" : "Allow to overwrite existing container.",
7aacca6f 15718 "optional" : 1,
44660702
DM
15719 "type" : "boolean"
15720 },
15721 "hostname" : {
15722 "description" : "Set a host name for the container.",
15723 "format" : "dns-name",
15724 "maxLength" : 255,
15725 "optional" : 1,
15726 "type" : "string"
15727 },
15728 "ignore-unpack-errors" : {
15729 "description" : "Ignore errors when extracting the template.",
15730 "optional" : 1,
15731 "type" : "boolean"
15732 },
15733 "lock" : {
15734 "description" : "Lock/unlock the VM.",
7aacca6f
DM
15735 "enum" : [
15736 "migrate",
15737 "backup",
15738 "snapshot",
15739 "rollback"
15740 ],
44660702
DM
15741 "optional" : 1,
15742 "type" : "string"
7aacca6f 15743 },
44660702
DM
15744 "memory" : {
15745 "default" : 512,
15746 "description" : "Amount of RAM for the VM in MB.",
15747 "minimum" : 16,
7aacca6f 15748 "optional" : 1,
4bd7df8b 15749 "type" : "integer",
2c0dde61 15750 "typetext" : "integer (16 - N)"
44660702
DM
15751 },
15752 "mp[n]" : {
c2993fe5 15753 "description" : "Use volume as container mount point.",
56122987 15754 "format" : {
7aacca6f
DM
15755 "acl" : {
15756 "description" : "Explicitly enable or disable ACL support.",
15757 "optional" : 1,
44660702 15758 "type" : "boolean"
56122987
DM
15759 },
15760 "backup" : {
56122987 15761 "description" : "Whether to include the mountpoint in backups.",
44660702 15762 "optional" : 1,
4bd7df8b
DM
15763 "type" : "boolean",
15764 "verbose_description" : "Whether to include the mountpoint in backups (only used for volume mountpoints)."
44660702
DM
15765 },
15766 "mp" : {
4bd7df8b 15767 "description" : "Path to the mountpoint as seen from inside the container (must not contain symlinks).",
44660702
DM
15768 "format" : "pve-lxc-mp-string",
15769 "format_description" : "Path",
4bd7df8b
DM
15770 "type" : "string",
15771 "verbose_description" : "Path to the mountpoint as seen from inside the container.\n\nNOTE: Must not contain any symlinks for security reasons."
44660702
DM
15772 },
15773 "quota" : {
15774 "description" : "Enable user quotas inside the container (not supported with zfs subvolumes)",
7aacca6f 15775 "optional" : 1,
44660702
DM
15776 "type" : "boolean"
15777 },
15778 "ro" : {
4bd7df8b 15779 "description" : "Read-only mountpoint",
44660702
DM
15780 "optional" : 1,
15781 "type" : "boolean"
7aacca6f
DM
15782 },
15783 "size" : {
44660702 15784 "description" : "Volume size (read only value).",
7aacca6f
DM
15785 "format" : "disk-size",
15786 "format_description" : "DiskSize",
7aacca6f
DM
15787 "optional" : 1,
15788 "type" : "string"
56122987
DM
15789 },
15790 "volume" : {
7aacca6f 15791 "default_key" : 1,
44660702 15792 "description" : "Volume, device or directory to mount into the container.",
56122987 15793 "format" : "pve-lxc-mp-string",
56122987 15794 "format_description" : "volume",
44660702 15795 "type" : "string"
56122987 15796 }
44660702 15797 },
56122987 15798 "optional" : 1,
4bd7df8b
DM
15799 "type" : "string",
15800 "typetext" : "[volume=]<volume> ,mp=<Path> [,acl=<1|0>] [,backup=<1|0>] [,quota=<1|0>] [,ro=<1|0>] [,size=<DiskSize>]"
56122987 15801 },
44660702
DM
15802 "nameserver" : {
15803 "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.",
15804 "format" : "address-list",
56122987 15805 "optional" : 1,
44660702 15806 "type" : "string"
56122987 15807 },
44660702
DM
15808 "net[n]" : {
15809 "description" : "Specifies network interfaces for the container.",
7aacca6f 15810 "format" : {
44660702
DM
15811 "bridge" : {
15812 "description" : "Bridge to attach the network device to.",
f004f5b9 15813 "format_description" : "bridge",
7aacca6f 15814 "optional" : 1,
44660702
DM
15815 "pattern" : "[-_.\\w\\d]+",
15816 "type" : "string"
7aacca6f 15817 },
44660702
DM
15818 "firewall" : {
15819 "description" : "Controls whether this interface's firewall rules should be used.",
7aacca6f 15820 "optional" : 1,
44660702 15821 "type" : "boolean"
7aacca6f 15822 },
44660702
DM
15823 "gw" : {
15824 "description" : "Default gateway for IPv4 traffic.",
15825 "format" : "ipv4",
15826 "format_description" : "GatewayIPv4",
7aacca6f 15827 "optional" : 1,
44660702 15828 "type" : "string"
7aacca6f 15829 },
44660702
DM
15830 "gw6" : {
15831 "description" : "Default gateway for IPv6 traffic.",
15832 "format" : "ipv6",
15833 "format_description" : "GatewayIPv6",
15834 "optional" : 1,
15835 "type" : "string"
7aacca6f 15836 },
44660702 15837 "hwaddr" : {
f004f5b9
DM
15838 "description" : "The interface MAC address. This is dynamically allocated by default, but you can set that statically if needed, for example to always have the same link-local IPv6 address. (lxc.network.hwaddr)",
15839 "format_description" : "XX:XX:XX:XX:XX:XX",
44660702
DM
15840 "optional" : 1,
15841 "pattern" : "(?^i:(?:[a-f0-9]{2}:){5}[a-f0-9]{2})",
7aacca6f
DM
15842 "type" : "string"
15843 },
44660702
DM
15844 "ip" : {
15845 "description" : "IPv4 address in CIDR format.",
15846 "format" : "pve-ipv4-config",
15847 "format_description" : "IPv4Format/CIDR",
7aacca6f 15848 "optional" : 1,
44660702 15849 "type" : "string"
7aacca6f 15850 },
44660702
DM
15851 "ip6" : {
15852 "description" : "IPv6 address in CIDR format.",
15853 "format" : "pve-ipv6-config",
15854 "format_description" : "IPv6Format/CIDR",
15855 "optional" : 1,
15856 "type" : "string"
15857 },
15858 "mtu" : {
15859 "description" : "Maximum transfer unit of the interface. (lxc.network.mtu)",
44660702
DM
15860 "minimum" : 64,
15861 "optional" : 1,
15862 "type" : "integer"
15863 },
15864 "name" : {
15865 "description" : "Name of the network device as seen from inside the container. (lxc.network.name)",
f004f5b9 15866 "format_description" : "string",
44660702
DM
15867 "pattern" : "[-_.\\w\\d]+",
15868 "type" : "string"
15869 },
15870 "rate" : {
15871 "description" : "Apply rate limiting to the interface",
15872 "format_description" : "mbps",
15873 "optional" : 1,
15874 "type" : "number"
15875 },
15876 "tag" : {
15877 "description" : "VLAN tag for this interface.",
4bd7df8b
DM
15878 "maximum" : 4094,
15879 "minimum" : 1,
44660702
DM
15880 "optional" : 1,
15881 "type" : "integer"
15882 },
15883 "trunks" : {
15884 "description" : "VLAN ids to pass through the interface",
15885 "format_description" : "vlanid[;vlanid...]",
15886 "optional" : 1,
15887 "pattern" : "(?^:\\d+(?:;\\d+)*)",
15888 "type" : "string"
15889 },
15890 "type" : {
15891 "description" : "Network interface type.",
15892 "enum" : [
15893 "veth"
15894 ],
15895 "optional" : 1,
15896 "type" : "string"
7aacca6f
DM
15897 }
15898 },
56122987 15899 "optional" : 1,
4bd7df8b
DM
15900 "type" : "string",
15901 "typetext" : "name=<string> [,bridge=<bridge>] [,firewall=<1|0>] [,gw=<GatewayIPv4>] [,gw6=<GatewayIPv6>] [,hwaddr=<XX:XX:XX:XX:XX:XX>] [,ip=<IPv4Format/CIDR>] [,ip6=<IPv6Format/CIDR>] [,mtu=<integer>] [,rate=<mbps>] [,tag=<integer>] [,trunks=<vlanid[;vlanid...]>] [,type=<veth>]"
56122987 15902 },
44660702
DM
15903 "node" : {
15904 "description" : "The cluster node name.",
15905 "format" : "pve-node",
15906 "type" : "string"
56122987 15907 },
44660702
DM
15908 "onboot" : {
15909 "default" : 0,
15910 "description" : "Specifies whether a VM will be started during system bootup.",
56122987 15911 "optional" : 1,
44660702
DM
15912 "type" : "boolean"
15913 },
15914 "ostemplate" : {
15915 "description" : "The OS template or backup file.",
15916 "maxLength" : 255,
15917 "type" : "string"
56122987
DM
15918 },
15919 "ostype" : {
7aacca6f 15920 "description" : "OS type. This is used to setup configuration inside the container, and corresponds to lxc setup scripts in /usr/share/lxc/config/<ostype>.common.conf. Value 'unmanaged' can be used to skip and OS specific setup.",
56122987
DM
15921 "enum" : [
15922 "debian",
15923 "ubuntu",
15924 "centos",
15925 "fedora",
15926 "opensuse",
15927 "archlinux",
15928 "alpine",
57b78691 15929 "gentoo",
56122987 15930 "unmanaged"
44660702 15931 ],
56122987 15932 "optional" : 1,
7aacca6f 15933 "type" : "string"
56122987 15934 },
44660702
DM
15935 "password" : {
15936 "description" : "Sets root password inside container.",
15937 "minLength" : 5,
7aacca6f
DM
15938 "optional" : 1,
15939 "type" : "string"
15940 },
44660702
DM
15941 "pool" : {
15942 "description" : "Add the VM to the specified pool.",
15943 "format" : "pve-poolid",
7aacca6f 15944 "optional" : 1,
44660702 15945 "type" : "string"
7aacca6f 15946 },
44660702
DM
15947 "protection" : {
15948 "default" : 0,
15949 "description" : "Sets the protection flag of the container. This will prevent the CT or CT's disk remove/update operation.",
7aacca6f 15950 "optional" : 1,
44660702 15951 "type" : "boolean"
7aacca6f 15952 },
44660702
DM
15953 "restore" : {
15954 "description" : "Mark this as restore task.",
15955 "optional" : 1,
15956 "type" : "boolean"
7aacca6f 15957 },
44660702
DM
15958 "rootfs" : {
15959 "description" : "Use volume as container root.",
56122987 15960 "format" : {
44660702
DM
15961 "acl" : {
15962 "description" : "Explicitly enable or disable ACL support.",
56122987 15963 "optional" : 1,
44660702 15964 "type" : "boolean"
56122987 15965 },
44660702
DM
15966 "quota" : {
15967 "description" : "Enable user quotas inside the container (not supported with zfs subvolumes)",
7aacca6f 15968 "optional" : 1,
44660702 15969 "type" : "boolean"
7aacca6f 15970 },
44660702 15971 "ro" : {
4bd7df8b 15972 "description" : "Read-only mountpoint",
7aacca6f 15973 "optional" : 1,
44660702 15974 "type" : "boolean"
7aacca6f 15975 },
44660702
DM
15976 "size" : {
15977 "description" : "Volume size (read only value).",
15978 "format" : "disk-size",
15979 "format_description" : "DiskSize",
7aacca6f
DM
15980 "optional" : 1,
15981 "type" : "string"
15982 },
44660702
DM
15983 "volume" : {
15984 "default_key" : 1,
15985 "description" : "Volume, device or directory to mount into the container.",
15986 "format" : "pve-lxc-mp-string",
15987 "format_description" : "volume",
15988 "type" : "string"
56122987 15989 }
7aacca6f 15990 },
7aacca6f 15991 "optional" : 1,
4bd7df8b
DM
15992 "type" : "string",
15993 "typetext" : "[volume=]<volume> [,acl=<1|0>] [,quota=<1|0>] [,ro=<1|0>] [,size=<DiskSize>]"
44660702
DM
15994 },
15995 "searchdomain" : {
15996 "description" : "Sets DNS search domains for a container. Create will automatically use the setting from the host if you neither set searchdomain nor nameserver.",
15997 "format" : "dns-name-list",
15998 "optional" : 1,
15999 "type" : "string"
16000 },
16001 "ssh-public-keys" : {
16002 "description" : "Setup public SSH keys (one key per line, OpenSSH format).",
16003 "optional" : 1,
16004 "type" : "string"
16005 },
16006 "startup" : {
16007 "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.",
16008 "format" : "pve-startup-order",
16009 "optional" : 1,
7aacca6f 16010 "type" : "string",
44660702 16011 "typetext" : "[[order=]\\d+] [,up=\\d+] [,down=\\d+] "
7aacca6f 16012 },
44660702
DM
16013 "storage" : {
16014 "default" : "local",
16015 "description" : "Default Storage.",
16016 "format" : "pve-storage-id",
16017 "optional" : 1,
7aacca6f 16018 "type" : "string"
7aacca6f 16019 },
44660702
DM
16020 "swap" : {
16021 "default" : 512,
16022 "description" : "Amount of SWAP for the VM in MB.",
16023 "minimum" : 0,
16024 "optional" : 1,
4bd7df8b 16025 "type" : "integer",
2c0dde61 16026 "typetext" : "integer (0 - N)"
44660702
DM
16027 },
16028 "template" : {
16029 "default" : 0,
16030 "description" : "Enable/disable Template.",
16031 "optional" : 1,
16032 "type" : "boolean"
7aacca6f 16033 },
44660702
DM
16034 "tty" : {
16035 "default" : 2,
16036 "description" : "Specify the number of tty available to the container",
16037 "maximum" : 6,
16038 "minimum" : 0,
16039 "optional" : 1,
4bd7df8b 16040 "type" : "integer",
2c0dde61 16041 "typetext" : "integer (0 - 6)"
7aacca6f 16042 },
44660702
DM
16043 "unprivileged" : {
16044 "default" : 0,
16045 "description" : "Makes the container run as unprivileged user. (Should not be modified manually.)",
16046 "optional" : 1,
16047 "type" : "boolean"
16048 },
16049 "unused[n]" : {
c2993fe5 16050 "description" : "Reference to unused volumes. This is used internally, and should not be modified manually.",
44660702
DM
16051 "format" : "pve-volume-id",
16052 "optional" : 1,
16053 "type" : "string"
16054 },
16055 "vmid" : {
16056 "description" : "The (unique) ID of the VM.",
16057 "format" : "pve-vmid",
16058 "minimum" : 1,
4bd7df8b 16059 "type" : "integer",
2c0dde61 16060 "typetext" : "integer (1 - N)"
44660702 16061 }
7aacca6f
DM
16062 }
16063 },
44660702
DM
16064 "permissions" : {
16065 "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.",
16066 "user" : "all"
16067 },
16068 "protected" : 1,
16069 "proxyto" : "node",
16070 "returns" : {
16071 "type" : "string"
16072 }
16073 }
16074 },
16075 "leaf" : 0,
16076 "path" : "/nodes/{node}/lxc",
16077 "text" : "lxc"
16078 },
16079 {
16080 "children" : [
16081 {
56122987
DM
16082 "children" : [
16083 {
7aacca6f
DM
16084 "children" : [
16085 {
7aacca6f
DM
16086 "info" : {
16087 "POST" : {
44660702
DM
16088 "description" : "ceph osd in",
16089 "method" : "POST",
16090 "name" : "in",
16091 "parameters" : {
16092 "additionalProperties" : 0,
16093 "properties" : {
16094 "node" : {
16095 "description" : "The cluster node name.",
16096 "format" : "pve-node",
16097 "type" : "string"
16098 },
16099 "osdid" : {
16100 "description" : "OSD ID",
16101 "type" : "integer"
16102 }
16103 }
16104 },
56122987
DM
16105 "permissions" : {
16106 "check" : [
16107 "perm",
16108 "/",
16109 [
16110 "Sys.Modify"
16111 ]
16112 ]
7aacca6f 16113 },
44660702 16114 "protected" : 1,
7aacca6f
DM
16115 "proxyto" : "node",
16116 "returns" : {
16117 "type" : "null"
44660702 16118 }
56122987
DM
16119 }
16120 },
44660702 16121 "leaf" : 1,
7aacca6f 16122 "path" : "/nodes/{node}/ceph/osd/{osdid}/in",
44660702 16123 "text" : "in"
56122987
DM
16124 },
16125 {
56122987
DM
16126 "info" : {
16127 "POST" : {
44660702
DM
16128 "description" : "ceph osd out",
16129 "method" : "POST",
16130 "name" : "out",
16131 "parameters" : {
16132 "additionalProperties" : 0,
16133 "properties" : {
16134 "node" : {
16135 "description" : "The cluster node name.",
16136 "format" : "pve-node",
16137 "type" : "string"
16138 },
16139 "osdid" : {
16140 "description" : "OSD ID",
16141 "type" : "integer"
16142 }
16143 }
16144 },
56122987
DM
16145 "permissions" : {
16146 "check" : [
16147 "perm",
16148 "/",
16149 [
16150 "Sys.Modify"
16151 ]
16152 ]
16153 },
44660702 16154 "protected" : 1,
56122987 16155 "proxyto" : "node",
7aacca6f
DM
16156 "returns" : {
16157 "type" : "null"
44660702
DM
16158 }
16159 }
16160 },
16161 "leaf" : 1,
16162 "path" : "/nodes/{node}/ceph/osd/{osdid}/out",
16163 "text" : "out"
16164 }
16165 ],
16166 "info" : {
16167 "DELETE" : {
16168 "description" : "Destroy OSD",
16169 "method" : "DELETE",
16170 "name" : "destroyosd",
16171 "parameters" : {
16172 "additionalProperties" : 0,
16173 "properties" : {
16174 "cleanup" : {
16175 "default" : 0,
16176 "description" : "If set, we remove partition table entries.",
16177 "optional" : 1,
16178 "type" : "boolean"
7aacca6f 16179 },
44660702
DM
16180 "node" : {
16181 "description" : "The cluster node name.",
16182 "format" : "pve-node",
16183 "type" : "string"
56122987 16184 },
44660702
DM
16185 "osdid" : {
16186 "description" : "OSD ID",
16187 "type" : "integer"
16188 }
56122987
DM
16189 }
16190 },
44660702
DM
16191 "protected" : 1,
16192 "proxyto" : "node",
16193 "returns" : {
16194 "type" : "string"
16195 }
16196 }
16197 },
16198 "leaf" : 0,
16199 "path" : "/nodes/{node}/ceph/osd/{osdid}",
16200 "text" : "{osdid}"
16201 }
16202 ],
16203 "info" : {
16204 "GET" : {
16205 "description" : "Get Ceph osd list/tree.",
16206 "method" : "GET",
16207 "name" : "index",
16208 "parameters" : {
16209 "additionalProperties" : 0,
16210 "properties" : {
16211 "node" : {
16212 "description" : "The cluster node name.",
16213 "format" : "pve-node",
16214 "type" : "string"
16215 }
16216 }
16217 },
16218 "permissions" : {
16219 "check" : [
16220 "perm",
16221 "/",
16222 [
16223 "Sys.Audit",
16224 "Datastore.Audit"
16225 ],
16226 "any",
16227 1
16228 ]
16229 },
16230 "protected" : 1,
16231 "proxyto" : "node",
16232 "returns" : {
16233 "type" : "object"
16234 }
16235 },
16236 "POST" : {
16237 "description" : "Create OSD",
16238 "method" : "POST",
16239 "name" : "createosd",
16240 "parameters" : {
16241 "additionalProperties" : 0,
16242 "properties" : {
16243 "dev" : {
16244 "description" : "Block device name.",
16245 "type" : "string"
16246 },
16247 "fstype" : {
16248 "default" : "xfs",
16249 "description" : "File system type.",
16250 "enum" : [
16251 "xfs",
16252 "ext4",
16253 "btrfs"
16254 ],
16255 "optional" : 1,
16256 "type" : "string"
16257 },
16258 "journal_dev" : {
16259 "description" : "Block device name for journal.",
16260 "optional" : 1,
16261 "type" : "string"
16262 },
16263 "node" : {
16264 "description" : "The cluster node name.",
16265 "format" : "pve-node",
16266 "type" : "string"
16267 }
56122987 16268 }
44660702
DM
16269 },
16270 "protected" : 1,
16271 "proxyto" : "node",
16272 "returns" : {
16273 "type" : "string"
16274 }
56122987 16275 }
44660702 16276 },
7aacca6f 16277 "leaf" : 0,
44660702
DM
16278 "path" : "/nodes/{node}/ceph/osd",
16279 "text" : "osd"
7aacca6f
DM
16280 },
16281 {
56122987
DM
16282 "info" : {
16283 "GET" : {
7aacca6f 16284 "description" : "List local disks.",
44660702
DM
16285 "method" : "GET",
16286 "name" : "disks",
16287 "parameters" : {
16288 "additionalProperties" : 0,
16289 "properties" : {
16290 "node" : {
16291 "description" : "The cluster node name.",
16292 "format" : "pve-node",
16293 "type" : "string"
16294 },
16295 "type" : {
16296 "description" : "Only list specific types of disks.",
16297 "enum" : [
16298 "unused",
16299 "journal_disks"
16300 ],
16301 "optional" : 1,
16302 "type" : "string"
16303 }
16304 }
16305 },
56122987
DM
16306 "permissions" : {
16307 "check" : [
16308 "perm",
16309 "/",
16310 [
16311 "Sys.Audit",
16312 "Datastore.Audit"
16313 ],
16314 "any",
16315 1
16316 ]
7aacca6f 16317 },
44660702
DM
16318 "protected" : 1,
16319 "proxyto" : "node",
56122987 16320 "returns" : {
7aacca6f
DM
16321 "items" : {
16322 "properties" : {
44660702
DM
16323 "dev" : {
16324 "type" : "string"
16325 },
16326 "gpt" : {
16327 "type" : "boolean"
16328 },
16329 "model" : {
16330 "optional" : 1,
16331 "type" : "string"
7aacca6f
DM
16332 },
16333 "osdid" : {
16334 "type" : "integer"
16335 },
16336 "serial" : {
7aacca6f
DM
16337 "optional" : 1,
16338 "type" : "string"
16339 },
16340 "size" : {
16341 "type" : "integer"
16342 },
44660702
DM
16343 "used" : {
16344 "optional" : 1,
7aacca6f
DM
16345 "type" : "string"
16346 },
44660702
DM
16347 "vendor" : {
16348 "optional" : 1,
16349 "type" : "string"
7aacca6f
DM
16350 }
16351 },
16352 "type" : "object"
44660702
DM
16353 },
16354 "type" : "array"
16355 }
56122987 16356 }
44660702
DM
16357 },
16358 "leaf" : 1,
16359 "path" : "/nodes/{node}/ceph/disks",
16360 "text" : "disks"
56122987
DM
16361 },
16362 {
56122987
DM
16363 "info" : {
16364 "GET" : {
7aacca6f 16365 "description" : "Get Ceph configuration.",
44660702
DM
16366 "method" : "GET",
16367 "name" : "config",
56122987 16368 "parameters" : {
7aacca6f 16369 "additionalProperties" : 0,
56122987 16370 "properties" : {
56122987 16371 "node" : {
7aacca6f 16372 "description" : "The cluster node name.",
44660702 16373 "format" : "pve-node",
56122987
DM
16374 "type" : "string"
16375 }
7aacca6f 16376 }
56122987 16377 },
56122987
DM
16378 "permissions" : {
16379 "check" : [
16380 "perm",
16381 "/",
16382 [
16383 "Sys.Audit",
16384 "Datastore.Audit"
16385 ],
16386 "any",
16387 1
16388 ]
44660702
DM
16389 },
16390 "returns" : {
16391 "type" : "string"
7aacca6f
DM
16392 }
16393 }
44660702
DM
16394 },
16395 "leaf" : 1,
16396 "path" : "/nodes/{node}/ceph/config",
16397 "text" : "config"
7aacca6f
DM
16398 },
16399 {
7aacca6f
DM
16400 "children" : [
16401 {
7aacca6f
DM
16402 "info" : {
16403 "DELETE" : {
7aacca6f 16404 "description" : "Destroy Ceph monitor.",
44660702
DM
16405 "method" : "DELETE",
16406 "name" : "destroymon",
16407 "parameters" : {
16408 "additionalProperties" : 0,
16409 "properties" : {
16410 "monid" : {
16411 "description" : "Monitor ID",
16412 "type" : "integer"
16413 },
16414 "node" : {
16415 "description" : "The cluster node name.",
16416 "format" : "pve-node",
16417 "type" : "string"
16418 }
16419 }
16420 },
7aacca6f
DM
16421 "permissions" : {
16422 "check" : [
16423 "perm",
16424 "/",
16425 [
16426 "Sys.Modify"
16427 ]
16428 ]
16429 },
44660702
DM
16430 "protected" : 1,
16431 "proxyto" : "node",
7aacca6f
DM
16432 "returns" : {
16433 "type" : "string"
44660702 16434 }
7aacca6f 16435 }
44660702
DM
16436 },
16437 "leaf" : 1,
16438 "path" : "/nodes/{node}/ceph/mon/{monid}",
16439 "text" : "{monid}"
7aacca6f
DM
16440 }
16441 ],
16442 "info" : {
16443 "GET" : {
44660702 16444 "description" : "Get Ceph monitor list.",
7aacca6f 16445 "method" : "GET",
44660702 16446 "name" : "listmon",
7aacca6f
DM
16447 "parameters" : {
16448 "additionalProperties" : 0,
16449 "properties" : {
16450 "node" : {
7aacca6f 16451 "description" : "The cluster node name.",
44660702
DM
16452 "format" : "pve-node",
16453 "type" : "string"
7aacca6f
DM
16454 }
16455 }
16456 },
44660702
DM
16457 "permissions" : {
16458 "check" : [
16459 "perm",
16460 "/",
16461 [
16462 "Sys.Audit",
16463 "Datastore.Audit"
16464 ],
16465 "any",
16466 1
16467 ]
16468 },
7aacca6f 16469 "protected" : 1,
44660702 16470 "proxyto" : "node",
7aacca6f
DM
16471 "returns" : {
16472 "items" : {
16473 "properties" : {
44660702 16474 "addr" : {
7aacca6f 16475 "type" : "string"
56122987 16476 },
44660702 16477 "name" : {
56122987
DM
16478 "type" : "string"
16479 }
7aacca6f
DM
16480 },
16481 "type" : "object"
56122987 16482 },
7aacca6f
DM
16483 "links" : [
16484 {
16485 "href" : "{name}",
16486 "rel" : "child"
16487 }
16488 ],
56122987 16489 "type" : "array"
44660702 16490 }
7aacca6f
DM
16491 },
16492 "POST" : {
44660702
DM
16493 "description" : "Create Ceph Monitor",
16494 "method" : "POST",
16495 "name" : "createmon",
16496 "parameters" : {
16497 "additionalProperties" : 0,
16498 "properties" : {
16499 "node" : {
16500 "description" : "The cluster node name.",
16501 "format" : "pve-node",
16502 "type" : "string"
16503 }
16504 }
16505 },
7aacca6f
DM
16506 "permissions" : {
16507 "check" : [
16508 "perm",
16509 "/",
16510 [
16511 "Sys.Modify"
16512 ]
16513 ]
16514 },
44660702 16515 "protected" : 1,
7aacca6f 16516 "proxyto" : "node",
56122987
DM
16517 "returns" : {
16518 "type" : "string"
44660702 16519 }
56122987 16520 }
44660702
DM
16521 },
16522 "leaf" : 0,
16523 "path" : "/nodes/{node}/ceph/mon",
16524 "text" : "mon"
56122987
DM
16525 },
16526 {
16527 "info" : {
16528 "POST" : {
44660702
DM
16529 "description" : "Create initial ceph default configuration and setup symlinks.",
16530 "method" : "POST",
16531 "name" : "init",
16532 "parameters" : {
16533 "additionalProperties" : 0,
16534 "properties" : {
16535 "network" : {
16536 "description" : "Use specific network for all ceph related traffic",
16537 "format" : "CIDR",
16538 "maxLength" : 128,
16539 "optional" : 1,
16540 "type" : "string"
16541 },
16542 "node" : {
16543 "description" : "The cluster node name.",
16544 "format" : "pve-node",
16545 "type" : "string"
16546 },
16547 "pg_bits" : {
16548 "default" : 6,
16549 "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.",
16550 "maximum" : 14,
16551 "minimum" : 6,
16552 "optional" : 1,
4bd7df8b 16553 "type" : "integer",
2c0dde61 16554 "typetext" : "integer (6 - 14)"
44660702
DM
16555 },
16556 "size" : {
16557 "default" : 2,
16558 "description" : "Number of replicas per object",
16559 "maximum" : 3,
16560 "minimum" : 1,
16561 "optional" : 1,
4bd7df8b 16562 "type" : "integer",
2c0dde61 16563 "typetext" : "integer (1 - 3)"
44660702
DM
16564 }
16565 }
7aacca6f 16566 },
56122987
DM
16567 "permissions" : {
16568 "check" : [
16569 "perm",
16570 "/",
16571 [
16572 "Sys.Modify"
16573 ]
16574 ]
16575 },
7aacca6f 16576 "protected" : 1,
44660702
DM
16577 "proxyto" : "node",
16578 "returns" : {
16579 "type" : "null"
7aacca6f
DM
16580 }
16581 }
16582 },
7aacca6f 16583 "leaf" : 1,
44660702
DM
16584 "path" : "/nodes/{node}/ceph/init",
16585 "text" : "init"
7aacca6f
DM
16586 },
16587 {
7aacca6f
DM
16588 "info" : {
16589 "POST" : {
44660702 16590 "description" : "Stop ceph services.",
7aacca6f
DM
16591 "method" : "POST",
16592 "name" : "stop",
16593 "parameters" : {
44660702 16594 "additionalProperties" : 0,
7aacca6f
DM
16595 "properties" : {
16596 "node" : {
7aacca6f 16597 "description" : "The cluster node name.",
44660702 16598 "format" : "pve-node",
56122987 16599 "type" : "string"
7aacca6f
DM
16600 },
16601 "service" : {
7aacca6f 16602 "description" : "Ceph service name.",
44660702
DM
16603 "optional" : 1,
16604 "pattern" : "(mon|mds|osd)\\.[A-Za-z0-9]{1,32}",
16605 "type" : "string"
56122987 16606 }
44660702 16607 }
7aacca6f
DM
16608 },
16609 "permissions" : {
16610 "check" : [
16611 "perm",
16612 "/",
16613 [
16614 "Sys.Modify"
16615 ]
16616 ]
16617 },
44660702
DM
16618 "protected" : 1,
16619 "proxyto" : "node",
16620 "returns" : {
16621 "type" : "string"
16622 }
7aacca6f 16623 }
44660702
DM
16624 },
16625 "leaf" : 1,
16626 "path" : "/nodes/{node}/ceph/stop",
16627 "text" : "stop"
7aacca6f
DM
16628 },
16629 {
7aacca6f
DM
16630 "info" : {
16631 "POST" : {
7aacca6f 16632 "description" : "Start ceph services.",
44660702 16633 "method" : "POST",
7aacca6f 16634 "name" : "start",
56122987
DM
16635 "parameters" : {
16636 "additionalProperties" : 0,
16637 "properties" : {
16638 "node" : {
7aacca6f 16639 "description" : "The cluster node name.",
44660702 16640 "format" : "pve-node",
7aacca6f
DM
16641 "type" : "string"
16642 },
16643 "service" : {
16644 "description" : "Ceph service name.",
44660702 16645 "optional" : 1,
7aacca6f 16646 "pattern" : "(mon|mds|osd)\\.[A-Za-z0-9]{1,32}",
44660702 16647 "type" : "string"
7aacca6f
DM
16648 }
16649 }
16650 },
44660702
DM
16651 "permissions" : {
16652 "check" : [
16653 "perm",
16654 "/",
16655 [
16656 "Sys.Modify"
16657 ]
16658 ]
16659 },
7aacca6f 16660 "protected" : 1,
44660702
DM
16661 "proxyto" : "node",
16662 "returns" : {
16663 "type" : "string"
16664 }
7aacca6f 16665 }
44660702
DM
16666 },
16667 "leaf" : 1,
16668 "path" : "/nodes/{node}/ceph/start",
16669 "text" : "start"
7aacca6f
DM
16670 },
16671 {
7aacca6f
DM
16672 "info" : {
16673 "GET" : {
44660702
DM
16674 "description" : "Get ceph status.",
16675 "method" : "GET",
16676 "name" : "status",
7aacca6f
DM
16677 "parameters" : {
16678 "additionalProperties" : 0,
16679 "properties" : {
16680 "node" : {
7aacca6f 16681 "description" : "The cluster node name.",
44660702 16682 "format" : "pve-node",
7aacca6f 16683 "type" : "string"
56122987
DM
16684 }
16685 }
16686 },
16687 "permissions" : {
16688 "check" : [
16689 "perm",
16690 "/",
16691 [
16692 "Sys.Audit",
16693 "Datastore.Audit"
16694 ],
16695 "any",
16696 1
16697 ]
16698 },
44660702
DM
16699 "protected" : 1,
16700 "proxyto" : "node",
56122987 16701 "returns" : {
7aacca6f
DM
16702 "type" : "object"
16703 }
16704 }
16705 },
44660702 16706 "leaf" : 1,
7aacca6f 16707 "path" : "/nodes/{node}/ceph/status",
44660702 16708 "text" : "status"
7aacca6f
DM
16709 },
16710 {
44660702
DM
16711 "children" : [
16712 {
16713 "info" : {
16714 "DELETE" : {
16715 "description" : "Destroy pool",
16716 "method" : "DELETE",
16717 "name" : "destroypool",
16718 "parameters" : {
16719 "additionalProperties" : 0,
16720 "properties" : {
4bd7df8b
DM
16721 "force" : {
16722 "default" : 0,
16723 "description" : "If true, destroys pool even if in use",
16724 "optional" : 1,
16725 "type" : "boolean"
16726 },
44660702
DM
16727 "name" : {
16728 "description" : "The name of the pool. It must be unique.",
16729 "type" : "string"
16730 },
16731 "node" : {
16732 "description" : "The cluster node name.",
16733 "format" : "pve-node",
16734 "type" : "string"
16735 }
16736 }
16737 },
16738 "permissions" : {
16739 "check" : [
16740 "perm",
16741 "/",
16742 [
16743 "Sys.Modify"
16744 ]
16745 ]
16746 },
16747 "protected" : 1,
16748 "proxyto" : "node",
16749 "returns" : {
16750 "type" : "null"
16751 }
16752 }
16753 },
16754 "leaf" : 1,
16755 "path" : "/nodes/{node}/ceph/pools/{name}",
16756 "text" : "{name}"
16757 }
16758 ],
7aacca6f
DM
16759 "info" : {
16760 "GET" : {
44660702
DM
16761 "description" : "List all pools.",
16762 "method" : "GET",
16763 "name" : "lspools",
7aacca6f
DM
16764 "parameters" : {
16765 "additionalProperties" : 0,
16766 "properties" : {
16767 "node" : {
7aacca6f 16768 "description" : "The cluster node name.",
44660702
DM
16769 "format" : "pve-node",
16770 "type" : "string"
7aacca6f
DM
16771 }
16772 }
16773 },
7aacca6f
DM
16774 "permissions" : {
16775 "check" : [
16776 "perm",
16777 "/",
16778 [
16779 "Sys.Audit",
16780 "Datastore.Audit"
16781 ],
16782 "any",
16783 1
16784 ]
16785 },
44660702
DM
16786 "protected" : 1,
16787 "proxyto" : "node",
7aacca6f 16788 "returns" : {
56122987 16789 "items" : {
56122987 16790 "properties" : {
7aacca6f
DM
16791 "pool" : {
16792 "type" : "integer"
16793 },
44660702
DM
16794 "pool_name" : {
16795 "type" : "string"
16796 },
7aacca6f
DM
16797 "size" : {
16798 "type" : "integer"
56122987 16799 }
44660702
DM
16800 },
16801 "type" : "object"
7aacca6f 16802 },
44660702
DM
16803 "links" : [
16804 {
16805 "href" : "{pool_name}",
16806 "rel" : "child"
16807 }
16808 ],
7aacca6f
DM
16809 "type" : "array"
16810 }
16811 },
16812 "POST" : {
7aacca6f 16813 "description" : "Create POOL",
7aacca6f 16814 "method" : "POST",
7aacca6f
DM
16815 "name" : "createpool",
16816 "parameters" : {
16817 "additionalProperties" : 0,
16818 "properties" : {
7aacca6f 16819 "crush_ruleset" : {
7aacca6f 16820 "default" : 0,
44660702 16821 "description" : "The ruleset to use for mapping object placement in the cluster.",
7aacca6f 16822 "maximum" : 32768,
44660702 16823 "minimum" : 0,
7aacca6f 16824 "optional" : 1,
4bd7df8b 16825 "type" : "integer",
2c0dde61 16826 "typetext" : "integer (0 - 32768)"
56122987 16827 },
44660702
DM
16828 "min_size" : {
16829 "default" : 1,
16830 "description" : "Minimum number of replicas per object",
16831 "maximum" : 3,
16832 "minimum" : 1,
16833 "optional" : 1,
4bd7df8b 16834 "type" : "integer",
2c0dde61 16835 "typetext" : "integer (1 - 3)"
7aacca6f 16836 },
44660702
DM
16837 "name" : {
16838 "description" : "The name of the pool. It must be unique.",
16839 "type" : "string"
16840 },
16841 "node" : {
16842 "description" : "The cluster node name.",
16843 "format" : "pve-node",
16844 "type" : "string"
16845 },
16846 "pg_num" : {
16847 "default" : 64,
16848 "description" : "Number of placement groups.",
16849 "maximum" : 32768,
16850 "minimum" : 8,
16851 "optional" : 1,
4bd7df8b 16852 "type" : "integer",
2c0dde61 16853 "typetext" : "integer (8 - 32768)"
44660702
DM
16854 },
16855 "size" : {
16856 "default" : 2,
16857 "description" : "Number of replicas per object",
16858 "maximum" : 3,
16859 "minimum" : 1,
16860 "optional" : 1,
4bd7df8b 16861 "type" : "integer",
2c0dde61 16862 "typetext" : "integer (1 - 3)"
56122987
DM
16863 }
16864 }
44660702
DM
16865 },
16866 "permissions" : {
16867 "check" : [
16868 "perm",
16869 "/",
16870 [
16871 "Sys.Modify"
16872 ]
16873 ]
16874 },
16875 "protected" : 1,
16876 "proxyto" : "node",
16877 "returns" : {
16878 "type" : "null"
7aacca6f 16879 }
56122987 16880 }
44660702 16881 },
56122987 16882 "leaf" : 0,
44660702
DM
16883 "path" : "/nodes/{node}/ceph/pools",
16884 "text" : "pools"
56122987
DM
16885 },
16886 {
56122987 16887 "info" : {
7aacca6f 16888 "GET" : {
44660702
DM
16889 "description" : "Get OSD crush map",
16890 "method" : "GET",
16891 "name" : "crush",
16892 "parameters" : {
16893 "additionalProperties" : 0,
16894 "properties" : {
16895 "node" : {
16896 "description" : "The cluster node name.",
16897 "format" : "pve-node",
16898 "type" : "string"
16899 }
16900 }
16901 },
7aacca6f
DM
16902 "permissions" : {
16903 "check" : [
16904 "perm",
16905 "/",
16906 [
16907 "Sys.Audit",
16908 "Datastore.Audit"
16909 ],
16910 "any",
16911 1
16912 ]
16913 },
44660702 16914 "protected" : 1,
7aacca6f 16915 "proxyto" : "node",
56122987 16916 "returns" : {
7aacca6f 16917 "type" : "string"
44660702 16918 }
56122987
DM
16919 }
16920 },
44660702
DM
16921 "leaf" : 1,
16922 "path" : "/nodes/{node}/ceph/crush",
7aacca6f 16923 "text" : "crush"
56122987
DM
16924 },
16925 {
56122987 16926 "info" : {
7aacca6f 16927 "GET" : {
44660702
DM
16928 "description" : "Read ceph log",
16929 "method" : "GET",
16930 "name" : "log",
16931 "parameters" : {
16932 "additionalProperties" : 0,
16933 "properties" : {
16934 "limit" : {
16935 "minimum" : 0,
16936 "optional" : 1,
4bd7df8b 16937 "type" : "integer",
2c0dde61 16938 "typetext" : "integer (0 - N)"
7aacca6f 16939 },
44660702
DM
16940 "node" : {
16941 "description" : "The cluster node name.",
16942 "format" : "pve-node",
16943 "type" : "string"
16944 },
16945 "start" : {
16946 "minimum" : 0,
16947 "optional" : 1,
4bd7df8b 16948 "type" : "integer",
2c0dde61 16949 "typetext" : "integer (0 - N)"
44660702 16950 }
7aacca6f 16951 }
56122987 16952 },
56122987
DM
16953 "permissions" : {
16954 "check" : [
16955 "perm",
7aacca6f 16956 "/nodes/{node}",
56122987 16957 [
7aacca6f 16958 "Sys.Syslog"
56122987
DM
16959 ]
16960 ]
16961 },
7aacca6f 16962 "protected" : 1,
44660702
DM
16963 "proxyto" : "node",
16964 "returns" : {
16965 "items" : {
16966 "properties" : {
16967 "n" : {
16968 "description" : "Line number",
16969 "type" : "integer"
16970 },
16971 "t" : {
16972 "description" : "Line text",
16973 "type" : "string"
16974 }
56122987 16975 },
44660702 16976 "type" : "object"
56122987 16977 },
44660702 16978 "type" : "array"
7aacca6f 16979 }
56122987
DM
16980 }
16981 },
16982 "leaf" : 1,
44660702
DM
16983 "path" : "/nodes/{node}/ceph/log",
16984 "text" : "log"
7aacca6f
DM
16985 }
16986 ],
44660702
DM
16987 "info" : {
16988 "GET" : {
16989 "description" : "Directory index.",
16990 "method" : "GET",
16991 "name" : "index",
16992 "parameters" : {
16993 "additionalProperties" : 0,
16994 "properties" : {
16995 "node" : {
16996 "description" : "The cluster node name.",
16997 "format" : "pve-node",
16998 "type" : "string"
16999 }
17000 }
17001 },
17002 "permissions" : {
17003 "check" : [
17004 "perm",
17005 "/",
17006 [
17007 "Sys.Audit",
17008 "Datastore.Audit"
17009 ],
17010 "any",
17011 1
17012 ]
17013 },
17014 "returns" : {
17015 "items" : {
17016 "properties" : {},
17017 "type" : "object"
17018 },
17019 "links" : [
17020 {
17021 "href" : "{name}",
17022 "rel" : "child"
17023 }
17024 ],
17025 "type" : "array"
17026 }
17027 }
17028 },
7aacca6f 17029 "leaf" : 0,
44660702
DM
17030 "path" : "/nodes/{node}/ceph",
17031 "text" : "ceph"
7aacca6f
DM
17032 },
17033 {
4bd7df8b
DM
17034 "children" : [
17035 {
17036 "info" : {
17037 "GET" : {
17038 "description" : "Extract configuration from vzdump backup archive.",
17039 "method" : "GET",
17040 "name" : "extractconfig",
17041 "parameters" : {
17042 "additionalProperties" : 0,
17043 "properties" : {
17044 "node" : {
17045 "description" : "The cluster node name.",
17046 "format" : "pve-node",
17047 "type" : "string"
17048 },
17049 "volume" : {
17050 "description" : "Volume identifier",
17051 "type" : "string"
17052 }
17053 }
17054 },
17055 "permissions" : {
17056 "description" : "The user needs 'VM.Backup' permissions on the backed up guest ID, and 'Datastore.AllocateSpace' on the backup storage.",
17057 "user" : "all"
17058 },
17059 "protected" : 1,
17060 "proxyto" : "node",
17061 "returns" : {
17062 "type" : "string"
17063 }
17064 }
17065 },
17066 "leaf" : 1,
17067 "path" : "/nodes/{node}/vzdump/extractconfig",
17068 "text" : "extractconfig"
17069 }
17070 ],
7aacca6f
DM
17071 "info" : {
17072 "POST" : {
7aacca6f 17073 "description" : "Create backup.",
44660702 17074 "method" : "POST",
7aacca6f
DM
17075 "name" : "vzdump",
17076 "parameters" : {
44660702 17077 "additionalProperties" : 0,
7aacca6f 17078 "properties" : {
44660702
DM
17079 "all" : {
17080 "default" : 0,
17081 "description" : "Backup all known guest systems on this host.",
7aacca6f 17082 "optional" : 1,
44660702 17083 "type" : "boolean"
56122987 17084 },
44660702 17085 "bwlimit" : {
7aacca6f 17086 "default" : 0,
44660702
DM
17087 "description" : "Limit I/O bandwidth (KBytes per second).",
17088 "minimum" : 0,
7aacca6f 17089 "optional" : 1,
4bd7df8b 17090 "type" : "integer",
2c0dde61 17091 "typetext" : "integer (0 - N)"
56122987 17092 },
44660702
DM
17093 "compress" : {
17094 "default" : "0",
17095 "description" : "Compress dump file.",
17096 "enum" : [
17097 "0",
17098 "1",
17099 "gzip",
17100 "lzo"
17101 ],
7aacca6f 17102 "optional" : 1,
44660702 17103 "type" : "string"
56122987 17104 },
44660702
DM
17105 "dumpdir" : {
17106 "description" : "Store resulting files to specified directory.",
7aacca6f 17107 "optional" : 1,
44660702 17108 "type" : "string"
7aacca6f 17109 },
44660702
DM
17110 "exclude" : {
17111 "description" : "Exclude specified guest systems (assumes --all)",
17112 "format" : "pve-vmid-list",
7aacca6f 17113 "optional" : 1,
44660702 17114 "type" : "string"
7aacca6f 17115 },
44660702
DM
17116 "exclude-path" : {
17117 "description" : "Exclude certain files/directories (shell globs).",
17118 "format" : "string-alist",
7aacca6f 17119 "optional" : 1,
44660702 17120 "type" : "string"
7aacca6f 17121 },
44660702
DM
17122 "ionice" : {
17123 "default" : 7,
17124 "description" : "Set CFQ ionice priority.",
17125 "maximum" : 8,
17126 "minimum" : 0,
17127 "optional" : 1,
4bd7df8b 17128 "type" : "integer",
2c0dde61 17129 "typetext" : "integer (0 - 8)"
7aacca6f 17130 },
44660702
DM
17131 "lockwait" : {
17132 "default" : 180,
17133 "description" : "Maximal time to wait for the global lock (minutes).",
17134 "minimum" : 0,
7aacca6f 17135 "optional" : 1,
4bd7df8b 17136 "type" : "integer",
2c0dde61 17137 "typetext" : "integer (0 - N)"
7aacca6f
DM
17138 },
17139 "mailnotification" : {
44660702 17140 "default" : "always",
7aacca6f
DM
17141 "description" : "Specify when to send an email",
17142 "enum" : [
17143 "always",
17144 "failure"
17145 ],
7aacca6f 17146 "optional" : 1,
44660702 17147 "type" : "string"
7aacca6f
DM
17148 },
17149 "mailto" : {
7aacca6f 17150 "description" : "Comma-separated list of email addresses that should receive email notifications.",
44660702 17151 "format" : "string-list",
7aacca6f 17152 "optional" : 1,
44660702 17153 "type" : "string"
56122987 17154 },
44660702
DM
17155 "maxfiles" : {
17156 "default" : 1,
17157 "description" : "Maximal number of backup files per guest system.",
17158 "minimum" : 1,
7aacca6f 17159 "optional" : 1,
4bd7df8b 17160 "type" : "integer",
2c0dde61 17161 "typetext" : "integer (1 - N)"
56122987 17162 },
7aacca6f 17163 "mode" : {
44660702 17164 "default" : "snapshot",
7aacca6f
DM
17165 "description" : "Backup mode.",
17166 "enum" : [
17167 "snapshot",
17168 "suspend",
17169 "stop"
17170 ],
44660702
DM
17171 "optional" : 1,
17172 "type" : "string"
7aacca6f 17173 },
44660702
DM
17174 "node" : {
17175 "description" : "Only run if executed on this node.",
17176 "format" : "pve-node",
17177 "optional" : 1,
17178 "type" : "string"
17179 },
17180 "pigz" : {
17181 "default" : 0,
17182 "description" : "Use pigz instead of gzip when N>0. N=1 uses half of cores, N>1 uses N as thread count.",
17183 "optional" : 1,
17184 "type" : "integer"
17185 },
17186 "quiet" : {
17187 "default" : 0,
17188 "description" : "Be quiet.",
17189 "optional" : 1,
17190 "type" : "boolean"
17191 },
17192 "remove" : {
7aacca6f 17193 "default" : 1,
44660702 17194 "description" : "Remove old backup files if there are more than 'maxfiles' backup files.",
7aacca6f 17195 "optional" : 1,
44660702 17196 "type" : "boolean"
7aacca6f 17197 },
44660702
DM
17198 "script" : {
17199 "description" : "Use specified hook script.",
17200 "optional" : 1,
17201 "type" : "string"
17202 },
17203 "size" : {
17204 "default" : 1024,
17205 "description" : "Unused, will be removed in a future release.",
17206 "minimum" : 500,
17207 "optional" : 1,
4bd7df8b 17208 "type" : "integer",
2c0dde61 17209 "typetext" : "integer (500 - N)"
44660702
DM
17210 },
17211 "stdexcludes" : {
17212 "default" : 1,
17213 "description" : "Exclude temporary files and logs.",
17214 "optional" : 1,
17215 "type" : "boolean"
17216 },
17217 "stdout" : {
17218 "description" : "Write tar to stdout, not to a file.",
7aacca6f 17219 "optional" : 1,
44660702
DM
17220 "type" : "boolean"
17221 },
17222 "stop" : {
7aacca6f 17223 "default" : 0,
44660702
DM
17224 "description" : "Stop runnig backup jobs on this host.",
17225 "optional" : 1,
17226 "type" : "boolean"
7aacca6f 17227 },
44660702
DM
17228 "stopwait" : {
17229 "default" : 10,
17230 "description" : "Maximal time to wait until a guest system is stopped (minutes).",
7aacca6f
DM
17231 "minimum" : 0,
17232 "optional" : 1,
4bd7df8b 17233 "type" : "integer",
2c0dde61 17234 "typetext" : "integer (0 - N)"
7aacca6f 17235 },
44660702
DM
17236 "storage" : {
17237 "description" : "Store resulting file to this storage.",
17238 "format" : "pve-storage-id",
7aacca6f 17239 "optional" : 1,
44660702
DM
17240 "type" : "string"
17241 },
17242 "tmpdir" : {
17243 "description" : "Store temporary files to specified directory.",
17244 "optional" : 1,
17245 "type" : "string"
7aacca6f
DM
17246 },
17247 "vmid" : {
7aacca6f 17248 "description" : "The ID of the guest system you want to backup.",
44660702 17249 "format" : "pve-vmid-list",
7aacca6f
DM
17250 "optional" : 1,
17251 "type" : "string"
17252 }
7aacca6f
DM
17253 }
17254 },
7aacca6f 17255 "permissions" : {
44660702
DM
17256 "description" : "The user needs 'VM.Backup' permissions on any VM, and 'Datastore.AllocateSpace' on the backup storage.",
17257 "user" : "all"
7aacca6f 17258 },
44660702 17259 "protected" : 1,
7aacca6f 17260 "proxyto" : "node",
7aacca6f 17261 "returns" : {
44660702 17262 "type" : "string"
7aacca6f
DM
17263 }
17264 }
17265 },
4bd7df8b 17266 "leaf" : 0,
44660702
DM
17267 "path" : "/nodes/{node}/vzdump",
17268 "text" : "vzdump"
17269 },
17270 {
7aacca6f
DM
17271 "children" : [
17272 {
7aacca6f
DM
17273 "children" : [
17274 {
7aacca6f
DM
17275 "info" : {
17276 "GET" : {
7aacca6f
DM
17277 "description" : "Read service properties",
17278 "method" : "GET",
17279 "name" : "service_state",
17280 "parameters" : {
44660702 17281 "additionalProperties" : 0,
7aacca6f
DM
17282 "properties" : {
17283 "node" : {
7aacca6f 17284 "description" : "The cluster node name.",
44660702
DM
17285 "format" : "pve-node",
17286 "type" : "string"
7aacca6f
DM
17287 },
17288 "service" : {
44660702 17289 "description" : "Service ID",
7aacca6f
DM
17290 "enum" : [
17291 "pveproxy",
17292 "pvedaemon",
17293 "spiceproxy",
17294 "pvestatd",
17295 "pve-cluster",
17296 "corosync",
17297 "pve-firewall",
17298 "pvefw-logger",
17299 "pve-ha-crm",
17300 "pve-ha-lrm",
17301 "sshd",
17302 "syslog",
17303 "cron",
17304 "postfix",
17305 "ksmtuned",
17306 "systemd-timesyncd"
17307 ],
7aacca6f
DM
17308 "type" : "string"
17309 }
44660702 17310 }
56122987 17311 },
7aacca6f
DM
17312 "permissions" : {
17313 "check" : [
17314 "perm",
17315 "/nodes/{node}",
17316 [
44660702 17317 "Sys.Audit"
7aacca6f
DM
17318 ]
17319 ]
56122987 17320 },
44660702 17321 "protected" : 1,
7aacca6f 17322 "proxyto" : "node",
44660702
DM
17323 "returns" : {
17324 "properties" : {},
17325 "type" : "object"
17326 }
17327 }
17328 },
17329 "leaf" : 1,
17330 "path" : "/nodes/{node}/services/{service}/state",
17331 "text" : "state"
17332 },
17333 {
17334 "info" : {
17335 "POST" : {
17336 "description" : "Start service.",
7aacca6f
DM
17337 "method" : "POST",
17338 "name" : "service_start",
17339 "parameters" : {
44660702 17340 "additionalProperties" : 0,
7aacca6f 17341 "properties" : {
44660702
DM
17342 "node" : {
17343 "description" : "The cluster node name.",
17344 "format" : "pve-node",
17345 "type" : "string"
17346 },
7aacca6f 17347 "service" : {
44660702 17348 "description" : "Service ID",
7aacca6f
DM
17349 "enum" : [
17350 "pveproxy",
17351 "pvedaemon",
17352 "spiceproxy",
17353 "pvestatd",
17354 "pve-cluster",
17355 "corosync",
17356 "pve-firewall",
17357 "pvefw-logger",
17358 "pve-ha-crm",
17359 "pve-ha-lrm",
17360 "sshd",
17361 "syslog",
17362 "cron",
17363 "postfix",
17364 "ksmtuned",
17365 "systemd-timesyncd"
17366 ],
7aacca6f
DM
17367 "type" : "string"
17368 }
44660702 17369 }
56122987 17370 },
56122987
DM
17371 "permissions" : {
17372 "check" : [
17373 "perm",
17374 "/nodes/{node}",
17375 [
7aacca6f 17376 "Sys.Modify"
56122987
DM
17377 ]
17378 ]
7aacca6f 17379 },
7aacca6f 17380 "protected" : 1,
44660702
DM
17381 "proxyto" : "node",
17382 "returns" : {
17383 "type" : "string"
17384 }
17385 }
17386 },
17387 "leaf" : 1,
17388 "path" : "/nodes/{node}/services/{service}/start",
17389 "text" : "start"
17390 },
17391 {
17392 "info" : {
17393 "POST" : {
17394 "description" : "Stop service.",
17395 "method" : "POST",
7aacca6f 17396 "name" : "service_stop",
56122987 17397 "parameters" : {
7aacca6f 17398 "additionalProperties" : 0,
56122987
DM
17399 "properties" : {
17400 "node" : {
44660702 17401 "description" : "The cluster node name.",
56122987 17402 "format" : "pve-node",
44660702 17403 "type" : "string"
56122987
DM
17404 },
17405 "service" : {
44660702 17406 "description" : "Service ID",
56122987
DM
17407 "enum" : [
17408 "pveproxy",
17409 "pvedaemon",
17410 "spiceproxy",
17411 "pvestatd",
17412 "pve-cluster",
17413 "corosync",
17414 "pve-firewall",
17415 "pvefw-logger",
17416 "pve-ha-crm",
17417 "pve-ha-lrm",
17418 "sshd",
17419 "syslog",
17420 "cron",
17421 "postfix",
17422 "ksmtuned",
17423 "systemd-timesyncd"
17424 ],
56122987
DM
17425 "type" : "string"
17426 }
7aacca6f 17427 }
44660702 17428 },
56122987
DM
17429 "permissions" : {
17430 "check" : [
17431 "perm",
17432 "/nodes/{node}",
17433 [
17434 "Sys.Modify"
17435 ]
17436 ]
17437 },
44660702
DM
17438 "protected" : 1,
17439 "proxyto" : "node",
7aacca6f
DM
17440 "returns" : {
17441 "type" : "string"
44660702
DM
17442 }
17443 }
17444 },
17445 "leaf" : 1,
17446 "path" : "/nodes/{node}/services/{service}/stop",
17447 "text" : "stop"
17448 },
17449 {
17450 "info" : {
17451 "POST" : {
17452 "description" : "Restart service.",
17453 "method" : "POST",
17454 "name" : "service_restart",
56122987
DM
17455 "parameters" : {
17456 "additionalProperties" : 0,
17457 "properties" : {
7aacca6f
DM
17458 "node" : {
17459 "description" : "The cluster node name.",
44660702
DM
17460 "format" : "pve-node",
17461 "type" : "string"
7aacca6f
DM
17462 },
17463 "service" : {
44660702 17464 "description" : "Service ID",
56122987
DM
17465 "enum" : [
17466 "pveproxy",
17467 "pvedaemon",
17468 "spiceproxy",
17469 "pvestatd",
17470 "pve-cluster",
17471 "corosync",
17472 "pve-firewall",
17473 "pvefw-logger",
17474 "pve-ha-crm",
17475 "pve-ha-lrm",
17476 "sshd",
17477 "syslog",
17478 "cron",
17479 "postfix",
17480 "ksmtuned",
17481 "systemd-timesyncd"
7aacca6f 17482 ],
7aacca6f 17483 "type" : "string"
56122987
DM
17484 }
17485 }
17486 },
44660702
DM
17487 "permissions" : {
17488 "check" : [
17489 "perm",
17490 "/nodes/{node}",
17491 [
17492 "Sys.Modify"
17493 ]
17494 ]
17495 },
17496 "protected" : 1,
17497 "proxyto" : "node",
17498 "returns" : {
17499 "type" : "string"
17500 }
56122987 17501 }
44660702
DM
17502 },
17503 "leaf" : 1,
17504 "path" : "/nodes/{node}/services/{service}/restart",
17505 "text" : "restart"
56122987
DM
17506 },
17507 {
56122987
DM
17508 "info" : {
17509 "POST" : {
44660702
DM
17510 "description" : "Reload service.",
17511 "method" : "POST",
7aacca6f 17512 "name" : "service_reload",
56122987
DM
17513 "parameters" : {
17514 "additionalProperties" : 0,
17515 "properties" : {
44660702
DM
17516 "node" : {
17517 "description" : "The cluster node name.",
17518 "format" : "pve-node",
17519 "type" : "string"
17520 },
56122987 17521 "service" : {
56122987
DM
17522 "description" : "Service ID",
17523 "enum" : [
17524 "pveproxy",
17525 "pvedaemon",
17526 "spiceproxy",
17527 "pvestatd",
17528 "pve-cluster",
17529 "corosync",
17530 "pve-firewall",
17531 "pvefw-logger",
17532 "pve-ha-crm",
17533 "pve-ha-lrm",
17534 "sshd",
17535 "syslog",
17536 "cron",
17537 "postfix",
17538 "ksmtuned",
17539 "systemd-timesyncd"
44660702
DM
17540 ],
17541 "type" : "string"
56122987
DM
17542 }
17543 }
17544 },
56122987
DM
17545 "permissions" : {
17546 "check" : [
17547 "perm",
17548 "/nodes/{node}",
17549 [
17550 "Sys.Modify"
17551 ]
17552 ]
17553 },
44660702 17554 "protected" : 1,
56122987 17555 "proxyto" : "node",
7aacca6f
DM
17556 "returns" : {
17557 "type" : "string"
56122987
DM
17558 }
17559 }
44660702
DM
17560 },
17561 "leaf" : 1,
17562 "path" : "/nodes/{node}/services/{service}/reload",
17563 "text" : "reload"
17564 }
17565 ],
17566 "info" : {
17567 "GET" : {
17568 "description" : "Directory index",
17569 "method" : "GET",
17570 "name" : "srvcmdidx",
17571 "parameters" : {
17572 "additionalProperties" : 0,
17573 "properties" : {
17574 "node" : {
17575 "description" : "The cluster node name.",
17576 "format" : "pve-node",
17577 "type" : "string"
17578 },
17579 "service" : {
17580 "description" : "Service ID",
17581 "enum" : [
17582 "pveproxy",
17583 "pvedaemon",
17584 "spiceproxy",
17585 "pvestatd",
17586 "pve-cluster",
17587 "corosync",
17588 "pve-firewall",
17589 "pvefw-logger",
17590 "pve-ha-crm",
17591 "pve-ha-lrm",
17592 "sshd",
17593 "syslog",
17594 "cron",
17595 "postfix",
17596 "ksmtuned",
17597 "systemd-timesyncd"
17598 ],
17599 "type" : "string"
17600 }
17601 }
17602 },
17603 "permissions" : {
17604 "check" : [
17605 "perm",
17606 "/nodes/{node}",
17607 [
17608 "Sys.Audit"
17609 ]
17610 ]
17611 },
17612 "returns" : {
17613 "items" : {
17614 "properties" : {
17615 "subdir" : {
17616 "type" : "string"
17617 }
17618 },
17619 "type" : "object"
17620 },
17621 "links" : [
17622 {
17623 "href" : "{subdir}",
17624 "rel" : "child"
17625 }
17626 ],
17627 "type" : "array"
17628 }
17629 }
17630 },
17631 "leaf" : 0,
17632 "path" : "/nodes/{node}/services/{service}",
17633 "text" : "{service}"
17634 }
17635 ],
17636 "info" : {
17637 "GET" : {
17638 "description" : "Service list.",
17639 "method" : "GET",
17640 "name" : "index",
17641 "parameters" : {
17642 "additionalProperties" : 0,
17643 "properties" : {
17644 "node" : {
17645 "description" : "The cluster node name.",
17646 "format" : "pve-node",
17647 "type" : "string"
17648 }
17649 }
17650 },
17651 "permissions" : {
17652 "check" : [
17653 "perm",
17654 "/nodes/{node}",
17655 [
17656 "Sys.Audit"
17657 ]
17658 ]
17659 },
17660 "protected" : 1,
17661 "proxyto" : "node",
17662 "returns" : {
17663 "items" : {
17664 "properties" : {},
17665 "type" : "object"
17666 },
17667 "links" : [
17668 {
17669 "href" : "{service}",
17670 "rel" : "child"
56122987 17671 }
44660702
DM
17672 ],
17673 "type" : "array"
17674 }
7aacca6f 17675 }
44660702 17676 },
7aacca6f 17677 "leaf" : 0,
44660702
DM
17678 "path" : "/nodes/{node}/services",
17679 "text" : "services"
7aacca6f
DM
17680 },
17681 {
7aacca6f
DM
17682 "info" : {
17683 "GET" : {
44660702
DM
17684 "description" : "Read subscription info.",
17685 "method" : "GET",
17686 "name" : "get",
7aacca6f 17687 "parameters" : {
44660702 17688 "additionalProperties" : 0,
7aacca6f
DM
17689 "properties" : {
17690 "node" : {
17691 "description" : "The cluster node name.",
44660702
DM
17692 "format" : "pve-node",
17693 "type" : "string"
7aacca6f 17694 }
44660702
DM
17695 }
17696 },
17697 "permissions" : {
17698 "user" : "all"
7aacca6f 17699 },
7aacca6f
DM
17700 "proxyto" : "node",
17701 "returns" : {
17702 "type" : "object"
44660702 17703 }
7aacca6f 17704 },
44660702
DM
17705 "POST" : {
17706 "description" : "Update subscription info.",
17707 "method" : "POST",
17708 "name" : "update",
7aacca6f
DM
17709 "parameters" : {
17710 "additionalProperties" : 0,
17711 "properties" : {
44660702
DM
17712 "force" : {
17713 "default" : 0,
17714 "description" : "Always connect to server, even if we have up to date info inside local cache.",
17715 "optional" : 1,
17716 "type" : "boolean"
17717 },
7aacca6f 17718 "node" : {
7aacca6f 17719 "description" : "The cluster node name.",
44660702 17720 "format" : "pve-node",
7aacca6f
DM
17721 "type" : "string"
17722 }
17723 }
17724 },
7aacca6f 17725 "protected" : 1,
7aacca6f 17726 "proxyto" : "node",
44660702
DM
17727 "returns" : {
17728 "type" : "null"
17729 }
17730 },
17731 "PUT" : {
17732 "description" : "Set subscription key.",
17733 "method" : "PUT",
17734 "name" : "set",
7aacca6f
DM
17735 "parameters" : {
17736 "additionalProperties" : 0,
17737 "properties" : {
44660702
DM
17738 "key" : {
17739 "description" : "Proxmox VE subscription key",
17740 "type" : "string"
7aacca6f
DM
17741 },
17742 "node" : {
7aacca6f 17743 "description" : "The cluster node name.",
44660702
DM
17744 "format" : "pve-node",
17745 "type" : "string"
7aacca6f
DM
17746 }
17747 }
17748 },
44660702
DM
17749 "protected" : 1,
17750 "proxyto" : "node",
7aacca6f
DM
17751 "returns" : {
17752 "type" : "null"
44660702 17753 }
7aacca6f
DM
17754 }
17755 },
44660702 17756 "leaf" : 1,
7aacca6f 17757 "path" : "/nodes/{node}/subscription",
44660702 17758 "text" : "subscription"
7aacca6f
DM
17759 },
17760 {
7aacca6f
DM
17761 "children" : [
17762 {
56122987 17763 "info" : {
7aacca6f 17764 "DELETE" : {
44660702
DM
17765 "description" : "Delete network device configuration",
17766 "method" : "DELETE",
17767 "name" : "delete_network",
17768 "parameters" : {
17769 "additionalProperties" : 0,
17770 "properties" : {
17771 "iface" : {
17772 "description" : "Network interface name.",
17773 "format" : "pve-iface",
17774 "maxLength" : 20,
17775 "minLength" : 2,
17776 "type" : "string"
17777 },
17778 "node" : {
17779 "description" : "The cluster node name.",
17780 "format" : "pve-node",
17781 "type" : "string"
17782 }
17783 }
7aacca6f
DM
17784 },
17785 "permissions" : {
17786 "check" : [
17787 "perm",
17788 "/nodes/{node}",
17789 [
17790 "Sys.Modify"
17791 ]
17792 ]
17793 },
44660702 17794 "protected" : 1,
7aacca6f 17795 "proxyto" : "node",
44660702
DM
17796 "returns" : {
17797 "type" : "null"
17798 }
17799 },
17800 "GET" : {
17801 "description" : "Read network device configuration",
17802 "method" : "GET",
17803 "name" : "network_config",
56122987 17804 "parameters" : {
44660702 17805 "additionalProperties" : 0,
56122987 17806 "properties" : {
7aacca6f 17807 "iface" : {
7aacca6f 17808 "description" : "Network interface name.",
44660702
DM
17809 "format" : "pve-iface",
17810 "maxLength" : 20,
7aacca6f
DM
17811 "minLength" : 2,
17812 "type" : "string"
44660702
DM
17813 },
17814 "node" : {
17815 "description" : "The cluster node name.",
17816 "format" : "pve-node",
17817 "type" : "string"
56122987 17818 }
44660702 17819 }
7aacca6f
DM
17820 },
17821 "permissions" : {
17822 "check" : [
17823 "perm",
17824 "/nodes/{node}",
17825 [
44660702 17826 "Sys.Audit"
7aacca6f
DM
17827 ]
17828 ]
17829 },
17830 "proxyto" : "node",
44660702
DM
17831 "returns" : {
17832 "properties" : {
17833 "method" : {
17834 "type" : "string"
17835 },
17836 "type" : {
17837 "type" : "string"
17838 }
17839 },
17840 "type" : "object"
17841 }
17842 },
17843 "PUT" : {
7aacca6f
DM
17844 "description" : "Update network device configuration",
17845 "method" : "PUT",
17846 "name" : "update_network",
17847 "parameters" : {
17848 "additionalProperties" : 0,
17849 "properties" : {
7aacca6f 17850 "address" : {
44660702 17851 "description" : "IP address.",
7aacca6f 17852 "format" : "ipv4",
44660702 17853 "optional" : 1,
7aacca6f 17854 "requires" : "netmask",
44660702 17855 "type" : "string"
7aacca6f 17856 },
44660702
DM
17857 "address6" : {
17858 "description" : "IP address.",
17859 "format" : "ipv6",
17860 "optional" : 1,
17861 "requires" : "netmask6",
17862 "type" : "string"
7aacca6f
DM
17863 },
17864 "autostart" : {
44660702 17865 "description" : "Automatically start interface on boot.",
7aacca6f 17866 "optional" : 1,
44660702 17867 "type" : "boolean"
7aacca6f 17868 },
44660702
DM
17869 "bond_mode" : {
17870 "description" : "Bonding mode.",
7aacca6f 17871 "enum" : [
44660702
DM
17872 "balance-rr",
17873 "active-backup",
17874 "balance-xor",
17875 "broadcast",
17876 "802.3ad",
17877 "balance-tlb",
17878 "balance-alb",
17879 "balance-slb",
17880 "lacp-balance-slb",
17881 "lacp-balance-tcp"
17882 ],
7aacca6f 17883 "optional" : 1,
44660702 17884 "type" : "string"
7aacca6f 17885 },
44660702
DM
17886 "bond_xmit_hash_policy" : {
17887 "description" : "Selects the transmit hash policy to use for slave selection in balance-xor and 802.3ad modes.",
17888 "enum" : [
17889 "layer2",
17890 "layer2+3",
17891 "layer3+4"
17892 ],
7aacca6f 17893 "optional" : 1,
44660702 17894 "type" : "string"
7aacca6f 17895 },
44660702
DM
17896 "bridge_ports" : {
17897 "description" : "Specify the iterfaces you want to add to your bridge.",
17898 "format" : "pve-iface-list",
7aacca6f 17899 "optional" : 1,
44660702 17900 "type" : "string"
7aacca6f 17901 },
44660702
DM
17902 "bridge_vlan_aware" : {
17903 "description" : "Enable bridge vlan support.",
7aacca6f 17904 "optional" : 1,
44660702 17905 "type" : "boolean"
7aacca6f
DM
17906 },
17907 "comments" : {
44660702 17908 "description" : "Comments",
7aacca6f 17909 "optional" : 1,
44660702 17910 "type" : "string"
7aacca6f 17911 },
44660702
DM
17912 "comments6" : {
17913 "description" : "Comments",
7aacca6f 17914 "optional" : 1,
44660702 17915 "type" : "string"
7aacca6f 17916 },
44660702
DM
17917 "delete" : {
17918 "description" : "A list of settings you want to delete.",
17919 "format" : "pve-configid-list",
7aacca6f
DM
17920 "optional" : 1,
17921 "type" : "string"
17922 },
44660702
DM
17923 "gateway" : {
17924 "description" : "Default gateway address.",
17925 "format" : "ipv4",
7aacca6f
DM
17926 "optional" : 1,
17927 "type" : "string"
17928 },
44660702
DM
17929 "gateway6" : {
17930 "description" : "Default ipv6 gateway address.",
17931 "format" : "ipv6",
7aacca6f 17932 "optional" : 1,
44660702 17933 "type" : "string"
7aacca6f
DM
17934 },
17935 "iface" : {
44660702 17936 "description" : "Network interface name.",
7aacca6f
DM
17937 "format" : "pve-iface",
17938 "maxLength" : 20,
17939 "minLength" : 2,
7aacca6f
DM
17940 "type" : "string"
17941 },
44660702
DM
17942 "netmask" : {
17943 "description" : "Network mask.",
17944 "format" : "ipv4mask",
7aacca6f 17945 "optional" : 1,
44660702
DM
17946 "requires" : "address",
17947 "type" : "string"
7aacca6f
DM
17948 },
17949 "netmask6" : {
44660702 17950 "description" : "Network mask.",
7aacca6f 17951 "maximum" : 128,
44660702 17952 "minimum" : 0,
7aacca6f
DM
17953 "optional" : 1,
17954 "requires" : "address6",
4bd7df8b 17955 "type" : "integer",
2c0dde61 17956 "typetext" : "integer (0 - 128)"
44660702 17957 },
7aacca6f 17958 "node" : {
44660702 17959 "description" : "The cluster node name.",
7aacca6f 17960 "format" : "pve-node",
44660702 17961 "type" : "string"
7aacca6f 17962 },
44660702
DM
17963 "ovs_bonds" : {
17964 "description" : "Specify the interfaces used by the bonding device.",
17965 "format" : "pve-iface-list",
17966 "optional" : 1,
17967 "type" : "string"
17968 },
17969 "ovs_bridge" : {
17970 "description" : "The OVS bridge associated with a OVS port. This is required when you create an OVS port.",
17971 "format" : "pve-iface",
17972 "optional" : 1,
17973 "type" : "string"
17974 },
17975 "ovs_options" : {
17976 "description" : "OVS interface options.",
17977 "maxLength" : 1024,
17978 "optional" : 1,
17979 "type" : "string"
17980 },
17981 "ovs_ports" : {
17982 "description" : "Specify the iterfaces you want to add to your bridge.",
17983 "format" : "pve-iface-list",
17984 "optional" : 1,
17985 "type" : "string"
17986 },
17987 "ovs_tag" : {
17988 "description" : "Specify a VLan tag (used by OVSPort, OVSIntPort, OVSBond)",
17989 "maximum" : 4094,
17990 "minimum" : 1,
17991 "optional" : 1,
4bd7df8b 17992 "type" : "integer",
2c0dde61 17993 "typetext" : "integer (1 - 4094)"
44660702
DM
17994 },
17995 "slaves" : {
17996 "description" : "Specify the interfaces used by the bonding device.",
17997 "format" : "pve-iface-list",
17998 "optional" : 1,
17999 "type" : "string"
18000 },
18001 "type" : {
18002 "description" : "Network interface type",
18003 "enum" : [
18004 "bridge",
18005 "bond",
18006 "eth",
18007 "alias",
18008 "vlan",
18009 "OVSBridge",
18010 "OVSBond",
18011 "OVSPort",
18012 "OVSIntPort",
18013 "unknown"
18014 ],
18015 "type" : "string"
7aacca6f
DM
18016 }
18017 }
18018 },
7aacca6f
DM
18019 "permissions" : {
18020 "check" : [
18021 "perm",
18022 "/nodes/{node}",
18023 [
44660702 18024 "Sys.Modify"
7aacca6f
DM
18025 ]
18026 ]
18027 },
44660702
DM
18028 "protected" : 1,
18029 "proxyto" : "node",
7aacca6f 18030 "returns" : {
44660702
DM
18031 "type" : "null"
18032 }
7aacca6f
DM
18033 }
18034 },
7aacca6f 18035 "leaf" : 1,
44660702
DM
18036 "path" : "/nodes/{node}/network/{iface}",
18037 "text" : "{iface}"
7aacca6f
DM
18038 }
18039 ],
7aacca6f 18040 "info" : {
44660702
DM
18041 "DELETE" : {
18042 "description" : "Revert network configuration changes.",
18043 "method" : "DELETE",
18044 "name" : "revert_network_changes",
7aacca6f
DM
18045 "parameters" : {
18046 "additionalProperties" : 0,
18047 "properties" : {
7aacca6f 18048 "node" : {
7aacca6f 18049 "description" : "The cluster node name.",
44660702 18050 "format" : "pve-node",
7aacca6f
DM
18051 "type" : "string"
18052 }
18053 }
44660702 18054 },
7aacca6f
DM
18055 "permissions" : {
18056 "check" : [
18057 "perm",
18058 "/nodes/{node}",
18059 [
18060 "Sys.Modify"
18061 ]
18062 ]
18063 },
44660702
DM
18064 "protected" : 1,
18065 "proxyto" : "node",
7aacca6f
DM
18066 "returns" : {
18067 "type" : "null"
44660702 18068 }
7aacca6f 18069 },
44660702
DM
18070 "GET" : {
18071 "description" : "List available networks",
18072 "method" : "GET",
18073 "name" : "index",
7aacca6f 18074 "parameters" : {
44660702 18075 "additionalProperties" : 0,
7aacca6f 18076 "properties" : {
7aacca6f 18077 "node" : {
44660702
DM
18078 "description" : "The cluster node name.",
18079 "format" : "pve-node",
18080 "type" : "string"
7aacca6f
DM
18081 },
18082 "type" : {
44660702 18083 "description" : "Only list specific interface types.",
7aacca6f
DM
18084 "enum" : [
18085 "bridge",
18086 "bond",
18087 "eth",
18088 "alias",
18089 "vlan",
18090 "OVSBridge",
18091 "OVSBond",
18092 "OVSPort",
18093 "OVSIntPort",
44660702 18094 "any_bridge"
7aacca6f 18095 ],
7aacca6f 18096 "optional" : 1,
44660702
DM
18097 "type" : "string"
18098 }
18099 }
18100 },
18101 "permissions" : {
18102 "user" : "all"
18103 },
18104 "proxyto" : "node",
18105 "returns" : {
18106 "items" : {
18107 "properties" : {},
18108 "type" : "object"
18109 },
18110 "links" : [
18111 {
18112 "href" : "{iface}",
18113 "rel" : "child"
18114 }
18115 ],
18116 "type" : "array"
18117 }
18118 },
18119 "POST" : {
18120 "description" : "Create network device configuration",
18121 "method" : "POST",
18122 "name" : "create_network",
18123 "parameters" : {
18124 "additionalProperties" : 0,
18125 "properties" : {
7aacca6f 18126 "address" : {
44660702
DM
18127 "description" : "IP address.",
18128 "format" : "ipv4",
18129 "optional" : 1,
7aacca6f 18130 "requires" : "netmask",
44660702
DM
18131 "type" : "string"
18132 },
18133 "address6" : {
7aacca6f 18134 "description" : "IP address.",
44660702
DM
18135 "format" : "ipv6",
18136 "optional" : 1,
18137 "requires" : "netmask6",
18138 "type" : "string"
18139 },
18140 "autostart" : {
18141 "description" : "Automatically start interface on boot.",
7aacca6f 18142 "optional" : 1,
44660702 18143 "type" : "boolean"
7aacca6f
DM
18144 },
18145 "bond_mode" : {
18146 "description" : "Bonding mode.",
18147 "enum" : [
18148 "balance-rr",
18149 "active-backup",
18150 "balance-xor",
18151 "broadcast",
18152 "802.3ad",
18153 "balance-tlb",
18154 "balance-alb",
18155 "balance-slb",
18156 "lacp-balance-slb",
18157 "lacp-balance-tcp"
18158 ],
18159 "optional" : 1,
18160 "type" : "string"
18161 },
44660702
DM
18162 "bond_xmit_hash_policy" : {
18163 "description" : "Selects the transmit hash policy to use for slave selection in balance-xor and 802.3ad modes.",
18164 "enum" : [
18165 "layer2",
18166 "layer2+3",
18167 "layer3+4"
18168 ],
18169 "optional" : 1,
18170 "type" : "string"
18171 },
18172 "bridge_ports" : {
18173 "description" : "Specify the iterfaces you want to add to your bridge.",
7aacca6f 18174 "format" : "pve-iface-list",
7aacca6f 18175 "optional" : 1,
44660702 18176 "type" : "string"
7aacca6f 18177 },
44660702
DM
18178 "bridge_vlan_aware" : {
18179 "description" : "Enable bridge vlan support.",
7aacca6f 18180 "optional" : 1,
44660702 18181 "type" : "boolean"
7aacca6f 18182 },
44660702
DM
18183 "comments" : {
18184 "description" : "Comments",
7aacca6f 18185 "optional" : 1,
44660702
DM
18186 "type" : "string"
18187 },
18188 "comments6" : {
18189 "description" : "Comments",
18190 "optional" : 1,
18191 "type" : "string"
18192 },
18193 "gateway" : {
18194 "description" : "Default gateway address.",
18195 "format" : "ipv4",
18196 "optional" : 1,
18197 "type" : "string"
18198 },
18199 "gateway6" : {
18200 "description" : "Default ipv6 gateway address.",
18201 "format" : "ipv6",
18202 "optional" : 1,
18203 "type" : "string"
56122987 18204 },
7aacca6f 18205 "iface" : {
44660702 18206 "description" : "Network interface name.",
7aacca6f
DM
18207 "format" : "pve-iface",
18208 "maxLength" : 20,
44660702
DM
18209 "minLength" : 2,
18210 "type" : "string"
56122987 18211 },
44660702
DM
18212 "netmask" : {
18213 "description" : "Network mask.",
18214 "format" : "ipv4mask",
7aacca6f 18215 "optional" : 1,
44660702
DM
18216 "requires" : "address",
18217 "type" : "string"
7aacca6f 18218 },
44660702
DM
18219 "netmask6" : {
18220 "description" : "Network mask.",
18221 "maximum" : 128,
18222 "minimum" : 0,
7aacca6f 18223 "optional" : 1,
44660702 18224 "requires" : "address6",
4bd7df8b 18225 "type" : "integer",
2c0dde61 18226 "typetext" : "integer (0 - 128)"
7aacca6f 18227 },
44660702
DM
18228 "node" : {
18229 "description" : "The cluster node name.",
18230 "format" : "pve-node",
18231 "type" : "string"
18232 },
18233 "ovs_bonds" : {
18234 "description" : "Specify the interfaces used by the bonding device.",
18235 "format" : "pve-iface-list",
7aacca6f
DM
18236 "optional" : 1,
18237 "type" : "string"
18238 },
44660702
DM
18239 "ovs_bridge" : {
18240 "description" : "The OVS bridge associated with a OVS port. This is required when you create an OVS port.",
18241 "format" : "pve-iface",
18242 "optional" : 1,
18243 "type" : "string"
18244 },
18245 "ovs_options" : {
18246 "description" : "OVS interface options.",
18247 "maxLength" : 1024,
18248 "optional" : 1,
18249 "type" : "string"
18250 },
18251 "ovs_ports" : {
18252 "description" : "Specify the iterfaces you want to add to your bridge.",
18253 "format" : "pve-iface-list",
18254 "optional" : 1,
18255 "type" : "string"
18256 },
18257 "ovs_tag" : {
18258 "description" : "Specify a VLan tag (used by OVSPort, OVSIntPort, OVSBond)",
18259 "maximum" : 4094,
18260 "minimum" : 1,
18261 "optional" : 1,
4bd7df8b 18262 "type" : "integer",
2c0dde61 18263 "typetext" : "integer (1 - 4094)"
44660702
DM
18264 },
18265 "slaves" : {
18266 "description" : "Specify the interfaces used by the bonding device.",
18267 "format" : "pve-iface-list",
7aacca6f 18268 "optional" : 1,
44660702
DM
18269 "type" : "string"
18270 },
18271 "type" : {
18272 "description" : "Network interface type",
7aacca6f 18273 "enum" : [
44660702
DM
18274 "bridge",
18275 "bond",
18276 "eth",
18277 "alias",
18278 "vlan",
18279 "OVSBridge",
18280 "OVSBond",
18281 "OVSPort",
18282 "OVSIntPort",
18283 "unknown"
7aacca6f 18284 ],
44660702 18285 "type" : "string"
56122987 18286 }
44660702 18287 }
56122987 18288 },
56122987
DM
18289 "permissions" : {
18290 "check" : [
18291 "perm",
18292 "/nodes/{node}",
18293 [
7aacca6f 18294 "Sys.Modify"
44660702
DM
18295 ]
18296 ]
7aacca6f 18297 },
44660702
DM
18298 "protected" : 1,
18299 "proxyto" : "node",
18300 "returns" : {
18301 "type" : "null"
18302 }
18303 }
18304 },
18305 "leaf" : 0,
18306 "path" : "/nodes/{node}/network",
18307 "text" : "network"
18308 },
18309 {
18310 "children" : [
18311 {
7aacca6f
DM
18312 "children" : [
18313 {
18314 "info" : {
18315 "GET" : {
44660702 18316 "description" : "Read task log.",
7aacca6f
DM
18317 "method" : "GET",
18318 "name" : "read_task_log",
18319 "parameters" : {
44660702 18320 "additionalProperties" : 0,
7aacca6f 18321 "properties" : {
44660702
DM
18322 "limit" : {
18323 "minimum" : 0,
7aacca6f 18324 "optional" : 1,
4bd7df8b 18325 "type" : "integer",
2c0dde61 18326 "typetext" : "integer (0 - N)"
7aacca6f
DM
18327 },
18328 "node" : {
18329 "description" : "The cluster node name.",
44660702
DM
18330 "format" : "pve-node",
18331 "type" : "string"
7aacca6f 18332 },
44660702
DM
18333 "start" : {
18334 "minimum" : 0,
7aacca6f 18335 "optional" : 1,
4bd7df8b 18336 "type" : "integer",
2c0dde61 18337 "typetext" : "integer (0 - N)"
44660702
DM
18338 },
18339 "upid" : {
18340 "type" : "string"
7aacca6f 18341 }
44660702
DM
18342 }
18343 },
18344 "permissions" : {
18345 "description" : "The user needs 'Sys.Audit' permissions on '/nodes/<node>' if the task does not belong to him.",
18346 "user" : "all"
7aacca6f
DM
18347 },
18348 "protected" : 1,
44660702 18349 "proxyto" : "node",
7aacca6f 18350 "returns" : {
7aacca6f 18351 "items" : {
7aacca6f
DM
18352 "properties" : {
18353 "n" : {
44660702
DM
18354 "description" : "Line number",
18355 "type" : "integer"
7aacca6f
DM
18356 },
18357 "t" : {
44660702
DM
18358 "description" : "Line text",
18359 "type" : "string"
7aacca6f 18360 }
44660702
DM
18361 },
18362 "type" : "object"
18363 },
18364 "type" : "array"
18365 }
7aacca6f 18366 }
56122987 18367 },
7aacca6f 18368 "leaf" : 1,
44660702
DM
18369 "path" : "/nodes/{node}/tasks/{upid}/log",
18370 "text" : "log"
7aacca6f
DM
18371 },
18372 {
7aacca6f
DM
18373 "info" : {
18374 "GET" : {
44660702
DM
18375 "description" : "Read task status.",
18376 "method" : "GET",
7aacca6f
DM
18377 "name" : "read_task_status",
18378 "parameters" : {
18379 "additionalProperties" : 0,
18380 "properties" : {
18381 "node" : {
7aacca6f 18382 "description" : "The cluster node name.",
44660702 18383 "format" : "pve-node",
7aacca6f
DM
18384 "type" : "string"
18385 },
18386 "upid" : {
18387 "type" : "string"
18388 }
18389 }
18390 },
7aacca6f
DM
18391 "permissions" : {
18392 "description" : "The user needs 'Sys.Audit' permissions on '/nodes/<node>' if the task does not belong to him.",
18393 "user" : "all"
56122987 18394 },
44660702 18395 "protected" : 1,
7aacca6f 18396 "proxyto" : "node",
7aacca6f
DM
18397 "returns" : {
18398 "properties" : {
18399 "pid" : {
18400 "type" : "integer"
18401 },
18402 "status" : {
7aacca6f
DM
18403 "enum" : [
18404 "running",
18405 "stopped"
44660702
DM
18406 ],
18407 "type" : "string"
7aacca6f
DM
18408 }
18409 },
18410 "type" : "object"
56122987 18411 }
7aacca6f 18412 }
44660702
DM
18413 },
18414 "leaf" : 1,
18415 "path" : "/nodes/{node}/tasks/{upid}/status",
18416 "text" : "status"
56122987 18417 }
7aacca6f 18418 ],
44660702
DM
18419 "info" : {
18420 "DELETE" : {
18421 "description" : "Stop a task.",
18422 "method" : "DELETE",
18423 "name" : "stop_task",
18424 "parameters" : {
18425 "additionalProperties" : 0,
18426 "properties" : {
18427 "node" : {
18428 "description" : "The cluster node name.",
18429 "format" : "pve-node",
18430 "type" : "string"
18431 },
18432 "upid" : {
18433 "type" : "string"
18434 }
7aacca6f 18435 }
44660702
DM
18436 },
18437 "permissions" : {
18438 "description" : "The user needs 'Sys.Modify' permissions on '/nodes/<node>' if the task does not belong to him.",
18439 "user" : "all"
18440 },
18441 "protected" : 1,
18442 "proxyto" : "node",
18443 "returns" : {
18444 "type" : "null"
7aacca6f 18445 }
56122987 18446 },
44660702
DM
18447 "GET" : {
18448 "description" : "",
18449 "method" : "GET",
18450 "name" : "upid_index",
18451 "parameters" : {
18452 "additionalProperties" : 0,
18453 "properties" : {
18454 "node" : {
18455 "description" : "The cluster node name.",
18456 "format" : "pve-node",
18457 "type" : "string"
18458 },
18459 "upid" : {
18460 "type" : "string"
18461 }
18462 }
18463 },
18464 "permissions" : {
18465 "user" : "all"
18466 },
18467 "returns" : {
18468 "items" : {
18469 "properties" : {},
18470 "type" : "object"
18471 },
18472 "links" : [
18473 {
18474 "href" : "{name}",
18475 "rel" : "child"
18476 }
18477 ],
18478 "type" : "array"
56122987 18479 }
44660702 18480 }
56122987 18481 },
44660702
DM
18482 "leaf" : 0,
18483 "path" : "/nodes/{node}/tasks/{upid}",
18484 "text" : "{upid}"
18485 }
18486 ],
18487 "info" : {
18488 "GET" : {
7aacca6f 18489 "description" : "Read task list for one node (finished tasks).",
44660702
DM
18490 "method" : "GET",
18491 "name" : "node_tasks",
56122987 18492 "parameters" : {
7aacca6f 18493 "additionalProperties" : 0,
56122987 18494 "properties" : {
44660702 18495 "errors" : {
56122987 18496 "optional" : 1,
44660702 18497 "type" : "boolean"
56122987 18498 },
44660702 18499 "limit" : {
56122987 18500 "minimum" : 0,
56122987 18501 "optional" : 1,
4bd7df8b 18502 "type" : "integer",
2c0dde61 18503 "typetext" : "integer (0 - N)"
56122987 18504 },
56122987
DM
18505 "node" : {
18506 "description" : "The cluster node name.",
44660702
DM
18507 "format" : "pve-node",
18508 "type" : "string"
56122987 18509 },
44660702 18510 "start" : {
7aacca6f 18511 "minimum" : 0,
44660702 18512 "optional" : 1,
4bd7df8b 18513 "type" : "integer",
2c0dde61 18514 "typetext" : "integer (0 - N)"
56122987 18515 },
7aacca6f 18516 "userfilter" : {
44660702
DM
18517 "optional" : 1,
18518 "type" : "string"
18519 },
18520 "vmid" : {
18521 "description" : "Only list tasks for this VM.",
18522 "format" : "pve-vmid",
18523 "minimum" : 1,
18524 "optional" : 1,
4bd7df8b 18525 "type" : "integer",
2c0dde61 18526 "typetext" : "integer (1 - N)"
56122987
DM
18527 }
18528 }
18529 },
7aacca6f 18530 "permissions" : {
44660702 18531 "description" : "List task associated with the current user, or all task the user has 'Sys.Audit' permissions on /nodes/<node> (the <node> the task runs on).",
7aacca6f
DM
18532 "user" : "all"
18533 },
44660702 18534 "proxyto" : "node",
56122987
DM
18535 "returns" : {
18536 "items" : {
18537 "properties" : {
44660702 18538 "upid" : {
56122987
DM
18539 "type" : "string"
18540 }
18541 },
18542 "type" : "object"
18543 },
56122987
DM
18544 "links" : [
18545 {
44660702
DM
18546 "href" : "{upid}",
18547 "rel" : "child"
56122987 18548 }
44660702
DM
18549 ],
18550 "type" : "array"
56122987
DM
18551 }
18552 }
18553 },
44660702
DM
18554 "leaf" : 0,
18555 "path" : "/nodes/{node}/tasks",
18556 "text" : "tasks"
18557 },
18558 {
56122987
DM
18559 "children" : [
18560 {
56122987
DM
18561 "info" : {
18562 "GET" : {
7aacca6f 18563 "description" : "Scan zfs pool list on local node.",
44660702
DM
18564 "method" : "GET",
18565 "name" : "zfsscan",
56122987 18566 "parameters" : {
44660702 18567 "additionalProperties" : 0,
56122987 18568 "properties" : {
56122987
DM
18569 "node" : {
18570 "description" : "The cluster node name.",
44660702
DM
18571 "format" : "pve-node",
18572 "type" : "string"
56122987 18573 }
44660702
DM
18574 }
18575 },
7aacca6f
DM
18576 "permissions" : {
18577 "check" : [
18578 "perm",
18579 "/storage",
18580 [
18581 "Datastore.Allocate"
18582 ]
18583 ]
18584 },
44660702
DM
18585 "protected" : 1,
18586 "proxyto" : "node",
56122987 18587 "returns" : {
56122987
DM
18588 "items" : {
18589 "properties" : {
44660702 18590 "pool" : {
56122987
DM
18591 "type" : "string"
18592 }
44660702
DM
18593 },
18594 "type" : "object"
18595 },
18596 "type" : "array"
18597 }
18598 }
18599 },
18600 "leaf" : 1,
18601 "path" : "/nodes/{node}/scan/zfs",
18602 "text" : "zfs"
18603 },
18604 {
18605 "info" : {
18606 "GET" : {
18607 "description" : "Scan remote NFS server.",
18608 "method" : "GET",
7aacca6f 18609 "name" : "nfsscan",
56122987 18610 "parameters" : {
44660702 18611 "additionalProperties" : 0,
56122987
DM
18612 "properties" : {
18613 "node" : {
7aacca6f 18614 "description" : "The cluster node name.",
44660702 18615 "format" : "pve-node",
7aacca6f
DM
18616 "type" : "string"
18617 },
18618 "server" : {
18619 "format" : "pve-storage-server",
18620 "type" : "string"
56122987 18621 }
44660702 18622 }
56122987 18623 },
56122987
DM
18624 "permissions" : {
18625 "check" : [
18626 "perm",
18627 "/storage",
18628 [
18629 "Datastore.Allocate"
18630 ]
18631 ]
18632 },
44660702 18633 "protected" : 1,
56122987 18634 "proxyto" : "node",
44660702
DM
18635 "returns" : {
18636 "items" : {
18637 "properties" : {
18638 "options" : {
18639 "type" : "string"
18640 },
18641 "path" : {
18642 "type" : "string"
18643 }
18644 },
18645 "type" : "object"
18646 },
18647 "type" : "array"
18648 }
18649 }
18650 },
18651 "leaf" : 1,
18652 "path" : "/nodes/{node}/scan/nfs",
18653 "text" : "nfs"
18654 },
18655 {
18656 "info" : {
18657 "GET" : {
18658 "description" : "Scan remote GlusterFS server.",
7aacca6f
DM
18659 "method" : "GET",
18660 "name" : "glusterfsscan",
56122987 18661 "parameters" : {
44660702 18662 "additionalProperties" : 0,
56122987 18663 "properties" : {
56122987 18664 "node" : {
44660702 18665 "description" : "The cluster node name.",
56122987 18666 "format" : "pve-node",
44660702 18667 "type" : "string"
7aacca6f
DM
18668 },
18669 "server" : {
18670 "format" : "pve-storage-server",
18671 "type" : "string"
56122987 18672 }
44660702
DM
18673 }
18674 },
18675 "permissions" : {
18676 "check" : [
18677 "perm",
18678 "/storage",
18679 [
18680 "Datastore.Allocate"
18681 ]
18682 ]
7aacca6f 18683 },
44660702
DM
18684 "protected" : 1,
18685 "proxyto" : "node",
18686 "returns" : {
18687 "items" : {
18688 "properties" : {
18689 "volname" : {
18690 "type" : "string"
18691 }
18692 },
18693 "type" : "object"
18694 },
18695 "type" : "array"
18696 }
56122987
DM
18697 }
18698 },
44660702
DM
18699 "leaf" : 1,
18700 "path" : "/nodes/{node}/scan/glusterfs",
7aacca6f 18701 "text" : "glusterfs"
56122987
DM
18702 },
18703 {
56122987
DM
18704 "info" : {
18705 "GET" : {
7aacca6f 18706 "description" : "Scan remote iSCSI server.",
44660702
DM
18707 "method" : "GET",
18708 "name" : "iscsiscan",
18709 "parameters" : {
18710 "additionalProperties" : 0,
18711 "properties" : {
18712 "node" : {
18713 "description" : "The cluster node name.",
18714 "format" : "pve-node",
18715 "type" : "string"
18716 },
18717 "portal" : {
18718 "format" : "pve-storage-portal-dns",
18719 "type" : "string"
18720 }
18721 }
18722 },
56122987
DM
18723 "permissions" : {
18724 "check" : [
18725 "perm",
18726 "/storage",
18727 [
18728 "Datastore.Allocate"
18729 ]
18730 ]
18731 },
44660702
DM
18732 "protected" : 1,
18733 "proxyto" : "node",
56122987 18734 "returns" : {
56122987
DM
18735 "items" : {
18736 "properties" : {
44660702 18737 "portal" : {
56122987
DM
18738 "type" : "string"
18739 },
44660702 18740 "target" : {
56122987
DM
18741 "type" : "string"
18742 }
18743 },
18744 "type" : "object"
56122987 18745 },
44660702
DM
18746 "type" : "array"
18747 }
56122987
DM
18748 }
18749 },
44660702 18750 "leaf" : 1,
7aacca6f 18751 "path" : "/nodes/{node}/scan/iscsi",
44660702 18752 "text" : "iscsi"
56122987
DM
18753 },
18754 {
56122987
DM
18755 "info" : {
18756 "GET" : {
44660702
DM
18757 "description" : "List local LVM volume groups.",
18758 "method" : "GET",
18759 "name" : "lvmscan",
18760 "parameters" : {
18761 "additionalProperties" : 0,
18762 "properties" : {
18763 "node" : {
18764 "description" : "The cluster node name.",
18765 "format" : "pve-node",
18766 "type" : "string"
56122987 18767 }
7aacca6f 18768 }
56122987 18769 },
56122987
DM
18770 "permissions" : {
18771 "check" : [
18772 "perm",
18773 "/storage",
18774 [
18775 "Datastore.Allocate"
18776 ]
18777 ]
18778 },
7aacca6f 18779 "protected" : 1,
44660702
DM
18780 "proxyto" : "node",
18781 "returns" : {
18782 "items" : {
18783 "properties" : {
18784 "vg" : {
18785 "type" : "string"
18786 }
18787 },
18788 "type" : "object"
18789 },
18790 "type" : "array"
7aacca6f 18791 }
56122987
DM
18792 }
18793 },
18794 "leaf" : 1,
44660702
DM
18795 "path" : "/nodes/{node}/scan/lvm",
18796 "text" : "lvm"
56122987
DM
18797 },
18798 {
56122987
DM
18799 "info" : {
18800 "GET" : {
44660702
DM
18801 "description" : "List local LVM Thin Pools.",
18802 "method" : "GET",
18803 "name" : "lvmthinscan",
56122987 18804 "parameters" : {
44660702 18805 "additionalProperties" : 0,
56122987
DM
18806 "properties" : {
18807 "node" : {
44660702 18808 "description" : "The cluster node name.",
56122987 18809 "format" : "pve-node",
44660702 18810 "type" : "string"
56122987
DM
18811 },
18812 "vg" : {
44660702 18813 "maxLength" : 100,
56122987 18814 "pattern" : "[a-zA-Z0-9\\.\\+\\_][a-zA-Z0-9\\.\\+\\_\\-]+",
44660702 18815 "type" : "string"
56122987 18816 }
44660702 18817 }
56122987 18818 },
7aacca6f
DM
18819 "permissions" : {
18820 "check" : [
18821 "perm",
18822 "/storage",
18823 [
18824 "Datastore.Allocate"
18825 ]
18826 ]
18827 },
44660702 18828 "protected" : 1,
7aacca6f 18829 "proxyto" : "node",
56122987 18830 "returns" : {
56122987
DM
18831 "items" : {
18832 "properties" : {
18833 "lv" : {
18834 "type" : "string"
18835 }
18836 },
18837 "type" : "object"
44660702
DM
18838 },
18839 "type" : "array"
7aacca6f 18840 }
56122987
DM
18841 }
18842 },
7aacca6f 18843 "leaf" : 1,
44660702
DM
18844 "path" : "/nodes/{node}/scan/lvmthin",
18845 "text" : "lvmthin"
56122987
DM
18846 },
18847 {
56122987
DM
18848 "info" : {
18849 "GET" : {
44660702
DM
18850 "description" : "List local USB devices.",
18851 "method" : "GET",
18852 "name" : "usbscan",
18853 "parameters" : {
18854 "additionalProperties" : 0,
18855 "properties" : {
18856 "node" : {
18857 "description" : "The cluster node name.",
18858 "format" : "pve-node",
18859 "type" : "string"
18860 }
18861 }
18862 },
7aacca6f
DM
18863 "permissions" : {
18864 "check" : [
18865 "perm",
18866 "/",
18867 [
18868 "Sys.Modify"
18869 ]
18870 ]
18871 },
44660702 18872 "protected" : 1,
7aacca6f 18873 "proxyto" : "node",
56122987
DM
18874 "returns" : {
18875 "items" : {
18876 "properties" : {
44660702
DM
18877 "busnum" : {
18878 "type" : "integer"
56122987 18879 },
44660702
DM
18880 "class" : {
18881 "type" : "integer"
56122987 18882 },
7aacca6f 18883 "devnum" : {
56122987
DM
18884 "type" : "integer"
18885 },
44660702
DM
18886 "level" : {
18887 "type" : "integer"
18888 },
18889 "manufacturer" : {
18890 "optional" : 1,
7aacca6f
DM
18891 "type" : "string"
18892 },
44660702 18893 "port" : {
56122987
DM
18894 "type" : "integer"
18895 },
44660702
DM
18896 "prodid" : {
18897 "type" : "string"
56122987 18898 },
44660702
DM
18899 "product" : {
18900 "optional" : 1,
18901 "type" : "string"
18902 },
18903 "serial" : {
7aacca6f 18904 "optional" : 1,
56122987
DM
18905 "type" : "string"
18906 },
44660702 18907 "speed" : {
7aacca6f 18908 "type" : "string"
56122987 18909 },
44660702 18910 "usbpath" : {
56122987
DM
18911 "optional" : 1,
18912 "type" : "string"
18913 },
44660702
DM
18914 "vendid" : {
18915 "type" : "string"
56122987
DM
18916 }
18917 },
18918 "type" : "object"
7aacca6f
DM
18919 },
18920 "type" : "array"
44660702
DM
18921 }
18922 }
18923 },
18924 "leaf" : 1,
18925 "path" : "/nodes/{node}/scan/usb",
18926 "text" : "usb"
18927 }
18928 ],
18929 "info" : {
18930 "GET" : {
18931 "description" : "Index of available scan methods",
18932 "method" : "GET",
18933 "name" : "index",
18934 "parameters" : {
18935 "additionalProperties" : 0,
18936 "properties" : {
18937 "node" : {
18938 "description" : "The cluster node name.",
18939 "format" : "pve-node",
18940 "type" : "string"
18941 }
18942 }
18943 },
18944 "permissions" : {
18945 "user" : "all"
18946 },
18947 "returns" : {
18948 "items" : {
18949 "properties" : {
18950 "method" : {
18951 "type" : "string"
56122987
DM
18952 }
18953 },
44660702
DM
18954 "type" : "object"
18955 },
18956 "links" : [
18957 {
18958 "href" : "{method}",
18959 "rel" : "child"
18960 }
18961 ],
18962 "type" : "array"
56122987
DM
18963 }
18964 }
44660702
DM
18965 },
18966 "leaf" : 0,
18967 "path" : "/nodes/{node}/scan",
7aacca6f 18968 "text" : "scan"
56122987
DM
18969 },
18970 {
56122987
DM
18971 "children" : [
18972 {
56122987
DM
18973 "children" : [
18974 {
7aacca6f
DM
18975 "children" : [
18976 {
18977 "info" : {
44660702
DM
18978 "DELETE" : {
18979 "description" : "Delete volume",
18980 "method" : "DELETE",
18981 "name" : "delete",
7aacca6f
DM
18982 "parameters" : {
18983 "additionalProperties" : 0,
18984 "properties" : {
7aacca6f
DM
18985 "node" : {
18986 "description" : "The cluster node name.",
44660702
DM
18987 "format" : "pve-node",
18988 "type" : "string"
18989 },
18990 "storage" : {
18991 "description" : "The storage identifier.",
18992 "format" : "pve-storage-id",
18993 "optional" : 1,
18994 "type" : "string"
7aacca6f
DM
18995 },
18996 "volume" : {
18997 "description" : "Volume identifier",
18998 "type" : "string"
18999 }
19000 }
19001 },
44660702
DM
19002 "permissions" : {
19003 "description" : "You need 'Datastore.Allocate' privilege on the storage (or 'Datastore.AllocateSpace' for backup volumes if you have VM.Backup privilege on the VM).",
19004 "user" : "all"
19005 },
19006 "protected" : 1,
19007 "proxyto" : "node",
19008 "returns" : {
19009 "type" : "null"
19010 }
7aacca6f 19011 },
44660702
DM
19012 "GET" : {
19013 "description" : "Get volume attributes",
19014 "method" : "GET",
19015 "name" : "info",
7aacca6f
DM
19016 "parameters" : {
19017 "additionalProperties" : 0,
19018 "properties" : {
7aacca6f
DM
19019 "node" : {
19020 "description" : "The cluster node name.",
44660702
DM
19021 "format" : "pve-node",
19022 "type" : "string"
7aacca6f
DM
19023 },
19024 "storage" : {
7aacca6f 19025 "description" : "The storage identifier.",
44660702 19026 "format" : "pve-storage-id",
7aacca6f
DM
19027 "optional" : 1,
19028 "type" : "string"
44660702
DM
19029 },
19030 "volume" : {
19031 "description" : "Volume identifier",
19032 "type" : "string"
7aacca6f
DM
19033 }
19034 }
19035 },
7aacca6f 19036 "permissions" : {
44660702 19037 "description" : "You need read access for the volume.",
7aacca6f
DM
19038 "user" : "all"
19039 },
44660702 19040 "protected" : 1,
7aacca6f 19041 "proxyto" : "node",
7aacca6f 19042 "returns" : {
44660702 19043 "type" : "object"
7aacca6f
DM
19044 }
19045 },
19046 "POST" : {
44660702
DM
19047 "description" : "Copy a volume. This is experimental code - do not use.",
19048 "method" : "POST",
19049 "name" : "copy",
7aacca6f
DM
19050 "parameters" : {
19051 "additionalProperties" : 0,
19052 "properties" : {
44660702
DM
19053 "node" : {
19054 "description" : "The cluster node name.",
19055 "format" : "pve-node",
19056 "type" : "string"
19057 },
19058 "storage" : {
19059 "description" : "The storage identifier.",
19060 "format" : "pve-storage-id",
19061 "optional" : 1,
19062 "type" : "string"
19063 },
7aacca6f 19064 "target" : {
44660702
DM
19065 "description" : "Target volume identifier",
19066 "type" : "string"
7aacca6f
DM
19067 },
19068 "target_node" : {
7aacca6f 19069 "description" : "Target node. Default is local node.",
44660702
DM
19070 "format" : "pve-node",
19071 "optional" : 1,
19072 "type" : "string"
7aacca6f
DM
19073 },
19074 "volume" : {
44660702
DM
19075 "description" : "Source volume identifier",
19076 "type" : "string"
7aacca6f
DM
19077 }
19078 }
19079 },
7aacca6f
DM
19080 "protected" : 1,
19081 "proxyto" : "node",
19082 "returns" : {
19083 "type" : "string"
44660702 19084 }
7aacca6f
DM
19085 }
19086 },
7aacca6f 19087 "leaf" : 1,
44660702
DM
19088 "path" : "/nodes/{node}/storage/{storage}/content/{volume}",
19089 "text" : "{volume}"
7aacca6f
DM
19090 }
19091 ],
56122987
DM
19092 "info" : {
19093 "GET" : {
44660702
DM
19094 "description" : "List storage content.",
19095 "method" : "GET",
19096 "name" : "index",
19097 "parameters" : {
19098 "additionalProperties" : 0,
19099 "properties" : {
19100 "content" : {
19101 "description" : "Only list content of this type.",
19102 "format" : "pve-storage-content",
19103 "optional" : 1,
19104 "type" : "string"
19105 },
19106 "node" : {
19107 "description" : "The cluster node name.",
19108 "format" : "pve-node",
19109 "type" : "string"
19110 },
19111 "storage" : {
19112 "description" : "The storage identifier.",
19113 "format" : "pve-storage-id",
19114 "type" : "string"
19115 },
19116 "vmid" : {
19117 "description" : "Only list images for this VM",
19118 "format" : "pve-vmid",
19119 "minimum" : 1,
19120 "optional" : 1,
4bd7df8b 19121 "type" : "integer",
2c0dde61 19122 "typetext" : "integer (1 - N)"
44660702
DM
19123 }
19124 }
19125 },
7aacca6f
DM
19126 "permissions" : {
19127 "check" : [
19128 "perm",
19129 "/storage/{storage}",
19130 [
19131 "Datastore.Audit",
19132 "Datastore.AllocateSpace"
19133 ],
19134 "any",
19135 1
19136 ]
19137 },
44660702 19138 "protected" : 1,
7aacca6f 19139 "proxyto" : "node",
56122987 19140 "returns" : {
44660702
DM
19141 "items" : {
19142 "properties" : {
19143 "volid" : {
19144 "type" : "string"
19145 }
19146 },
19147 "type" : "object"
19148 },
19149 "links" : [
19150 {
19151 "href" : "{volid}",
19152 "rel" : "child"
19153 }
19154 ],
19155 "type" : "array"
19156 }
19157 },
19158 "POST" : {
19159 "description" : "Allocate disk images.",
19160 "method" : "POST",
19161 "name" : "create",
56122987 19162 "parameters" : {
44660702 19163 "additionalProperties" : 0,
56122987 19164 "properties" : {
44660702
DM
19165 "filename" : {
19166 "description" : "The name of the file to create.",
19167 "type" : "string"
19168 },
19169 "format" : {
19170 "enum" : [
19171 "raw",
19172 "qcow2",
19173 "subvol"
19174 ],
19175 "optional" : 1,
19176 "requires" : "size",
19177 "type" : "string"
19178 },
19179 "node" : {
19180 "description" : "The cluster node name.",
19181 "format" : "pve-node",
19182 "type" : "string"
19183 },
19184 "size" : {
19185 "description" : "Size in kilobyte (1024 bytes). Optional suffixes 'M' (megabyte, 1024K) and 'G' (gigabyte, 1024M)",
19186 "pattern" : "\\d+[MG]?",
19187 "type" : "string"
19188 },
56122987
DM
19189 "storage" : {
19190 "description" : "The storage identifier.",
44660702
DM
19191 "format" : "pve-storage-id",
19192 "type" : "string"
56122987 19193 },
44660702
DM
19194 "vmid" : {
19195 "description" : "Specify owner VM",
19196 "format" : "pve-vmid",
19197 "minimum" : 1,
4bd7df8b 19198 "type" : "integer",
2c0dde61 19199 "typetext" : "integer (1 - N)"
44660702
DM
19200 }
19201 }
19202 },
19203 "permissions" : {
19204 "check" : [
19205 "perm",
19206 "/storage/{storage}",
19207 [
19208 "Datastore.AllocateSpace"
19209 ]
19210 ]
19211 },
19212 "protected" : 1,
19213 "proxyto" : "node",
19214 "returns" : {
19215 "description" : "Volume identifier",
19216 "type" : "string"
19217 }
19218 }
19219 },
19220 "leaf" : 0,
19221 "path" : "/nodes/{node}/storage/{storage}/content",
19222 "text" : "content"
19223 },
19224 {
19225 "info" : {
19226 "GET" : {
19227 "description" : "Read storage status.",
19228 "method" : "GET",
19229 "name" : "read_status",
19230 "parameters" : {
19231 "additionalProperties" : 0,
19232 "properties" : {
56122987
DM
19233 "node" : {
19234 "description" : "The cluster node name.",
44660702
DM
19235 "format" : "pve-node",
19236 "type" : "string"
19237 },
19238 "storage" : {
19239 "description" : "The storage identifier.",
19240 "format" : "pve-storage-id",
19241 "type" : "string"
56122987 19242 }
44660702
DM
19243 }
19244 },
19245 "permissions" : {
19246 "check" : [
19247 "perm",
19248 "/storage/{storage}",
19249 [
19250 "Datastore.Audit",
19251 "Datastore.AllocateSpace"
19252 ],
19253 "any",
19254 1
19255 ]
56122987
DM
19256 },
19257 "protected" : 1,
44660702
DM
19258 "proxyto" : "node",
19259 "returns" : {
19260 "properties" : {},
19261 "type" : "object"
19262 }
56122987
DM
19263 }
19264 },
44660702
DM
19265 "leaf" : 1,
19266 "path" : "/nodes/{node}/storage/{storage}/status",
7aacca6f 19267 "text" : "status"
56122987
DM
19268 },
19269 {
56122987
DM
19270 "info" : {
19271 "GET" : {
44660702
DM
19272 "description" : "Read storage RRD statistics (returns PNG).",
19273 "method" : "GET",
19274 "name" : "rrd",
56122987 19275 "parameters" : {
44660702 19276 "additionalProperties" : 0,
56122987 19277 "properties" : {
44660702
DM
19278 "cf" : {
19279 "description" : "The RRD consolidation function",
19280 "enum" : [
19281 "AVERAGE",
19282 "MAX"
19283 ],
19284 "optional" : 1,
19285 "type" : "string"
19286 },
7aacca6f 19287 "ds" : {
7aacca6f 19288 "description" : "The list of datasources you want to display.",
44660702
DM
19289 "format" : "pve-configid-list",
19290 "type" : "string"
56122987 19291 },
7aacca6f
DM
19292 "node" : {
19293 "description" : "The cluster node name.",
44660702
DM
19294 "format" : "pve-node",
19295 "type" : "string"
56122987 19296 },
7aacca6f 19297 "storage" : {
7aacca6f 19298 "description" : "The storage identifier.",
44660702
DM
19299 "format" : "pve-storage-id",
19300 "type" : "string"
19301 },
19302 "timeframe" : {
19303 "description" : "Specify the time frame you are interested in.",
7aacca6f 19304 "enum" : [
44660702
DM
19305 "hour",
19306 "day",
19307 "week",
19308 "month",
19309 "year"
7aacca6f 19310 ],
44660702 19311 "type" : "string"
56122987 19312 }
44660702 19313 }
56122987
DM
19314 },
19315 "permissions" : {
19316 "check" : [
19317 "perm",
19318 "/storage/{storage}",
19319 [
19320 "Datastore.Audit",
19321 "Datastore.AllocateSpace"
19322 ],
19323 "any",
19324 1
19325 ]
19326 },
44660702
DM
19327 "protected" : 1,
19328 "proxyto" : "node",
7aacca6f
DM
19329 "returns" : {
19330 "properties" : {
19331 "filename" : {
19332 "type" : "string"
19333 }
19334 },
19335 "type" : "object"
19336 }
56122987
DM
19337 }
19338 },
19339 "leaf" : 1,
44660702
DM
19340 "path" : "/nodes/{node}/storage/{storage}/rrd",
19341 "text" : "rrd"
56122987
DM
19342 },
19343 {
56122987
DM
19344 "info" : {
19345 "GET" : {
44660702
DM
19346 "description" : "Read storage RRD statistics.",
19347 "method" : "GET",
19348 "name" : "rrddata",
56122987 19349 "parameters" : {
44660702 19350 "additionalProperties" : 0,
56122987 19351 "properties" : {
44660702
DM
19352 "cf" : {
19353 "description" : "The RRD consolidation function",
19354 "enum" : [
19355 "AVERAGE",
19356 "MAX"
19357 ],
19358 "optional" : 1,
19359 "type" : "string"
19360 },
7aacca6f 19361 "node" : {
7aacca6f 19362 "description" : "The cluster node name.",
44660702
DM
19363 "format" : "pve-node",
19364 "type" : "string"
19365 },
19366 "storage" : {
19367 "description" : "The storage identifier.",
19368 "format" : "pve-storage-id",
7aacca6f
DM
19369 "type" : "string"
19370 },
56122987 19371 "timeframe" : {
7aacca6f 19372 "description" : "Specify the time frame you are interested in.",
56122987
DM
19373 "enum" : [
19374 "hour",
19375 "day",
19376 "week",
19377 "month",
19378 "year"
56122987 19379 ],
44660702 19380 "type" : "string"
56122987 19381 }
44660702 19382 }
7aacca6f 19383 },
7aacca6f
DM
19384 "permissions" : {
19385 "check" : [
19386 "perm",
19387 "/storage/{storage}",
19388 [
19389 "Datastore.Audit",
19390 "Datastore.AllocateSpace"
19391 ],
19392 "any",
19393 1
19394 ]
19395 },
44660702
DM
19396 "protected" : 1,
19397 "proxyto" : "node",
7aacca6f
DM
19398 "returns" : {
19399 "items" : {
44660702
DM
19400 "properties" : {},
19401 "type" : "object"
7aacca6f
DM
19402 },
19403 "type" : "array"
56122987
DM
19404 }
19405 }
7aacca6f 19406 },
7aacca6f 19407 "leaf" : 1,
44660702
DM
19408 "path" : "/nodes/{node}/storage/{storage}/rrddata",
19409 "text" : "rrddata"
56122987
DM
19410 },
19411 {
56122987
DM
19412 "info" : {
19413 "POST" : {
7aacca6f 19414 "description" : "Upload templates and ISO images.",
44660702
DM
19415 "method" : "POST",
19416 "name" : "upload",
56122987 19417 "parameters" : {
7aacca6f 19418 "additionalProperties" : 0,
56122987 19419 "properties" : {
56122987 19420 "content" : {
7aacca6f 19421 "description" : "Content type.",
44660702
DM
19422 "format" : "pve-storage-content",
19423 "type" : "string"
56122987
DM
19424 },
19425 "filename" : {
44660702
DM
19426 "description" : "The name of the file to create.",
19427 "type" : "string"
56122987
DM
19428 },
19429 "node" : {
19430 "description" : "The cluster node name.",
44660702
DM
19431 "format" : "pve-node",
19432 "type" : "string"
19433 },
19434 "storage" : {
19435 "description" : "The storage identifier.",
19436 "format" : "pve-storage-id",
19437 "type" : "string"
19438 },
19439 "tmpfilename" : {
19440 "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.",
19441 "optional" : 1,
19442 "type" : "string"
56122987 19443 }
7aacca6f 19444 }
56122987 19445 },
56122987
DM
19446 "permissions" : {
19447 "check" : [
19448 "perm",
19449 "/storage/{storage}",
19450 [
19451 "Datastore.AllocateTemplate"
19452 ]
19453 ]
44660702
DM
19454 },
19455 "protected" : 1,
19456 "returns" : {
19457 "type" : "string"
19458 }
19459 }
19460 },
19461 "leaf" : 1,
19462 "path" : "/nodes/{node}/storage/{storage}/upload",
19463 "text" : "upload"
19464 }
19465 ],
19466 "info" : {
19467 "GET" : {
19468 "description" : "",
19469 "method" : "GET",
19470 "name" : "diridx",
19471 "parameters" : {
19472 "additionalProperties" : 0,
19473 "properties" : {
19474 "node" : {
19475 "description" : "The cluster node name.",
19476 "format" : "pve-node",
19477 "type" : "string"
19478 },
19479 "storage" : {
19480 "description" : "The storage identifier.",
19481 "format" : "pve-storage-id",
19482 "type" : "string"
56122987
DM
19483 }
19484 }
44660702
DM
19485 },
19486 "permissions" : {
19487 "check" : [
19488 "perm",
19489 "/storage/{storage}",
19490 [
19491 "Datastore.Audit",
19492 "Datastore.AllocateSpace"
19493 ],
19494 "any",
19495 1
19496 ]
19497 },
19498 "returns" : {
19499 "items" : {
19500 "properties" : {
19501 "subdir" : {
19502 "type" : "string"
19503 }
19504 },
19505 "type" : "object"
19506 },
19507 "links" : [
19508 {
19509 "href" : "{subdir}",
19510 "rel" : "child"
19511 }
19512 ],
19513 "type" : "array"
56122987
DM
19514 }
19515 }
44660702
DM
19516 },
19517 "leaf" : 0,
19518 "path" : "/nodes/{node}/storage/{storage}",
19519 "text" : "{storage}"
56122987
DM
19520 }
19521 ],
56122987
DM
19522 "info" : {
19523 "GET" : {
44660702
DM
19524 "description" : "Get status for all datastores.",
19525 "method" : "GET",
19526 "name" : "index",
19527 "parameters" : {
19528 "additionalProperties" : 0,
19529 "properties" : {
19530 "content" : {
19531 "description" : "Only list stores which support this content type.",
19532 "format" : "pve-storage-content-list",
19533 "optional" : 1,
19534 "type" : "string"
19535 },
19536 "enabled" : {
19537 "default" : 0,
19538 "description" : "Only list stores which are enabled (not disabled in config).",
19539 "optional" : 1,
19540 "type" : "boolean"
19541 },
19542 "node" : {
19543 "description" : "The cluster node name.",
19544 "format" : "pve-node",
19545 "type" : "string"
19546 },
19547 "storage" : {
19548 "description" : "Only list status for specified storage",
19549 "format" : "pve-storage-id",
19550 "optional" : 1,
19551 "type" : "string"
19552 },
19553 "target" : {
19554 "description" : "If target is different to 'node', we only lists shared storages which content is accessible on this 'node' and the specified 'target' node.",
19555 "format" : "pve-node",
19556 "optional" : 1,
19557 "type" : "string"
19558 }
19559 }
19560 },
7aacca6f
DM
19561 "permissions" : {
19562 "description" : "Only list entries where you have 'Datastore.Audit' or 'Datastore.AllocateSpace' permissions on '/storage/<storage>'",
19563 "user" : "all"
19564 },
44660702 19565 "protected" : 1,
7aacca6f 19566 "proxyto" : "node",
56122987
DM
19567 "returns" : {
19568 "items" : {
56122987
DM
19569 "properties" : {
19570 "storage" : {
19571 "type" : "string"
19572 }
44660702
DM
19573 },
19574 "type" : "object"
56122987 19575 },
56122987
DM
19576 "links" : [
19577 {
7aacca6f
DM
19578 "href" : "{storage}",
19579 "rel" : "child"
56122987 19580 }
44660702
DM
19581 ],
19582 "type" : "array"
19583 }
56122987 19584 }
44660702
DM
19585 },
19586 "leaf" : 0,
19587 "path" : "/nodes/{node}/storage",
19588 "text" : "storage"
56122987 19589 },
2c0dde61
DM
19590 {
19591 "children" : [
19592 {
19593 "info" : {
19594 "GET" : {
19595 "description" : "List local disks.",
19596 "method" : "GET",
19597 "name" : "list",
19598 "parameters" : {
19599 "additionalProperties" : 0,
19600 "properties" : {
19601 "node" : {
19602 "description" : "The cluster node name.",
19603 "format" : "pve-node",
19604 "type" : "string"
19605 }
19606 }
19607 },
19608 "permissions" : {
19609 "check" : [
19610 "perm",
19611 "/",
19612 [
19613 "Sys.Audit",
19614 "Datastore.Audit"
19615 ],
19616 "any",
19617 1
19618 ]
19619 },
19620 "protected" : 1,
19621 "proxyto" : "node",
19622 "returns" : {
19623 "items" : {
19624 "properties" : {
19625 "devpath" : {
19626 "description" : "The device path",
19627 "type" : "string"
19628 },
19629 "gpt" : {
19630 "type" : "boolean"
19631 },
19632 "health" : {
19633 "optional" : 1,
19634 "type" : "string"
19635 },
19636 "model" : {
19637 "optional" : 1,
19638 "type" : "string"
19639 },
19640 "osdid" : {
19641 "type" : "integer"
19642 },
19643 "serial" : {
19644 "optional" : 1,
19645 "type" : "string"
19646 },
19647 "size" : {
19648 "type" : "integer"
19649 },
19650 "used" : {
19651 "optional" : 1,
19652 "type" : "string"
19653 },
19654 "vendor" : {
19655 "optional" : 1,
19656 "type" : "string"
19657 },
19658 "wwn" : {
19659 "optional" : 1,
19660 "type" : "string"
19661 }
19662 },
19663 "type" : "object"
19664 },
19665 "type" : "array"
19666 }
19667 }
19668 },
19669 "leaf" : 1,
19670 "path" : "/nodes/{node}/disks/list",
19671 "text" : "list"
19672 },
19673 {
19674 "info" : {
19675 "GET" : {
19676 "description" : "Get SMART Health of a disk.",
19677 "method" : "GET",
19678 "name" : "smart",
19679 "parameters" : {
19680 "additionalProperties" : 0,
19681 "properties" : {
19682 "disk" : {
19683 "description" : "Block device name",
19684 "pattern" : "^/dev/[a-zA-Z0-9\\/]+$",
19685 "type" : "string"
19686 },
19687 "healthonly" : {
19688 "description" : "If true returns only the health status",
19689 "optional" : 1,
19690 "type" : "boolean"
19691 },
19692 "node" : {
19693 "description" : "The cluster node name.",
19694 "format" : "pve-node",
19695 "type" : "string"
19696 }
19697 }
19698 },
19699 "permissions" : {
19700 "check" : [
19701 "perm",
19702 "/",
19703 [
19704 "Sys.Audit",
19705 "Datastore.Audit"
19706 ],
19707 "any",
19708 1
19709 ]
19710 },
19711 "protected" : 1,
19712 "proxyto" : "node",
19713 "returns" : {
19714 "type" : "object"
19715 }
19716 }
19717 },
19718 "leaf" : 1,
19719 "path" : "/nodes/{node}/disks/smart",
19720 "text" : "smart"
19721 },
19722 {
19723 "info" : {
19724 "POST" : {
19725 "description" : "Initialize Disk with GPT",
19726 "method" : "POST",
19727 "name" : "initgpt",
19728 "parameters" : {
19729 "additionalProperties" : 0,
19730 "properties" : {
19731 "disk" : {
19732 "description" : "Block device name",
19733 "pattern" : "^/dev/[a-zA-Z0-9\\/]+$",
19734 "type" : "string"
19735 },
19736 "node" : {
19737 "description" : "The cluster node name.",
19738 "format" : "pve-node",
19739 "type" : "string"
19740 },
19741 "uuid" : {
19742 "description" : "UUID for the GPT table",
19743 "maxLength" : 36,
19744 "optional" : 1,
19745 "pattern" : "[a-fA-F0-9\\-]+",
19746 "type" : "string"
19747 }
19748 }
19749 },
19750 "permissions" : {
19751 "check" : [
19752 "perm",
19753 "/",
19754 [
19755 "Sys.Modify"
19756 ]
19757 ]
19758 },
19759 "protected" : 1,
19760 "proxyto" : "node",
19761 "returns" : {
19762 "type" : "string"
19763 }
19764 }
19765 },
19766 "leaf" : 1,
19767 "path" : "/nodes/{node}/disks/initgpt",
19768 "text" : "initgpt"
19769 }
19770 ],
19771 "info" : {
19772 "GET" : {
19773 "description" : "Node index.",
19774 "method" : "GET",
19775 "name" : "index",
19776 "parameters" : {
19777 "additionalProperties" : 0,
19778 "properties" : {
19779 "node" : {
19780 "description" : "The cluster node name.",
19781 "format" : "pve-node",
19782 "type" : "string"
19783 }
19784 }
19785 },
19786 "permissions" : {
19787 "user" : "all"
19788 },
19789 "proxyto" : "node",
19790 "returns" : {
19791 "items" : {
19792 "properties" : {},
19793 "type" : "object"
19794 },
19795 "links" : [
19796 {
19797 "href" : "{name}",
19798 "rel" : "child"
19799 }
19800 ],
19801 "type" : "array"
19802 }
19803 }
19804 },
19805 "leaf" : 0,
19806 "path" : "/nodes/{node}/disks",
19807 "text" : "disks"
19808 },
56122987 19809 {
56122987
DM
19810 "children" : [
19811 {
19812 "info" : {
44660702
DM
19813 "GET" : {
19814 "description" : "List available updates.",
19815 "method" : "GET",
19816 "name" : "list_updates",
19817 "parameters" : {
19818 "additionalProperties" : 0,
19819 "properties" : {
19820 "node" : {
19821 "description" : "The cluster node name.",
19822 "format" : "pve-node",
19823 "type" : "string"
19824 }
19825 }
7aacca6f
DM
19826 },
19827 "permissions" : {
19828 "check" : [
19829 "perm",
19830 "/nodes/{node}",
19831 [
19832 "Sys.Modify"
19833 ]
19834 ]
19835 },
44660702 19836 "protected" : 1,
56122987 19837 "proxyto" : "node",
44660702
DM
19838 "returns" : {
19839 "items" : {
19840 "properties" : {},
19841 "type" : "object"
19842 },
19843 "type" : "array"
19844 }
19845 },
19846 "POST" : {
19847 "description" : "This is used to resynchronize the package index files from their sources (apt-get update).",
7aacca6f
DM
19848 "method" : "POST",
19849 "name" : "update_database",
56122987
DM
19850 "parameters" : {
19851 "additionalProperties" : 0,
19852 "properties" : {
44660702
DM
19853 "node" : {
19854 "description" : "The cluster node name.",
19855 "format" : "pve-node",
19856 "type" : "string"
19857 },
56122987 19858 "notify" : {
56122987 19859 "default" : 0,
44660702
DM
19860 "description" : "Send notification mail about new packages (to email address specified for user 'root@pam').",
19861 "optional" : 1,
19862 "type" : "boolean"
56122987
DM
19863 },
19864 "quiet" : {
56122987 19865 "default" : 0,
44660702 19866 "description" : "Only produces output suitable for logging, omitting progress indicators.",
56122987 19867 "optional" : 1,
44660702 19868 "type" : "boolean"
56122987 19869 }
7aacca6f
DM
19870 }
19871 },
19872 "permissions" : {
19873 "check" : [
19874 "perm",
19875 "/nodes/{node}",
19876 [
19877 "Sys.Modify"
19878 ]
19879 ]
19880 },
44660702
DM
19881 "protected" : 1,
19882 "proxyto" : "node",
19883 "returns" : {
19884 "type" : "string"
19885 }
56122987
DM
19886 }
19887 },
7aacca6f 19888 "leaf" : 1,
44660702
DM
19889 "path" : "/nodes/{node}/apt/update",
19890 "text" : "update"
56122987
DM
19891 },
19892 {
56122987
DM
19893 "info" : {
19894 "GET" : {
44660702 19895 "description" : "Get package changelogs.",
56122987 19896 "method" : "GET",
7aacca6f 19897 "name" : "changelog",
56122987 19898 "parameters" : {
44660702 19899 "additionalProperties" : 0,
56122987
DM
19900 "properties" : {
19901 "name" : {
19902 "description" : "Package name.",
19903 "type" : "string"
19904 },
44660702
DM
19905 "node" : {
19906 "description" : "The cluster node name.",
19907 "format" : "pve-node",
19908 "type" : "string"
19909 },
56122987 19910 "version" : {
7aacca6f 19911 "description" : "Package version.",
44660702
DM
19912 "optional" : 1,
19913 "type" : "string"
56122987 19914 }
44660702 19915 }
56122987 19916 },
44660702
DM
19917 "permissions" : {
19918 "check" : [
19919 "perm",
19920 "/nodes/{node}",
19921 [
19922 "Sys.Modify"
19923 ]
19924 ]
19925 },
19926 "proxyto" : "node",
19927 "returns" : {
19928 "type" : "string"
19929 }
56122987
DM
19930 }
19931 },
44660702
DM
19932 "leaf" : 1,
19933 "path" : "/nodes/{node}/apt/changelog",
7aacca6f 19934 "text" : "changelog"
56122987
DM
19935 },
19936 {
56122987
DM
19937 "info" : {
19938 "GET" : {
44660702
DM
19939 "description" : "Get package information for important Proxmox packages.",
19940 "method" : "GET",
7aacca6f
DM
19941 "name" : "versions",
19942 "parameters" : {
44660702 19943 "additionalProperties" : 0,
7aacca6f
DM
19944 "properties" : {
19945 "node" : {
44660702 19946 "description" : "The cluster node name.",
7aacca6f 19947 "format" : "pve-node",
44660702 19948 "type" : "string"
7aacca6f 19949 }
44660702 19950 }
7aacca6f 19951 },
56122987
DM
19952 "permissions" : {
19953 "check" : [
19954 "perm",
19955 "/nodes/{node}",
19956 [
19957 "Sys.Audit"
19958 ]
19959 ]
19960 },
7aacca6f 19961 "proxyto" : "node",
56122987
DM
19962 "returns" : {
19963 "items" : {
7aacca6f
DM
19964 "properties" : {},
19965 "type" : "object"
44660702
DM
19966 },
19967 "type" : "array"
56122987
DM
19968 }
19969 }
19970 },
44660702 19971 "leaf" : 1,
7aacca6f 19972 "path" : "/nodes/{node}/apt/versions",
44660702 19973 "text" : "versions"
56122987
DM
19974 }
19975 ],
56122987
DM
19976 "info" : {
19977 "GET" : {
44660702 19978 "description" : "Directory index for apt (Advanced Package Tool).",
7aacca6f 19979 "method" : "GET",
44660702 19980 "name" : "index",
7aacca6f
DM
19981 "parameters" : {
19982 "additionalProperties" : 0,
19983 "properties" : {
19984 "node" : {
44660702 19985 "description" : "The cluster node name.",
7aacca6f 19986 "format" : "pve-node",
44660702 19987 "type" : "string"
7aacca6f
DM
19988 }
19989 }
19990 },
7aacca6f
DM
19991 "permissions" : {
19992 "user" : "all"
19993 },
44660702
DM
19994 "returns" : {
19995 "items" : {
19996 "properties" : {
19997 "id" : {
19998 "type" : "string"
19999 }
20000 },
20001 "type" : "object"
20002 },
20003 "links" : [
20004 {
20005 "href" : "{id}",
20006 "rel" : "child"
20007 }
20008 ],
20009 "type" : "array"
20010 }
56122987 20011 }
7aacca6f 20012 },
44660702 20013 "leaf" : 0,
7aacca6f 20014 "path" : "/nodes/{node}/apt",
44660702 20015 "text" : "apt"
56122987
DM
20016 },
20017 {
56122987
DM
20018 "children" : [
20019 {
20020 "children" : [
20021 {
56122987
DM
20022 "info" : {
20023 "DELETE" : {
44660702 20024 "description" : "Delete rule.",
7aacca6f 20025 "method" : "DELETE",
44660702 20026 "name" : "delete_rule",
56122987
DM
20027 "parameters" : {
20028 "additionalProperties" : 0,
20029 "properties" : {
56122987
DM
20030 "digest" : {
20031 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
44660702 20032 "maxLength" : 40,
56122987 20033 "optional" : 1,
56122987
DM
20034 "type" : "string"
20035 },
44660702
DM
20036 "node" : {
20037 "description" : "The cluster node name.",
20038 "format" : "pve-node",
20039 "type" : "string"
20040 },
7aacca6f 20041 "pos" : {
7aacca6f 20042 "description" : "Update rule at position <pos>.",
44660702
DM
20043 "minimum" : 0,
20044 "optional" : 1,
4bd7df8b 20045 "type" : "integer",
2c0dde61 20046 "typetext" : "integer (0 - N)"
56122987
DM
20047 }
20048 }
20049 },
44660702
DM
20050 "permissions" : {
20051 "check" : [
20052 "perm",
20053 "/nodes/{node}",
20054 [
20055 "Sys.Modify"
20056 ]
20057 ]
20058 },
20059 "protected" : 1,
20060 "proxyto" : "node",
56122987
DM
20061 "returns" : {
20062 "type" : "null"
44660702
DM
20063 }
20064 },
20065 "GET" : {
20066 "description" : "Get single rule data.",
20067 "method" : "GET",
20068 "name" : "get_rule",
20069 "parameters" : {
20070 "additionalProperties" : 0,
20071 "properties" : {
20072 "node" : {
20073 "description" : "The cluster node name.",
20074 "format" : "pve-node",
20075 "type" : "string"
20076 },
20077 "pos" : {
20078 "description" : "Update rule at position <pos>.",
20079 "minimum" : 0,
20080 "optional" : 1,
4bd7df8b 20081 "type" : "integer",
2c0dde61 20082 "typetext" : "integer (0 - N)"
44660702
DM
20083 }
20084 }
56122987 20085 },
56122987
DM
20086 "permissions" : {
20087 "check" : [
20088 "perm",
20089 "/nodes/{node}",
20090 [
44660702 20091 "Sys.Audit"
56122987
DM
20092 ]
20093 ]
44660702
DM
20094 },
20095 "proxyto" : "node",
20096 "returns" : {
20097 "properties" : {
20098 "pos" : {
20099 "type" : "integer"
20100 }
20101 },
20102 "type" : "object"
7aacca6f 20103 }
56122987
DM
20104 },
20105 "PUT" : {
44660702
DM
20106 "description" : "Modify rule data.",
20107 "method" : "PUT",
56122987 20108 "name" : "update_rule",
56122987 20109 "parameters" : {
44660702 20110 "additionalProperties" : 0,
56122987 20111 "properties" : {
44660702
DM
20112 "action" : {
20113 "description" : "Rule action ('ACCEPT', 'DROP', 'REJECT') or security group name.",
20114 "maxLength" : 20,
20115 "minLength" : 2,
56122987 20116 "optional" : 1,
44660702
DM
20117 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
20118 "type" : "string"
56122987 20119 },
7aacca6f 20120 "comment" : {
e94f0d56 20121 "description" : "Descriptive comment.",
56122987 20122 "optional" : 1,
56122987
DM
20123 "type" : "string"
20124 },
44660702
DM
20125 "delete" : {
20126 "description" : "A list of settings you want to delete.",
20127 "format" : "pve-configid-list",
56122987 20128 "optional" : 1,
44660702 20129 "type" : "string"
56122987 20130 },
44660702
DM
20131 "dest" : {
20132 "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.",
20133 "format" : "pve-fw-addr-spec",
56122987 20134 "optional" : 1,
44660702 20135 "type" : "string"
56122987 20136 },
44660702
DM
20137 "digest" : {
20138 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
20139 "maxLength" : 40,
56122987 20140 "optional" : 1,
44660702 20141 "type" : "string"
56122987 20142 },
7aacca6f 20143 "dport" : {
7aacca6f 20144 "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.",
44660702
DM
20145 "format" : "pve-fw-dport-spec",
20146 "optional" : 1,
20147 "type" : "string"
7aacca6f 20148 },
44660702 20149 "enable" : {
e94f0d56 20150 "description" : "Flag to enable/disable a rule.",
44660702 20151 "minimum" : 0,
56122987 20152 "optional" : 1,
4bd7df8b 20153 "type" : "integer",
2c0dde61 20154 "typetext" : "integer (0 - N)"
56122987 20155 },
7aacca6f 20156 "iface" : {
44660702 20157 "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.",
7aacca6f 20158 "format" : "pve-iface",
44660702 20159 "maxLength" : 20,
56122987 20160 "minLength" : 2,
44660702
DM
20161 "optional" : 1,
20162 "type" : "string"
56122987 20163 },
44660702 20164 "macro" : {
e94f0d56 20165 "description" : "Use predefined standard macro.",
44660702
DM
20166 "maxLength" : 128,
20167 "optional" : 1,
20168 "type" : "string"
20169 },
20170 "moveto" : {
20171 "description" : "Move rule to new position <moveto>. Other arguments are ignored.",
20172 "minimum" : 0,
7aacca6f 20173 "optional" : 1,
4bd7df8b 20174 "type" : "integer",
2c0dde61 20175 "typetext" : "integer (0 - N)"
44660702
DM
20176 },
20177 "node" : {
20178 "description" : "The cluster node name.",
20179 "format" : "pve-node",
20180 "type" : "string"
56122987
DM
20181 },
20182 "pos" : {
44660702 20183 "description" : "Update rule at position <pos>.",
7aacca6f 20184 "minimum" : 0,
7aacca6f 20185 "optional" : 1,
4bd7df8b 20186 "type" : "integer",
2c0dde61 20187 "typetext" : "integer (0 - N)"
7aacca6f 20188 },
44660702
DM
20189 "proto" : {
20190 "description" : "IP protocol. You can use protocol names ('tcp'/'udp') or simple numbers, as defined in '/etc/protocols'.",
20191 "format" : "pve-fw-protocol-spec",
7aacca6f
DM
20192 "optional" : 1,
20193 "type" : "string"
20194 },
44660702
DM
20195 "source" : {
20196 "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.",
20197 "format" : "pve-fw-addr-spec",
56122987 20198 "optional" : 1,
44660702 20199 "type" : "string"
7aacca6f 20200 },
44660702
DM
20201 "sport" : {
20202 "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.",
20203 "format" : "pve-fw-sport-spec",
20204 "optional" : 1,
20205 "type" : "string"
20206 },
20207 "type" : {
e94f0d56 20208 "description" : "Rule type.",
44660702
DM
20209 "enum" : [
20210 "in",
20211 "out",
20212 "group"
20213 ],
20214 "optional" : 1,
20215 "type" : "string"
56122987 20216 }
44660702 20217 }
56122987 20218 },
56122987
DM
20219 "permissions" : {
20220 "check" : [
20221 "perm",
20222 "/nodes/{node}",
20223 [
20224 "Sys.Modify"
20225 ]
20226 ]
7aacca6f 20227 },
44660702 20228 "protected" : 1,
7aacca6f 20229 "proxyto" : "node",
7aacca6f
DM
20230 "returns" : {
20231 "type" : "null"
56122987
DM
20232 }
20233 }
7aacca6f 20234 },
44660702 20235 "leaf" : 1,
7aacca6f 20236 "path" : "/nodes/{node}/firewall/rules/{pos}",
44660702 20237 "text" : "{pos}"
56122987
DM
20238 }
20239 ],
56122987
DM
20240 "info" : {
20241 "GET" : {
44660702
DM
20242 "description" : "List rules.",
20243 "method" : "GET",
20244 "name" : "get_rules",
20245 "parameters" : {
20246 "additionalProperties" : 0,
20247 "properties" : {
20248 "node" : {
20249 "description" : "The cluster node name.",
20250 "format" : "pve-node",
20251 "type" : "string"
20252 }
20253 }
20254 },
20255 "permissions" : {
20256 "check" : [
20257 "perm",
20258 "/nodes/{node}",
20259 [
20260 "Sys.Audit"
20261 ]
20262 ]
20263 },
20264 "proxyto" : "node",
56122987 20265 "returns" : {
56122987
DM
20266 "items" : {
20267 "properties" : {
20268 "pos" : {
20269 "type" : "integer"
20270 }
44660702
DM
20271 },
20272 "type" : "object"
56122987 20273 },
7aacca6f
DM
20274 "links" : [
20275 {
20276 "href" : "{pos}",
20277 "rel" : "child"
20278 }
20279 ],
20280 "type" : "array"
44660702 20281 }
56122987
DM
20282 },
20283 "POST" : {
44660702 20284 "description" : "Create new rule.",
7aacca6f
DM
20285 "method" : "POST",
20286 "name" : "create_rule",
56122987 20287 "parameters" : {
44660702 20288 "additionalProperties" : 0,
56122987 20289 "properties" : {
7aacca6f 20290 "action" : {
7aacca6f 20291 "description" : "Rule action ('ACCEPT', 'DROP', 'REJECT') or security group name.",
44660702 20292 "maxLength" : 20,
7aacca6f
DM
20293 "minLength" : 2,
20294 "optional" : 0,
44660702
DM
20295 "pattern" : "[A-Za-z][A-Za-z0-9\\-\\_]+",
20296 "type" : "string"
56122987 20297 },
44660702 20298 "comment" : {
e94f0d56 20299 "description" : "Descriptive comment.",
56122987 20300 "optional" : 1,
44660702 20301 "type" : "string"
56122987 20302 },
44660702
DM
20303 "dest" : {
20304 "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.",
20305 "format" : "pve-fw-addr-spec",
7aacca6f 20306 "optional" : 1,
44660702 20307 "type" : "string"
56122987 20308 },
44660702
DM
20309 "digest" : {
20310 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
20311 "maxLength" : 40,
20312 "optional" : 1,
20313 "type" : "string"
56122987 20314 },
44660702
DM
20315 "dport" : {
20316 "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.",
20317 "format" : "pve-fw-dport-spec",
7aacca6f
DM
20318 "optional" : 1,
20319 "type" : "string"
56122987 20320 },
44660702 20321 "enable" : {
e94f0d56 20322 "description" : "Flag to enable/disable a rule.",
44660702
DM
20323 "minimum" : 0,
20324 "optional" : 1,
4bd7df8b 20325 "type" : "integer",
2c0dde61 20326 "typetext" : "integer (0 - N)"
44660702 20327 },
7aacca6f 20328 "iface" : {
44660702 20329 "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.",
7aacca6f 20330 "format" : "pve-iface",
56122987 20331 "maxLength" : 20,
7aacca6f 20332 "minLength" : 2,
7aacca6f 20333 "optional" : 1,
56122987
DM
20334 "type" : "string"
20335 },
44660702 20336 "macro" : {
e94f0d56 20337 "description" : "Use predefined standard macro.",
44660702 20338 "maxLength" : 128,
7aacca6f
DM
20339 "optional" : 1,
20340 "type" : "string"
56122987 20341 },
44660702
DM
20342 "node" : {
20343 "description" : "The cluster node name.",
20344 "format" : "pve-node",
20345 "type" : "string"
20346 },
20347 "pos" : {
20348 "description" : "Update rule at position <pos>.",
20349 "minimum" : 0,
20350 "optional" : 1,
4bd7df8b 20351 "type" : "integer",
2c0dde61 20352 "typetext" : "integer (0 - N)"
44660702
DM
20353 },
20354 "proto" : {
20355 "description" : "IP protocol. You can use protocol names ('tcp'/'udp') or simple numbers, as defined in '/etc/protocols'.",
20356 "format" : "pve-fw-protocol-spec",
56122987 20357 "optional" : 1,
44660702 20358 "type" : "string"
56122987 20359 },
7aacca6f 20360 "source" : {
7aacca6f 20361 "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.",
44660702
DM
20362 "format" : "pve-fw-addr-spec",
20363 "optional" : 1,
20364 "type" : "string"
7aacca6f 20365 },
44660702
DM
20366 "sport" : {
20367 "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.",
20368 "format" : "pve-fw-sport-spec",
7aacca6f 20369 "optional" : 1,
44660702
DM
20370 "type" : "string"
20371 },
20372 "type" : {
e94f0d56 20373 "description" : "Rule type.",
44660702
DM
20374 "enum" : [
20375 "in",
20376 "out",
20377 "group"
20378 ],
20379 "optional" : 0,
20380 "type" : "string"
56122987 20381 }
44660702 20382 }
7aacca6f 20383 },
56122987
DM
20384 "permissions" : {
20385 "check" : [
20386 "perm",
20387 "/nodes/{node}",
20388 [
20389 "Sys.Modify"
20390 ]
20391 ]
20392 },
44660702
DM
20393 "protected" : 1,
20394 "proxyto" : "node",
20395 "returns" : {
20396 "type" : "null"
20397 }
56122987
DM
20398 }
20399 },
44660702 20400 "leaf" : 0,
7aacca6f 20401 "path" : "/nodes/{node}/firewall/rules",
44660702 20402 "text" : "rules"
56122987
DM
20403 },
20404 {
56122987 20405 "info" : {
44660702
DM
20406 "GET" : {
20407 "description" : "Get host firewall options.",
20408 "method" : "GET",
20409 "name" : "get_options",
56122987 20410 "parameters" : {
7aacca6f 20411 "additionalProperties" : 0,
56122987 20412 "properties" : {
44660702
DM
20413 "node" : {
20414 "description" : "The cluster node name.",
20415 "format" : "pve-node",
20416 "type" : "string"
20417 }
20418 }
20419 },
20420 "permissions" : {
20421 "check" : [
20422 "perm",
20423 "/nodes/{node}",
20424 [
20425 "Sys.Audit"
20426 ]
20427 ]
20428 },
20429 "proxyto" : "node",
20430 "returns" : {
20431 "properties" : {
20432 "enable" : {
20433 "description" : "Enable host firewall rules.",
7aacca6f 20434 "optional" : 1,
44660702 20435 "type" : "boolean"
7aacca6f 20436 },
44660702
DM
20437 "log_level_in" : {
20438 "description" : "Log level for incoming traffic.",
56122987
DM
20439 "enum" : [
20440 "emerg",
20441 "alert",
20442 "crit",
20443 "err",
20444 "warning",
20445 "notice",
20446 "info",
20447 "debug",
20448 "nolog"
20449 ],
56122987 20450 "optional" : 1,
44660702
DM
20451 "type" : "string"
20452 },
20453 "log_level_out" : {
20454 "description" : "Log level for outgoing traffic.",
56122987
DM
20455 "enum" : [
20456 "emerg",
20457 "alert",
20458 "crit",
20459 "err",
20460 "warning",
20461 "notice",
20462 "info",
20463 "debug",
20464 "nolog"
20465 ],
44660702
DM
20466 "optional" : 1,
20467 "type" : "string"
20468 },
20469 "ndp" : {
20470 "description" : "Enable NDP.",
20471 "optional" : 1,
20472 "type" : "boolean"
20473 },
20474 "nf_conntrack_max" : {
20475 "description" : "Maximum number of tracked connections.",
20476 "minimum" : 32768,
20477 "optional" : 1,
20478 "type" : "integer"
20479 },
20480 "nf_conntrack_tcp_timeout_established" : {
20481 "description" : "Conntrack established timeout.",
20482 "minimum" : 7875,
20483 "optional" : 1,
20484 "type" : "integer"
20485 },
20486 "nosmurfs" : {
20487 "description" : "Enable SMURFS filter.",
20488 "optional" : 1,
20489 "type" : "boolean"
56122987 20490 },
7aacca6f 20491 "smurf_log_level" : {
44660702 20492 "description" : "Log level for SMURFS filter.",
56122987
DM
20493 "enum" : [
20494 "emerg",
20495 "alert",
20496 "crit",
20497 "err",
20498 "warning",
20499 "notice",
20500 "info",
20501 "debug",
20502 "nolog"
7aacca6f 20503 ],
7aacca6f
DM
20504 "optional" : 1,
20505 "type" : "string"
56122987 20506 },
44660702
DM
20507 "tcp_flags_log_level" : {
20508 "description" : "Log level for illegal tcp flags filter.",
56122987
DM
20509 "enum" : [
20510 "emerg",
20511 "alert",
20512 "crit",
20513 "err",
20514 "warning",
20515 "notice",
20516 "info",
20517 "debug",
20518 "nolog"
20519 ],
44660702
DM
20520 "optional" : 1,
20521 "type" : "string"
7aacca6f 20522 },
44660702
DM
20523 "tcpflags" : {
20524 "description" : "Filter illegal combinations of TCP flags.",
56122987 20525 "optional" : 1,
44660702 20526 "type" : "boolean"
56122987 20527 }
44660702
DM
20528 },
20529 "type" : "object"
7aacca6f 20530 }
56122987 20531 },
44660702
DM
20532 "PUT" : {
20533 "description" : "Set Firewall options.",
20534 "method" : "PUT",
20535 "name" : "set_options",
7aacca6f 20536 "parameters" : {
44660702 20537 "additionalProperties" : 0,
7aacca6f 20538 "properties" : {
44660702
DM
20539 "delete" : {
20540 "description" : "A list of settings you want to delete.",
20541 "format" : "pve-configid-list",
7aacca6f 20542 "optional" : 1,
44660702 20543 "type" : "string"
56122987 20544 },
44660702
DM
20545 "digest" : {
20546 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
20547 "maxLength" : 40,
20548 "optional" : 1,
20549 "type" : "string"
56122987 20550 },
44660702
DM
20551 "enable" : {
20552 "description" : "Enable host firewall rules.",
7aacca6f 20553 "optional" : 1,
44660702
DM
20554 "type" : "boolean"
20555 },
20556 "log_level_in" : {
20557 "description" : "Log level for incoming traffic.",
56122987
DM
20558 "enum" : [
20559 "emerg",
20560 "alert",
20561 "crit",
20562 "err",
20563 "warning",
20564 "notice",
20565 "info",
20566 "debug",
20567 "nolog"
44660702 20568 ],
7aacca6f 20569 "optional" : 1,
44660702 20570 "type" : "string"
7aacca6f 20571 },
44660702
DM
20572 "log_level_out" : {
20573 "description" : "Log level for outgoing traffic.",
56122987
DM
20574 "enum" : [
20575 "emerg",
20576 "alert",
20577 "crit",
20578 "err",
20579 "warning",
20580 "notice",
20581 "info",
20582 "debug",
20583 "nolog"
20584 ],
20585 "optional" : 1,
7aacca6f 20586 "type" : "string"
56122987 20587 },
44660702
DM
20588 "ndp" : {
20589 "description" : "Enable NDP.",
7aacca6f 20590 "optional" : 1,
44660702
DM
20591 "type" : "boolean"
20592 },
20593 "nf_conntrack_max" : {
20594 "description" : "Maximum number of tracked connections.",
20595 "minimum" : 32768,
20596 "optional" : 1,
4bd7df8b 20597 "type" : "integer",
2c0dde61 20598 "typetext" : "integer (32768 - N)"
44660702
DM
20599 },
20600 "nf_conntrack_tcp_timeout_established" : {
20601 "description" : "Conntrack established timeout.",
20602 "minimum" : 7875,
20603 "optional" : 1,
4bd7df8b 20604 "type" : "integer",
2c0dde61 20605 "typetext" : "integer (7875 - N)"
44660702
DM
20606 },
20607 "node" : {
20608 "description" : "The cluster node name.",
20609 "format" : "pve-node",
20610 "type" : "string"
20611 },
20612 "nosmurfs" : {
20613 "description" : "Enable SMURFS filter.",
20614 "optional" : 1,
20615 "type" : "boolean"
20616 },
20617 "smurf_log_level" : {
20618 "description" : "Log level for SMURFS filter.",
56122987
DM
20619 "enum" : [
20620 "emerg",
20621 "alert",
20622 "crit",
20623 "err",
20624 "warning",
20625 "notice",
20626 "info",
20627 "debug",
20628 "nolog"
44660702
DM
20629 ],
20630 "optional" : 1,
20631 "type" : "string"
56122987 20632 },
44660702
DM
20633 "tcp_flags_log_level" : {
20634 "description" : "Log level for illegal tcp flags filter.",
56122987
DM
20635 "enum" : [
20636 "emerg",
20637 "alert",
20638 "crit",
20639 "err",
20640 "warning",
20641 "notice",
20642 "info",
20643 "debug",
20644 "nolog"
20645 ],
44660702
DM
20646 "optional" : 1,
20647 "type" : "string"
7aacca6f 20648 },
44660702
DM
20649 "tcpflags" : {
20650 "description" : "Filter illegal combinations of TCP flags.",
56122987 20651 "optional" : 1,
7aacca6f 20652 "type" : "boolean"
56122987 20653 }
7aacca6f 20654 }
56122987 20655 },
44660702
DM
20656 "permissions" : {
20657 "check" : [
20658 "perm",
20659 "/nodes/{node}",
20660 [
20661 "Sys.Modify"
20662 ]
20663 ]
20664 },
20665 "protected" : 1,
20666 "proxyto" : "node",
20667 "returns" : {
20668 "type" : "null"
20669 }
7aacca6f
DM
20670 }
20671 },
44660702
DM
20672 "leaf" : 1,
20673 "path" : "/nodes/{node}/firewall/options",
7aacca6f
DM
20674 "text" : "options"
20675 },
20676 {
7aacca6f
DM
20677 "info" : {
20678 "GET" : {
44660702
DM
20679 "description" : "Read firewall log",
20680 "method" : "GET",
7aacca6f 20681 "name" : "log",
56122987 20682 "parameters" : {
44660702 20683 "additionalProperties" : 0,
56122987 20684 "properties" : {
7aacca6f 20685 "limit" : {
44660702 20686 "minimum" : 0,
7aacca6f 20687 "optional" : 1,
4bd7df8b 20688 "type" : "integer",
2c0dde61 20689 "typetext" : "integer (0 - N)"
7aacca6f 20690 },
56122987 20691 "node" : {
7aacca6f 20692 "description" : "The cluster node name.",
44660702 20693 "format" : "pve-node",
7aacca6f 20694 "type" : "string"
44660702
DM
20695 },
20696 "start" : {
20697 "minimum" : 0,
20698 "optional" : 1,
4bd7df8b 20699 "type" : "integer",
2c0dde61 20700 "typetext" : "integer (0 - N)"
56122987 20701 }
44660702 20702 }
7aacca6f 20703 },
56122987
DM
20704 "permissions" : {
20705 "check" : [
20706 "perm",
20707 "/nodes/{node}",
20708 [
20709 "Sys.Syslog"
20710 ]
20711 ]
20712 },
44660702
DM
20713 "protected" : 1,
20714 "proxyto" : "node",
56122987
DM
20715 "returns" : {
20716 "items" : {
56122987 20717 "properties" : {
56122987 20718 "n" : {
44660702
DM
20719 "description" : "Line number",
20720 "type" : "integer"
7aacca6f
DM
20721 },
20722 "t" : {
44660702
DM
20723 "description" : "Line text",
20724 "type" : "string"
56122987 20725 }
44660702
DM
20726 },
20727 "type" : "object"
56122987
DM
20728 },
20729 "type" : "array"
7aacca6f 20730 }
56122987
DM
20731 }
20732 },
44660702
DM
20733 "leaf" : 1,
20734 "path" : "/nodes/{node}/firewall/log",
7aacca6f 20735 "text" : "log"
56122987
DM
20736 }
20737 ],
20738 "info" : {
20739 "GET" : {
44660702
DM
20740 "description" : "Directory index.",
20741 "method" : "GET",
20742 "name" : "index",
56122987 20743 "parameters" : {
44660702 20744 "additionalProperties" : 0,
56122987
DM
20745 "properties" : {
20746 "node" : {
20747 "description" : "The cluster node name.",
44660702
DM
20748 "format" : "pve-node",
20749 "type" : "string"
56122987 20750 }
44660702 20751 }
56122987 20752 },
7aacca6f
DM
20753 "permissions" : {
20754 "user" : "all"
20755 },
56122987
DM
20756 "returns" : {
20757 "items" : {
20758 "properties" : {},
20759 "type" : "object"
20760 },
56122987
DM
20761 "links" : [
20762 {
44660702
DM
20763 "href" : "{name}",
20764 "rel" : "child"
56122987 20765 }
44660702
DM
20766 ],
20767 "type" : "array"
20768 }
56122987 20769 }
7aacca6f 20770 },
44660702 20771 "leaf" : 0,
7aacca6f 20772 "path" : "/nodes/{node}/firewall",
44660702 20773 "text" : "firewall"
56122987
DM
20774 },
20775 {
56122987
DM
20776 "info" : {
20777 "GET" : {
44660702
DM
20778 "description" : "API version details",
20779 "method" : "GET",
20780 "name" : "version",
56122987 20781 "parameters" : {
44660702 20782 "additionalProperties" : 0,
56122987
DM
20783 "properties" : {
20784 "node" : {
56122987 20785 "description" : "The cluster node name.",
44660702 20786 "format" : "pve-node",
7aacca6f 20787 "type" : "string"
56122987 20788 }
44660702 20789 }
56122987 20790 },
56122987 20791 "permissions" : {
7aacca6f 20792 "user" : "all"
56122987 20793 },
56122987 20794 "proxyto" : "node",
56122987 20795 "returns" : {
56122987 20796 "properties" : {
44660702 20797 "release" : {
56122987
DM
20798 "type" : "string"
20799 },
44660702 20800 "repoid" : {
7aacca6f
DM
20801 "type" : "string"
20802 },
20803 "version" : {
20804 "type" : "string"
20805 }
44660702
DM
20806 },
20807 "type" : "object"
7aacca6f 20808 }
56122987
DM
20809 }
20810 },
56122987 20811 "leaf" : 1,
44660702
DM
20812 "path" : "/nodes/{node}/version",
20813 "text" : "version"
56122987
DM
20814 },
20815 {
56122987
DM
20816 "info" : {
20817 "GET" : {
7aacca6f 20818 "description" : "Read node status",
44660702 20819 "method" : "GET",
7aacca6f 20820 "name" : "status",
56122987 20821 "parameters" : {
44660702 20822 "additionalProperties" : 0,
56122987
DM
20823 "properties" : {
20824 "node" : {
7aacca6f 20825 "description" : "The cluster node name.",
44660702
DM
20826 "format" : "pve-node",
20827 "type" : "string"
56122987 20828 }
44660702 20829 }
56122987 20830 },
56122987
DM
20831 "permissions" : {
20832 "check" : [
20833 "perm",
20834 "/nodes/{node}",
20835 [
20836 "Sys.Audit"
20837 ]
20838 ]
44660702
DM
20839 },
20840 "proxyto" : "node",
20841 "returns" : {
20842 "properties" : {},
20843 "type" : "object"
7aacca6f
DM
20844 }
20845 },
20846 "POST" : {
44660702
DM
20847 "description" : "Reboot or shutdown a node.",
20848 "method" : "POST",
7aacca6f 20849 "name" : "node_cmd",
56122987 20850 "parameters" : {
44660702 20851 "additionalProperties" : 0,
56122987 20852 "properties" : {
7aacca6f
DM
20853 "command" : {
20854 "description" : "Specify the command.",
56122987 20855 "enum" : [
7aacca6f
DM
20856 "reboot",
20857 "shutdown"
56122987
DM
20858 ],
20859 "type" : "string"
44660702
DM
20860 },
20861 "node" : {
20862 "description" : "The cluster node name.",
20863 "format" : "pve-node",
20864 "type" : "string"
56122987 20865 }
44660702 20866 }
7aacca6f 20867 },
7aacca6f
DM
20868 "permissions" : {
20869 "check" : [
20870 "perm",
20871 "/nodes/{node}",
20872 [
20873 "Sys.PowerMgmt"
20874 ]
20875 ]
20876 },
44660702 20877 "protected" : 1,
7aacca6f 20878 "proxyto" : "node",
7aacca6f
DM
20879 "returns" : {
20880 "type" : "null"
56122987
DM
20881 }
20882 }
20883 },
7aacca6f 20884 "leaf" : 1,
44660702
DM
20885 "path" : "/nodes/{node}/status",
20886 "text" : "status"
56122987
DM
20887 },
20888 {
56122987
DM
20889 "info" : {
20890 "GET" : {
44660702
DM
20891 "description" : "Read tap/vm network device interface counters",
20892 "method" : "GET",
20893 "name" : "netstat",
20894 "parameters" : {
20895 "additionalProperties" : 0,
20896 "properties" : {
20897 "node" : {
20898 "description" : "The cluster node name.",
20899 "format" : "pve-node",
20900 "type" : "string"
20901 }
56122987
DM
20902 }
20903 },
20904 "permissions" : {
20905 "check" : [
20906 "perm",
20907 "/nodes/{node}",
20908 [
7aacca6f 20909 "Sys.Audit"
56122987
DM
20910 ]
20911 ]
20912 },
7aacca6f 20913 "proxyto" : "node",
44660702
DM
20914 "returns" : {
20915 "items" : {
20916 "properties" : {},
20917 "type" : "object"
20918 },
20919 "type" : "array"
20920 }
7aacca6f
DM
20921 }
20922 },
44660702
DM
20923 "leaf" : 1,
20924 "path" : "/nodes/{node}/netstat",
7aacca6f
DM
20925 "text" : "netstat"
20926 },
20927 {
20928 "info" : {
20929 "POST" : {
7aacca6f 20930 "description" : "Execute multiple commands in order.",
7aacca6f 20931 "method" : "POST",
7aacca6f 20932 "name" : "execute",
56122987
DM
20933 "parameters" : {
20934 "additionalProperties" : 0,
20935 "properties" : {
7aacca6f
DM
20936 "commands" : {
20937 "description" : "JSON encoded array of commands.",
56122987
DM
20938 "type" : "string"
20939 },
20940 "node" : {
44660702 20941 "description" : "The cluster node name.",
56122987 20942 "format" : "pve-node",
44660702 20943 "type" : "string"
56122987
DM
20944 }
20945 }
44660702
DM
20946 },
20947 "permissions" : {
20948 "check" : [
20949 "perm",
20950 "/nodes/{node}",
20951 [
20952 "Sys.Audit"
20953 ]
20954 ]
20955 },
20956 "protected" : 1,
20957 "proxyto" : "node",
20958 "returns" : {
20959 "properties" : {},
20960 "type" : "array"
56122987
DM
20961 }
20962 }
20963 },
56122987 20964 "leaf" : 1,
44660702
DM
20965 "path" : "/nodes/{node}/execute",
20966 "text" : "execute"
56122987
DM
20967 },
20968 {
20969 "info" : {
7aacca6f 20970 "GET" : {
44660702
DM
20971 "description" : "Read node RRD statistics (returns PNG)",
20972 "method" : "GET",
7aacca6f 20973 "name" : "rrd",
56122987 20974 "parameters" : {
7aacca6f 20975 "additionalProperties" : 0,
56122987 20976 "properties" : {
44660702
DM
20977 "cf" : {
20978 "description" : "The RRD consolidation function",
20979 "enum" : [
20980 "AVERAGE",
20981 "MAX"
20982 ],
20983 "optional" : 1,
20984 "type" : "string"
20985 },
7aacca6f 20986 "ds" : {
7aacca6f 20987 "description" : "The list of datasources you want to display.",
44660702
DM
20988 "format" : "pve-configid-list",
20989 "type" : "string"
20990 },
20991 "node" : {
20992 "description" : "The cluster node name.",
20993 "format" : "pve-node",
20994 "type" : "string"
7aacca6f
DM
20995 },
20996 "timeframe" : {
20997 "description" : "Specify the time frame you are interested in.",
20998 "enum" : [
20999 "hour",
21000 "day",
21001 "week",
21002 "month",
21003 "year"
21004 ],
21005 "type" : "string"
56122987 21006 }
7aacca6f 21007 }
56122987 21008 },
56122987 21009 "permissions" : {
56122987
DM
21010 "check" : [
21011 "perm",
21012 "/nodes/{node}",
21013 [
7aacca6f 21014 "Sys.Audit"
56122987
DM
21015 ]
21016 ]
21017 },
7aacca6f 21018 "protected" : 1,
56122987 21019 "returns" : {
56122987 21020 "properties" : {
7aacca6f 21021 "filename" : {
56122987
DM
21022 "type" : "string"
21023 }
44660702
DM
21024 },
21025 "type" : "object"
21026 }
56122987
DM
21027 }
21028 },
44660702 21029 "leaf" : 1,
7aacca6f 21030 "path" : "/nodes/{node}/rrd",
44660702 21031 "text" : "rrd"
56122987
DM
21032 },
21033 {
21034 "info" : {
7aacca6f 21035 "GET" : {
44660702
DM
21036 "description" : "Read node RRD statistics",
21037 "method" : "GET",
7aacca6f 21038 "name" : "rrddata",
56122987 21039 "parameters" : {
44660702 21040 "additionalProperties" : 0,
56122987 21041 "properties" : {
7aacca6f 21042 "cf" : {
7aacca6f
DM
21043 "description" : "The RRD consolidation function",
21044 "enum" : [
21045 "AVERAGE",
21046 "MAX"
44660702
DM
21047 ],
21048 "optional" : 1,
21049 "type" : "string"
56122987
DM
21050 },
21051 "node" : {
44660702 21052 "description" : "The cluster node name.",
56122987 21053 "format" : "pve-node",
44660702 21054 "type" : "string"
56122987 21055 },
7aacca6f 21056 "timeframe" : {
7aacca6f
DM
21057 "description" : "Specify the time frame you are interested in.",
21058 "enum" : [
21059 "hour",
21060 "day",
21061 "week",
21062 "month",
21063 "year"
44660702
DM
21064 ],
21065 "type" : "string"
56122987 21066 }
56122987
DM
21067 }
21068 },
56122987
DM
21069 "permissions" : {
21070 "check" : [
21071 "perm",
21072 "/nodes/{node}",
21073 [
44660702 21074 "Sys.Audit"
56122987
DM
21075 ]
21076 ]
7aacca6f 21077 },
44660702 21078 "protected" : 1,
56122987 21079 "returns" : {
7aacca6f 21080 "items" : {
44660702 21081 "properties" : {},
7aacca6f
DM
21082 "type" : "object"
21083 },
21084 "type" : "array"
44660702
DM
21085 }
21086 }
21087 },
21088 "leaf" : 1,
21089 "path" : "/nodes/{node}/rrddata",
21090 "text" : "rrddata"
21091 },
21092 {
21093 "info" : {
21094 "GET" : {
21095 "description" : "Read system log",
21096 "method" : "GET",
21097 "name" : "syslog",
56122987 21098 "parameters" : {
44660702 21099 "additionalProperties" : 0,
56122987 21100 "properties" : {
44660702
DM
21101 "limit" : {
21102 "minimum" : 0,
7aacca6f 21103 "optional" : 1,
4bd7df8b 21104 "type" : "integer",
2c0dde61 21105 "typetext" : "integer (0 - N)"
7aacca6f 21106 },
56122987 21107 "node" : {
7aacca6f 21108 "description" : "The cluster node name.",
44660702
DM
21109 "format" : "pve-node",
21110 "type" : "string"
56122987 21111 },
44660702
DM
21112 "since" : {
21113 "description" : "Display all log since this date-time string.",
21114 "optional" : 1,
21115 "pattern" : "^\\d{4}-\\d{2}-\\d{2}( \\d{2}:\\d{2}(:\\d{2})?)?$",
21116 "type" : "string"
21117 },
21118 "start" : {
7aacca6f
DM
21119 "minimum" : 0,
21120 "optional" : 1,
4bd7df8b 21121 "type" : "integer",
2c0dde61 21122 "typetext" : "integer (0 - N)"
7aacca6f
DM
21123 },
21124 "until" : {
21125 "description" : "Display all log until this date-time string.",
7aacca6f 21126 "optional" : 1,
44660702 21127 "pattern" : "^\\d{4}-\\d{2}-\\d{2}( \\d{2}:\\d{2}(:\\d{2})?)?$",
56122987
DM
21128 "type" : "string"
21129 }
44660702 21130 }
56122987 21131 },
44660702
DM
21132 "permissions" : {
21133 "check" : [
21134 "perm",
21135 "/nodes/{node}",
21136 [
21137 "Sys.Syslog"
21138 ]
21139 ]
21140 },
21141 "protected" : 1,
21142 "proxyto" : "node",
21143 "returns" : {
21144 "items" : {
21145 "properties" : {
21146 "n" : {
21147 "description" : "Line number",
21148 "type" : "integer"
21149 },
21150 "t" : {
21151 "description" : "Line text",
21152 "type" : "string"
21153 }
21154 },
21155 "type" : "object"
21156 },
21157 "type" : "array"
21158 }
56122987
DM
21159 }
21160 },
44660702
DM
21161 "leaf" : 1,
21162 "path" : "/nodes/{node}/syslog",
7aacca6f 21163 "text" : "syslog"
56122987
DM
21164 },
21165 {
56122987
DM
21166 "info" : {
21167 "POST" : {
44660702
DM
21168 "description" : "Creates a VNC Shell proxy.",
21169 "method" : "POST",
21170 "name" : "vncshell",
21171 "parameters" : {
21172 "additionalProperties" : 0,
56122987 21173 "properties" : {
44660702
DM
21174 "node" : {
21175 "description" : "The cluster node name.",
21176 "format" : "pve-node",
7aacca6f
DM
21177 "type" : "string"
21178 },
44660702
DM
21179 "upgrade" : {
21180 "default" : 0,
21181 "description" : "Run 'apt-get dist-upgrade' instead of normal shell.",
21182 "optional" : 1,
21183 "type" : "boolean"
7aacca6f 21184 },
44660702
DM
21185 "websocket" : {
21186 "description" : "use websocket instead of standard vnc.",
21187 "optional" : 1,
21188 "type" : "boolean"
56122987 21189 }
44660702 21190 }
56122987 21191 },
56122987
DM
21192 "permissions" : {
21193 "check" : [
21194 "perm",
7aacca6f 21195 "/nodes/{node}",
56122987 21196 [
7aacca6f 21197 "Sys.Console"
56122987 21198 ]
44660702
DM
21199 ],
21200 "description" : "Restricted to users on realm 'pam'"
56122987 21201 },
44660702
DM
21202 "protected" : 1,
21203 "returns" : {
21204 "additionalProperties" : 0,
56122987 21205 "properties" : {
44660702
DM
21206 "cert" : {
21207 "type" : "string"
7aacca6f 21208 },
44660702
DM
21209 "port" : {
21210 "type" : "integer"
7aacca6f 21211 },
44660702
DM
21212 "ticket" : {
21213 "type" : "string"
21214 },
21215 "upid" : {
21216 "type" : "string"
21217 },
21218 "user" : {
21219 "type" : "string"
56122987 21220 }
44660702
DM
21221 }
21222 }
56122987
DM
21223 }
21224 },
7aacca6f 21225 "leaf" : 1,
44660702
DM
21226 "path" : "/nodes/{node}/vncshell",
21227 "text" : "vncshell"
56122987
DM
21228 },
21229 {
21230 "info" : {
21231 "GET" : {
7aacca6f 21232 "description" : "Opens a weksocket for VNC traffic.",
44660702
DM
21233 "method" : "GET",
21234 "name" : "vncwebsocket",
56122987 21235 "parameters" : {
44660702 21236 "additionalProperties" : 0,
56122987
DM
21237 "properties" : {
21238 "node" : {
21239 "description" : "The cluster node name.",
44660702 21240 "format" : "pve-node",
7aacca6f
DM
21241 "type" : "string"
21242 },
21243 "port" : {
7aacca6f
DM
21244 "description" : "Port number returned by previous vncproxy call.",
21245 "maximum" : 5999,
44660702 21246 "minimum" : 5900,
4bd7df8b 21247 "type" : "integer",
2c0dde61 21248 "typetext" : "integer (5900 - 5999)"
44660702
DM
21249 },
21250 "vncticket" : {
21251 "description" : "Ticket from previous call to vncproxy.",
21252 "maxLength" : 512,
21253 "type" : "string"
56122987 21254 }
44660702 21255 }
56122987 21256 },
56122987
DM
21257 "permissions" : {
21258 "check" : [
21259 "perm",
21260 "/nodes/{node}",
21261 [
7aacca6f 21262 "Sys.Console"
56122987 21263 ]
44660702
DM
21264 ],
21265 "description" : "Restricted to users on realm 'pam'. You also need to pass a valid ticket (vncticket)."
21266 },
21267 "returns" : {
21268 "properties" : {
21269 "port" : {
21270 "type" : "string"
21271 }
21272 },
21273 "type" : "object"
7aacca6f 21274 }
56122987
DM
21275 }
21276 },
44660702 21277 "leaf" : 1,
7aacca6f 21278 "path" : "/nodes/{node}/vncwebsocket",
44660702 21279 "text" : "vncwebsocket"
56122987
DM
21280 },
21281 {
21282 "info" : {
21283 "POST" : {
44660702 21284 "description" : "Creates a SPICE shell.",
7aacca6f 21285 "method" : "POST",
44660702 21286 "name" : "spiceshell",
56122987 21287 "parameters" : {
7aacca6f 21288 "additionalProperties" : 0,
56122987 21289 "properties" : {
7aacca6f 21290 "node" : {
44660702 21291 "description" : "The cluster node name.",
56122987 21292 "format" : "pve-node",
7aacca6f
DM
21293 "type" : "string"
21294 },
44660702
DM
21295 "proxy" : {
21296 "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).",
21297 "format" : "address",
21298 "optional" : 1,
7aacca6f
DM
21299 "type" : "string"
21300 },
44660702
DM
21301 "upgrade" : {
21302 "default" : 0,
21303 "description" : "Run 'apt-get dist-upgrade' instead of normal shell.",
21304 "optional" : 1,
21305 "type" : "boolean"
56122987 21306 }
7aacca6f 21307 }
56122987 21308 },
56122987
DM
21309 "permissions" : {
21310 "check" : [
21311 "perm",
7aacca6f 21312 "/nodes/{node}",
56122987 21313 [
7aacca6f 21314 "Sys.Console"
56122987 21315 ]
7aacca6f
DM
21316 ],
21317 "description" : "Restricted to users on realm 'pam'"
44660702
DM
21318 },
21319 "protected" : 1,
21320 "proxyto" : "node",
21321 "returns" : {
21322 "additionalProperties" : 1,
21323 "description" : "Returned values can be directly passed to the 'remote-viewer' application.",
21324 "properties" : {
21325 "host" : {
21326 "type" : "string"
21327 },
21328 "password" : {
21329 "type" : "string"
21330 },
21331 "proxy" : {
21332 "type" : "string"
21333 },
21334 "tls-port" : {
21335 "type" : "integer"
21336 },
21337 "type" : {
21338 "type" : "string"
21339 }
21340 }
7aacca6f 21341 }
56122987
DM
21342 }
21343 },
56122987 21344 "leaf" : 1,
44660702
DM
21345 "path" : "/nodes/{node}/spiceshell",
21346 "text" : "spiceshell"
56122987
DM
21347 },
21348 {
56122987 21349 "info" : {
7aacca6f 21350 "GET" : {
44660702 21351 "description" : "Read DNS settings.",
7aacca6f 21352 "method" : "GET",
44660702
DM
21353 "name" : "dns",
21354 "parameters" : {
7aacca6f
DM
21355 "additionalProperties" : 0,
21356 "properties" : {
44660702
DM
21357 "node" : {
21358 "description" : "The cluster node name.",
21359 "format" : "pve-node",
21360 "type" : "string"
7aacca6f
DM
21361 }
21362 }
21363 },
7aacca6f
DM
21364 "permissions" : {
21365 "check" : [
21366 "perm",
21367 "/nodes/{node}",
21368 [
21369 "Sys.Audit"
21370 ]
21371 ]
21372 },
44660702
DM
21373 "proxyto" : "node",
21374 "returns" : {
56122987
DM
21375 "additionalProperties" : 0,
21376 "properties" : {
44660702
DM
21377 "dns1" : {
21378 "description" : "First name server IP address.",
21379 "optional" : 1,
21380 "type" : "string"
21381 },
21382 "dns2" : {
21383 "description" : "Second name server IP address.",
21384 "optional" : 1,
21385 "type" : "string"
21386 },
21387 "dns3" : {
21388 "description" : "Third name server IP address.",
21389 "optional" : 1,
21390 "type" : "string"
21391 },
21392 "search" : {
21393 "description" : "Search domain for host-name lookup.",
21394 "optional" : 1,
21395 "type" : "string"
7aacca6f 21396 }
44660702
DM
21397 },
21398 "type" : "object"
21399 }
7aacca6f
DM
21400 },
21401 "PUT" : {
44660702
DM
21402 "description" : "Write DNS settings.",
21403 "method" : "PUT",
7aacca6f
DM
21404 "name" : "update_dns",
21405 "parameters" : {
21406 "additionalProperties" : 0,
21407 "properties" : {
44660702
DM
21408 "dns1" : {
21409 "description" : "First name server IP address.",
21410 "format" : "ip",
21411 "optional" : 1,
7aacca6f
DM
21412 "type" : "string"
21413 },
44660702
DM
21414 "dns2" : {
21415 "description" : "Second name server IP address.",
21416 "format" : "ip",
7aacca6f 21417 "optional" : 1,
44660702 21418 "type" : "string"
7aacca6f 21419 },
44660702
DM
21420 "dns3" : {
21421 "description" : "Third name server IP address.",
21422 "format" : "ip",
7aacca6f 21423 "optional" : 1,
44660702 21424 "type" : "string"
7aacca6f
DM
21425 },
21426 "node" : {
44660702 21427 "description" : "The cluster node name.",
56122987 21428 "format" : "pve-node",
44660702 21429 "type" : "string"
7aacca6f 21430 },
44660702
DM
21431 "search" : {
21432 "description" : "Search domain for host-name lookup.",
21433 "type" : "string"
56122987
DM
21434 }
21435 }
21436 },
21437 "permissions" : {
21438 "check" : [
21439 "perm",
7aacca6f 21440 "/nodes/{node}",
56122987 21441 [
7aacca6f 21442 "Sys.Modify"
56122987
DM
21443 ]
21444 ]
21445 },
44660702 21446 "protected" : 1,
7aacca6f 21447 "proxyto" : "node",
56122987 21448 "returns" : {
7aacca6f
DM
21449 "type" : "null"
21450 }
56122987 21451 }
44660702
DM
21452 },
21453 "leaf" : 1,
21454 "path" : "/nodes/{node}/dns",
21455 "text" : "dns"
56122987
DM
21456 },
21457 {
21458 "info" : {
7aacca6f 21459 "GET" : {
7aacca6f 21460 "description" : "Read server time and time zone settings.",
44660702
DM
21461 "method" : "GET",
21462 "name" : "time",
56122987 21463 "parameters" : {
44660702 21464 "additionalProperties" : 0,
56122987
DM
21465 "properties" : {
21466 "node" : {
44660702 21467 "description" : "The cluster node name.",
56122987 21468 "format" : "pve-node",
44660702 21469 "type" : "string"
56122987 21470 }
44660702 21471 }
56122987
DM
21472 },
21473 "permissions" : {
21474 "check" : [
21475 "perm",
7aacca6f 21476 "/nodes/{node}",
56122987 21477 [
7aacca6f 21478 "Sys.Audit"
56122987
DM
21479 ]
21480 ]
44660702
DM
21481 },
21482 "proxyto" : "node",
21483 "returns" : {
21484 "additionalProperties" : 0,
21485 "properties" : {
21486 "localtime" : {
21487 "description" : "Seconds since 1970-01-01 00:00:00 (local time)",
21488 "minimum" : 1297163644,
21489 "type" : "integer"
21490 },
21491 "time" : {
21492 "description" : "Seconds since 1970-01-01 00:00:00 UTC.",
21493 "minimum" : 1297163644,
21494 "type" : "integer"
21495 },
21496 "timezone" : {
21497 "description" : "Time zone",
21498 "type" : "string"
21499 }
21500 },
21501 "type" : "object"
7aacca6f
DM
21502 }
21503 },
21504 "PUT" : {
7aacca6f 21505 "description" : "Set time zone.",
44660702
DM
21506 "method" : "PUT",
21507 "name" : "set_timezone",
21508 "parameters" : {
21509 "additionalProperties" : 0,
21510 "properties" : {
21511 "node" : {
21512 "description" : "The cluster node name.",
21513 "format" : "pve-node",
21514 "type" : "string"
21515 },
21516 "timezone" : {
21517 "description" : "Time zone. The file '/usr/share/zoneinfo/zone.tab' contains the list of valid names.",
21518 "type" : "string"
21519 }
21520 }
21521 },
7aacca6f
DM
21522 "permissions" : {
21523 "check" : [
21524 "perm",
21525 "/nodes/{node}",
21526 [
21527 "Sys.Modify"
21528 ]
21529 ]
56122987 21530 },
7aacca6f 21531 "protected" : 1,
44660702
DM
21532 "proxyto" : "node",
21533 "returns" : {
21534 "type" : "null"
21535 }
7aacca6f
DM
21536 }
21537 },
7aacca6f 21538 "leaf" : 1,
44660702
DM
21539 "path" : "/nodes/{node}/time",
21540 "text" : "time"
7aacca6f
DM
21541 },
21542 {
21543 "info" : {
44660702
DM
21544 "GET" : {
21545 "description" : "Get list of appliances.",
21546 "method" : "GET",
21547 "name" : "aplinfo",
7aacca6f
DM
21548 "parameters" : {
21549 "additionalProperties" : 0,
21550 "properties" : {
7aacca6f 21551 "node" : {
44660702 21552 "description" : "The cluster node name.",
7aacca6f 21553 "format" : "pve-node",
44660702 21554 "type" : "string"
7aacca6f
DM
21555 }
21556 }
56122987 21557 },
7aacca6f 21558 "permissions" : {
44660702 21559 "user" : "all"
56122987 21560 },
44660702 21561 "proxyto" : "node",
7aacca6f
DM
21562 "returns" : {
21563 "items" : {
44660702
DM
21564 "properties" : {},
21565 "type" : "object"
7aacca6f
DM
21566 },
21567 "type" : "array"
44660702
DM
21568 }
21569 },
21570 "POST" : {
21571 "description" : "Download appliance templates.",
21572 "method" : "POST",
21573 "name" : "apl_download",
7aacca6f
DM
21574 "parameters" : {
21575 "additionalProperties" : 0,
21576 "properties" : {
21577 "node" : {
7aacca6f 21578 "description" : "The cluster node name.",
44660702
DM
21579 "format" : "pve-node",
21580 "type" : "string"
21581 },
21582 "storage" : {
4bd7df8b 21583 "description" : "The storage where the template will be stored",
44660702
DM
21584 "format" : "pve-storage-id",
21585 "type" : "string"
21586 },
21587 "template" : {
21588 "description" : "The template wich will downloaded",
21589 "maxLength" : 255,
7aacca6f
DM
21590 "type" : "string"
21591 }
21592 }
56122987 21593 },
7aacca6f 21594 "permissions" : {
44660702
DM
21595 "check" : [
21596 "perm",
21597 "/storage/{storage}",
21598 [
21599 "Datastore.AllocateTemplate"
21600 ]
21601 ]
21602 },
21603 "protected" : 1,
21604 "proxyto" : "node",
21605 "returns" : {
21606 "type" : "string"
7aacca6f
DM
21607 }
21608 }
21609 },
7aacca6f 21610 "leaf" : 1,
44660702
DM
21611 "path" : "/nodes/{node}/aplinfo",
21612 "text" : "aplinfo"
7aacca6f
DM
21613 },
21614 {
21615 "info" : {
21616 "GET" : {
44660702
DM
21617 "description" : "Gather various systems information about a node",
21618 "method" : "GET",
21619 "name" : "report",
7aacca6f 21620 "parameters" : {
44660702 21621 "additionalProperties" : 0,
7aacca6f
DM
21622 "properties" : {
21623 "node" : {
7aacca6f 21624 "description" : "The cluster node name.",
44660702 21625 "format" : "pve-node",
7aacca6f
DM
21626 "type" : "string"
21627 }
44660702 21628 }
56122987 21629 },
7aacca6f
DM
21630 "permissions" : {
21631 "check" : [
21632 "perm",
21633 "/nodes/{node}",
21634 [
21635 "Sys.Audit"
21636 ]
21637 ]
56122987 21638 },
44660702 21639 "protected" : 1,
7aacca6f
DM
21640 "proxyto" : "node",
21641 "returns" : {
56122987 21642 "type" : "string"
7aacca6f
DM
21643 }
21644 }
21645 },
7aacca6f 21646 "leaf" : 1,
44660702
DM
21647 "path" : "/nodes/{node}/report",
21648 "text" : "report"
7aacca6f
DM
21649 },
21650 {
7aacca6f
DM
21651 "info" : {
21652 "POST" : {
44660702 21653 "description" : "Start all VMs and containers (when onboot=1).",
7aacca6f 21654 "method" : "POST",
44660702 21655 "name" : "startall",
7aacca6f 21656 "parameters" : {
44660702 21657 "additionalProperties" : 0,
7aacca6f
DM
21658 "properties" : {
21659 "force" : {
44660702 21660 "description" : "force if onboot=0.",
7aacca6f 21661 "optional" : 1,
44660702 21662 "type" : "boolean"
7aacca6f
DM
21663 },
21664 "node" : {
7aacca6f 21665 "description" : "The cluster node name.",
44660702
DM
21666 "format" : "pve-node",
21667 "type" : "string"
7aacca6f 21668 }
44660702 21669 }
56122987 21670 },
7aacca6f
DM
21671 "permissions" : {
21672 "check" : [
21673 "perm",
21674 "/",
21675 [
21676 "VM.PowerMgmt"
21677 ]
21678 ]
44660702
DM
21679 },
21680 "protected" : 1,
21681 "proxyto" : "node",
21682 "returns" : {
21683 "type" : "string"
7aacca6f
DM
21684 }
21685 }
21686 },
44660702 21687 "leaf" : 1,
7aacca6f 21688 "path" : "/nodes/{node}/startall",
44660702 21689 "text" : "startall"
7aacca6f
DM
21690 },
21691 {
7aacca6f
DM
21692 "info" : {
21693 "POST" : {
21694 "description" : "Stop all VMs and Containers.",
44660702
DM
21695 "method" : "POST",
21696 "name" : "stopall",
7aacca6f 21697 "parameters" : {
44660702 21698 "additionalProperties" : 0,
7aacca6f
DM
21699 "properties" : {
21700 "node" : {
44660702 21701 "description" : "The cluster node name.",
7aacca6f 21702 "format" : "pve-node",
44660702 21703 "type" : "string"
7aacca6f 21704 }
44660702 21705 }
56122987 21706 },
7aacca6f
DM
21707 "permissions" : {
21708 "check" : [
21709 "perm",
21710 "/",
21711 [
44660702 21712 "VM.PowerMgmt"
7aacca6f
DM
21713 ]
21714 ]
56122987 21715 },
44660702 21716 "protected" : 1,
7aacca6f 21717 "proxyto" : "node",
44660702
DM
21718 "returns" : {
21719 "type" : "string"
21720 }
21721 }
56122987 21722 },
44660702
DM
21723 "leaf" : 1,
21724 "path" : "/nodes/{node}/stopall",
21725 "text" : "stopall"
21726 },
21727 {
21728 "info" : {
21729 "POST" : {
21730 "description" : "Migrate all VMs and Containers.",
21731 "method" : "POST",
21732 "name" : "migrateall",
21733 "parameters" : {
21734 "additionalProperties" : 0,
21735 "properties" : {
21736 "maxworkers" : {
21737 "description" : "Maximal number of parallel migration job. If not set use 'max_workers' from datacenter.cfg, one of both must be set!",
21738 "minimum" : 1,
21739 "optional" : 1,
4bd7df8b 21740 "type" : "integer",
2c0dde61 21741 "typetext" : "integer (1 - N)"
44660702
DM
21742 },
21743 "node" : {
21744 "description" : "The cluster node name.",
21745 "format" : "pve-node",
21746 "type" : "string"
21747 },
21748 "target" : {
21749 "description" : "Target node.",
21750 "format" : "pve-node",
21751 "type" : "string"
21752 }
21753 }
21754 },
21755 "permissions" : {
21756 "check" : [
21757 "perm",
21758 "/",
21759 [
21760 "VM.Migrate"
21761 ]
21762 ]
21763 },
21764 "protected" : 1,
21765 "proxyto" : "node",
21766 "returns" : {
21767 "type" : "string"
21768 }
21769 }
56122987 21770 },
44660702
DM
21771 "leaf" : 1,
21772 "path" : "/nodes/{node}/migrateall",
21773 "text" : "migrateall"
21774 }
21775 ],
21776 "info" : {
21777 "GET" : {
21778 "description" : "Node index.",
21779 "method" : "GET",
21780 "name" : "index",
21781 "parameters" : {
21782 "additionalProperties" : 0,
21783 "properties" : {
21784 "node" : {
21785 "description" : "The cluster node name.",
21786 "format" : "pve-node",
21787 "type" : "string"
21788 }
21789 }
56122987 21790 },
44660702
DM
21791 "permissions" : {
21792 "user" : "all"
56122987 21793 },
44660702
DM
21794 "returns" : {
21795 "items" : {
21796 "properties" : {},
21797 "type" : "object"
21798 },
21799 "links" : [
21800 {
21801 "href" : "{name}",
21802 "rel" : "child"
21803 }
56122987 21804 ],
44660702 21805 "type" : "array"
7aacca6f
DM
21806 }
21807 }
21808 },
44660702
DM
21809 "leaf" : 0,
21810 "path" : "/nodes/{node}",
21811 "text" : "{node}"
21812 }
21813 ],
21814 "info" : {
7aacca6f 21815 "GET" : {
44660702 21816 "description" : "Cluster node index.",
7aacca6f 21817 "method" : "GET",
44660702 21818 "name" : "index",
7aacca6f 21819 "parameters" : {
7aacca6f
DM
21820 "additionalProperties" : 0
21821 },
21822 "permissions" : {
7aacca6f
DM
21823 "user" : "all"
21824 },
44660702
DM
21825 "returns" : {
21826 "items" : {
21827 "properties" : {},
21828 "type" : "object"
21829 },
21830 "links" : [
21831 {
21832 "href" : "{node}",
21833 "rel" : "child"
21834 }
21835 ],
21836 "type" : "array"
21837 }
7aacca6f
DM
21838 }
21839 },
44660702
DM
21840 "leaf" : 0,
21841 "path" : "/nodes",
21842 "text" : "nodes"
21843 },
21844 {
7aacca6f
DM
21845 "children" : [
21846 {
7aacca6f 21847 "info" : {
44660702
DM
21848 "DELETE" : {
21849 "description" : "Delete storage configuration.",
21850 "method" : "DELETE",
21851 "name" : "delete",
7aacca6f
DM
21852 "parameters" : {
21853 "additionalProperties" : 0,
21854 "properties" : {
21855 "storage" : {
7aacca6f 21856 "description" : "The storage identifier.",
44660702 21857 "format" : "pve-storage-id",
7aacca6f
DM
21858 "type" : "string"
21859 }
21860 }
56122987 21861 },
7aacca6f
DM
21862 "permissions" : {
21863 "check" : [
21864 "perm",
21865 "/storage",
21866 [
21867 "Datastore.Allocate"
21868 ]
21869 ]
56122987 21870 },
44660702
DM
21871 "protected" : 1,
21872 "returns" : {
21873 "type" : "null"
21874 }
21875 },
21876 "GET" : {
21877 "description" : "Read storage configuration.",
21878 "method" : "GET",
21879 "name" : "read",
7aacca6f
DM
21880 "parameters" : {
21881 "additionalProperties" : 0,
21882 "properties" : {
21883 "storage" : {
44660702 21884 "description" : "The storage identifier.",
7aacca6f 21885 "format" : "pve-storage-id",
44660702 21886 "type" : "string"
7aacca6f
DM
21887 }
21888 }
21889 },
44660702
DM
21890 "permissions" : {
21891 "check" : [
21892 "perm",
21893 "/storage/{storage}",
21894 [
21895 "Datastore.Allocate"
21896 ]
21897 ]
21898 },
21899 "returns" : {}
7aacca6f
DM
21900 },
21901 "PUT" : {
44660702
DM
21902 "description" : "Update storage configuration.",
21903 "method" : "PUT",
21904 "name" : "update",
21905 "parameters" : {
21906 "additionalProperties" : 0,
21907 "properties" : {
21908 "blocksize" : {
21909 "description" : "block size",
7aacca6f 21910 "optional" : 1,
44660702 21911 "type" : "string"
7aacca6f 21912 },
44660702
DM
21913 "comstar_hg" : {
21914 "description" : "host group for comstar views",
21915 "optional" : 1,
21916 "type" : "string"
7aacca6f 21917 },
44660702
DM
21918 "comstar_tg" : {
21919 "description" : "target group for comstar views",
7aacca6f 21920 "optional" : 1,
44660702 21921 "type" : "string"
7aacca6f 21922 },
44660702
DM
21923 "content" : {
21924 "description" : "Allowed content types.\n\nNOTE: the value 'rootdir' is used for Containers, and value 'images' for VMs.\n",
21925 "format" : "pve-storage-content-list",
7aacca6f 21926 "optional" : 1,
44660702 21927 "type" : "string"
7aacca6f 21928 },
44660702
DM
21929 "delete" : {
21930 "description" : "A list of settings you want to delete.",
21931 "format" : "pve-configid-list",
21932 "maxLength" : 4096,
7aacca6f 21933 "optional" : 1,
44660702 21934 "type" : "string"
7aacca6f
DM
21935 },
21936 "digest" : {
44660702 21937 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
7aacca6f 21938 "maxLength" : 40,
7aacca6f 21939 "optional" : 1,
7aacca6f
DM
21940 "type" : "string"
21941 },
44660702
DM
21942 "disable" : {
21943 "description" : "Flag to disable the storage.",
21944 "optional" : 1,
21945 "type" : "boolean"
7aacca6f
DM
21946 },
21947 "format" : {
21948 "description" : "Default image format.",
44660702 21949 "format" : "pve-storage-format",
7aacca6f 21950 "optional" : 1,
44660702 21951 "type" : "string"
7aacca6f 21952 },
2c0dde61
DM
21953 "is_mountpoint" : {
21954 "default" : "no",
21955 "description" : "Assume the directory is an externally managed mountpoint. If nothing is mounted the storage will be considered offline.",
21956 "optional" : 1,
21957 "type" : "boolean"
21958 },
44660702
DM
21959 "krbd" : {
21960 "description" : "Access rbd through krbd kernel module.",
7aacca6f 21961 "optional" : 1,
44660702 21962 "type" : "boolean"
7aacca6f 21963 },
44660702
DM
21964 "maxfiles" : {
21965 "description" : "Maximal number of backup files per VM. Use '0' for unlimted.",
21966 "minimum" : 0,
21967 "optional" : 1,
4bd7df8b 21968 "type" : "integer",
2c0dde61 21969 "typetext" : "integer (0 - N)"
4bd7df8b
DM
21970 },
21971 "mkdir" : {
21972 "default" : "yes",
21973 "description" : "Create the directory if it doesn't exist.",
21974 "optional" : 1,
21975 "type" : "boolean"
7aacca6f
DM
21976 },
21977 "nodes" : {
44660702 21978 "description" : "List of cluster node names.",
7aacca6f
DM
21979 "format" : "pve-node-list",
21980 "optional" : 1,
44660702 21981 "type" : "string"
7aacca6f 21982 },
44660702
DM
21983 "nowritecache" : {
21984 "description" : "disable write caching on the target",
7aacca6f 21985 "optional" : 1,
44660702 21986 "type" : "boolean"
7aacca6f
DM
21987 },
21988 "options" : {
7aacca6f 21989 "description" : "NFS mount options (see 'man nfs')",
44660702
DM
21990 "format" : "pve-storage-options",
21991 "optional" : 1,
21992 "type" : "string"
21993 },
21994 "pool" : {
21995 "description" : "Pool.",
21996 "optional" : 1,
21997 "type" : "string"
21998 },
21999 "redundancy" : {
22000 "default" : 2,
22001 "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.",
22002 "maximum" : 16,
22003 "minimum" : 1,
22004 "optional" : 1,
4bd7df8b 22005 "type" : "integer",
2c0dde61 22006 "typetext" : "integer (1 - 16)"
44660702
DM
22007 },
22008 "saferemove" : {
22009 "description" : "Zero-out data when removing LVs.",
22010 "optional" : 1,
22011 "type" : "boolean"
7aacca6f
DM
22012 },
22013 "saferemove_throughput" : {
44660702 22014 "description" : "Wipe throughput (cstream -t parameter value).",
7aacca6f 22015 "optional" : 1,
44660702 22016 "type" : "string"
7aacca6f 22017 },
44660702
DM
22018 "server" : {
22019 "description" : "Server IP or DNS name.",
22020 "format" : "pve-storage-server",
7aacca6f 22021 "optional" : 1,
44660702 22022 "type" : "string"
7aacca6f 22023 },
44660702
DM
22024 "server2" : {
22025 "description" : "Backup volfile server IP or DNS name.",
22026 "format" : "pve-storage-server",
7aacca6f 22027 "optional" : 1,
44660702
DM
22028 "requires" : "server",
22029 "type" : "string"
22030 },
22031 "shared" : {
22032 "description" : "Mark storage as shared.",
22033 "optional" : 1,
22034 "type" : "boolean"
22035 },
22036 "sparse" : {
22037 "description" : "use sparse volumes",
22038 "optional" : 1,
22039 "type" : "boolean"
22040 },
22041 "storage" : {
22042 "description" : "The storage identifier.",
22043 "format" : "pve-storage-id",
22044 "type" : "string"
22045 },
4bd7df8b
DM
22046 "tagged_only" : {
22047 "description" : "Only use logical volumes tagged with 'pve-vm-ID'.",
22048 "optional" : 1,
22049 "type" : "boolean"
22050 },
44660702
DM
22051 "transport" : {
22052 "description" : "Gluster transport: tcp or rdma",
22053 "enum" : [
22054 "tcp",
22055 "rdma",
22056 "unix"
22057 ],
22058 "optional" : 1,
22059 "type" : "string"
7aacca6f
DM
22060 },
22061 "username" : {
22062 "description" : "RBD Id.",
44660702
DM
22063 "optional" : 1,
22064 "type" : "string"
7aacca6f 22065 }
44660702
DM
22066 },
22067 "type" : "object"
22068 },
22069 "permissions" : {
22070 "check" : [
22071 "perm",
22072 "/storage",
22073 [
22074 "Datastore.Allocate"
22075 ]
22076 ]
22077 },
22078 "protected" : 1,
22079 "returns" : {
22080 "type" : "null"
22081 }
22082 }
22083 },
22084 "leaf" : 1,
22085 "path" : "/storage/{storage}",
22086 "text" : "{storage}"
22087 }
22088 ],
22089 "info" : {
22090 "GET" : {
22091 "description" : "Storage index.",
22092 "method" : "GET",
22093 "name" : "index",
22094 "parameters" : {
22095 "additionalProperties" : 0,
22096 "properties" : {
22097 "type" : {
22098 "description" : "Only list storage of specific type",
22099 "enum" : [
22100 "dir",
22101 "drbd",
22102 "glusterfs",
22103 "iscsi",
22104 "iscsidirect",
22105 "lvm",
22106 "lvmthin",
22107 "nfs",
22108 "rbd",
22109 "sheepdog",
22110 "zfs",
22111 "zfspool"
22112 ],
22113 "optional" : 1,
22114 "type" : "string"
22115 }
22116 }
22117 },
22118 "permissions" : {
22119 "description" : "Only list entries where you have 'Datastore.Audit' or 'Datastore.AllocateSpace' permissions on '/storage/<storage>'",
22120 "user" : "all"
22121 },
22122 "returns" : {
22123 "items" : {
22124 "properties" : {
22125 "storage" : {
22126 "type" : "string"
7aacca6f 22127 }
56122987 22128 },
44660702
DM
22129 "type" : "object"
22130 },
22131 "links" : [
22132 {
22133 "href" : "{storage}",
22134 "rel" : "child"
22135 }
22136 ],
22137 "type" : "array"
22138 }
22139 },
22140 "POST" : {
22141 "description" : "Create a new storage.",
22142 "method" : "POST",
22143 "name" : "create",
22144 "parameters" : {
22145 "additionalProperties" : 0,
22146 "properties" : {
22147 "authsupported" : {
22148 "description" : "Authsupported.",
22149 "optional" : 1,
22150 "type" : "string"
22151 },
22152 "base" : {
22153 "description" : "Base volume. This volume is automatically activated.",
22154 "format" : "pve-volume-id",
22155 "optional" : 1,
22156 "type" : "string"
22157 },
22158 "blocksize" : {
22159 "description" : "block size",
22160 "optional" : 1,
22161 "type" : "string"
22162 },
22163 "comstar_hg" : {
22164 "description" : "host group for comstar views",
22165 "optional" : 1,
22166 "type" : "string"
22167 },
22168 "comstar_tg" : {
22169 "description" : "target group for comstar views",
22170 "optional" : 1,
22171 "type" : "string"
22172 },
22173 "content" : {
22174 "description" : "Allowed content types.\n\nNOTE: the value 'rootdir' is used for Containers, and value 'images' for VMs.\n",
22175 "format" : "pve-storage-content-list",
22176 "optional" : 1,
22177 "type" : "string"
22178 },
22179 "disable" : {
22180 "description" : "Flag to disable the storage.",
22181 "optional" : 1,
22182 "type" : "boolean"
22183 },
22184 "export" : {
22185 "description" : "NFS export path.",
22186 "format" : "pve-storage-path",
22187 "optional" : 1,
22188 "type" : "string"
22189 },
22190 "format" : {
22191 "description" : "Default image format.",
22192 "format" : "pve-storage-format",
22193 "optional" : 1,
22194 "type" : "string"
22195 },
2c0dde61
DM
22196 "is_mountpoint" : {
22197 "default" : "no",
22198 "description" : "Assume the directory is an externally managed mountpoint. If nothing is mounted the storage will be considered offline.",
22199 "optional" : 1,
22200 "type" : "boolean"
22201 },
44660702
DM
22202 "iscsiprovider" : {
22203 "description" : "iscsi provider",
22204 "optional" : 1,
22205 "type" : "string"
22206 },
22207 "krbd" : {
22208 "description" : "Access rbd through krbd kernel module.",
22209 "optional" : 1,
22210 "type" : "boolean"
56122987 22211 },
44660702
DM
22212 "maxfiles" : {
22213 "description" : "Maximal number of backup files per VM. Use '0' for unlimted.",
22214 "minimum" : 0,
22215 "optional" : 1,
4bd7df8b 22216 "type" : "integer",
2c0dde61 22217 "typetext" : "integer (0 - N)"
4bd7df8b
DM
22218 },
22219 "mkdir" : {
22220 "default" : "yes",
22221 "description" : "Create the directory if it doesn't exist.",
22222 "optional" : 1,
22223 "type" : "boolean"
7aacca6f 22224 },
44660702
DM
22225 "monhost" : {
22226 "description" : "Monitors daemon ips.",
4bd7df8b 22227 "format" : "pve-storage-portal-dns-list",
44660702
DM
22228 "optional" : 1,
22229 "type" : "string"
7aacca6f 22230 },
44660702
DM
22231 "nodes" : {
22232 "description" : "List of cluster node names.",
22233 "format" : "pve-node-list",
22234 "optional" : 1,
22235 "type" : "string"
7aacca6f 22236 },
44660702
DM
22237 "nowritecache" : {
22238 "description" : "disable write caching on the target",
22239 "optional" : 1,
22240 "type" : "boolean"
22241 },
22242 "options" : {
22243 "description" : "NFS mount options (see 'man nfs')",
22244 "format" : "pve-storage-options",
22245 "optional" : 1,
22246 "type" : "string"
22247 },
22248 "path" : {
22249 "description" : "File system path.",
22250 "format" : "pve-storage-path",
22251 "optional" : 1,
22252 "type" : "string"
22253 },
22254 "pool" : {
22255 "description" : "Pool.",
22256 "optional" : 1,
22257 "type" : "string"
22258 },
22259 "portal" : {
22260 "description" : "iSCSI portal (IP or DNS name with optional port).",
22261 "format" : "pve-storage-portal-dns",
22262 "optional" : 1,
22263 "type" : "string"
22264 },
22265 "redundancy" : {
22266 "default" : 2,
22267 "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.",
22268 "maximum" : 16,
22269 "minimum" : 1,
22270 "optional" : 1,
4bd7df8b 22271 "type" : "integer",
2c0dde61 22272 "typetext" : "integer (1 - 16)"
44660702
DM
22273 },
22274 "saferemove" : {
22275 "description" : "Zero-out data when removing LVs.",
22276 "optional" : 1,
22277 "type" : "boolean"
22278 },
22279 "saferemove_throughput" : {
22280 "description" : "Wipe throughput (cstream -t parameter value).",
22281 "optional" : 1,
22282 "type" : "string"
22283 },
22284 "server" : {
22285 "description" : "Server IP or DNS name.",
22286 "format" : "pve-storage-server",
22287 "optional" : 1,
22288 "type" : "string"
22289 },
22290 "server2" : {
22291 "description" : "Backup volfile server IP or DNS name.",
22292 "format" : "pve-storage-server",
22293 "optional" : 1,
22294 "requires" : "server",
22295 "type" : "string"
22296 },
22297 "shared" : {
22298 "description" : "Mark storage as shared.",
22299 "optional" : 1,
22300 "type" : "boolean"
22301 },
22302 "sparse" : {
22303 "description" : "use sparse volumes",
22304 "optional" : 1,
22305 "type" : "boolean"
22306 },
22307 "storage" : {
22308 "description" : "The storage identifier.",
22309 "format" : "pve-storage-id",
22310 "type" : "string"
22311 },
4bd7df8b
DM
22312 "tagged_only" : {
22313 "description" : "Only use logical volumes tagged with 'pve-vm-ID'.",
22314 "optional" : 1,
22315 "type" : "boolean"
22316 },
44660702
DM
22317 "target" : {
22318 "description" : "iSCSI target.",
22319 "optional" : 1,
22320 "type" : "string"
22321 },
22322 "thinpool" : {
22323 "description" : "LVM thin pool LV name.",
22324 "format" : "pve-storage-vgname",
22325 "optional" : 1,
22326 "type" : "string"
22327 },
22328 "transport" : {
22329 "description" : "Gluster transport: tcp or rdma",
22330 "enum" : [
22331 "tcp",
22332 "rdma",
22333 "unix"
7aacca6f 22334 ],
44660702
DM
22335 "optional" : 1,
22336 "type" : "string"
56122987 22337 },
44660702
DM
22338 "type" : {
22339 "description" : "Storage type.",
22340 "enum" : [
22341 "dir",
22342 "drbd",
22343 "glusterfs",
22344 "iscsi",
22345 "iscsidirect",
22346 "lvm",
22347 "lvmthin",
22348 "nfs",
22349 "rbd",
22350 "sheepdog",
22351 "zfs",
22352 "zfspool"
22353 ],
22354 "type" : "string"
56122987 22355 },
44660702
DM
22356 "username" : {
22357 "description" : "RBD Id.",
22358 "optional" : 1,
22359 "type" : "string"
7aacca6f 22360 },
44660702
DM
22361 "vgname" : {
22362 "description" : "Volume group name.",
22363 "format" : "pve-storage-vgname",
22364 "optional" : 1,
22365 "type" : "string"
22366 },
22367 "volume" : {
22368 "description" : "Glusterfs Volume.",
22369 "optional" : 1,
22370 "type" : "string"
22371 }
22372 },
22373 "type" : "object"
22374 },
22375 "permissions" : {
22376 "check" : [
22377 "perm",
22378 "/storage",
22379 [
22380 "Datastore.Allocate"
22381 ]
22382 ]
56122987 22383 },
44660702
DM
22384 "protected" : 1,
22385 "returns" : {
22386 "type" : "null"
22387 }
22388 }
22389 },
22390 "leaf" : 0,
22391 "path" : "/storage",
22392 "text" : "storage"
22393 },
22394 {
22395 "children" : [
22396 {
56122987
DM
22397 "children" : [
22398 {
56122987 22399 "info" : {
44660702
DM
22400 "DELETE" : {
22401 "description" : "Delete user.",
22402 "method" : "DELETE",
22403 "name" : "delete_user",
56122987 22404 "parameters" : {
7aacca6f 22405 "additionalProperties" : 0,
56122987 22406 "properties" : {
56122987 22407 "userid" : {
56122987
DM
22408 "description" : "User ID",
22409 "format" : "pve-userid",
44660702 22410 "maxLength" : 64,
56122987
DM
22411 "type" : "string"
22412 }
7aacca6f 22413 }
56122987 22414 },
56122987
DM
22415 "permissions" : {
22416 "check" : [
44660702 22417 "and",
56122987 22418 [
44660702
DM
22419 "userid-param",
22420 "Realm.AllocateUser"
56122987 22421 ],
44660702
DM
22422 [
22423 "userid-group",
22424 [
22425 "User.Modify"
22426 ]
22427 ]
56122987 22428 ]
7aacca6f 22429 },
44660702 22430 "protected" : 1,
56122987
DM
22431 "returns" : {
22432 "type" : "null"
44660702 22433 }
7aacca6f 22434 },
44660702
DM
22435 "GET" : {
22436 "description" : "Get user configuration.",
22437 "method" : "GET",
22438 "name" : "read_user",
56122987
DM
22439 "parameters" : {
22440 "additionalProperties" : 0,
22441 "properties" : {
22442 "userid" : {
44660702 22443 "description" : "User ID",
56122987 22444 "format" : "pve-userid",
44660702
DM
22445 "maxLength" : 64,
22446 "type" : "string"
56122987
DM
22447 }
22448 }
22449 },
56122987
DM
22450 "permissions" : {
22451 "check" : [
44660702 22452 "userid-group",
56122987 22453 [
44660702
DM
22454 "User.Modify",
22455 "Sys.Audit"
56122987
DM
22456 ]
22457 ]
22458 },
56122987 22459 "returns" : {
7aacca6f 22460 "additionalProperties" : 0,
56122987 22461 "properties" : {
44660702
DM
22462 "comment" : {
22463 "optional" : 1,
22464 "type" : "string"
56122987 22465 },
44660702
DM
22466 "email" : {
22467 "optional" : 1,
22468 "type" : "string"
7aacca6f
DM
22469 },
22470 "enable" : {
22471 "type" : "boolean"
22472 },
44660702
DM
22473 "expire" : {
22474 "optional" : 1,
22475 "type" : "integer"
22476 },
22477 "firstname" : {
56122987
DM
22478 "optional" : 1,
22479 "type" : "string"
22480 },
44660702
DM
22481 "groups" : {
22482 "type" : "array"
56122987 22483 },
44660702
DM
22484 "keys" : {
22485 "optional" : 1,
22486 "type" : "string"
7aacca6f 22487 },
44660702
DM
22488 "lastname" : {
22489 "optional" : 1,
22490 "type" : "string"
56122987 22491 }
7aacca6f 22492 }
44660702
DM
22493 }
22494 },
22495 "PUT" : {
22496 "description" : "Update user configuration.",
22497 "method" : "PUT",
22498 "name" : "update_user",
56122987 22499 "parameters" : {
44660702 22500 "additionalProperties" : 0,
56122987 22501 "properties" : {
44660702
DM
22502 "append" : {
22503 "optional" : 1,
22504 "requires" : "groups",
22505 "type" : "boolean"
22506 },
22507 "comment" : {
22508 "optional" : 1,
22509 "type" : "string"
22510 },
22511 "email" : {
22512 "format" : "email-opt",
22513 "optional" : 1,
22514 "type" : "string"
22515 },
22516 "enable" : {
22517 "description" : "Enable/disable the account.",
22518 "optional" : 1,
22519 "type" : "boolean"
22520 },
22521 "expire" : {
22522 "description" : "Account expiration date (seconds since epoch). '0' means no expiration date.",
22523 "minimum" : 0,
22524 "optional" : 1,
4bd7df8b 22525 "type" : "integer",
2c0dde61 22526 "typetext" : "integer (0 - N)"
44660702
DM
22527 },
22528 "firstname" : {
22529 "optional" : 1,
22530 "type" : "string"
22531 },
22532 "groups" : {
22533 "format" : "pve-groupid-list",
22534 "optional" : 1,
22535 "type" : "string"
22536 },
22537 "keys" : {
22538 "description" : "Keys for two factor auth (yubico).",
22539 "optional" : 1,
22540 "type" : "string"
22541 },
22542 "lastname" : {
22543 "optional" : 1,
22544 "type" : "string"
22545 },
56122987 22546 "userid" : {
56122987
DM
22547 "description" : "User ID",
22548 "format" : "pve-userid",
44660702
DM
22549 "maxLength" : 64,
22550 "type" : "string"
56122987 22551 }
44660702 22552 }
56122987 22553 },
56122987
DM
22554 "permissions" : {
22555 "check" : [
22556 "userid-group",
22557 [
44660702
DM
22558 "User.Modify"
22559 ],
22560 "groups_param",
22561 1
56122987
DM
22562 ]
22563 },
44660702
DM
22564 "protected" : 1,
22565 "returns" : {
22566 "type" : "null"
22567 }
56122987
DM
22568 }
22569 },
44660702
DM
22570 "leaf" : 1,
22571 "path" : "/access/users/{userid}",
7aacca6f 22572 "text" : "{userid}"
56122987 22573 }
7aacca6f 22574 ],
56122987 22575 "info" : {
7aacca6f 22576 "GET" : {
44660702
DM
22577 "description" : "User index.",
22578 "method" : "GET",
7aacca6f 22579 "name" : "index",
56122987 22580 "parameters" : {
44660702
DM
22581 "additionalProperties" : 0,
22582 "properties" : {
22583 "enabled" : {
22584 "description" : "Optional filter for enable property.",
22585 "optional" : 1,
22586 "type" : "boolean"
22587 }
22588 }
22589 },
22590 "permissions" : {
22591 "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.",
22592 "user" : "all"
56122987 22593 },
7aacca6f 22594 "returns" : {
7aacca6f
DM
22595 "items" : {
22596 "properties" : {
44660702 22597 "userid" : {
7aacca6f
DM
22598 "type" : "string"
22599 }
22600 },
22601 "type" : "object"
22602 },
44660702
DM
22603 "links" : [
22604 {
22605 "href" : "{userid}",
22606 "rel" : "child"
22607 }
22608 ],
7aacca6f
DM
22609 "type" : "array"
22610 }
22611 },
22612 "POST" : {
44660702 22613 "description" : "Create new user.",
7aacca6f 22614 "method" : "POST",
44660702 22615 "name" : "create_user",
56122987 22616 "parameters" : {
7aacca6f
DM
22617 "additionalProperties" : 0,
22618 "properties" : {
44660702
DM
22619 "comment" : {
22620 "optional" : 1,
7aacca6f
DM
22621 "type" : "string"
22622 },
44660702
DM
22623 "email" : {
22624 "format" : "email-opt",
22625 "optional" : 1,
22626 "type" : "string"
22627 },
22628 "enable" : {
22629 "default" : 1,
22630 "description" : "Enable the account (default). You can set this to '0' to disable the accout",
22631 "optional" : 1,
22632 "type" : "boolean"
22633 },
22634 "expire" : {
22635 "description" : "Account expiration date (seconds since epoch). '0' means no expiration date.",
22636 "minimum" : 0,
22637 "optional" : 1,
4bd7df8b 22638 "type" : "integer",
2c0dde61 22639 "typetext" : "integer (0 - N)"
44660702
DM
22640 },
22641 "firstname" : {
22642 "optional" : 1,
22643 "type" : "string"
22644 },
22645 "groups" : {
22646 "format" : "pve-groupid-list",
22647 "optional" : 1,
22648 "type" : "string"
22649 },
22650 "keys" : {
22651 "description" : "Keys for two factor auth (yubico).",
22652 "optional" : 1,
22653 "type" : "string"
22654 },
22655 "lastname" : {
7aacca6f
DM
22656 "optional" : 1,
22657 "type" : "string"
44660702
DM
22658 },
22659 "password" : {
22660 "description" : "Initial password.",
22661 "maxLength" : 64,
22662 "minLength" : 5,
22663 "optional" : 1,
22664 "type" : "string"
22665 },
22666 "userid" : {
22667 "description" : "User ID",
22668 "format" : "pve-userid",
22669 "maxLength" : 64,
22670 "type" : "string"
56122987 22671 }
7aacca6f 22672 }
56122987 22673 },
44660702
DM
22674 "permissions" : {
22675 "check" : [
22676 "and",
22677 [
22678 "userid-param",
22679 "Realm.AllocateUser"
22680 ],
22681 [
22682 "userid-group",
22683 [
22684 "User.Modify"
22685 ],
22686 "groups_param",
22687 1
22688 ]
22689 ],
22690 "description" : "You need 'Realm.AllocateUser' on '/access/realm/<realm>' on the realm of user <userid>, and 'User.Modify' permissions to '/access/groups/<group>' for any group specified (or 'User.Modify' on '/access/groups' if you pass no groups."
22691 },
22692 "protected" : 1,
22693 "returns" : {
22694 "type" : "null"
22695 }
56122987
DM
22696 }
22697 },
44660702
DM
22698 "leaf" : 0,
22699 "path" : "/access/users",
22700 "text" : "users"
22701 },
22702 {
56122987
DM
22703 "children" : [
22704 {
56122987
DM
22705 "info" : {
22706 "DELETE" : {
44660702
DM
22707 "description" : "Delete group.",
22708 "method" : "DELETE",
22709 "name" : "delete_group",
22710 "parameters" : {
22711 "additionalProperties" : 0,
22712 "properties" : {
22713 "groupid" : {
22714 "format" : "pve-groupid",
22715 "type" : "string"
22716 }
22717 }
22718 },
7aacca6f
DM
22719 "permissions" : {
22720 "check" : [
22721 "perm",
22722 "/access/groups",
22723 [
22724 "Group.Allocate"
22725 ]
22726 ]
22727 },
7aacca6f 22728 "protected" : 1,
7aacca6f
DM
22729 "returns" : {
22730 "type" : "null"
44660702 22731 }
7aacca6f 22732 },
44660702
DM
22733 "GET" : {
22734 "description" : "Get group configuration.",
22735 "method" : "GET",
22736 "name" : "read_group",
22737 "parameters" : {
22738 "additionalProperties" : 0,
22739 "properties" : {
22740 "groupid" : {
22741 "format" : "pve-groupid",
22742 "type" : "string"
22743 }
22744 }
56122987 22745 },
7aacca6f
DM
22746 "permissions" : {
22747 "check" : [
22748 "perm",
22749 "/access/groups",
22750 [
44660702 22751 "Sys.Audit",
7aacca6f 22752 "Group.Allocate"
44660702
DM
22753 ],
22754 "any",
22755 1
7aacca6f
DM
22756 ]
22757 },
7aacca6f 22758 "returns" : {
44660702 22759 "additionalProperties" : 0,
7aacca6f
DM
22760 "properties" : {
22761 "comment" : {
44660702
DM
22762 "optional" : 1,
22763 "type" : "string"
7aacca6f
DM
22764 },
22765 "members" : {
22766 "items" : {
22767 "type" : "string"
22768 },
22769 "type" : "array"
22770 }
22771 },
44660702
DM
22772 "type" : "object"
22773 }
22774 },
22775 "PUT" : {
22776 "description" : "Update group data.",
22777 "method" : "PUT",
22778 "name" : "update_group",
56122987 22779 "parameters" : {
44660702 22780 "additionalProperties" : 0,
56122987 22781 "properties" : {
44660702
DM
22782 "comment" : {
22783 "optional" : 1,
22784 "type" : "string"
22785 },
56122987
DM
22786 "groupid" : {
22787 "format" : "pve-groupid",
22788 "type" : "string"
22789 }
44660702 22790 }
56122987 22791 },
56122987
DM
22792 "permissions" : {
22793 "check" : [
22794 "perm",
22795 "/access/groups",
22796 [
22797 "Group.Allocate"
44660702 22798 ]
56122987
DM
22799 ]
22800 },
44660702
DM
22801 "protected" : 1,
22802 "returns" : {
22803 "type" : "null"
22804 }
7aacca6f
DM
22805 }
22806 },
7aacca6f 22807 "leaf" : 1,
44660702
DM
22808 "path" : "/access/groups/{groupid}",
22809 "text" : "{groupid}"
22810 }
22811 ],
22812 "info" : {
22813 "GET" : {
22814 "description" : "Group index.",
22815 "method" : "GET",
22816 "name" : "index",
22817 "parameters" : {
22818 "additionalProperties" : 0
22819 },
22820 "permissions" : {
22821 "description" : "The returned list is restricted to groups where you have 'User.Modify', 'Sys.Audit' or 'Group.Allocate' permissions on /access/groups/<group>.",
22822 "user" : "all"
22823 },
22824 "returns" : {
22825 "items" : {
22826 "properties" : {
22827 "groupid" : {
22828 "type" : "string"
22829 }
22830 },
22831 "type" : "object"
22832 },
22833 "links" : [
22834 {
22835 "href" : "{groupid}",
22836 "rel" : "child"
22837 }
22838 ],
22839 "type" : "array"
22840 }
22841 },
22842 "POST" : {
22843 "description" : "Create new group.",
22844 "method" : "POST",
22845 "name" : "create_group",
22846 "parameters" : {
22847 "additionalProperties" : 0,
22848 "properties" : {
22849 "comment" : {
22850 "optional" : 1,
22851 "type" : "string"
22852 },
22853 "groupid" : {
22854 "format" : "pve-groupid",
22855 "type" : "string"
22856 }
22857 }
22858 },
22859 "permissions" : {
22860 "check" : [
22861 "perm",
22862 "/access/groups",
22863 [
22864 "Group.Allocate"
22865 ]
22866 ]
22867 },
22868 "protected" : 1,
22869 "returns" : {
22870 "type" : "null"
22871 }
7aacca6f 22872 }
44660702 22873 },
7aacca6f 22874 "leaf" : 0,
44660702
DM
22875 "path" : "/access/groups",
22876 "text" : "groups"
7aacca6f
DM
22877 },
22878 {
22879 "children" : [
22880 {
7aacca6f 22881 "info" : {
7aacca6f 22882 "DELETE" : {
7aacca6f 22883 "description" : "Delete role.",
44660702 22884 "method" : "DELETE",
7aacca6f 22885 "name" : "delete_role",
56122987
DM
22886 "parameters" : {
22887 "additionalProperties" : 0,
22888 "properties" : {
7aacca6f
DM
22889 "roleid" : {
22890 "format" : "pve-roleid",
22891 "type" : "string"
56122987
DM
22892 }
22893 }
22894 },
56122987
DM
22895 "permissions" : {
22896 "check" : [
22897 "perm",
7aacca6f 22898 "/access",
56122987 22899 [
7aacca6f
DM
22900 "Sys.Modify"
22901 ]
56122987 22902 ]
44660702
DM
22903 },
22904 "protected" : 1,
22905 "returns" : {
22906 "type" : "null"
56122987
DM
22907 }
22908 },
44660702
DM
22909 "GET" : {
22910 "description" : "Get role configuration.",
22911 "method" : "GET",
22912 "name" : "read_role",
22913 "parameters" : {
22914 "additionalProperties" : 0,
22915 "properties" : {
22916 "roleid" : {
22917 "format" : "pve-roleid",
22918 "type" : "string"
22919 }
22920 }
22921 },
7aacca6f 22922 "permissions" : {
44660702 22923 "user" : "all"
56122987 22924 },
44660702
DM
22925 "returns" : {}
22926 },
22927 "PUT" : {
22928 "description" : "Create new role.",
22929 "method" : "PUT",
22930 "name" : "update_role",
56122987
DM
22931 "parameters" : {
22932 "additionalProperties" : 0,
22933 "properties" : {
7aacca6f 22934 "append" : {
44660702 22935 "optional" : 1,
7aacca6f 22936 "requires" : "privs",
44660702 22937 "type" : "boolean"
7aacca6f
DM
22938 },
22939 "privs" : {
22940 "format" : "pve-priv-list",
56122987 22941 "type" : "string"
44660702
DM
22942 },
22943 "roleid" : {
22944 "format" : "pve-roleid",
22945 "type" : "string"
56122987
DM
22946 }
22947 }
22948 },
44660702
DM
22949 "permissions" : {
22950 "check" : [
22951 "perm",
22952 "/access",
22953 [
22954 "Sys.Modify"
22955 ]
22956 ]
22957 },
56122987 22958 "protected" : 1,
7aacca6f
DM
22959 "returns" : {
22960 "type" : "null"
56122987
DM
22961 }
22962 }
22963 },
44660702 22964 "leaf" : 1,
7aacca6f 22965 "path" : "/access/roles/{roleid}",
44660702 22966 "text" : "{roleid}"
56122987
DM
22967 }
22968 ],
56122987 22969 "info" : {
7aacca6f
DM
22970 "GET" : {
22971 "description" : "Role index.",
44660702 22972 "method" : "GET",
7aacca6f 22973 "name" : "index",
56122987 22974 "parameters" : {
56122987
DM
22975 "additionalProperties" : 0
22976 },
7aacca6f
DM
22977 "permissions" : {
22978 "user" : "all"
22979 },
56122987 22980 "returns" : {
7aacca6f 22981 "items" : {
7aacca6f
DM
22982 "properties" : {
22983 "roleid" : {
22984 "type" : "string"
22985 }
44660702
DM
22986 },
22987 "type" : "object"
22988 },
22989 "links" : [
22990 {
22991 "href" : "{roleid}",
22992 "rel" : "child"
7aacca6f 22993 }
44660702
DM
22994 ],
22995 "type" : "array"
22996 }
7aacca6f
DM
22997 },
22998 "POST" : {
22999 "description" : "Create new role.",
44660702
DM
23000 "method" : "POST",
23001 "name" : "create_role",
7aacca6f
DM
23002 "parameters" : {
23003 "additionalProperties" : 0,
23004 "properties" : {
7aacca6f
DM
23005 "privs" : {
23006 "format" : "pve-priv-list",
23007 "optional" : 1,
23008 "type" : "string"
44660702
DM
23009 },
23010 "roleid" : {
23011 "format" : "pve-roleid",
23012 "type" : "string"
7aacca6f
DM
23013 }
23014 }
23015 },
44660702
DM
23016 "permissions" : {
23017 "check" : [
23018 "perm",
23019 "/access",
23020 [
23021 "Sys.Modify"
23022 ]
23023 ]
23024 },
23025 "protected" : 1,
7aacca6f
DM
23026 "returns" : {
23027 "type" : "null"
23028 }
23029 }
23030 },
44660702 23031 "leaf" : 0,
7aacca6f 23032 "path" : "/access/roles",
44660702 23033 "text" : "roles"
7aacca6f
DM
23034 },
23035 {
23036 "info" : {
56122987 23037 "GET" : {
44660702
DM
23038 "description" : "Get Access Control List (ACLs).",
23039 "method" : "GET",
23040 "name" : "read_acl",
7aacca6f
DM
23041 "parameters" : {
23042 "additionalProperties" : 0
23043 },
44660702
DM
23044 "permissions" : {
23045 "description" : "The returned list is restricted to objects where you have rights to modify permissions.",
23046 "user" : "all"
23047 },
56122987 23048 "returns" : {
56122987 23049 "items" : {
44660702 23050 "additionalProperties" : 0,
56122987 23051 "properties" : {
7aacca6f
DM
23052 "path" : {
23053 "type" : "string"
23054 },
44660702
DM
23055 "propagate" : {
23056 "type" : "boolean"
23057 },
23058 "roleid" : {
23059 "type" : "string"
23060 },
7aacca6f
DM
23061 "type" : {
23062 "enum" : [
23063 "user",
23064 "group"
23065 ],
23066 "type" : "string"
23067 },
7aacca6f
DM
23068 "ugid" : {
23069 "type" : "string"
56122987 23070 }
7aacca6f 23071 },
44660702 23072 "type" : "object"
7aacca6f
DM
23073 },
23074 "type" : "array"
44660702 23075 }
7aacca6f
DM
23076 },
23077 "PUT" : {
44660702
DM
23078 "description" : "Update Access Control List (add or remove permissions).",
23079 "method" : "PUT",
7aacca6f
DM
23080 "name" : "update_acl",
23081 "parameters" : {
23082 "additionalProperties" : 0,
23083 "properties" : {
23084 "delete" : {
44660702 23085 "description" : "Remove permissions (instead of adding it).",
7aacca6f 23086 "optional" : 1,
44660702 23087 "type" : "boolean"
7aacca6f 23088 },
44660702
DM
23089 "groups" : {
23090 "description" : "List of groups.",
23091 "format" : "pve-groupid-list",
7aacca6f 23092 "optional" : 1,
44660702 23093 "type" : "string"
7aacca6f
DM
23094 },
23095 "path" : {
23096 "description" : "Access control path",
23097 "type" : "string"
23098 },
7aacca6f 23099 "propagate" : {
44660702 23100 "default" : 1,
7aacca6f 23101 "description" : "Allow to propagate (inherit) permissions.",
7aacca6f 23102 "optional" : 1,
44660702 23103 "type" : "boolean"
7aacca6f 23104 },
44660702
DM
23105 "roles" : {
23106 "description" : "List of roles.",
23107 "format" : "pve-roleid-list",
23108 "type" : "string"
23109 },
23110 "users" : {
23111 "description" : "List of users.",
23112 "format" : "pve-userid-list",
7aacca6f 23113 "optional" : 1,
44660702 23114 "type" : "string"
56122987
DM
23115 }
23116 }
23117 },
56122987 23118 "permissions" : {
7aacca6f
DM
23119 "check" : [
23120 "perm-modify",
23121 "{path}"
23122 ]
23123 },
7aacca6f
DM
23124 "protected" : 1,
23125 "returns" : {
23126 "type" : "null"
44660702 23127 }
56122987
DM
23128 }
23129 },
7aacca6f 23130 "leaf" : 1,
44660702
DM
23131 "path" : "/access/acl",
23132 "text" : "acl"
7aacca6f
DM
23133 },
23134 {
56122987
DM
23135 "children" : [
23136 {
56122987 23137 "info" : {
44660702
DM
23138 "DELETE" : {
23139 "description" : "Delete an authentication server.",
23140 "method" : "DELETE",
23141 "name" : "delete",
23142 "parameters" : {
23143 "additionalProperties" : 0,
23144 "properties" : {
23145 "realm" : {
23146 "description" : "Authentication domain ID",
23147 "format" : "pve-realm",
23148 "maxLength" : 32,
23149 "type" : "string"
56122987 23150 }
44660702 23151 }
56122987 23152 },
56122987
DM
23153 "permissions" : {
23154 "check" : [
23155 "perm",
7aacca6f 23156 "/access/realm",
56122987 23157 [
7aacca6f 23158 "Realm.Allocate"
56122987
DM
23159 ]
23160 ]
23161 },
7aacca6f 23162 "protected" : 1,
7aacca6f
DM
23163 "returns" : {
23164 "type" : "null"
44660702 23165 }
7aacca6f 23166 },
44660702
DM
23167 "GET" : {
23168 "description" : "Get auth server configuration.",
23169 "method" : "GET",
23170 "name" : "read",
56122987 23171 "parameters" : {
44660702 23172 "additionalProperties" : 0,
56122987 23173 "properties" : {
7aacca6f 23174 "realm" : {
44660702 23175 "description" : "Authentication domain ID",
7aacca6f
DM
23176 "format" : "pve-realm",
23177 "maxLength" : 32,
44660702 23178 "type" : "string"
56122987 23179 }
44660702 23180 }
7aacca6f 23181 },
7aacca6f
DM
23182 "permissions" : {
23183 "check" : [
23184 "perm",
23185 "/access/realm",
23186 [
44660702
DM
23187 "Realm.Allocate",
23188 "Sys.Audit"
23189 ],
23190 "any",
23191 1
7aacca6f 23192 ]
44660702
DM
23193 },
23194 "returns" : {}
7aacca6f 23195 },
44660702
DM
23196 "PUT" : {
23197 "description" : "Update authentication server settings.",
23198 "method" : "PUT",
23199 "name" : "update",
7aacca6f 23200 "parameters" : {
44660702 23201 "additionalProperties" : 0,
7aacca6f 23202 "properties" : {
44660702
DM
23203 "base_dn" : {
23204 "description" : "LDAP base domain name",
23205 "maxLength" : 256,
23206 "optional" : 1,
23207 "pattern" : "\\w+=[^,]+(,\\s*\\w+=[^,]+)*",
23208 "type" : "string"
23209 },
4bd7df8b
DM
23210 "bind_dn" : {
23211 "description" : "LDAP bind domain name",
23212 "maxLength" : 256,
23213 "optional" : 1,
23214 "pattern" : "\\w+=[^,]+(,\\s*\\w+=[^,]+)*",
23215 "type" : "string"
23216 },
44660702
DM
23217 "comment" : {
23218 "description" : "Description.",
23219 "maxLength" : 4096,
23220 "optional" : 1,
23221 "type" : "string"
23222 },
23223 "default" : {
23224 "description" : "Use this as default realm",
23225 "optional" : 1,
23226 "type" : "boolean"
23227 },
23228 "delete" : {
23229 "description" : "A list of settings you want to delete.",
23230 "format" : "pve-configid-list",
23231 "maxLength" : 4096,
23232 "optional" : 1,
23233 "type" : "string"
23234 },
23235 "digest" : {
23236 "description" : "Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.",
23237 "maxLength" : 40,
23238 "optional" : 1,
23239 "type" : "string"
23240 },
23241 "domain" : {
23242 "description" : "AD domain name",
23243 "maxLength" : 256,
23244 "optional" : 1,
23245 "pattern" : "\\S+",
23246 "type" : "string"
23247 },
23248 "port" : {
23249 "description" : "Server port.",
23250 "maximum" : 65535,
23251 "minimum" : 1,
23252 "optional" : 1,
4bd7df8b 23253 "type" : "integer",
2c0dde61 23254 "typetext" : "integer (1 - 65535)"
44660702 23255 },
7aacca6f 23256 "realm" : {
7aacca6f
DM
23257 "description" : "Authentication domain ID",
23258 "format" : "pve-realm",
44660702
DM
23259 "maxLength" : 32,
23260 "type" : "string"
23261 },
23262 "secure" : {
23263 "description" : "Use secure LDAPS protocol.",
23264 "optional" : 1,
23265 "type" : "boolean"
23266 },
23267 "server1" : {
23268 "description" : "Server IP address (or DNS name)",
23269 "format" : "address",
23270 "maxLength" : 256,
23271 "optional" : 1,
23272 "type" : "string"
23273 },
23274 "server2" : {
23275 "description" : "Fallback Server IP address (or DNS name)",
23276 "format" : "address",
23277 "maxLength" : 256,
23278 "optional" : 1,
23279 "type" : "string"
23280 },
23281 "tfa" : {
23282 "description" : "Use Two-factor authentication.",
23283 "format" : "pve-tfa-config",
23284 "maxLength" : 128,
23285 "optional" : 1,
23286 "type" : "string"
23287 },
23288 "user_attr" : {
23289 "description" : "LDAP user attribute name",
23290 "maxLength" : 256,
23291 "optional" : 1,
23292 "pattern" : "\\S{2,}",
23293 "type" : "string"
7aacca6f 23294 }
56122987 23295 },
44660702 23296 "type" : "object"
56122987 23297 },
7aacca6f
DM
23298 "permissions" : {
23299 "check" : [
23300 "perm",
23301 "/access/realm",
23302 [
44660702
DM
23303 "Realm.Allocate"
23304 ]
7aacca6f
DM
23305 ]
23306 },
44660702
DM
23307 "protected" : 1,
23308 "returns" : {
23309 "type" : "null"
23310 }
56122987 23311 }
44660702
DM
23312 },
23313 "leaf" : 1,
23314 "path" : "/access/domains/{realm}",
23315 "text" : "{realm}"
56122987 23316 }
7aacca6f 23317 ],
56122987
DM
23318 "info" : {
23319 "GET" : {
44660702
DM
23320 "description" : "Authentication domain index.",
23321 "method" : "GET",
23322 "name" : "index",
23323 "parameters" : {
23324 "additionalProperties" : 0
23325 },
23326 "permissions" : {
23327 "description" : "Anyone can access that, because we need that list for the login box (before the user is authenticated).",
23328 "user" : "world"
23329 },
56122987 23330 "returns" : {
56122987
DM
23331 "items" : {
23332 "properties" : {
7aacca6f
DM
23333 "comment" : {
23334 "optional" : 1,
23335 "type" : "string"
23336 },
56122987
DM
23337 "realm" : {
23338 "type" : "string"
23339 },
23340 "tfa" : {
7aacca6f 23341 "description" : "Two-factor authentication provider.",
56122987
DM
23342 "enum" : [
23343 "yubico",
23344 "oath"
23345 ],
44660702
DM
23346 "optional" : 1,
23347 "type" : "string"
56122987
DM
23348 }
23349 },
23350 "type" : "object"
44660702
DM
23351 },
23352 "links" : [
23353 {
23354 "href" : "{realm}",
23355 "rel" : "child"
23356 }
23357 ],
23358 "type" : "array"
23359 }
56122987
DM
23360 },
23361 "POST" : {
7aacca6f 23362 "description" : "Add an authentication server.",
44660702 23363 "method" : "POST",
7aacca6f 23364 "name" : "create",
56122987 23365 "parameters" : {
44660702 23366 "additionalProperties" : 0,
56122987 23367 "properties" : {
44660702
DM
23368 "base_dn" : {
23369 "description" : "LDAP base domain name",
56122987 23370 "maxLength" : 256,
44660702
DM
23371 "optional" : 1,
23372 "pattern" : "\\w+=[^,]+(,\\s*\\w+=[^,]+)*",
7aacca6f 23373 "type" : "string"
56122987 23374 },
4bd7df8b
DM
23375 "bind_dn" : {
23376 "description" : "LDAP bind domain name",
23377 "maxLength" : 256,
23378 "optional" : 1,
23379 "pattern" : "\\w+=[^,]+(,\\s*\\w+=[^,]+)*",
23380 "type" : "string"
23381 },
44660702
DM
23382 "comment" : {
23383 "description" : "Description.",
23384 "maxLength" : 4096,
56122987 23385 "optional" : 1,
44660702 23386 "type" : "string"
56122987 23387 },
44660702
DM
23388 "default" : {
23389 "description" : "Use this as default realm",
7aacca6f 23390 "optional" : 1,
44660702 23391 "type" : "boolean"
56122987 23392 },
44660702
DM
23393 "domain" : {
23394 "description" : "AD domain name",
23395 "maxLength" : 256,
7aacca6f 23396 "optional" : 1,
44660702
DM
23397 "pattern" : "\\S+",
23398 "type" : "string"
56122987 23399 },
7aacca6f 23400 "port" : {
44660702 23401 "description" : "Server port.",
7aacca6f 23402 "maximum" : 65535,
44660702 23403 "minimum" : 1,
7aacca6f 23404 "optional" : 1,
4bd7df8b 23405 "type" : "integer",
2c0dde61 23406 "typetext" : "integer (1 - 65535)"
56122987 23407 },
44660702
DM
23408 "realm" : {
23409 "description" : "Authentication domain ID",
23410 "format" : "pve-realm",
23411 "maxLength" : 32,
23412 "type" : "string"
23413 },
23414 "secure" : {
23415 "description" : "Use secure LDAPS protocol.",
7aacca6f 23416 "optional" : 1,
44660702 23417 "type" : "boolean"
56122987 23418 },
44660702
DM
23419 "server1" : {
23420 "description" : "Server IP address (or DNS name)",
23421 "format" : "address",
23422 "maxLength" : 256,
23423 "optional" : 1,
23424 "type" : "string"
56122987 23425 },
44660702
DM
23426 "server2" : {
23427 "description" : "Fallback Server IP address (or DNS name)",
23428 "format" : "address",
7aacca6f 23429 "maxLength" : 256,
7aacca6f 23430 "optional" : 1,
44660702 23431 "type" : "string"
7aacca6f 23432 },
44660702
DM
23433 "tfa" : {
23434 "description" : "Use Two-factor authentication.",
23435 "format" : "pve-tfa-config",
23436 "maxLength" : 128,
23437 "optional" : 1,
23438 "type" : "string"
23439 },
23440 "type" : {
23441 "description" : "Realm type.",
23442 "enum" : [
23443 "ad",
23444 "ldap",
23445 "pam",
23446 "pve"
23447 ],
23448 "type" : "string"
23449 },
23450 "user_attr" : {
23451 "description" : "LDAP user attribute name",
7aacca6f 23452 "maxLength" : 256,
7aacca6f 23453 "optional" : 1,
44660702
DM
23454 "pattern" : "\\S{2,}",
23455 "type" : "string"
7aacca6f
DM
23456 }
23457 },
7aacca6f 23458 "type" : "object"
56122987 23459 },
7aacca6f
DM
23460 "permissions" : {
23461 "check" : [
23462 "perm",
23463 "/access/realm",
23464 [
23465 "Realm.Allocate"
23466 ]
23467 ]
44660702
DM
23468 },
23469 "protected" : 1,
23470 "returns" : {
23471 "type" : "null"
7aacca6f 23472 }
56122987 23473 }
7aacca6f 23474 },
44660702 23475 "leaf" : 0,
56122987 23476 "path" : "/access/domains",
44660702 23477 "text" : "domains"
56122987
DM
23478 },
23479 {
56122987 23480 "info" : {
44660702
DM
23481 "GET" : {
23482 "description" : "Dummy. Useful for formaters which want to priovde a login page.",
23483 "method" : "GET",
23484 "name" : "get_ticket",
23485 "parameters" : {
23486 "additionalProperties" : 0
23487 },
23488 "permissions" : {
23489 "user" : "world"
23490 },
23491 "returns" : {
23492 "type" : "null"
23493 }
23494 },
56122987 23495 "POST" : {
44660702 23496 "description" : "Create or verify authentication ticket.",
56122987 23497 "method" : "POST",
44660702
DM
23498 "name" : "create_ticket",
23499 "parameters" : {
23500 "additionalProperties" : 0,
56122987 23501 "properties" : {
44660702
DM
23502 "otp" : {
23503 "description" : "One-time password for Two-factor authentication.",
7aacca6f
DM
23504 "optional" : 1,
23505 "type" : "string"
56122987 23506 },
7aacca6f
DM
23507 "password" : {
23508 "description" : "The secret password. This can also be a valid ticket.",
23509 "type" : "string"
23510 },
44660702
DM
23511 "path" : {
23512 "description" : "Verify ticket, and check if user have access 'privs' on 'path'",
7aacca6f 23513 "maxLength" : 64,
56122987 23514 "optional" : 1,
56122987 23515 "requires" : "privs",
44660702
DM
23516 "type" : "string"
23517 },
23518 "privs" : {
7aacca6f 23519 "description" : "Verify ticket, and check if user have access 'privs' on 'path'",
44660702
DM
23520 "format" : "pve-priv-list",
23521 "maxLength" : 64,
56122987 23522 "optional" : 1,
44660702
DM
23523 "requires" : "path",
23524 "type" : "string"
56122987
DM
23525 },
23526 "realm" : {
56122987 23527 "description" : "You can optionally pass the realm using this parameter. Normally the realm is simply added to the username <username>@<relam>.",
44660702 23528 "format" : "pve-realm",
7aacca6f 23529 "maxLength" : 32,
44660702
DM
23530 "optional" : 1,
23531 "type" : "string"
56122987
DM
23532 },
23533 "username" : {
23534 "description" : "User name",
44660702
DM
23535 "maxLength" : 64,
23536 "type" : "string"
56122987 23537 }
44660702 23538 }
7aacca6f 23539 },
56122987 23540 "permissions" : {
44660702 23541 "description" : "You need to pass valid credientials.",
56122987
DM
23542 "user" : "world"
23543 },
44660702 23544 "protected" : 1,
7aacca6f 23545 "returns" : {
56122987 23546 "properties" : {
44660702
DM
23547 "CSRFPreventionToken" : {
23548 "optional" : 1,
23549 "type" : "string"
56122987 23550 },
44660702
DM
23551 "ticket" : {
23552 "optional" : 1,
23553 "type" : "string"
23554 },
23555 "username" : {
56122987
DM
23556 "type" : "string"
23557 }
23558 },
44660702 23559 "type" : "object"
7aacca6f 23560 }
7aacca6f
DM
23561 }
23562 },
44660702
DM
23563 "leaf" : 1,
23564 "path" : "/access/ticket",
23565 "text" : "ticket"
7aacca6f 23566 },
56122987 23567 {
56122987 23568 "info" : {
7aacca6f 23569 "PUT" : {
44660702 23570 "description" : "Change user password.",
7aacca6f 23571 "method" : "PUT",
44660702 23572 "name" : "change_passsword",
56122987
DM
23573 "parameters" : {
23574 "additionalProperties" : 0,
23575 "properties" : {
44660702
DM
23576 "password" : {
23577 "description" : "The new password.",
23578 "maxLength" : 64,
23579 "minLength" : 5,
23580 "type" : "string"
7aacca6f 23581 },
44660702
DM
23582 "userid" : {
23583 "description" : "User ID",
23584 "format" : "pve-userid",
23585 "maxLength" : 64,
7aacca6f 23586 "type" : "string"
56122987 23587 }
7aacca6f 23588 }
56122987
DM
23589 },
23590 "permissions" : {
23591 "check" : [
44660702 23592 "or",
56122987 23593 [
44660702
DM
23594 "userid-param",
23595 "self"
23596 ],
23597 [
23598 "and",
23599 [
23600 "userid-param",
23601 "Realm.AllocateUser"
23602 ],
23603 [
23604 "userid-group",
23605 [
23606 "User.Modify"
23607 ]
23608 ]
56122987 23609 ]
7aacca6f 23610 ],
44660702 23611 "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 <userid>) and 'User.Modify' permission on /access/groups/<group> on a group where user <userid> is member of."
56122987 23612 },
44660702 23613 "protected" : 1,
7aacca6f
DM
23614 "returns" : {
23615 "type" : "null"
44660702
DM
23616 }
23617 }
23618 },
23619 "leaf" : 1,
23620 "path" : "/access/password",
23621 "text" : "password"
23622 }
23623 ],
23624 "info" : {
23625 "GET" : {
23626 "description" : "Directory index.",
23627 "method" : "GET",
23628 "name" : "index",
23629 "parameters" : {
23630 "additionalProperties" : 0
23631 },
23632 "permissions" : {
23633 "user" : "all"
23634 },
23635 "returns" : {
23636 "items" : {
23637 "properties" : {
23638 "subdir" : {
23639 "type" : "string"
23640 }
7aacca6f 23641 },
44660702
DM
23642 "type" : "object"
23643 },
23644 "links" : [
23645 {
23646 "href" : "{subdir}",
23647 "rel" : "child"
23648 }
23649 ],
23650 "type" : "array"
23651 }
23652 }
23653 },
23654 "leaf" : 0,
23655 "path" : "/access",
23656 "text" : "access"
23657 },
23658 {
23659 "children" : [
23660 {
23661 "info" : {
23662 "DELETE" : {
7aacca6f 23663 "description" : "Delete pool.",
44660702
DM
23664 "method" : "DELETE",
23665 "name" : "delete_pool",
7aacca6f
DM
23666 "parameters" : {
23667 "additionalProperties" : 0,
23668 "properties" : {
23669 "poolid" : {
23670 "format" : "pve-poolid",
23671 "type" : "string"
23672 }
23673 }
23674 },
56122987
DM
23675 "permissions" : {
23676 "check" : [
23677 "perm",
23678 "/pool/{poolid}",
23679 [
23680 "Pool.Allocate"
23681 ]
44660702
DM
23682 ],
23683 "description" : "You can only delete empty pools (no members)."
23684 },
23685 "protected" : 1,
23686 "returns" : {
23687 "type" : "null"
7aacca6f
DM
23688 }
23689 },
23690 "GET" : {
23691 "description" : "Get pool configuration.",
44660702 23692 "method" : "GET",
7aacca6f 23693 "name" : "read_pool",
56122987 23694 "parameters" : {
44660702 23695 "additionalProperties" : 0,
56122987
DM
23696 "properties" : {
23697 "poolid" : {
44660702
DM
23698 "format" : "pve-poolid",
23699 "type" : "string"
56122987 23700 }
44660702 23701 }
56122987 23702 },
56122987 23703 "permissions" : {
56122987
DM
23704 "check" : [
23705 "perm",
23706 "/pool/{poolid}",
23707 [
23708 "Pool.Allocate"
23709 ]
23710 ]
23711 },
7aacca6f 23712 "returns" : {
44660702 23713 "additionalProperties" : 0,
56122987 23714 "properties" : {
44660702
DM
23715 "comment" : {
23716 "optional" : 1,
23717 "type" : "string"
23718 },
7aacca6f 23719 "members" : {
7aacca6f
DM
23720 "items" : {
23721 "additionalProperties" : 1,
7aacca6f 23722 "properties" : {
7aacca6f
DM
23723 "id" : {
23724 "type" : "string"
23725 },
23726 "node" : {
23727 "type" : "string"
23728 },
44660702
DM
23729 "storage" : {
23730 "optional" : 1,
23731 "type" : "string"
23732 },
7aacca6f 23733 "type" : {
7aacca6f
DM
23734 "enum" : [
23735 "qemu",
23736 "lxc",
23737 "openvz",
23738 "storage"
44660702
DM
23739 ],
23740 "type" : "string"
23741 },
23742 "vmid" : {
23743 "optional" : 1,
23744 "type" : "integer"
7aacca6f 23745 }
44660702
DM
23746 },
23747 "type" : "object"
23748 },
23749 "type" : "array"
23750 }
23751 },
23752 "type" : "object"
23753 }
23754 },
23755 "PUT" : {
23756 "description" : "Update pool data.",
23757 "method" : "PUT",
23758 "name" : "update_pool",
23759 "parameters" : {
23760 "additionalProperties" : 0,
23761 "properties" : {
56122987
DM
23762 "comment" : {
23763 "optional" : 1,
23764 "type" : "string"
44660702
DM
23765 },
23766 "delete" : {
23767 "description" : "Remove vms/storage (instead of adding it).",
23768 "optional" : 1,
23769 "type" : "boolean"
23770 },
23771 "poolid" : {
23772 "format" : "pve-poolid",
23773 "type" : "string"
23774 },
23775 "storage" : {
23776 "description" : "List of storage IDs.",
23777 "format" : "pve-storage-id-list",
23778 "optional" : 1,
23779 "type" : "string"
23780 },
23781 "vms" : {
23782 "description" : "List of virtual machines.",
23783 "format" : "pve-vmid-list",
23784 "optional" : 1,
23785 "type" : "string"
56122987 23786 }
44660702
DM
23787 }
23788 },
23789 "permissions" : {
23790 "check" : [
23791 "perm",
23792 "/pool/{poolid}",
23793 [
23794 "Pool.Allocate"
23795 ]
23796 ],
23797 "description" : "You also need the right to modify permissions on any object you add/delete."
23798 },
23799 "protected" : 1,
23800 "returns" : {
23801 "type" : "null"
56122987
DM
23802 }
23803 }
23804 },
44660702
DM
23805 "leaf" : 1,
23806 "path" : "/pools/{poolid}",
7aacca6f 23807 "text" : "{poolid}"
56122987 23808 }
7aacca6f 23809 ],
56122987
DM
23810 "info" : {
23811 "GET" : {
44660702
DM
23812 "description" : "Pool index.",
23813 "method" : "GET",
23814 "name" : "index",
23815 "parameters" : {
23816 "additionalProperties" : 0
23817 },
23818 "permissions" : {
23819 "description" : "List all pools where you have Pool.Allocate or VM.Allocate permissions on /pool/<pool>.",
23820 "user" : "all"
23821 },
56122987 23822 "returns" : {
44660702
DM
23823 "items" : {
23824 "properties" : {
23825 "poolid" : {
23826 "type" : "string"
23827 }
56122987 23828 },
44660702
DM
23829 "type" : "object"
23830 },
23831 "links" : [
23832 {
23833 "href" : "{poolid}",
23834 "rel" : "child"
23835 }
23836 ],
23837 "type" : "array"
23838 }
23839 },
23840 "POST" : {
23841 "description" : "Create new pool.",
23842 "method" : "POST",
23843 "name" : "create_pool",
23844 "parameters" : {
23845 "additionalProperties" : 0,
23846 "properties" : {
23847 "comment" : {
23848 "optional" : 1,
56122987 23849 "type" : "string"
7aacca6f 23850 },
44660702
DM
23851 "poolid" : {
23852 "format" : "pve-poolid",
7aacca6f 23853 "type" : "string"
56122987
DM
23854 }
23855 }
23856 },
56122987 23857 "permissions" : {
44660702
DM
23858 "check" : [
23859 "perm",
23860 "/pool/{poolid}",
23861 [
23862 "Pool.Allocate"
23863 ]
23864 ]
56122987 23865 },
44660702
DM
23866 "protected" : 1,
23867 "returns" : {
23868 "type" : "null"
23869 }
23870 }
23871 },
23872 "leaf" : 0,
23873 "path" : "/pools",
23874 "text" : "pools"
23875 },
23876 {
23877 "info" : {
23878 "GET" : {
23879 "description" : "API version details. The result also includes the global datacenter confguration.",
23880 "method" : "GET",
23881 "name" : "version",
7aacca6f
DM
23882 "parameters" : {
23883 "additionalProperties" : 0
23884 },
44660702
DM
23885 "permissions" : {
23886 "user" : "all"
23887 },
23888 "returns" : {
23889 "properties" : {
23890 "release" : {
23891 "type" : "string"
23892 },
23893 "repoid" : {
23894 "type" : "string"
23895 },
23896 "version" : {
23897 "type" : "string"
23898 }
23899 },
23900 "type" : "object"
23901 }
56122987
DM
23902 }
23903 },
44660702
DM
23904 "leaf" : 1,
23905 "path" : "/version",
56122987
DM
23906 "text" : "version"
23907 }
23908]
23909;
23910