Feature: add php-cs-fixer to the base image

Php-cs-fixer have conflicts with the symfony and doctrine version in use for us.

I propose to add it to the image until php-cs-fixer becomes compatible again with our dependencies.

This commit also add the environment variable PHP_CS_FIXER_IGNORE_ENV to make it works with php 8.2 (currently, it does not work with php > 8.1)
This commit is contained in:
Julien Fastré 2023-02-03 22:43:37 +01:00 committed by Mathieu Jaumotte
parent fcd00855f9
commit 2af27e8b42

View File

@ -42,6 +42,13 @@ RUN { \
echo ""; \ echo ""; \
} >> /usr/local/etc/php/conf.d/date.ini } >> /usr/local/etc/php/conf.d/date.ini
# temporary fix, while php-cs-fixer has conflict dependencies
# with chill
RUN curl -o /usr/local/bin/php-cs-fixer https://cs.symfony.com/download/php-cs-fixer-v3.phar \
&& chmod +x /usr/local/bin/php-cs-fixer
# to make php-cs-fixer works with php 8.2
ENV PHP_CS_FIXER_IGNORE_ENV=1
COPY --from=composer:2 /usr/bin/composer /usr/bin/composer COPY --from=composer:2 /usr/bin/composer /usr/bin/composer
ENV COMPOSER_ALLOW_SUPERUSER=1 ENV COMPOSER_ALLOW_SUPERUSER=1
ENV COMPOSER_MEMORY_LIMIT=-1 ENV COMPOSER_MEMORY_LIMIT=-1