This repository has been archived on 2025-06-23. You can view files and clone it. You cannot open issues or pull requests or push a commit.
Files
joeac.net-symfony/Dockerfile
2025-06-03 07:27:19 +01:00

35 lines
746 B
Docker

FROM docker.io/bitnami/php-fpm:8.4
WORKDIR /app
RUN set -eux \
&& apt-get update && apt-get install -y --no-install-recommends \
acl \
&& rm -rf /var/lib/apt/lists/*
COPY ./symfony/composer.* ./symfony/symfony.* ./
COPY ./symfony/.env.prod ./.env
RUN composer install \
--no-cache \
--no-dev \
--no-progress \
--no-scripts \
--optimize-autoloader \
--prefer-dist
WORKDIR /
COPY ./scripts ./scripts
WORKDIR /app
COPY ./symfony .
RUN mkdir -p var/log var/cache && \
chown -R www-data:www-data var && \
chmod -R 775 var
RUN composer install \
--no-cache \
--no-dev \
--no-progress \
--optimize-autoloader \
--prefer-dist
RUN php bin/console doctrine:migrations:migrate latest