LaravelPublisher v.0.0.2 修正不會換檔問題 20250610

This commit is contained in:
allen.yan 2025-06-10 14:57:23 +08:00
parent 2a950fcdec
commit 296f3a731e
2 changed files with 3 additions and 4 deletions

View File

@ -2,9 +2,7 @@ FROM php:8.3-fpm
# ---- system & PHP extensions -------------------------------------------------
RUN apt-get update && apt-get install -y --no-install-recommends \
nginx \
gettext \
logrotate \
procps nginx gettext logrotate \
git unzip zip curl ca-certificates supervisor cron nano \
libpng-dev libjpeg62-turbo-dev libfreetype6-dev \
libonig-dev libxml2-dev libzip-dev libpq-dev libicu-dev libxslt-dev \

View File

@ -43,8 +43,9 @@ php-fpm -D
envsubst '${NGINX_HOST} ${NGINX_PORT}' < /etc/nginx/templates/default.conf.template > /etc/nginx/conf.d/default.conf
exec nginx -g "daemon off;"
chmod -R go-w /etc/logrotate.d/app
echo "0 0 * * * root /usr/sbin/logrotate /etc/logrotate.d/app" > /etc/cron.d/logrotate-Laravel
chmod 0644 /etc/cron.d/logrotate-Laravel
crontab /etc/cron.d/logrotate-Laravel
echo "[entrypoint] Testing logrotate config..."
logrotate --debug /etc/logrotate.d/app/laravel.conf