Kumora/Dockerfile
Renovate Bot f6572696f4
All checks were successful
Apply PHP CS Fixer / php-cs-fixer (push) Successful in 8s
rector / Rector (pull_request) Successful in 1m13s
CI / build-test (push) Successful in 1m16s
rector / Rector (push) Successful in 1m13s
Update dunglas/frankenphp Docker digest to 7a45fd0
2025-01-29 00:02:10 +00:00

42 lines
935 B
Docker

FROM dunglas/frankenphp@sha256:7a45fd0a4114256cc49da94503e6c60c88e491f2ef74fee983887bfd0a271af2
ENV SERVER_NAME=":80"
ARG APP_ENV=prod
RUN apt-get update && apt-get install -y --no-install-recommends \
acl \
file \
gettext \
git \
&& rm -rf /var/lib/apt/lists/*
RUN set -eux; \
install-php-extensions \
@composer \
apcu \
intl \
opcache \
zip \
pdo_mysql \
;
RUN mv "$PHP_INI_DIR/php.ini-production" "$PHP_INI_DIR/php.ini"
ENV COMPOSER_ALLOW_SUPERUSER=1
COPY --link composer.* symfony.* ./
ENV APP_ENV=${APP_ENV}
# On ajoute un if pour installer les dépendances de dev si APP_ENV est égal à dev
RUN composer install --no-cache --prefer-dist --no-dev --optimize-autoloader --no-scripts --no-progress;
COPY . .
RUN rm -rf var/tailwind \
&& php bin/console importmap:install \
&& php bin/console tailwind:build \
&& php bin/console asset-map:compile \
&& php bin/console cache:clear