From 183f8e479cc4871edf9f9e9d78b303891ae2bb43 Mon Sep 17 00:00:00 2001 From: Christian Goll Date: Mon, 16 Oct 2023 10:10:28 +0200 Subject: [PATCH] Propagate paths to overlays and use for wwclient Signed-off-by: Christian Goll --- CHANGELOG.md | 1 + internal/pkg/overlay/datastructure.go | 1 + overlays/wwinit/warewulf/init.d/80-wwclient | 7 ------- overlays/wwinit/warewulf/init.d/80-wwclient.ww | 11 +++++++++++ 4 files changed, 13 insertions(+), 7 deletions(-) delete mode 100644 overlays/wwinit/warewulf/init.d/80-wwclient create mode 100644 overlays/wwinit/warewulf/init.d/80-wwclient.ww diff --git a/CHANGELOG.md b/CHANGELOG.md index a46e5236..0c7d060a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -114,6 +114,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - added general test framework which creates temporary directories on the fly - only write IPMI if write is true - Don't show an error if image files for containers can't be found. #933 +- Make configured paths available in overlays as `.Path` #960 ## [4.4.0] 2023-01-18 diff --git a/internal/pkg/overlay/datastructure.go b/internal/pkg/overlay/datastructure.go index f9806802..15c9d3d5 100644 --- a/internal/pkg/overlay/datastructure.go +++ b/internal/pkg/overlay/datastructure.go @@ -65,6 +65,7 @@ func InitStruct(nodeInfo *node.NodeInfo) TemplateStruct { tstruct.Nfs = *controller.NFS tstruct.Dhcp = *controller.DHCP tstruct.Tftp = *controller.TFTP + tstruct.Paths = *controller.Paths tstruct.Warewulf = *controller.Warewulf tstruct.Ipaddr = controller.Ipaddr tstruct.Ipaddr6 = controller.Ipaddr6 diff --git a/overlays/wwinit/warewulf/init.d/80-wwclient b/overlays/wwinit/warewulf/init.d/80-wwclient deleted file mode 100644 index d0945766..00000000 --- a/overlays/wwinit/warewulf/init.d/80-wwclient +++ /dev/null @@ -1,7 +0,0 @@ -#!/bin/sh - -. /warewulf/config -# Only start if the systemd is no available -test -e /usr/lib/systemd/systemd && exit 0 -echo "Starting wwclient" -nohup /warewulf/bin/wwclient >/var/log/wwclient.log 2>&1 /var/log/wwclient.log 2>&1