Support for backup standalone VMs (add root.img, apps/); add firewall.xml to backup
This commit is contained in:
parent
8bdbed7bb8
commit
7dca7a5a32
@ -121,19 +121,25 @@ def main():
|
||||
|
||||
files_to_backup += file_to_backup(vm.icon_path)
|
||||
files_to_backup += file_to_backup(vm.conf_file)
|
||||
#files_to_backup += file_to_backup(vm.dir_path + "/apps")
|
||||
if vm.is_updateable():
|
||||
files_to_backup += file_to_backup(vm.dir_path + "/apps")
|
||||
if os.path.exists (vm.firewall_conf):
|
||||
files_to_backup += file_to_backup(vm.firewall_conf)
|
||||
|
||||
if vm.is_updateable():
|
||||
sz = vm.get_disk_usage(vm.root_img)
|
||||
files_to_backup += file_to_backup(vm.root_img, sz)
|
||||
vm_sz += sz
|
||||
sz = vm.get_disk_usage(vm.volatile_img)
|
||||
files_to_backup += file_to_backup(vm.volatile_img, sz)
|
||||
vm_sz += sz
|
||||
|
||||
s = ""
|
||||
fmt="{{0:>{0}}} |".format(fields_to_display[0]["width"] + 1)
|
||||
s += fmt.format(vm.name)
|
||||
|
||||
fmt="{{0:>{0}}} |".format(fields_to_display[1]["width"] + 1)
|
||||
s += fmt.format("AppVM" + (" + COW" if vm.is_updateable() else ""))
|
||||
s += fmt.format("AppVM" + (" + Root FS" if vm.is_updateable() else ""))
|
||||
|
||||
fmt="{{0:>{0}}} |".format(fields_to_display[2]["width"] + 1)
|
||||
s += fmt.format(size_to_human(vm_sz))
|
||||
|
Loading…
Reference in New Issue
Block a user