This commit is contained in:
francesco
2026-06-19 16:40:19 +02:00
parent 5a32bebe32
commit abd6e5c21b
2 changed files with 15 additions and 0 deletions

View File

@@ -25,6 +25,14 @@ services:
start_period: 45s
environment:
- PHP_OPCACHE_VALIDATE_TIMESTAMPS=1
# DB/Redis creds must be passed into the container so the entrypoint can
# upsert them into .env. Defaults match the mariadb/redis services below.
- DB_HOST=${DB_HOST:-mariadb}
- DB_DATABASE=${DB_DATABASE:-termanager2}
- DB_USERNAME=${DB_USERNAME:-termanager2}
- DB_PASSWORD=${DB_PASSWORD:-secret}
- REDIS_HOST=${REDIS_HOST:-redis}
- REDIS_PASSWORD=${REDIS_PASSWORD:-redissecret}
- SEED_DEV_DATA=${SEED_DEV_DATA:-false}
- RUN_DB_SEED_ON_FIRST_START=${RUN_DB_SEED_ON_FIRST_START:-true}
- ENSURE_INITIAL_ADMIN_ON_EMPTY_DB=${ENSURE_INITIAL_ADMIN_ON_EMPTY_DB:-true}

View File

@@ -174,6 +174,13 @@ else
echo "[✓] Storage symlink already exists."
fi
# -----------------------------------------------
# 6b. Clear any stale cached config from a previous deploy
# (a cached bootstrap/cache/config.php would override the .env above)
# -----------------------------------------------
echo "[*] Clearing stale cached config..."
php artisan config:clear || warn "config:clear failed; continuing startup."
# -----------------------------------------------
# 7. Run migrations
# -----------------------------------------------