diff --git a/.github/workflows/php.yml b/.github/workflows/php.yml index 6f645d07..bf0e4e61 100644 --- a/.github/workflows/php.yml +++ b/.github/workflows/php.yml @@ -39,6 +39,14 @@ jobs: ${{ runner.os }}-build- ${{ runner.os }}- + - name: Install PHP 7.4 + run: | + sudo apt-get update + sudo apt-get install -y software-properties-common + sudo add-apt-repository ppa:ondrej/php -y + sudo apt-get update + sudo apt-get install -y php7.4 + - name: setup lxdmosaic run: sudo sh examples/test_setup.sh @@ -50,7 +58,7 @@ jobs: - name: run tests run: /usr/bin/php7.4 -dxdebug.mode=coverage vendor/bin/phpunit --coverage-html=./coverage - + - name: run phpstan run: /usr/bin/php7.4 vendor/bin/phpstan analyse src --level 1 diff --git a/examples/test_setup.sh b/examples/test_setup.sh index e4a92d15..4218cc30 100755 --- a/examples/test_setup.sh +++ b/examples/test_setup.sh @@ -5,10 +5,10 @@ sudo dpkg --purge --force-all lxd lxc apt-get update # # Install Dependecies -apt-get install -y apache2 php php-cli php-json php-mysql php-xml php-curl unzip zip git nodejs openssl || exit $? +apt-get install -y apache2 php7.4 php7.4-cli php7.4-json php7.4-mysql php7.4-xml php7.4-curl unzip zip git nodejs openssl || exit $? apt-get install -y mysql-server || exit $? apt-get install -y --no-install-recommends cron || exit $? -apt-get install -y --no-install-recommends php-xdebug || exit $? +apt-get install -y --no-install-recommends php7.4-xdebug || exit $? mkdir -p src/sensitiveData/certs mkdir -p src/sensitiveData/backups