make the apache2 service starts automatically on SLES when xCATsn is installed

git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@5635 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd
This commit is contained in:
mxi1 2010-04-01 08:16:00 +00:00
parent e1e8a9d02a
commit 93e4f57a26

View File

@ -88,12 +88,17 @@ if [ -f /etc/xCATMN ]; then
fi
%ifos linux
if [ -e "/etc/redhat-release" ]; then
apachedaemon='httpd'
else # SuSE
apachedaemon='apache2'
fi
# start xcatd
chkconfig httpd on
chkconfig $apachedaemon on
if [ -f "/proc/cmdline" ]; then # prevent running it during install into chroot image
XCATROOT=$RPM_INSTALL_PREFIX0 /etc/init.d/xcatd start
/etc/init.d/httpd stop
/etc/init.d/httpd start
/etc/init.d/$apachedaemon reload
fi
echo "xCATsn is now installed"
%endif