From 2e793ebe625289b2486a0ea2b00cef4c7808b523 Mon Sep 17 00:00:00 2001 From: Gregory Kurtzer Date: Fri, 23 Apr 2021 20:31:27 -0700 Subject: [PATCH] Merged the debian specific overlay into default --- overlays/system/debian/etc/hostname.ww | 1 - .../debian/etc/ssh/ssh_host_dsa_key.pub.ww | 1 - .../system/debian/etc/ssh/ssh_host_dsa_key.ww | 1 - .../debian/etc/ssh/ssh_host_ecdsa_key.pub.ww | 1 - .../debian/etc/ssh/ssh_host_ecdsa_key.ww | 1 - .../etc/ssh/ssh_host_ed25519_key.pub.ww | 1 - .../debian/etc/ssh/ssh_host_ed25519_key.ww | 1 - .../debian/etc/ssh/ssh_host_rsa_key.pub.ww | 1 - .../system/debian/etc/ssh/ssh_host_rsa_key.ww | 1 - overlays/system/debian/etc/ssh/sshd_config.ww | 14 ----- .../debian/etc/warewulf/warewulf.conf.ww | 1 - overlays/system/debian/init | 57 ------------------- overlays/system/debian/warewulf/config.ww | 9 --- .../system/debian/warewulf/init.d/20-loopback | 6 -- .../debian/warewulf/init.d/75-vnfs_fixes | 24 -------- .../system/debian/warewulf/init.d/80-wwclient | 6 -- .../system/debian/warewulf/init.d/90-selinux | 35 ------------ overlays/system/debian/warewulf/wwinit | 17 ------ .../etc/network/interfaces | 0 .../etc/network/interfaces.d/eth0.ww | 0 .../systemd/network/10-persistent-net.link.ww | 0 21 files changed, 178 deletions(-) delete mode 100644 overlays/system/debian/etc/hostname.ww delete mode 100644 overlays/system/debian/etc/ssh/ssh_host_dsa_key.pub.ww delete mode 100644 overlays/system/debian/etc/ssh/ssh_host_dsa_key.ww delete mode 100644 overlays/system/debian/etc/ssh/ssh_host_ecdsa_key.pub.ww delete mode 100644 overlays/system/debian/etc/ssh/ssh_host_ecdsa_key.ww delete mode 100644 overlays/system/debian/etc/ssh/ssh_host_ed25519_key.pub.ww delete mode 100644 overlays/system/debian/etc/ssh/ssh_host_ed25519_key.ww delete mode 100644 overlays/system/debian/etc/ssh/ssh_host_rsa_key.pub.ww delete mode 100644 overlays/system/debian/etc/ssh/ssh_host_rsa_key.ww delete mode 100644 overlays/system/debian/etc/ssh/sshd_config.ww delete mode 100644 overlays/system/debian/etc/warewulf/warewulf.conf.ww delete mode 100755 overlays/system/debian/init delete mode 100644 overlays/system/debian/warewulf/config.ww delete mode 100644 overlays/system/debian/warewulf/init.d/20-loopback delete mode 100644 overlays/system/debian/warewulf/init.d/75-vnfs_fixes delete mode 100644 overlays/system/debian/warewulf/init.d/80-wwclient delete mode 100644 overlays/system/debian/warewulf/init.d/90-selinux delete mode 100644 overlays/system/debian/warewulf/wwinit rename overlays/system/{debian => default}/etc/network/interfaces (100%) rename overlays/system/{debian => default}/etc/network/interfaces.d/eth0.ww (100%) rename overlays/system/{debian => default}/etc/systemd/network/10-persistent-net.link.ww (100%) diff --git a/overlays/system/debian/etc/hostname.ww b/overlays/system/debian/etc/hostname.ww deleted file mode 100644 index b195826a..00000000 --- a/overlays/system/debian/etc/hostname.ww +++ /dev/null @@ -1 +0,0 @@ -{{$.Id}} diff --git a/overlays/system/debian/etc/ssh/ssh_host_dsa_key.pub.ww b/overlays/system/debian/etc/ssh/ssh_host_dsa_key.pub.ww deleted file mode 100644 index 4bb82192..00000000 --- a/overlays/system/debian/etc/ssh/ssh_host_dsa_key.pub.ww +++ /dev/null @@ -1 +0,0 @@ -{{Include "/etc/warewulf/keys/ssh_host_dsa_key.pub"}} diff --git a/overlays/system/debian/etc/ssh/ssh_host_dsa_key.ww b/overlays/system/debian/etc/ssh/ssh_host_dsa_key.ww deleted file mode 100644 index 581f48f4..00000000 --- a/overlays/system/debian/etc/ssh/ssh_host_dsa_key.ww +++ /dev/null @@ -1 +0,0 @@ -{{Include "/etc/warewulf/keys/ssh_host_dsa_key"}} diff --git a/overlays/system/debian/etc/ssh/ssh_host_ecdsa_key.pub.ww b/overlays/system/debian/etc/ssh/ssh_host_ecdsa_key.pub.ww deleted file mode 100644 index b6d9aa89..00000000 --- a/overlays/system/debian/etc/ssh/ssh_host_ecdsa_key.pub.ww +++ /dev/null @@ -1 +0,0 @@ -{{Include "/etc/warewulf/keys/ssh_host_ecdsa_key.pub"}} diff --git a/overlays/system/debian/etc/ssh/ssh_host_ecdsa_key.ww b/overlays/system/debian/etc/ssh/ssh_host_ecdsa_key.ww deleted file mode 100644 index fbf8934c..00000000 --- a/overlays/system/debian/etc/ssh/ssh_host_ecdsa_key.ww +++ /dev/null @@ -1 +0,0 @@ -{{Include "/etc/warewulf/keys/ssh_host_ecdsa_key"}} diff --git a/overlays/system/debian/etc/ssh/ssh_host_ed25519_key.pub.ww b/overlays/system/debian/etc/ssh/ssh_host_ed25519_key.pub.ww deleted file mode 100644 index 76dbcfdb..00000000 --- a/overlays/system/debian/etc/ssh/ssh_host_ed25519_key.pub.ww +++ /dev/null @@ -1 +0,0 @@ -{{Include "/etc/warewulf/keys/ssh_host_ed25519_key.pub"}} diff --git a/overlays/system/debian/etc/ssh/ssh_host_ed25519_key.ww b/overlays/system/debian/etc/ssh/ssh_host_ed25519_key.ww deleted file mode 100644 index e6dec541..00000000 --- a/overlays/system/debian/etc/ssh/ssh_host_ed25519_key.ww +++ /dev/null @@ -1 +0,0 @@ -{{Include "/etc/warewulf/keys/ssh_host_ed25519_key"}} diff --git a/overlays/system/debian/etc/ssh/ssh_host_rsa_key.pub.ww b/overlays/system/debian/etc/ssh/ssh_host_rsa_key.pub.ww deleted file mode 100644 index d5b09fa8..00000000 --- a/overlays/system/debian/etc/ssh/ssh_host_rsa_key.pub.ww +++ /dev/null @@ -1 +0,0 @@ -{{Include "/etc/warewulf/keys/ssh_host_rsa_key.pub"}} diff --git a/overlays/system/debian/etc/ssh/ssh_host_rsa_key.ww b/overlays/system/debian/etc/ssh/ssh_host_rsa_key.ww deleted file mode 100644 index feffaad5..00000000 --- a/overlays/system/debian/etc/ssh/ssh_host_rsa_key.ww +++ /dev/null @@ -1 +0,0 @@ -{{Include "/etc/warewulf/keys/ssh_host_rsa_key"}} diff --git a/overlays/system/debian/etc/ssh/sshd_config.ww b/overlays/system/debian/etc/ssh/sshd_config.ww deleted file mode 100644 index cc466670..00000000 --- a/overlays/system/debian/etc/ssh/sshd_config.ww +++ /dev/null @@ -1,14 +0,0 @@ -{{Include "/etc/warewulf/ssh/sshd_config"}} - -# This is a Warewulf Template file. -# -# This file (suffix '.ww') will be automatically rewritten without the suffix -# when the overlay is rendered for the individual nodes. Here are some examples -# of macros and logic which can be used within this file: -# -# Node FQDN = {{.Id}} -# Node Group = {{.GroupName}} -# Network Config = {{.NetDevs.eth0.Ipaddr}}, {{.NetDevs.eth0.Hwaddr}}, etc. -# -# Goto the documentation pages for more information: http://www.hpcng.org/... - diff --git a/overlays/system/debian/etc/warewulf/warewulf.conf.ww b/overlays/system/debian/etc/warewulf/warewulf.conf.ww deleted file mode 100644 index df0e916e..00000000 --- a/overlays/system/debian/etc/warewulf/warewulf.conf.ww +++ /dev/null @@ -1 +0,0 @@ -{{Include "/etc/warewulf/warewulf.conf"}} diff --git a/overlays/system/debian/init b/overlays/system/debian/init deleted file mode 100755 index 95c67574..00000000 --- a/overlays/system/debian/init +++ /dev/null @@ -1,57 +0,0 @@ -#!/bin/sh -# -# This is one of those types of files that you shouldn't edit unless you really -# know what you are doing and even then you should make a backup. -# -# Edit at your own risk! DANGER DANGER. - - -if test -f "/warewulf/config"; then - . /warewulf/config -else - echo "ERROR: Warewulf configuration file not found... rebooting in 1 minute" - sleep 60 - /sbin/reboot -fi - -echo "Warewulf v4 is now booting: ${WWHOSTNAME}" -echo "debian specific overlay" - -echo "Mounting up kernel file systems" -mkdir /proc /dev /sys /run 2>/dev/null -mount -t proc proc /proc -mount -t devtmpfs devtmpfs /dev -mount -t sysfs sysfs /sys -mount -t tmpfs tmpfs /run - -chmod 755 /warewulf/wwinit - -echo "Checking Rootfs type" -ROOTFSTYPE=`stat -f -c "%T" /` - -if test "${WWROOT}" = "initramfs"; then - echo "Provisioned to default initramfs file system: ${ROOTFSTYPE}" - echo "Calling WW Init" - exec /warewulf/wwinit -elif test "${WWROOT}" = "tmpfs"; then - if test "${ROOTFSTYPE}" == "tmpfs"; then - echo "ERROR: Switching the root file system requires the kernel argument: 'rootfstype=ramfs'" - else - echo "Setting up tmpfs root file system" - mkdir /newroot - mount wwroot /newroot -t tmpfs - echo "Moving RAMFS to TMPFS" - tar -cf - --exclude ./proc --exclude ./sys --exclude ./dev --exclude ./newroot . | tar -xf - -C /newroot - mkdir /newroot/proc /newroot/dev /newroot/sys /newroot/run 2>/dev/null - echo "Calling switch_root and invoking WW Init" - exec /sbin/switch_root /newroot /warewulf/wwinit - fi -else - echo "ERROR: Unknown Warewulf Root file system: ${WWROOT}" -fi - -echo -echo "There was a problem with the provisioning process, rebooting in 1 minute..." -sleep 60 -/sbin/reboot - diff --git a/overlays/system/debian/warewulf/config.ww b/overlays/system/debian/warewulf/config.ww deleted file mode 100644 index 5a33472a..00000000 --- a/overlays/system/debian/warewulf/config.ww +++ /dev/null @@ -1,9 +0,0 @@ -WWCONTAINER={{$.Container}} -WWHOSTNAME={{$.Id}} -WWROOT={{$.Root}} -WWINIT={{$.Init}} -WWIPMI_IPADDR="{{$.IpmiIpaddr}}" -WWIPMI_NETMASK="{{$.IpmiNetmask}}" -WWIPMI_GATEWAY="{{$.IpmiGateway}}" -WWIPMI_USER="{{$.IpmiUserName}}" -WWIPMI_PASSWORD="{{$.IpmiPassword}}" diff --git a/overlays/system/debian/warewulf/init.d/20-loopback b/overlays/system/debian/warewulf/init.d/20-loopback deleted file mode 100644 index 01791174..00000000 --- a/overlays/system/debian/warewulf/init.d/20-loopback +++ /dev/null @@ -1,6 +0,0 @@ -#!/bin/sh - -. /warewulf/config - -echo "Bringing up lo:127.0.0.1" -/sbin/ip link set dev lo up diff --git a/overlays/system/debian/warewulf/init.d/75-vnfs_fixes b/overlays/system/debian/warewulf/init.d/75-vnfs_fixes deleted file mode 100644 index 5ce5b735..00000000 --- a/overlays/system/debian/warewulf/init.d/75-vnfs_fixes +++ /dev/null @@ -1,24 +0,0 @@ -#!/bin/sh - -. /warewulf/config - -# This will eventually be optional -if true; then - if [ -f "/etc/pam.d/system-auth" ]; then - echo "FIXING: system-auth" - sed -i -e '/^account.*pam_unix\.so\s*$/s/\s*$/\ broken_shadow/' /etc/pam.d/system-auth - fi - - if [ -f "/etc/pam.d/password-auth" ]; then - echo "FIXING: password-auth" - sed -i -e '/^account.*pam_unix\.so\s*$/s/\s*$/\ broken_shadow/' /etc/pam.d/password-auth - fi - - if [ -f "/etc/pam.d/common-account" ]; then - echo "FIXING: common-account" - sed -i -e '/^account.*pam_unix\.so\s*$/s/\s*$/\ broken_shadow/' /etc/pam.d/common-account - fi -fi - - -chmod 755 / diff --git a/overlays/system/debian/warewulf/init.d/80-wwclient b/overlays/system/debian/warewulf/init.d/80-wwclient deleted file mode 100644 index 184dac4e..00000000 --- a/overlays/system/debian/warewulf/init.d/80-wwclient +++ /dev/null @@ -1,6 +0,0 @@ -#!/bin/sh - -. /warewulf/config - -echo "Starting wwclient" -nohup /warewulf/bin/wwclient >/var/log/wwclient.log 2>&1