chore: exdev 배포 경로 단일화 및 서버 재구축 스크립트 추가

- Git 저장소/배포 work-tree를 /Users/aidev/apps/goldenChart로 통일
- 레거시 dev 경로는 심볼릭 링크로 흡수, deploy.sh에 소스 검증·no-cache 옵션
- server-rebuild-exdev.sh, verify-source-sync.sh 추가

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
Macbook
2026-06-02 22:55:12 +09:00
parent 85285f65c7
commit da11a9c29f
5 changed files with 288 additions and 8 deletions
+37
View File
@@ -0,0 +1,37 @@
#!/usr/bin/env bash
# 로컬 ↔ 서버 work-tree 소스 동일성 검증
set -euo pipefail
REMOTE="${REMOTE:-aidev@exdev.co.kr}"
WORK_TREE="${WORK_TREE:-/Users/aidev/apps/goldenChart}"
LOCAL_ROOT="$(cd "$(dirname "$0")/.." && pwd)"
FILES=(
frontend/src/utils/ChartManager.ts
frontend/src/utils/IchimokuCloudPlugin.ts
frontend/package-lock.json
scripts/deploy.sh
)
echo "=== 로컬 ↔ 서버 체크섬 ($REMOTE:$WORK_TREE) ==="
FAIL=0
for f in "${FILES[@]}"; do
L="$LOCAL_ROOT/$f"
[ -f "$L" ] || { echo "MISSING local $f"; FAIL=1; continue; }
LHASH=$(shasum -a 256 "$L" | awk '{print $1}')
RHASH=$(ssh -o BatchMode=yes "$REMOTE" "shasum -a 256 '$WORK_TREE/$f' 2>/dev/null" | awk '{print $1}')
if [ "$LHASH" = "$RHASH" ]; then
echo "OK $f"
else
echo "DIFF $f"
echo " local=$LHASH"
echo " remote=$RHASH"
FAIL=1
fi
done
echo "=== Git HEAD ==="
echo -n "local: "; git -C "$LOCAL_ROOT" rev-parse HEAD
echo -n "remote: "; ssh -o BatchMode=yes "$REMOTE" "git --git-dir=/Volumes/ADATA/git/goldenChart.git rev-parse HEAD"
echo ""
[ "$FAIL" -eq 0 ] && echo "검증 통과" || { echo "검증 실패"; exit 1; }