X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=tests%2Fci%2Fsetup%2Fsetup_php.sh;h=1a7c69c383b8c8ebeebe2e7adbbc8ae212dc8047;hb=e6e1579cece03e00e0b0c931f43694c90357aa4f;hp=ad16d3db0b5add9a5f5dd7d2c3ea1556a6f9d6c0;hpb=06f68009ebdc123aa242f849d01f5d6cbc043726;p=plcapi.git diff --git a/tests/ci/setup/setup_php.sh b/tests/ci/setup/setup_php.sh index ad16d3d..1a7c69c 100755 --- a/tests/ci/setup/setup_php.sh +++ b/tests/ci/setup/setup_php.sh @@ -57,9 +57,18 @@ PHPVER=$(php -r 'echo implode(".",array_slice(explode(".",PHP_VERSION),0,2));' 2 configure_php_ini /etc/php/${PHPVER}/fpm/php.ini -# use a nice name for the php-fpm service, so that it does not depend on php version running +# use a nice name for the php-fpm service, so that it does not depend on php version running. Try to make that work +# both for docker and VMs service "php${PHPVER}-fpm" stop -ln -s "/etc/init.d/php${PHPVER}-fpm" /etc/init.d/php-fpm +if [ -f "/etc/init.d/php${PHPVER}-fpm" ]; then + ln -s "/etc/init.d/php${PHPVER}-fpm" /etc/init.d/php-fpm +fi +if [ -f "/lib/systemd/system/php${PHPVER}-fpm.service" ]; then + ln -s "/lib/systemd/system/php${PHPVER}-fpm.service" /lib/systemd/system/php-fpm.service + if [ ! -f /.dockerenv ]; then + systemctl daeamon-reload + fi +fi # @todo shall we configure php-fpm?