Add VM snapshots functionality

Adds the ability to create snapshots of an entire VM, including all its
RBD disks and the VM XML config, though not any PVC metadata.
This commit is contained in:
2024-05-16 09:23:31 -04:00
parent 942de9f15b
commit 553c1e670e
7 changed files with 256 additions and 3 deletions

View File

@ -573,7 +573,7 @@ class ZKHandler(object):
#
class ZKSchema(object):
# Current version
_version = 13
_version = 14
# Root for doing nested keys
_schema_root = ""
@ -713,13 +713,21 @@ class ZKSchema(object):
"meta.node_limit": "/node_limit",
"meta.tags": "/tags",
"migrate.sync_lock": "/migrate_sync_lock",
"snapshots": "/snapshots",
},
# The schema of an individual domain tag entry (/domains/{domain}/tags/{tag})
"tag": {
"name": "",
"name": "", # The root key
"type": "/type",
"protected": "/protected",
}, # The root key
},
# The schema of an individual domain snapshot entry (/domains/{domain}/snapshots/{snapshot})
"domain_snapshot": {
"name": "", # The root key
"is_backup": "/is_backup",
"xml": "/xml",
"rbd_snapshots": "/rbdsnaplist",
},
# The schema of an individual network entry (/networks/{vni})
"network": {
"vni": "", # The root key