icingaweb2: Update test script to start apache everywhere

This commit is contained in:
Markus Frosch 2017-04-21 13:27:56 +02:00
parent ee7a9c669f
commit e1560e35c3

View File

@ -3,19 +3,17 @@
install_package icingaweb2
if [ -x /usr/sbin/apachectl ]; then
apache_command="apachectl start"
if [ -x /usr/sbin/httpd ]; then
sudo httpd -t
sudo httpd -k start
elif [ -x /usr/sbin/apache2 ]; then
sudo apache2 -t
sudo apache2 -k start
else
echo "Can not detect how to start Apache!" >&2
exit 1
fi
echo "Starting Apache httpd..."
if ! sudo $apache_command; then
echo "Failed to start httpd..." >&2
exit 1
fi
sleep 5
output=`mktemp`