diff --git a/xCAT-UI/xCAT-UI.spec b/xCAT-UI/xCAT-UI.spec index 12d6d8635..c118522fa 100644 --- a/xCAT-UI/xCAT-UI.spec +++ b/xCAT-UI/xCAT-UI.spec @@ -126,18 +126,18 @@ set -x if [ "$1" = 1 ] # Install then - # Update apache conf - /bin/rm -f /etc/$apachedaemon/conf.d/xcat-ui.conf - /bin/ln -s %{prefix}/ui/etc/apache2/conf.d/xcat-ui.conf /etc/$apachedaemon/conf.d/xcat-ui.conf - /etc/init.d/$apachedaemon reload - - # Copy php.ini file into /opt/xcat/ui and turn off output_buffering + # Copy php.ini file into /opt/xcat/ui and turn off output_buffering if [ -e "/etc/redhat-release" ]; then /bin/sed /etc/php.ini -e 's/output_buffering = 4096/output_buffering = Off/g' > %{prefix}/ui/php.ini else # SUSE /bin/sed /etc/php5/apache2/php.ini -e 's/output_buffering = 4096/output_buffering = Off/g' > %{prefix}/ui/php.ini fi - + + # Update apache conf + /bin/rm -f /etc/$apachedaemon/conf.d/xcat-ui.conf + /bin/ln -s %{prefix}/ui/etc/apache2/conf.d/xcat-ui.conf /etc/$apachedaemon/conf.d/xcat-ui.conf + /etc/init.d/$apachedaemon reload + # Automatically put encrypted password into the xCAT passwd database %{prefix}/sbin/chtab key=xcat,username=root passwd.password=`grep root /etc/shadow|cut -d : -f 2` @@ -191,6 +191,7 @@ set -x # Remove links made during the post install script echo "Undoing $apachedaemon configuration for xCAT..." /bin/rm -f /etc/$apachedaemon/conf.d/xcat-ui.conf + /bin/rm -f %{prefix}/ui/php.ini /etc/init.d/$apachedaemon reload fi %else # AIX