mirror of
https://github.com/xcat2/xcat-core.git
synced 2025-05-22 03:32:04 +00:00
add cmdlist_check file which store the commands need to be included in install file
This commit is contained in:
parent
615b6895d0
commit
a1ce787318
@ -144,6 +144,20 @@ libnss_pkgname=`find /usr/lib64/ -name libnss_dns-2*.so | xargs basename`
|
||||
sed -i "s/\/lib64\/libnss_dns-2.12.so/\/usr\/lib64\/$libnss_pkgname/g" $DRACUTMODDIR/install
|
||||
sed -i 's/\/lib64\/libnss_dns.so.2/\/usr\/lib64\/libnss_dns.so.2/' $DRACUTMODDIR/install
|
||||
|
||||
# Based on cmdlist_check, makesure the commands are included in $DRACUTMODDIR/install
|
||||
if [ -e "${DRACUTMODDIR}/cmdlist_check" ]; then
|
||||
miss_cmd=0
|
||||
for cmd in `cat ${DRACUTMODDIR}/cmdlist_check`; do
|
||||
if ! grep $cmd $DRACUTMODDIR/install; then
|
||||
echo "The $cmd is missed in install file"
|
||||
miss_cmd=1
|
||||
fi
|
||||
done
|
||||
if [ "$miss_cmd" = 1 ]; then
|
||||
exit 1
|
||||
fi
|
||||
fi
|
||||
|
||||
mkdir -p /tmp/xcatgenesis.$$/opt/xcat/share/xcat/netboot/genesis/$BUILDARCH/fs
|
||||
|
||||
# run dracut
|
||||
|
1
xCAT-genesis-builder/cmdlist_check
Normal file
1
xCAT-genesis-builder/cmdlist_check
Normal file
@ -0,0 +1 @@
|
||||
ntp-wait
|
@ -18,10 +18,6 @@ check:output=~Version
|
||||
cmd:service xcatd status
|
||||
check:rc==0
|
||||
check:output=~running
|
||||
cmd:rpm -ql xCAT-genesis-base-x86_64 |grep ntp-wait
|
||||
check:rc==0
|
||||
cmd:rpm -ql xCAT-genesis-base-ppc64 |grep ntp-wait
|
||||
check:rc==0
|
||||
cmd:rm -rf /install_xCAT_xcat-core.tar.bz2 /install_xCAT_xcat-dep.tar.bz2
|
||||
end
|
||||
|
||||
@ -47,10 +43,6 @@ check:output=~Version
|
||||
cmd:service xcatd status
|
||||
check:rc==0
|
||||
check:output=~running
|
||||
cmd:dpkg -L xcat-genesis-base-ppc64 |grep ntp-wait
|
||||
check:rc==0
|
||||
cmd:dpkg -L xcat-genesis-base-amd64 |grep ntp-wait
|
||||
check:rc==0
|
||||
cmd:rm -rf /install_xCAT_xcat-core.tar.bz2 /install_xCAT_xcat-dep.tar.bz2
|
||||
end
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user