diff --git a/Dockerfile b/Dockerfile index ae525c0..dd308b8 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,10 +1,19 @@ -FROM php:8.1-fpm +FROM php:8.4-fpm -# Install dependencies +# Install system dependencies & PHP extensions RUN apt-get update && apt-get install -y \ + libzip-dev \ + unzip \ + git \ libpq-dev \ - zip unzip curl git \ - && docker-php-ext-install pdo_pgsql + libicu-dev \ + zip \ + curl \ + && docker-php-ext-install \ + intl \ + zip \ + pdo_pgsql \ + bcmath # Install Composer COPY --from=composer:2 /usr/bin/composer /usr/bin/composer @@ -14,21 +23,18 @@ WORKDIR /var/www # Copy source COPY . . - -# Copy default env COPY .env.example .env -# Install Laravel dependencies +# Install dependencies RUN composer install --no-interaction --prefer-dist --optimize-autoloader -# Generate Laravel app key +# Generate app key RUN php artisan key:generate -# Set permissions for Laravel +# Set permissions RUN chown -R www-data:www-data /var/www \ - && chmod -R 755 /var/www \ && chmod -R 775 storage bootstrap/cache \ && chown -R www-data:www-data storage bootstrap/cache EXPOSE 9000 -CMD ["php-fpm"] +CMD ["php-fpm"] \ No newline at end of file