fix(deployer): git pull 후 파일 소유권을 PUID:PGID로 복원
deployer 컨테이너가 root로 git pull을 실행하면 새 파일이 root:root 소유로 생성되어 다른 컨테이너에서 권한 문제 발생. pull 직후 chown -R로 원래 소유권(bgg8988:users)을 복원. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -45,6 +45,11 @@ cd "$SRC"
|
||||
git fetch --all --prune
|
||||
git pull --ff-only
|
||||
|
||||
# ── git pull 후 파일 소유권 복원 (deployer가 root로 실행되므로) ──
|
||||
DEPLOY_UID="${PUID:-1026}"
|
||||
DEPLOY_GID="${PGID:-100}"
|
||||
chown -R "${DEPLOY_UID}:${DEPLOY_GID}" "$SRC"
|
||||
|
||||
# ── 릴리즈 백업 (롤백용) ──
|
||||
TAG="$(date +%Y%m%d-%H%M%S)"
|
||||
BACKUP_DIR="$DST/.releases/$TAG"
|
||||
|
||||
Reference in New Issue
Block a user