diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index fdc97324..f12aa614 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -40,12 +40,14 @@ jobs: uses: shivammathur/setup-php@v2 with: php-version: 7.4 + ini-values: session.save_path=${{ github.workspace }}/tmp/php_sessions extensions: mbstring, xml, ctype, iconv, intl, pdo_sqlite, mysql, pdo_mysql - name: Set SYMFONY_ENV to test run: echo "SYMFONY_ENV=test" >> $GITHUB_ENV - name: Install Apache + # We need the sed command at the bottom to set the PHP session save path to a directory that's writable for PHP run: | sudo add-apt-repository ppa:ondrej/php -y sudo add-apt-repository ppa:ondrej/apache2 -y @@ -54,6 +56,7 @@ jobs: sudo cp ./.github/workflows/mautic-apache.conf /etc/apache2/conf-available/mautic.conf sudo a2enconf mautic sudo service apache2 restart + sed -i 's,^;session.save_path =.*$,session.save_path = "${{ github.workspace }}/tmp/php_sessions",' php.ini - name: Install dependencies run: |