Skip to content

fix(docker): setup-cache.sh local/docker 모드 지원#712

Merged
jk-kim0 merged 1 commit intomainfrom
fix/setup-cache-local-mode
Feb 13, 2026
Merged

fix(docker): setup-cache.sh local/docker 모드 지원#712
jk-kim0 merged 1 commit intomainfrom
fix/setup-cache-local-mode

Conversation

@jk-kim0
Copy link
Copy Markdown
Contributor

@jk-kim0 jk-kim0 commented Feb 13, 2026

Summary

  • setup-cache.shlocal/docker 두 가지 모드로 재작성
    • local: 로컬 var/에서 cache/로 복제 (cp -a) — fetch_state.yaml 포함
    • docker: Docker Hub 이미지에서 추출 후 이동 (mv) — 기존 동작
  • GHA 워크플로우에서 ./bin/setup-cache.sh docker 명시적 호출로 수정
  • Bash 코딩 스타일 가이드 적용 (log::do, namespace::function, set -o errtrace)

Background

cache/fetch_state.yaml이 누락되어 Docker 빌드 시 --recent 모드가 fetch state를 찾지 못하고, 기본 21일치 100개 페이지 + 첨부파일을 불필요하게 재다운로드하는 문제 발생. setup-cache.sh local 모드로 로컬 var/에서 cache를 구성하면 fetch_state.yaml이 포함되어 문제 해결.

Test results

  • bin/setup-cache.sh (인자 없이) → usage 출력, exit code 1
  • bin/setup-cache.sh local → 302개 숫자 디렉토리 + fetch_state.yaml 복제 확인
  • Docker 빌드: Auto-detected since_date 출력 ("No fetch state" 경고 미출력)
  • Docker 빌드: Skipped 100 pages (already up-to-date), 첨부파일 다운로드 0건

🤖 Generated with Claude Code

setup-cache.sh를 재작성하여 두 가지 소스 모드를 지원:
- `local`: 로컬 var/에서 cache/로 복제 (fetch_state.yaml 포함)
- `docker`: Docker Hub 이미지에서 추출 (기존 동작)

fetch_state.yaml이 cache에 누락되어 Docker 빌드 시 불필요한
21일치 페이지/첨부파일을 재다운로드하던 문제를 해결한다.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@vercel
Copy link
Copy Markdown

vercel Bot commented Feb 13, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
querypie-docs Ready Ready Preview, Comment Feb 13, 2026 0:05am

Request Review

@jk-kim0 jk-kim0 self-assigned this Feb 13, 2026
@jk-kim0 jk-kim0 merged commit e84aec4 into main Feb 13, 2026
7 checks passed
@jk-kim0 jk-kim0 deleted the fix/setup-cache-local-mode branch February 13, 2026 12:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant