From 8cf63a39ec42acc748b77dea5b7fefe30d4a994a Mon Sep 17 00:00:00 2001 From: Albert Date: Thu, 30 Apr 2026 21:31:41 +0200 Subject: [PATCH] Stabilize Dockerfile for PHP Apache --- Dockerfile | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/Dockerfile b/Dockerfile index 8e64667..e922671 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,13 +1,15 @@ -FROM php:8.2-apache +FROM php:8.2-apache-bookworm -RUN apt-get update && apt-get install -y \ +ENV DEBIAN_FRONTEND=noninteractive + +RUN apt-get update && apt-get install -y --no-install-recommends \ libcurl4-openssl-dev \ libonig-dev \ ca-certificates \ - unzip \ - git \ && docker-php-ext-install curl mbstring mysqli pdo pdo_mysql \ && a2enmod rewrite \ + && echo "ServerName localhost" > /etc/apache2/conf-available/servername.conf \ + && a2enconf servername \ && rm -rf /var/lib/apt/lists/* COPY . /var/www/html/ @@ -15,3 +17,5 @@ COPY . /var/www/html/ RUN mkdir -p /var/www/html/api/cache \ && chown -R www-data:www-data /var/www/html \ && chmod -R 775 /var/www/html/api/cache + +EXPOSE 80