diff --git a/Dockerfile b/Dockerfile index e5570779..b04c39b3 100644 --- a/Dockerfile +++ b/Dockerfile @@ -13,7 +13,6 @@ RUN docker-php-ext-configure gd --with-freetype-dir=/usr/include/ --with-jpeg-di RUN docker-php-ext-install pdo pdo_mysql zip gd WORKDIR /app ADD . /app -RUN chown -R www-data:www-data /app RUN chmod 755 /app/storage RUN chmod 777 -R /app/bootstrap/cache @@ -23,5 +22,6 @@ RUN php artisan clear-compiled COPY wait.sh /usr/local/bin/wait.sh RUN chmod +x /usr/local/bin/wait.sh +RUN chown -R www-data:www-data /app CMD /usr/local/bin/wait.sh && composer update --no-scripts && composer dumpautoload && php artisan migrate && php artisan serve --host=0.0.0.0 --port=8000 EXPOSE 8000 diff --git a/caddy/Dockerfile b/caddy/Dockerfile index a36b4ea1..eb745bd2 100644 --- a/caddy/Dockerfile +++ b/caddy/Dockerfile @@ -15,5 +15,6 @@ COPY Caddyfile /etc/Caddyfile WORKDIR /var/www RUN mkdir -p /var/www/public/storage RUN ln -sf /var/www/storage/app/public /var/www/public/storage +RUN chown -R www-data:www-data /var/www CMD ["/usr/bin/caddy", "--conf", "/etc/Caddyfile", "--log", "stdout"] \ No newline at end of file