Created
August 9, 2025 04:29
-
-
Save arifnd/531effa8a23cde741ff35f3865638aa5 to your computer and use it in GitHub Desktop.
Example Dockerfile for run Laravel using serversideup/php Docker images
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| FROM serversideup/php:8.4-fpm-nginx-alpine | |
| WORKDIR /var/www/html | |
| COPY . . | |
| USER root | |
| RUN composer install --prefer-dist --no-progress --no-interaction --no-dev --optimize-autoloader \ | |
| && php artisan optimize \ # Can remove when set AUTORUN_ENABLED=true | |
| && chown -R www-data:www-data /var/www/html \ | |
| && chmod -R 755 /var/www/html/storage /var/www/html/bootstrap/cache | |
| USER www-data |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment