From patchwork Tue Aug 29 08:52:37 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jonatan Schlag X-Patchwork-Id: 7125 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 ECDSA (secp384r1)) (Client CN "mail01.haj.ipfire.org", Issuer "R3" (verified OK)) by web04.haj.ipfire.org (Postfix) with ESMTPS id 4RZh5h2B2Fz3wtG for ; Tue, 29 Aug 2023 08:52:56 +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 ECDSA (secp384r1) client-signature ECDSA (secp384r1)) (Client CN "mail02.haj.ipfire.org", Issuer "R3" (verified OK)) by mail01.ipfire.org (Postfix) with ESMTPS id 4RZh5f72RJz1Cd; Tue, 29 Aug 2023 08:52:54 +0000 (UTC) Received: from mail02.haj.ipfire.org (localhost [127.0.0.1]) by mail02.haj.ipfire.org (Postfix) with ESMTP id 4RZh5f5QRfz2xc7; Tue, 29 Aug 2023 08:52:54 +0000 (UTC) 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 (P-384) client-signature ECDSA (P-384)) (Client CN "mail01.haj.ipfire.org", Issuer "R3" (verified OK)) by mail02.haj.ipfire.org (Postfix) with ESMTPS id 4RZh5c6pdlz2xc7 for ; Tue, 29 Aug 2023 08:52:52 +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 ECDSA (secp384r1) server-digest SHA384) (No client certificate requested) by mail01.ipfire.org (Postfix) with ESMTPSA id 4RZh5c13MBzj5; Tue, 29 Aug 2023 08:52:52 +0000 (UTC) DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=ipfire.org; s=202003ed25519; t=1693299172; 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; bh=9w36XEsTmyHKYR/n7wZTQ3d5nk2ut+7n9RRuNoKIGUs=; b=rpc5u7vudF65rcSedY0sPT+FJxCHWMJ4yBBkl/fxPUk+iJtl+L/SThgnjINpo17W9Q6DoI AyGJkHTygUa5y9DQ== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ipfire.org; s=202003rsa; t=1693299172; 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; bh=9w36XEsTmyHKYR/n7wZTQ3d5nk2ut+7n9RRuNoKIGUs=; b=Vpnn0EanxZmVo3VQwZR1DWENelKXrlCNdEtFCuwSuFsFOp0f/UPDCB2QyJuDlo8dc8WI17 jRo5q+SzIXCBvzyEGkAMt79rIIcpuTEInwjm5Sj9/qfd8ID4cPVwo+eGRcO80i23Kwm2U5 JOsrPYSdwolfqaj7PFOed+oLAQXsM1k+3oJ0sC4crIjwqVPLpjgoOG9V+ZEPca/XJ4EWti S+O8R5cWJ0mQGO20nZ/pmn+o1Q8EMzr7CmUrVZBQlpuY+BXpRKmmSzAFHFxIZpmwuNlQpW /CpdTxh1eoJH1IdTTFIsElrcfiTsDCphMbvJQOaWkTACpAIPbEmmbZqvnAK03Q== From: Jonatan Schlag To: development@lists.ipfire.org Subject: [PATCH 1/5] Remove Start/Stop links for client175 Date: Tue, 29 Aug 2023 10:52:37 +0200 Message-Id: <20230829085241.6985-1-jonatan.schlag@ipfire.org> MIME-Version: 1.0 X-BeenThere: development@lists.ipfire.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: IPFire development talk List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: development-bounces@lists.ipfire.org Sender: "Development" This was dropped a while ago Signed-off-by: Jonatan Schlag --- lfs/initscripts | 3 --- 1 file changed, 3 deletions(-) diff --git a/lfs/initscripts b/lfs/initscripts index 19b79a474..e078632ab 100644 --- a/lfs/initscripts +++ b/lfs/initscripts @@ -98,7 +98,6 @@ $(TARGET) : ln -sf ../init.d/fcron /etc/rc.d/rc0.d/K08fcron ln -sf ../init.d/apache /etc/rc.d/rc0.d/K28apache ln -sf ../init.d/sshd /etc/rc.d/rc0.d/K30sshd - ln -sf ../init.d/client175 /etc/rc.d/rc0.d/K34client175 ln -sf ../init.d/setclock /etc/rc.d/rc0.d/K47setclock ln -sf ../init.d/cyrus-sasl /etc/rc.d/rc0.d/K49cyrus-sasl ln -sf ../init.d/vnstat /etc/rc.d/rc0.d/K51vnstat @@ -131,7 +130,6 @@ $(TARGET) : ln -sf ../init.d/sshd /etc/rc.d/rc3.d/S30sshd ln -sf ../init.d/apache /etc/rc.d/rc3.d/S32apache ln -sf ../init.d/fcron /etc/rc.d/rc3.d/S40fcron - ln -sf ../init.d/client175 /etc/rc.d/rc3.d/S66client175 ln -sf ../../sysconfig/rc.local /etc/rc.d/rc3.d/S98rc.local ln -sf ../init.d/sslh /etc/rc.d/rc3.d/S98sslh ln -sf ../init.d/imspetor /etc/rc.d/rc3.d/S99imspetor @@ -145,7 +143,6 @@ $(TARGET) : ln -sf ../init.d/fcron /etc/rc.d/rc6.d/K08fcron ln -sf ../init.d/apache /etc/rc.d/rc6.d/K28apache ln -sf ../init.d/sshd /etc/rc.d/rc6.d/K30sshd - ln -sf ../init.d/client175 /etc/rc.d/rc6.d/K34client175 ln -sf ../init.d/setclock /etc/rc.d/rc6.d/K47setclock ln -sf ../init.d/cyrus-sasl /etc/rc.d/rc6.d/K49cyrus-sasl ln -sf ../init.d/vnstat /etc/rc.d/rc6.d/K51vnstat From patchwork Tue Aug 29 08:52:38 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jonatan Schlag X-Patchwork-Id: 7126 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 ECDSA (secp384r1)) (Client CN "mail01.haj.ipfire.org", Issuer "R3" (verified OK)) by web04.haj.ipfire.org (Postfix) with ESMTPS id 4RZh5l213zz3wtG for ; Tue, 29 Aug 2023 08:52:59 +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 ECDSA (secp384r1) client-signature ECDSA (secp384r1)) (Client CN "mail02.haj.ipfire.org", Issuer "R3" (verified OK)) by mail01.ipfire.org (Postfix) with ESMTPS id 4RZh5k6MQ1zj5; Tue, 29 Aug 2023 08:52:58 +0000 (UTC) Received: from mail02.haj.ipfire.org (localhost [127.0.0.1]) by mail02.haj.ipfire.org (Postfix) with ESMTP id 4RZh5k5vkcz2yWd; Tue, 29 Aug 2023 08:52:58 +0000 (UTC) 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 (P-384) client-signature ECDSA (P-384)) (Client CN "mail01.haj.ipfire.org", Issuer "R3" (verified OK)) by mail02.haj.ipfire.org (Postfix) with ESMTPS id 4RZh5j422rz2xc7 for ; Tue, 29 Aug 2023 08:52:57 +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 ECDSA (secp384r1) server-digest SHA384) (No client certificate requested) by mail01.ipfire.org (Postfix) with ESMTPSA id 4RZh5j2WC2zj5; Tue, 29 Aug 2023 08:52:57 +0000 (UTC) DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=ipfire.org; s=202003ed25519; t=1693299177; 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=khKwUsimcCcMxuaFAkgnHyX5vaIwsDc+dFoSYqLk1Pc=; b=1Jb0oOtaWXpChxhU1Fz19nrnMNVxRoMAOL336wWOCBpUwS8LLyPiR6CzeYjZmYXm2vQBDm SK55+d0nK2uP4BAQ== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ipfire.org; s=202003rsa; t=1693299177; 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=khKwUsimcCcMxuaFAkgnHyX5vaIwsDc+dFoSYqLk1Pc=; b=E/cHQ6xeWZl7PQsXBM2jxCG6Pfv+e4AqNRHopEHJ1F/BiEVFukIZ2iCm5ANvqDoOt6bieA D6m93oJpFwFrV4ujT7Q4MLsH+FSgYtGEE0GCp0ueHhqyMsKVOH5XU7hMSJloqrlXh9PNUD DR+CEEgp0JJNI2gRV1kmJLA0L1r5x7rOmaHbyyiS5nuU0ZE6qX41IlK+4O9HHyfiVT5Opn wmZbMxf6jOQH/H8w/lTyAX5qhpXzyRL/dDZXF9mhGpXLnkRqrEqCtXBmkOMqFFvzdQJQkD 3jgjkoE6pdo7XUtMh+Qdlrbe2Fzg2LEDV5+V/+f0s7GEmWfnhNQxgSxKwZ+6rA== From: Jonatan Schlag To: development@lists.ipfire.org Subject: [PATCH 2/5] Use bash as shebang in network initscripts Date: Tue, 29 Aug 2023 10:52:38 +0200 Message-Id: <20230829085241.6985-2-jonatan.schlag@ipfire.org> In-Reply-To: <20230829085241.6985-1-jonatan.schlag@ipfire.org> References: <20230829085241.6985-1-jonatan.schlag@ipfire.org> MIME-Version: 1.0 X-BeenThere: development@lists.ipfire.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: IPFire development talk List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: development-bounces@lists.ipfire.org Sender: "Development" /bin/sh is a symlink to /bin/bash on ipfire systems. Using /bin/sh in the scripts as shebang hurts in two ways: 1. We use features which do not work with sh as shell. This is not really a problem but if we rely on features of a real bash we can state this clearly. 2. The syntay highlighting in vim does not work without a correct shebang. As I want and need correct syntax highlighting I propose to change the shebang. Signed-off-by: Jonatan Schlag --- src/initscripts/networking/any | 2 +- src/initscripts/networking/functions.network | 2 +- src/initscripts/networking/red | 2 +- src/initscripts/networking/red.up/99-pakfire-update | 2 +- src/initscripts/system/network | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/initscripts/networking/any b/src/initscripts/networking/any index 15197badb..dc4796e91 100644 --- a/src/initscripts/networking/any +++ b/src/initscripts/networking/any @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/bash ############################################################################### # # # IPFire.org - A linux based firewall # diff --git a/src/initscripts/networking/functions.network b/src/initscripts/networking/functions.network index 0e2e5009e..4c7ad51d4 100644 --- a/src/initscripts/networking/functions.network +++ b/src/initscripts/networking/functions.network @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/bash ############################################################################### # # # IPFire.org - A linux based firewall # diff --git a/src/initscripts/networking/red b/src/initscripts/networking/red index 75a17bd5a..9da3ea406 100644 --- a/src/initscripts/networking/red +++ b/src/initscripts/networking/red @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/bash ############################################################################### # # # IPFire.org - A linux based firewall # diff --git a/src/initscripts/networking/red.up/99-pakfire-update b/src/initscripts/networking/red.up/99-pakfire-update index 3cc79a107..56cee66aa 100644 --- a/src/initscripts/networking/red.up/99-pakfire-update +++ b/src/initscripts/networking/red.up/99-pakfire-update @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/bash nice -n 10 /opt/pakfire/pakfire update >/dev/null 2>&1 & diff --git a/src/initscripts/system/network b/src/initscripts/system/network index 9ef3fb0d8..16609175a 100644 --- a/src/initscripts/system/network +++ b/src/initscripts/system/network @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/bash ############################################################################### # # # IPFire.org - A linux based firewall # From patchwork Tue Aug 29 08:52:39 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jonatan Schlag X-Patchwork-Id: 7127 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 ECDSA (secp384r1)) (Client CN "mail01.haj.ipfire.org", Issuer "R3" (verified OK)) by web04.haj.ipfire.org (Postfix) with ESMTPS id 4RZh5n4jT6z3wtG for ; Tue, 29 Aug 2023 08:53:01 +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 ECDSA (secp384r1) client-signature ECDSA (secp384r1)) (Client CN "mail02.haj.ipfire.org", Issuer "R3" (verified OK)) by mail01.ipfire.org (Postfix) with ESMTPS id 4RZh5m6kP6z2jW; Tue, 29 Aug 2023 08:53:00 +0000 (UTC) Received: from mail02.haj.ipfire.org (localhost [127.0.0.1]) by mail02.haj.ipfire.org (Postfix) with ESMTP id 4RZh5m6HGTz2ylN; Tue, 29 Aug 2023 08:53:00 +0000 (UTC) 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 (P-384) client-signature ECDSA (P-384)) (Client CN "mail01.haj.ipfire.org", Issuer "R3" (verified OK)) by mail02.haj.ipfire.org (Postfix) with ESMTPS id 4RZh5l1J4Xz2xc7 for ; Tue, 29 Aug 2023 08:52: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 ECDSA (secp384r1) server-digest SHA384) (No client certificate requested) by mail01.ipfire.org (Postfix) with ESMTPSA id 4RZh5k6n6wz3cS; Tue, 29 Aug 2023 08:52:58 +0000 (UTC) DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=ipfire.org; s=202003ed25519; t=1693299179; 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=AMgx6ON5itIieIU3bqdKxa6YHX6HuBUk2OR6gSgdXAA=; b=ZHoi/AOuetJHax5v+h30CDabQNS+50Jk7M7FVZShItJao/642cZAGMqxs1R3eGpswC/LeU xnjQp9sP2lWykADg== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ipfire.org; s=202003rsa; t=1693299179; 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=AMgx6ON5itIieIU3bqdKxa6YHX6HuBUk2OR6gSgdXAA=; b=qm8jNu7Sg+sm+Tlo9OWRObasI0dkPNhduLXC0d+jtBfjf9Ad0oSenjuy0MpdSQ+shqIBQu PbX0Sg2W7CqhTbzpdvb8pfE38G3sz1w9unbBzpK7qoO6mwZsRzdXR5EK5G/ZnjhQYrDuCv NylgbT1YUdK3SFHOdf/dXwS0opT01LMKsgJf2uwdy0j5zB7f+7BFKnYdvfWN0B0UNK79Jk P+haVRYYwu7leG1WL3zG5mekQbON5OUw+qlio3j3n6PxiPTK6tex1V3bSdh8LaOgV8+9kb ZOFNgOscFgVIuJa4fNybz6eL2URmL0MVieNZZVF82EpAZHVfQFW/HojC892OxQ== From: Jonatan Schlag To: development@lists.ipfire.org Subject: [PATCH 3/5] network initscripts: Remove code for old zone scheme Date: Tue, 29 Aug 2023 10:52:39 +0200 Message-Id: <20230829085241.6985-3-jonatan.schlag@ipfire.org> In-Reply-To: <20230829085241.6985-1-jonatan.schlag@ipfire.org> References: <20230829085241.6985-1-jonatan.schlag@ipfire.org> MIME-Version: 1.0 X-BeenThere: development@lists.ipfire.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: IPFire development talk List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: development-bounces@lists.ipfire.org Sender: "Development" A long time ago (2007) there were more config types possible then 1, 2, 3 and 4. As our installer currently only accepts config type out of the set 1, 2, 3 and 4 we do not need to check if our CONFIG_TYPE is in this set. Signed-off-by: Jonatan Schlag --- src/initscripts/system/network | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/src/initscripts/system/network b/src/initscripts/system/network index 16609175a..ecc007a47 100644 --- a/src/initscripts/system/network +++ b/src/initscripts/system/network @@ -63,11 +63,9 @@ case "${DO}" in # RED if [ "$red" == "1" ]; then - if [ "$CONFIG_TYPE" = "1" -o "$CONFIG_TYPE" = "2" -o "$CONFIG_TYPE" = "3" -o "$CONFIG_TYPE" = "4" ]; then - # Remove possible leftover files - rm -f /var/ipfire/red/{active,device,dial-on-demand,dns1,dns2,local-ipaddress,remote-ipaddress,resolv.conf} - [ "$AUTOCONNECT" == "off" ] || /etc/rc.d/init.d/networking/red start - fi + # Remove possible leftover files + rm -f /var/ipfire/red/{active,device,dial-on-demand,dns1,dns2,local-ipaddress,remote-ipaddress,resolv.conf} + [ "$AUTOCONNECT" == "off" ] || /etc/rc.d/init.d/networking/red start fi # Create IPsec interfaces From patchwork Tue Aug 29 08:52:40 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jonatan Schlag X-Patchwork-Id: 7128 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 ECDSA (secp384r1)) (Client CN "mail01.haj.ipfire.org", Issuer "R3" (verified OK)) by web04.haj.ipfire.org (Postfix) with ESMTPS id 4RZh5r0FDVz3wtG for ; Tue, 29 Aug 2023 08:53:04 +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 ECDSA (secp384r1) client-signature ECDSA (secp384r1)) (Client CN "mail02.haj.ipfire.org", Issuer "R3" (verified OK)) by mail01.ipfire.org (Postfix) with ESMTPS id 4RZh5q007yz2TZ; Tue, 29 Aug 2023 08:53:02 +0000 (UTC) Received: from mail02.haj.ipfire.org (localhost [127.0.0.1]) by mail02.haj.ipfire.org (Postfix) with ESMTP id 4RZh5p6fCRz2xkr; Tue, 29 Aug 2023 08:53:02 +0000 (UTC) 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 (P-384) client-signature ECDSA (P-384)) (Client CN "mail01.haj.ipfire.org", Issuer "R3" (verified OK)) by mail02.haj.ipfire.org (Postfix) with ESMTPS id 4RZh5m3tbbz2xhG for ; Tue, 29 Aug 2023 08:53:00 +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 ECDSA (secp384r1) server-digest SHA384) (No client certificate requested) by mail01.ipfire.org (Postfix) with ESMTPSA id 4RZh5m285kzhp; Tue, 29 Aug 2023 08:53:00 +0000 (UTC) DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=ipfire.org; s=202003ed25519; t=1693299180; 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=8CdRlO5joGRo+ZYCPbAejHBDX2efFF0asJH38lEjjHQ=; b=yMTJW3pTq8zSWP7quKz019YCniB70dVjJAAu57foirPJnPghy/5/KqkGBYQLmil8YoG/0s 2/VaEETQ3pvvx5Aw== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ipfire.org; s=202003rsa; t=1693299180; 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=8CdRlO5joGRo+ZYCPbAejHBDX2efFF0asJH38lEjjHQ=; b=Jp7WHNeHtGQzL1g/NszxAR9iAOSkcYALwNI8lDUHvYmsXxBbszh/a3lDnBC2fNx0G+qAUk 4us1Kx40T1lNDsE6iahCJTIkiyXCIwp9NDa+DwM/ZNnuox0LFlPFU1a2av9rExx0B0gQeN FViAXp5E6sBrokoHK/CUZep+Qo1StwN6IXNMhNt5cZhK57rCY85+CV/b60HYn1F1wry0KY yQcRy2TtxXQ7NnlY66y4MhM4tb4of7fwQPae5l/MjIU7sfMz5mmvl5ZnFyAraFdGqd82t9 DiPvrVDNWG+YAfSD+1AwihbmUv0nbhrAG4GDK1H7nHLIU1fsbQB2VBX0Wm+Cpg== From: Jonatan Schlag To: development@lists.ipfire.org Subject: [PATCH 4/5] network scripts: remove check for AUTOCONNECT Date: Tue, 29 Aug 2023 10:52:40 +0200 Message-Id: <20230829085241.6985-4-jonatan.schlag@ipfire.org> In-Reply-To: <20230829085241.6985-1-jonatan.schlag@ipfire.org> References: <20230829085241.6985-1-jonatan.schlag@ipfire.org> MIME-Version: 1.0 X-BeenThere: development@lists.ipfire.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: IPFire development talk List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: development-bounces@lists.ipfire.org Sender: "Development" This setting is also old (2007) and cannot be set via the webinterface anymore. So why checking for something, which can only be true. Signed-off-by: Jonatan Schlag --- src/initscripts/system/network | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/initscripts/system/network b/src/initscripts/system/network index ecc007a47..b38c3836c 100644 --- a/src/initscripts/system/network +++ b/src/initscripts/system/network @@ -65,7 +65,7 @@ case "${DO}" in if [ "$red" == "1" ]; then # Remove possible leftover files rm -f /var/ipfire/red/{active,device,dial-on-demand,dns1,dns2,local-ipaddress,remote-ipaddress,resolv.conf} - [ "$AUTOCONNECT" == "off" ] || /etc/rc.d/init.d/networking/red start + /etc/rc.d/init.d/networking/red start fi # Create IPsec interfaces From patchwork Tue Aug 29 08:52:41 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jonatan Schlag X-Patchwork-Id: 7129 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 ECDSA (secp384r1)) (Client CN "mail01.haj.ipfire.org", Issuer "R3" (verified OK)) by web04.haj.ipfire.org (Postfix) with ESMTPS id 4RZh5r4LDSz3wtK for ; Tue, 29 Aug 2023 08:53:04 +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 ECDSA (secp384r1) client-signature ECDSA (secp384r1)) (Client CN "mail02.haj.ipfire.org", Issuer "R3" (verified OK)) by mail01.ipfire.org (Postfix) with ESMTPS id 4RZh5q1JZJz3qv; Tue, 29 Aug 2023 08:53:03 +0000 (UTC) Received: from mail02.haj.ipfire.org (localhost [127.0.0.1]) by mail02.haj.ipfire.org (Postfix) with ESMTP id 4RZh5p6wnSz306n; Tue, 29 Aug 2023 08:53:02 +0000 (UTC) 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 (P-384) client-signature ECDSA (P-384)) (Client CN "mail01.haj.ipfire.org", Issuer "R3" (verified OK)) by mail02.haj.ipfire.org (Postfix) with ESMTPS id 4RZh5n3G82z2xc7 for ; Tue, 29 Aug 2023 08:53:01 +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 ECDSA (secp384r1) server-digest SHA384) (No client certificate requested) by mail01.ipfire.org (Postfix) with ESMTPSA id 4RZh5n1gTyz3sV; Tue, 29 Aug 2023 08:53:01 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ipfire.org; s=202003rsa; t=1693299181; 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=vnvqapTz31gsbxy3xYqJzpsmunPIx3r2JJ4qpwKys5A=; b=KhYKX2WcMT2qMUyxGpQEjQm/gDIw67Vbrcsu5UaDuMcSq86+GTAndfnIwIsb9ZlajTfPhu 4Yhu0ei1tzLQ8ygAAnJTVt7CSbrP2QrsfoCzHiXwiGUmHkk6FBcSBKA4uJ2qnVS646nE1o yuSjpUZ4TBKfVWDzBAa/Ngx+imJhT17jjdKFyHEtCUfviBvZz5hfX7Rt6is0LUc6WVzq/Q v4evsDWYju0khd12XGwzLYH969o0ZkbwDQnikXNTQuaM8YUA6ErGGQRNBFR6ZVzQAcbKJJ bKEppmF67N05MeavTg7l3Jc80PV0cTGOqxZuJUEFcehzPL+7UsxaiTg34B8YDA== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=ipfire.org; s=202003ed25519; t=1693299181; 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=vnvqapTz31gsbxy3xYqJzpsmunPIx3r2JJ4qpwKys5A=; b=iF2/UemON2I4qePxcfwX1i2fPUlpLh4m0mLUntmYbBSAgcPMoHPtkBjJ/na1AIukdXB678 XTkaeNDfb4EoBZCA== From: Jonatan Schlag To: development@lists.ipfire.org Subject: [PATCH 5/5] network startup: Always cleanup before red gets started Date: Tue, 29 Aug 2023 10:52:41 +0200 Message-Id: <20230829085241.6985-5-jonatan.schlag@ipfire.org> In-Reply-To: <20230829085241.6985-1-jonatan.schlag@ipfire.org> References: <20230829085241.6985-1-jonatan.schlag@ipfire.org> MIME-Version: 1.0 X-BeenThere: development@lists.ipfire.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: IPFire development talk List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: development-bounces@lists.ipfire.org Sender: "Development" There is no sense in doing this only in /etc/init.d/network and not in /etc/init.d/networking/red This files should be always deleted before a startup Signed-off-by: Jonatan Schlag --- src/initscripts/networking/red | 3 +++ src/initscripts/system/network | 6 +----- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/src/initscripts/networking/red b/src/initscripts/networking/red index 9da3ea406..beb665e5f 100644 --- a/src/initscripts/networking/red +++ b/src/initscripts/networking/red @@ -80,6 +80,9 @@ fi case "${1}" in start) + # Remove possible leftover files + rm -f /var/ipfire/red/{active,device,dial-on-demand,dns1,dns2,local-ipaddress,remote-ipaddress,resolv.conf} + if [ "${DEVICE}" != "${GREEN_DEV}" ] && [ "${DEVICE}" != "" ]; then boot_mesg "Bringing up the ${DEVICE} interface..." boot_mesg_flush diff --git a/src/initscripts/system/network b/src/initscripts/system/network index b38c3836c..0dcce060f 100644 --- a/src/initscripts/system/network +++ b/src/initscripts/system/network @@ -62,11 +62,7 @@ case "${DO}" in /etc/rc.d/init.d/networking/orange start # RED - if [ "$red" == "1" ]; then - # Remove possible leftover files - rm -f /var/ipfire/red/{active,device,dial-on-demand,dns1,dns2,local-ipaddress,remote-ipaddress,resolv.conf} - /etc/rc.d/init.d/networking/red start - fi + [ "$red" == "1" ] && /etc/rc.d/init.d/networking/red start # Create IPsec interfaces /usr/local/bin/ipsec-interfaces