On 11/21/19 5:48 PM, Oguz Bektas wrote:
> diff --git a/src/lxc-pve-poststop-hook b/src/lxc-pve-poststop-hook
> index 19d0b52..64fe54d 100755
> --- a/src/lxc-pve-poststop-hook
> +++ b/src/lxc-pve-poststop-hook
> @@ -38,6 +38,14 @@ PVE::LXC::Tools::lxc_hook('post-stop', 'lxc', sub {
>       PVE::Network::veth_delete("veth${vmid}i$ind");
>      }
>  
> +    my $config_updated = 0;
> +    if ($conf->{pending}) {
> +     PVE::LXC::Config->vmconfig_apply_pending($vmid, $conf, $storage_cfg);

we may want to eval this statement, and just warn the errors it throws,
It may error but that should _not_ abort a reboot, config re-generation
can be done nonetheless, so just above would be enough to wrap:

eval { PVE::LXC::Config->vmconfig_apply_pending($vmid, $conf, $storage_cfg) };
warn "$@" if $@;

_______________________________________________
pve-devel mailing list
pve-devel@pve.proxmox.com
https://pve.proxmox.com/cgi-bin/mailman/listinfo/pve-devel

Reply via email to