From 110c0f7291432a560757891c9f81b348873a75f6 Mon Sep 17 00:00:00 2001 From: Frank John Begornia Date: Thu, 18 Dec 2025 12:14:14 +0800 Subject: [PATCH] Fix: Create storage directories and set proper permissions --- Dockerfile | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/Dockerfile b/Dockerfile index 418f250..fc01642 100644 --- a/Dockerfile +++ b/Dockerfile @@ -32,10 +32,17 @@ WORKDIR /var/www/html # Copy existing application directory contents COPY . /var/www/html -# Copy existing application directory permissions +# Create storage directories and set permissions +RUN mkdir -p storage/framework/views \ + storage/framework/cache \ + storage/framework/sessions \ + storage/logs \ + bootstrap/cache + +# Set proper ownership and permissions RUN chown -R www-data:www-data /var/www/html \ - && chmod -R 755 /var/www/html/storage \ - && chmod -R 755 /var/www/html/bootstrap/cache + && chmod -R 775 /var/www/html/storage \ + && chmod -R 775 /var/www/html/bootstrap/cache # Create .env file if it doesn't exist RUN if [ ! -f .env ]; then cp .env.example .env; fi