]> git.proxmox.com Git - pve-manager.git/commitdiff
pve7to8: avoid confusing warning about required setting 'storage' for vzdump
authorFiona Ebner <f.ebner@proxmox.com>
Wed, 21 Jun 2023 15:02:01 +0000 (17:02 +0200)
committerThomas Lamprecht <t.lamprecht@proxmox.com>
Wed, 21 Jun 2023 16:16:14 +0000 (18:16 +0200)
It's required in the schema for notes-template and protected, but when
parsing vzdump.conf, it shouldn't matter whether the storage parameter
is set or not.

The warning is ugly and users might interpret it as something that
needs to be acted upon for the upgrade:
parse error in '/etc/vzdump.conf' - 'storage': missing property - 'notes-template' requires this property\nmissing property - 'protected' requires this property

Signed-off-by: Fiona Ebner <f.ebner@proxmox.com>
PVE/CLI/pve7to8.pm

index a65e5bf9639a6d726290ec2cfcfea7f8fbb7225a..9db3b18eb65f886c4d66d4aeee3caacf191952bb 100644 (file)
@@ -614,6 +614,8 @@ sub check_backup_retention_settings {
 
     eval {
        my $confdesc = PVE::VZDump::Common::get_confdesc();
+       # vzdump.conf by itself doesn't need to honor any 'requires'
+       delete $confdesc->{$_}->{requires} for keys $confdesc->%*;
 
        my $fn = "/etc/vzdump.conf";
        my $raw = PVE::Tools::file_get_contents($fn);