From 25cc3e982ecdbf13033a381674dc8fcb1eac6e9e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=A9my=20Munsch?= Date: Tue, 6 Oct 2026 15:02:44 +0200 Subject: [PATCH] ci: update CI images and optimize composer install commands Changed CI images to use a specific docker image and optimized composer install commands for better performance. --- .gitlab-ci.yml | 20 +++++++++----------- 1 file changed, 9 insertions(+), 11 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index c78a13f..ff3cc01 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -26,7 +26,7 @@ include: # * LINT -------------------------------------------------------------------- .php-lint-base: &php-lint-base - image: composer:2.10 + image: $CI_REGISTRY/ldc-web/projets/ldc-web-images-docker/uwil-ci-8.5:latest variables: COMPOSER_CACHE_DIR: ".composer-cache" cache: @@ -39,9 +39,8 @@ include: - .composer-cache/ - vendor/ before_script: - - apk add --no-cache icu-dev && docker-php-ext-install bcmath intl - - composer config gitlab-token.lab.s-web.fr "${CI_DEPLOY_USER}" "${CI_DEPLOY_PASSWORD}" - - composer install --no-interaction --optimize-autoloader --no-scripts --ignore-platform-req=ext-oci8 + - composer config gitlab-token.lab.s-web.fr $CI_DEPLOY_USER $CI_DEPLOY_PASSWORD + - composer install --no-scripts --no-interaction --no-ansi --no-progress --prefer-dist --ignore-platform-req=ext-oci8 rules: - if: $CI_PIPELINE_SOURCE == "merge_request_event" - if: $CI_COMMIT_BRANCH == "develop" @@ -67,7 +66,7 @@ phpcs: - vendor/bin/phpcs --standard=phpcs.xml --extensions=php --ignore=vendor/*,storage/*,bootstrap/*,node_modules/* --report=junit --report-file=phpcs-report.xml artifacts: when: on_failure - expose_as: 'phpcs' + expose_as: "phpcs" paths: - phpcs-report.xml reports: @@ -84,7 +83,7 @@ phpstan: - php -d memory_limit=512M vendor/bin/phpstan --error-format=junit > phpstan-report.xml artifacts: when: on_failure - expose_as: 'phpstan' + expose_as: "phpstan" paths: - phpstan-report.xml reports: @@ -95,7 +94,7 @@ phpstan: tests_laravel: stage: test - image: composer:2.10 + image: $CI_REGISTRY/ldc-web/projets/ldc-web-images-docker/uwil-ci-8.5:latest allow_failure: false variables: COMPOSER_CACHE_DIR: ".composer-cache" @@ -109,9 +108,8 @@ tests_laravel: - .composer-cache/ - vendor/ before_script: - - apk add --no-cache $PHPIZE_DEPS linux-headers icu-dev && docker-php-ext-install bcmath intl && pecl install pcov && docker-php-ext-enable pcov - - composer config gitlab-token.lab.s-web.fr "${CI_DEPLOY_USER}" "${CI_DEPLOY_PASSWORD}" - - composer install --no-interaction --prefer-dist --optimize-autoloader --no-scripts --ignore-platform-req=ext-oci8 + - composer config gitlab-token.lab.s-web.fr $CI_DEPLOY_USER $CI_DEPLOY_PASSWORD + - composer install --no-scripts --no-interaction --no-ansi --no-progress --prefer-dist --ignore-platform-req=ext-oci8 script: - cp .env.testing .env - php artisan key:generate @@ -121,7 +119,7 @@ tests_laravel: - if [ "$CI_JOB_STATUS" == "failed" ]; then cat storage/logs/laravel.log; fi artifacts: when: always - expose_as: 'coverage' + expose_as: "coverage" paths: - coverage/html/ reports: