# Has to be run as admin
-# To be kept in sync with setup_php_travis.sh
-
# @todo make it optional to install xdebug. It is fe. missing in sury's ppa for Xenial
+# @todo make it optional to install fpm. It is not needed for the cd workflow
# @todo make it optional to disable xdebug ?
set -e
service php-fpm start
-# configure apache
-a2enconf php${PHPVER}-fpm
-service apache2 restart
+# configure apache (if installed)
+if [ -n "$(dpkg --list | grep apache)" ]; then
+ a2enconf php${PHPVER}-fpm
+ service apache2 restart
+fi