feat: update Docker configuration to manage public storage and optimize entrypoint script
This commit is contained in:
@@ -41,15 +41,19 @@ chmod -R 775 \
|
||||
bootstrap/cache \
|
||||
database
|
||||
|
||||
# ── 5. Run migrations ────────────────────────
|
||||
# ── 5. Discover packages (composer --no-scripts skips this) ──
|
||||
echo "[packages] Discovering service providers…"
|
||||
php artisan package:discover --ansi 2>/dev/null || true
|
||||
|
||||
# ── 6. Run migrations ─────────────────────────
|
||||
echo "[migrate] Running database migrations…"
|
||||
php artisan migrate --force --no-interaction
|
||||
|
||||
# ── 5b. Create public storage symlink ────────
|
||||
# ── 7. Create public storage symlink ──────────
|
||||
echo "[storage] Creating public storage symlink…"
|
||||
php artisan storage:link --quiet 2>/dev/null || true
|
||||
|
||||
# ── 6. Cache config / routes / views ────────
|
||||
# ── 8. Cache config / routes / views ─────────
|
||||
echo "[optimize] Caching configuration…"
|
||||
php artisan config:cache --quiet
|
||||
php artisan route:cache --quiet
|
||||
@@ -59,5 +63,5 @@ echo "────────────────────────
|
||||
echo " All checks passed. Starting services…"
|
||||
echo "──────────────────────────────────────────"
|
||||
|
||||
# ── 7. Hand off to Supervisor ────────────────
|
||||
# ── 9. Hand off to Supervisor ────────────────
|
||||
exec supervisord -c /etc/supervisord.conf
|
||||
|
||||
Reference in New Issue
Block a user