public inbox for pve-devel@lists.proxmox.com
 help / color / mirror / Atom feed
From: Fiona Ebner <f.ebner@proxmox.com>
To: pve-devel@lists.proxmox.com
Subject: [pve-devel] [PATCH qemu-server 2/2] cloudinit: restore previous default for package upgrades
Date: Wed, 21 Jun 2023 12:04:32 +0200	[thread overview]
Message-ID: <20230621100433.36525-3-f.ebner@proxmox.com> (raw)
In-Reply-To: <20230621100433.36525-1-f.ebner@proxmox.com>

Commit efa3355d ("fix #3428: cloudinit: add parameter for upgrade on
boot") changed the default, but this is a breaking change. The bug
report was only about making the option configurable.

The commit doesn't give an explicit reason for why, and arguably,
doing the upgrade is not an issue for most users. It also leads to a
different cloud-init instance ID, because of the different setting,
which in turn leads to ssh host key regeneration within the VM.

Reported-by: Friedrich Weber <f.weber@proxmox.com>
Signed-off-by: Fiona Ebner <f.ebner@proxmox.com>
---
 PVE/QemuServer.pm           | 2 +-
 PVE/QemuServer/Cloudinit.pm | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/PVE/QemuServer.pm b/PVE/QemuServer.pm
index 91aab21c..c9c1936a 100644
--- a/PVE/QemuServer.pm
+++ b/PVE/QemuServer.pm
@@ -786,7 +786,7 @@ my $confdesc_cloudinit = {
 	optional => 1,
 	type => 'boolean',
 	description => 'cloud-init: do an automatic package upgrade after the first boot.',
-	default => 0,
+	default => 1,
     },
     cicustom => {
 	optional => 1,
diff --git a/PVE/QemuServer/Cloudinit.pm b/PVE/QemuServer/Cloudinit.pm
index cd5cc242..7449993a 100644
--- a/PVE/QemuServer/Cloudinit.pm
+++ b/PVE/QemuServer/Cloudinit.pm
@@ -148,7 +148,7 @@ sub cloudinit_userdata {
 	$content .= "  - default\n";
     }
 
-    $content .= "package_upgrade: true\n" if $conf->{ciupgrade};
+    $content .= "package_upgrade: true\n" if !defined($conf->{ciupgrade}) || $conf->{ciupgrade};
 
     return $content;
 }
-- 
2.39.2





  parent reply	other threads:[~2023-06-21 10:04 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-06-21 10:04 [pve-devel] [PATCH-SERIES qemu-server/manager] restore PVE 7 default for cloudinit " Fiona Ebner
2023-06-21 10:04 ` [pve-devel] [PATCH qemu-server 1/2] schema: cloudinit: document default for ciupgrade Fiona Ebner
2023-06-21 10:04 ` Fiona Ebner [this message]
2023-06-21 10:04 ` [pve-devel] [PATCH manager 1/1] ui: cloudinit: align default value for package upgrades with backend again Fiona Ebner
2023-06-21 10:47 ` [pve-devel] applied-series: [PATCH-SERIES qemu-server/manager] restore PVE 7 default for cloudinit package upgrades Thomas Lamprecht

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20230621100433.36525-3-f.ebner@proxmox.com \
    --to=f.ebner@proxmox.com \
    --cc=pve-devel@lists.proxmox.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
Service provided by Proxmox Server Solutions GmbH | Privacy | Legal