From f40e9c9c3d86a0862308cbd6a999f3cb7d468253 Mon Sep 17 00:00:00 2001 From: Thierry Parmentelat Date: Thu, 5 Apr 2012 09:25:09 +0200 Subject: [PATCH] the systemd/ files are intended to end up on the node side, not on the server side remove them from the bootcd-initscripts package that is for server add them in bootcd image (as created by prep.sh) --- bootcd.spec | 11 ----------- prep.sh | 12 ++++++++++++ 2 files changed, 12 insertions(+), 11 deletions(-) diff --git a/bootcd.spec b/bootcd.spec index e5298ba..bc3dd5d 100644 --- a/bootcd.spec +++ b/bootcd.spec @@ -101,15 +101,6 @@ for script in bootcd bootcd-kernel; do install -D -m 755 plc.d/$script $RPM_BUILD_ROOT/etc/plc.d/$script done -#systemd files -mkdir -p $RPM_BUILD_ROOT/lib/systemd/system -mkdir -p $RPM_BUILD_ROOT/etc/systemd/system -cp -pr systemd/* $RPM_BUILD_ROOT/lib/systemd/system -ln -sf /lib/systemd/system/pl_boot.target $RPM_BUILD_ROOT/etc/systemd/system/default.target -mkdir -p $RPM_BUILD_ROOT/lib/systemd/system/pl_boot.target.wants -mkdir -p $RPM_BUILD_ROOT/lib/systemd/system/pl_sysinit.target.wants -ln -sf /lib/systemd/system/pl_boot.service $RPM_BUILD_ROOT/lib/systemd/system/pl_boot.target.wants/pl_boot.service -ln -sf /lib/systemd/system/pl_sysinit.service $RPM_BUILD_ROOT/lib/systemd/system/pl_sysinit.target.wants/pl_sysinit.service popd %clean @@ -122,8 +113,6 @@ rm -rf $RPM_BUILD_ROOT %files -n bootcd-initscripts %defattr(-,root,root,-) /etc/plc.d -/lib/systemd/system -/etc/systemd/system %changelog * Mon Nov 07 2011 Thierry Parmentelat - bootcd-5.0-11 diff --git a/prep.sh b/prep.sh index 4d45e76..473d25e 100755 --- a/prep.sh +++ b/prep.sh @@ -63,6 +63,18 @@ for file in pl_functions pl_sysinit pl_hwinit pl_netinit pl_validateconf pl_boot install -D -m 755 initscripts/$file $bootcd/etc/init.d/$file done +# Install systemd files +echo "* Installing systemd files" +for file in pl_boot.service pl_boot.target pl_sysinit.service pl_sysinit.target; do + install -D -m 644 systemd/$file $bootcd/lib/systemd/system +done +ln -sf /lib/systemd/system/pl_boot.target $bootcd/etc/systemd/system/default.target +mkdir -p $bootcd/lib/systemd/system/pl_boot.target.wants +mkdir -p $bootcd/lib/systemd/system/pl_sysinit.target.wants +ln -sf /lib/systemd/system/pl_boot.service $bootcd/lib/systemd/system/pl_boot.target.wants/pl_boot.service +ln -sf /lib/systemd/system/pl_sysinit.service $bootcd/lib/systemd/system/pl_sysinit.target.wants/pl_sysinit.service + + # Install configuration files echo "* Installing configuration files" for file in fstab mtab modprobe.conf inittab hosts sysctl.conf ; do -- 2.43.0