Updated ns2.in (converted to the new c3d format).
authorZoltán Felleg <zoltan.felleg@userrendszerhaz.hu>
Fri, 11 Feb 2022 17:14:12 +0000 (18:14 +0100)
committerZoltán Felleg <zoltan.felleg@userrendszerhaz.hu>
Fri, 11 Feb 2022 17:14:12 +0000 (18:14 +0100)
13 files changed:
sources/ns2.in/c3d/firstboot/scripts/01_setupnetworking.sh [moved from sources/ns2.in/firstboot/01_setupnetworking.sh with 100% similarity]
sources/ns2.in/c3d/firstboot/scripts/02_settimezone.sh [moved from sources/ns2.in/firstboot/02_settimezone.sh with 100% similarity]
sources/ns2.in/c3d/mode.txt [new file with mode: 0644]
sources/ns2.in/c3d/owner.txt [new file with mode: 0644]
sources/ns2.in/c3d/postinstall/install-data/etc/named.conf [moved from sources/ns2.in/postinstall/install/etc/named.conf with 100% similarity]
sources/ns2.in/c3d/postinstall/scripts/01_editfiles.sh [new file with mode: 0755]
sources/ns2.in/c3d/postinstall/scripts/10_setupservices.sh [moved from sources/ns2.in/postinstall/10_setupservices.sh with 100% similarity]
sources/ns2.in/envvars
sources/ns2.in/firstboot/99_cleanup.sh [deleted file]
sources/ns2.in/postinstall/01_setownership.sh [deleted file]
sources/ns2.in/postinstall/02_setpermissions.sh [deleted file]
sources/ns2.in/postinstall/03_installfiles.sh [deleted file]
sources/ns2.in/postinstall/99_cleanup.sh [deleted file]

diff --git a/sources/ns2.in/c3d/mode.txt b/sources/ns2.in/c3d/mode.txt
new file mode 100644 (file)
index 0000000..ee44133
--- /dev/null
@@ -0,0 +1,4 @@
+# mode file (relative to /c3d)
+755 firstboot/scripts/*.sh
+640 postinstall/install-data/etc/named.conf
+755 postinstall/scripts/*.sh
diff --git a/sources/ns2.in/c3d/owner.txt b/sources/ns2.in/c3d/owner.txt
new file mode 100644 (file)
index 0000000..86b3d1d
--- /dev/null
@@ -0,0 +1,3 @@
+# owner file (relative to /c3d)
+# shell globbing does not work
+root.named postinstall/install-data/etc/named.conf
diff --git a/sources/ns2.in/c3d/postinstall/scripts/01_editfiles.sh b/sources/ns2.in/c3d/postinstall/scripts/01_editfiles.sh
new file mode 100755 (executable)
index 0000000..816ca13
--- /dev/null
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+
+sed --in-place=.orig \
+    '/^After=.*network\.target.*$/a After=network-online.target\nWants=network-online.target' \
+    /usr/lib/systemd/system/named.service
index 875dfc12c566a865b82f35c685c21425dbd7af90..67de93fc89aa6fa0744d16a47bfcc961be0eec56 100644 (file)
@@ -1,5 +1,3 @@
 DISTRIBUTION=Fedora
 DISTRIBUTION_VERSION=35
-ROOT_PACKAGES="hostname initscripts iproute rootfiles systemd-udev"
-BASE_PACKAGES="NetworkManager iputils logrotate rsyslog tar vim-minimal"
 SPEC_PACKAGES="bind bind-utils"
diff --git a/sources/ns2.in/firstboot/99_cleanup.sh b/sources/ns2.in/firstboot/99_cleanup.sh
deleted file mode 100755 (executable)
index b87f2f4..0000000
+++ /dev/null
@@ -1,6 +0,0 @@
-#!/bin/sh
-
-
-REAL_PATH=$(dirname $(realpath $0))
-
-echo rm -Rf $REAL_PATH
diff --git a/sources/ns2.in/postinstall/01_setownership.sh b/sources/ns2.in/postinstall/01_setownership.sh
deleted file mode 100755 (executable)
index 51d768a..0000000
+++ /dev/null
@@ -1,9 +0,0 @@
-#!/bin/sh
-
-
-REAL_PATH=$(dirname $(realpath $0))
-SOURCE_PATH=$REAL_PATH/install
-
-chown -R root.root $SOURCE_PATH/*
-
-chgrp named $SOURCE_PATH/etc/named.conf
diff --git a/sources/ns2.in/postinstall/02_setpermissions.sh b/sources/ns2.in/postinstall/02_setpermissions.sh
deleted file mode 100755 (executable)
index e7e809e..0000000
+++ /dev/null
@@ -1,7 +0,0 @@
-#!/bin/sh
-
-
-REAL_PATH=$(dirname $(realpath $0))
-SOURCE_PATH=$REAL_PATH/install
-
-chmod 640 $SOURCE_PATH/etc/named.conf
diff --git a/sources/ns2.in/postinstall/03_installfiles.sh b/sources/ns2.in/postinstall/03_installfiles.sh
deleted file mode 100755 (executable)
index e4ee7ff..0000000
+++ /dev/null
@@ -1,16 +0,0 @@
-#!/bin/sh
-
-
-REAL_PATH=$(dirname $(realpath $0))
-
-tar --create \
-    --directory=$REAL_PATH \
-    --exclude=.placeholder \
-    --to-stdout \
-    install \
-    | tar --extract \
-          --backup \
-          --directory=/ \
-          --no-overwrite-dir \
-          --strip-components=1 \
-          --suffix=.orig
diff --git a/sources/ns2.in/postinstall/99_cleanup.sh b/sources/ns2.in/postinstall/99_cleanup.sh
deleted file mode 100755 (executable)
index b87f2f4..0000000
+++ /dev/null
@@ -1,6 +0,0 @@
-#!/bin/sh
-
-
-REAL_PATH=$(dirname $(realpath $0))
-
-echo rm -Rf $REAL_PATH