From patchwork Sat Jun 28 13:48:51 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Adolf Belka X-Patchwork-Id: 8858 Return-Path: Received: from mail01.ipfire.org (mail01.haj.ipfire.org [172.28.1.202]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (secp384r1) client-signature RSA-PSS (4096 bits)) (Client CN "mail01.haj.ipfire.org", Issuer "R10" (verified OK)) by web04.haj.ipfire.org (Postfix) with ESMTPS id 4bTv0k0V0hz3wnP for ; Sat, 28 Jun 2025 13:49:10 +0000 (UTC) Received: from mail02.haj.ipfire.org (mail02.haj.ipfire.org [172.28.1.201]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) client-signature ECDSA (secp384r1)) (Client CN "mail02.haj.ipfire.org", Issuer "E5" (verified OK)) by mail01.ipfire.org (Postfix) with ESMTPS id 4bTv0b32wjz71p for ; Sat, 28 Jun 2025 13:49:03 +0000 (UTC) Received: from mail02.haj.ipfire.org (localhost [127.0.0.1]) by mail02.haj.ipfire.org (Postfix) with ESMTP id 4bTv0Z3HZJz36VZ for ; Sat, 28 Jun 2025 13:49:02 +0000 (UTC) X-Original-To: development@lists.ipfire.org Received: from mail01.ipfire.org (mail01.haj.ipfire.org [172.28.1.202]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (secp384r1) client-signature RSA-PSS (4096 bits)) (Client CN "mail01.haj.ipfire.org", Issuer "R10" (verified OK)) by mail02.haj.ipfire.org (Postfix) with ESMTPS id 4bTv0W3q3Mz33t6 for ; Sat, 28 Jun 2025 13:48:59 +0000 (UTC) Received: from [127.0.0.1] (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by mail01.ipfire.org (Postfix) with ESMTPSA id 4bTv0W25PZz118; Sat, 28 Jun 2025 13:48:59 +0000 (UTC) DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=ipfire.org; s=202003ed25519; t=1751118539; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=QPf1/jCznlcyLHk/dxK0iC166n2CLcKMat7YW2LHEHc=; b=SWAbvfr38FmXEEFBahfX0HwtFkM9BGne4bFYA4T7ojZ3h0E7SlKxk2o/U2+yTSTPeymfO2 zUA7oATt8WYlNCBQ== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ipfire.org; s=202003rsa; t=1751118539; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=QPf1/jCznlcyLHk/dxK0iC166n2CLcKMat7YW2LHEHc=; b=Od4Yqz54/ZfRKWcjHNmOdWgn7x5HcomY8EXzUub9TWEXc9xa59kLjBCzat8kOlBCsGuYrC X9DxuLwalQ+A0I7g4BklA2Vm+viNd9NYUo6e+lE6idtxeR38k+RBpjrbG3tDZJkak4Gnib L47gqUTrEATvUZcRLb7ECxhMVOB17fIi2RY3KlPXm1SWQ71rLLWUT7NEqirw5Pimn2ZrmV 4YU9tjfUqMaL+14VJsNgtkgFTaxz+FCCOMnUFhjXHKpoMxD8XtGWKxPYU/RS9A6yN74B8Z 7UDdjwXxXxyEkTGGtOGhpPKuuATehdgoch3CSn6fl7Ndi6UtObvpIeTtvDVD5A== From: Adolf Belka To: development@lists.ipfire.org Cc: Adolf Belka Subject: [PATCH 3/5] backup.pl: Stop restore of the empty pakfire.log file Date: Sat, 28 Jun 2025 15:48:51 +0200 Message-ID: <20250628134853.3312365-3-adolf.belka@ipfire.org> In-Reply-To: <20250628134853.3312365-1-adolf.belka@ipfire.org> References: <20250628134853.3312365-1-adolf.belka@ipfire.org> Precedence: list List-Id: List-Subscribe: , List-Unsubscribe: , List-Post: List-Help: Sender: Mail-Followup-To: MIME-Version: 1.0 - With the removal of the pakfire.log file from the install, this patch stops the empty file being restored from old backups Signed-off-by: Adolf Belka --- config/backup/backup.pl | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/config/backup/backup.pl b/config/backup/backup.pl index 0b8272266..fe62213e8 100644 --- a/config/backup/backup.pl +++ b/config/backup/backup.pl @@ -345,6 +345,11 @@ restore_backup() { /usr/local/bin/ipsecctrl S fi + if [ -e /var/log/pakfire.log ]; then + rm /var/log/pakfire.log + fi + + return 0 }