From 4e9d7a629c7198b513784bebb97f00ea367ec148 Mon Sep 17 00:00:00 2001 From: "Fabian @ Blax Software" Date: Thu, 23 Apr 2026 11:04:47 +0200 Subject: [PATCH] I safe directory inside --- scripts/start-container | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/scripts/start-container b/scripts/start-container index 8244eb8..9f311d4 100755 --- a/scripts/start-container +++ b/scripts/start-container @@ -20,6 +20,15 @@ echo "[1/5] Preparing writable dirs..." mkdir -p /.composer && chmod 0777 /.composer 2>/dev/null || true +if command -v git >/dev/null 2>&1; then + if git config --system --get-all safe.directory 2>/dev/null | grep -Fxq "/var/www/html"; then + echo " git safe.directory already includes /var/www/html" + else + git config --system --add safe.directory /var/www/html 2>/dev/null || true + echo " Added git safe.directory: /var/www/html" + fi +fi + if [ "${ENABLE_LARAVEL_PERMS:-0}" = "1" ]; then echo " ENABLE_LARAVEL_PERMS=1 — applying targeted writable-dir fixes" for p in /var/www/html/storage /var/www/html/bootstrap/cache; do