자동빌드 배포 오류 수정
This commit is contained in:
+17
-3
@@ -49,17 +49,31 @@ while read -r OLDREV NEWREV REFNAME; do
|
||||
WORK_TREE="$WORK_TREE" "$RELOAD" >> "$DEPLOY_LOG" 2>&1 || true
|
||||
fi
|
||||
|
||||
# Desktop(macOS·Windows) Jenkins 빌드 — git push 성공 후 자동 (웹 배포와 독립)
|
||||
chmod +x "$WORK_TREE/scripts/update-desktop-source-state.sh" 2>/dev/null || true
|
||||
if [[ -x "$WORK_TREE/scripts/update-desktop-source-state.sh" ]]; then
|
||||
WORK_TREE="$WORK_TREE" "$WORK_TREE/scripts/update-desktop-source-state.sh" || true
|
||||
fi
|
||||
|
||||
# Desktop(macOS·Windows) Jenkins 빌드 — 데스크톱 영향 변경 시에만 자동 트리거
|
||||
WORK_TREE="${WORK_TREE:-/Users/aidev/apps/goldenChart}"
|
||||
TRIGGER="${WORK_TREE}/scripts/trigger-desktop-jenkins-build.sh"
|
||||
if [ -x "$TRIGGER" ]; then
|
||||
DESKTOP_BUILD_NEEDED=1
|
||||
if [[ -x "$WORK_TREE/scripts/desktop-version-scope.sh" ]]; then
|
||||
# shellcheck disable=SC1091
|
||||
source "$WORK_TREE/scripts/desktop-version-scope.sh"
|
||||
if ! desktop_version_diff_affects_app "$OLDREV..$NEWREV"; then
|
||||
DESKTOP_BUILD_NEEDED=0
|
||||
echo "$(date '+%Y-%m-%d %H:%M:%S') $HOOK_TAG Desktop Jenkins 스kip — 데스크톱 영향 없는 변경"
|
||||
fi
|
||||
fi
|
||||
if [ "$DESKTOP_BUILD_NEEDED" = "1" ] && [ -x "$TRIGGER" ]; then
|
||||
echo "$(date '+%Y-%m-%d %H:%M:%S') $HOOK_TAG Desktop Jenkins 빌드 트리거"
|
||||
if "$TRIGGER" >> "$DEPLOY_LOG" 2>&1; then
|
||||
echo "$(date '+%Y-%m-%d %H:%M:%S') $HOOK_TAG Desktop 빌드 큐 등록 완료"
|
||||
else
|
||||
echo "$(date '+%Y-%m-%d %H:%M:%S') $HOOK_TAG [WARN] Desktop Jenkins 트리거 실패 (웹 배포는 성공)"
|
||||
fi
|
||||
else
|
||||
elif [ "$DESKTOP_BUILD_NEEDED" = "1" ]; then
|
||||
echo "$(date '+%Y-%m-%d %H:%M:%S') $HOOK_TAG [WARN] trigger-desktop-jenkins-build.sh 없음: $TRIGGER"
|
||||
fi
|
||||
|
||||
|
||||
Reference in New Issue
Block a user