diff --git a/.github/workflows/test.yaml b/.github/workflows/test.yaml index aaf60bf..8af02f0 100644 --- a/.github/workflows/test.yaml +++ b/.github/workflows/test.yaml @@ -6,7 +6,7 @@ jobs: integration_test: strategy: matrix: - php_version: [8.2, 8.3, 8.4] + php_version: [8.1, 8.2, 8.3, 8.4] testsuite: [general, brancher] runs-on: ubuntu-latest steps: diff --git a/ci/build/Dockerfile b/ci/build/Dockerfile index 28b54e4..53cef46 100644 --- a/ci/build/Dockerfile +++ b/ci/build/Dockerfile @@ -94,8 +94,14 @@ COPY ./ci/build/files / RUN curl -sS https://getcomposer.org/installer | php \ && mv composer.phar /usr/local/bin/composer \ - && chmod +x /usr/local/bin/composer \ - && composer install --no-dev --optimize-autoloader --working-dir=/hypernode + && chmod +x /usr/local/bin/composer + +# Remove dev dependencies from composer.json +RUN cd /hypernode && \ + jq 'del(.["require-dev"])' composer.json > composer.tmp.json && \ + cp composer.tmp.json composer.json + +RUN composer install --no-dev --optimize-autoloader --working-dir=/hypernode --no-scripts --no-progress --no-interaction RUN bash /hypernode/ci/compile.sh diff --git a/ci/test/run-general.sh b/ci/test/run-general.sh index dc21cc2..fafa385 100755 --- a/ci/test/run-general.sh +++ b/ci/test/run-general.sh @@ -10,6 +10,12 @@ else export IMAGE_OS="buster" fi +if [[ "${PHP_VERSION:-8.2}" == "8.0" || "${PHP_VERSION:-8.2}" == "8.1" ]]; then + export MAGENTO_VERSION="2.4.6-p10" +else + export MAGENTO_VERSION="2.4.8" +fi + # Handy aliases HN="docker-compose exec -T hypernode" DP="docker-compose exec -e GITHUB_WORKFLOW -T deploy" @@ -64,7 +70,7 @@ end_task begin_task "Setting Magento 2" # Create working initial Magento install on the Hypernode container -$HN composer create-project --repository=https://mirror.mage-os.org/ magento/project-community-edition:2.4.8 /data/web/magento2 +$HN composer create-project --repository=https://mirror.mage-os.org/ magento/project-community-edition:${MAGENTO_VERSION:-2.4.8} /data/web/magento2 echo "Waiting for MySQL to be available on the Hypernode container" $HN bash -c "until mysql -e 'select 1' ; do sleep 1; done" install_magento