WBS-7.9: trim CI cache-hit overhead and wait for deploy readiness

This commit is contained in:
2026-06-22 01:38:11 +09:00
parent 4b1a33ba48
commit 47184a2f25
+16 -4
View File
@@ -5,6 +5,7 @@ on:
branches: [ main ] branches: [ main ]
pull_request: pull_request:
branches: [ main ] branches: [ main ]
workflow_dispatch:
# ───────────────────────────────────────────────────────────────── # ─────────────────────────────────────────────────────────────────
# Synology DS216j (ARMv7l 32-bit) 환경 제약 # Synology DS216j (ARMv7l 32-bit) 환경 제약
@@ -70,8 +71,13 @@ jobs:
ls -dt "$VENV_BASE"/*/ 2>/dev/null | tail -n +3 | xargs rm -rf 2>/dev/null || true ls -dt "$VENV_BASE"/*/ 2>/dev/null | tail -n +3 | xargs rm -rf 2>/dev/null || true
else else
echo "=== venv 캐시 히트: $("$VENV/bin/python" --version 2>&1) ===" echo "=== venv 캐시 히트: $("$VENV/bin/python" --version 2>&1) ==="
"$VENV/bin/python" - <<'PY'
import importlib
for mod in ("requests", "yaml", "openpyxl"):
importlib.import_module(mod)
print("venv dependency import check: PASS")
PY
fi fi
"$VENV/bin/pip" install requests pyyaml openpyxl --quiet
echo "$VENV/bin" >> $GITHUB_PATH echo "$VENV/bin" >> $GITHUB_PATH
- name: Install Node Dependencies - name: Install Node Dependencies
@@ -84,9 +90,15 @@ jobs:
if [ -d "$CACHE_DIR/node_modules" ]; then if [ -d "$CACHE_DIR/node_modules" ]; then
echo "=== node_modules 캐시 히트: $LOCK_HASH ===" echo "=== node_modules 캐시 히트: $LOCK_HASH ==="
# 캐시에서 심볼릭 링크로 연결 (복사 대신 즉시) # 이미 같은 캐시를 가리키고 있으면 재연결하지 않음
rm -rf node_modules if [ -L node_modules ] && [ "$(readlink node_modules)" = "$CACHE_DIR/node_modules" ]; then
ln -s "$CACHE_DIR/node_modules" node_modules echo "=== node_modules already linked to cache ==="
else
if [ -e node_modules ] || [ -L node_modules ]; then
rm -rf node_modules
fi
ln -s "$CACHE_DIR/node_modules" node_modules
fi
else else
echo "=== npm install (최초 or lock 변경) ===" echo "=== npm install (최초 or lock 변경) ==="
npm install --quiet npm install --quiet