From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from firstgate.proxmox.com (firstgate.proxmox.com [212.224.123.68]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by lists.proxmox.com (Postfix) with ESMTPS id B90A47360E for ; Tue, 6 Jul 2021 13:42:04 +0200 (CEST) Received: from firstgate.proxmox.com (localhost [127.0.0.1]) by firstgate.proxmox.com (Proxmox) with ESMTP id AC00F9CC6 for ; Tue, 6 Jul 2021 13:42:04 +0200 (CEST) Received: from proxmox-new.maurer-it.com (proxmox-new.maurer-it.com [94.136.29.106]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by firstgate.proxmox.com (Proxmox) with ESMTPS id 2AF6F9CBC for ; Tue, 6 Jul 2021 13:42:03 +0200 (CEST) Received: from proxmox-new.maurer-it.com (localhost.localdomain [127.0.0.1]) by proxmox-new.maurer-it.com (Proxmox) with ESMTP id A495A4054A for ; Tue, 6 Jul 2021 13:42:03 +0200 (CEST) From: Dominik Csapak To: pve-devel@lists.proxmox.com Date: Tue, 6 Jul 2021 13:42:02 +0200 Message-Id: <20210706114202.936811-1-d.csapak@proxmox.com> X-Mailer: git-send-email 2.30.2 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-SPAM-LEVEL: Spam detection results: 0 AWL 0.673 Adjusted score from AWL reputation of From: address BAYES_00 -1.9 Bayes spam probability is 0 to 1% KAM_DMARC_STATUS 0.01 Test Rule for DKIM or SPF Failure with Strict Alignment SPF_HELO_NONE 0.001 SPF: HELO does not publish an SPF Record SPF_PASS -0.001 SPF: sender matches SPF record Subject: [pve-devel] [PATCH] add patch to reload after first install X-BeenThere: pve-devel@lists.proxmox.com X-Mailman-Version: 2.1.29 Precedence: list List-Id: Proxmox VE development discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 06 Jul 2021 11:42:04 -0000 when installing for the first time we want to reload the network config, since sometimes the network will not be configured, e.g. when coming from ifupdown. this would break installing ifupdown2 over the network (e.g. ssh) Signed-off-by: Dominik Csapak --- ...load-network-config-on-first-install.patch | 26 +++++++++++++++++++ debian/patches/series | 1 + 2 files changed, 27 insertions(+) create mode 100644 debian/patches/pve/0013-postinst-reload-network-config-on-first-install.patch diff --git a/debian/patches/pve/0013-postinst-reload-network-config-on-first-install.patch b/debian/patches/pve/0013-postinst-reload-network-config-on-first-install.patch new file mode 100644 index 0000000..25c6851 --- /dev/null +++ b/debian/patches/pve/0013-postinst-reload-network-config-on-first-install.patch @@ -0,0 +1,26 @@ +From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 +From: Dominik Csapak +Date: Tue, 6 Jul 2021 13:11:24 +0200 +Subject: [PATCH] postinst: reload network config on first install + +Signed-off-by: Dominik Csapak +--- + debian/ifupdown2.postinst | 2 ++ + 1 file changed, 2 insertions(+) + +diff --git a/debian/ifupdown2.postinst b/debian/ifupdown2.postinst +index b7de485..eaade7c 100644 +--- a/debian/ifupdown2.postinst ++++ b/debian/ifupdown2.postinst +@@ -113,6 +113,8 @@ case "$1" in + postinst_remove_diverts + if [ -f "/tmp/.ifupdown2-first-install" ]; then + proxmox_compatibility ++ echo "Reloading network config on first install" ++ ifreload -a + rm /tmp/.ifupdown2-first-install + fi + ;; +-- +2.30.2 + diff --git a/debian/patches/series b/debian/patches/series index 2cb57a0..c8bcffb 100644 --- a/debian/patches/series +++ b/debian/patches/series @@ -10,3 +10,4 @@ pve/0009-allow-vlan-tag-inside-vxlan-tunnel.patch pve/0010-postinst-rm-update-network-config-compatibility.patch pve/0011-d-rules-drop-now-default-with-systemd.patch pve/0012-d-rules-add-dh_installsystemd-override-for-compat-12.patch +pve/0013-postinst-reload-network-config-on-first-install.patch -- 2.30.2