From 1c4b161acf372235535544fd7ea2a4118519310b Mon Sep 17 00:00:00 2001 From: developjik <67889389+developjik@users.noreply.github.com> Date: Tue, 24 Nov 2026 14:27:39 +0900 Subject: [PATCH 1/5] Refactor deploy.yml with action version updates Updated GitHub Actions workflow to use specific versions of actions and adjusted permissions. --- .github/workflows/deploy.yml | 20 ++++++++++++-------- 1 file changed, 12 insertions(+), 8 deletions(-) diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index 522ecf4..2aadf06 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -7,8 +7,6 @@ on: permissions: contents: read - pages: write - id-token: write concurrency: group: pages @@ -22,10 +20,10 @@ jobs: contents: write runs-on: ubuntu-latest steps: - - uses: actions/checkout@v7 + - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7 with: ref: main - - uses: actions/setup-node@v7 + - uses: actions/setup-node@949feb2413d6458794dcd2491c4babbbce0c15c1 # v7 with: node-version: 20 - name: README 수치 동기화 @@ -45,10 +43,13 @@ jobs: git push origin HEAD:main build: + permissions: + contents: read + pages: read runs-on: ubuntu-latest steps: - - uses: actions/checkout@v7 - - uses: actions/setup-node@v7 + - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7 + - uses: actions/setup-node@949feb2413d6458794dcd2491c4babbbce0c15c1 # v7 with: node-version: 20 cache: npm @@ -64,10 +65,13 @@ jobs: - name: Build (slop-lint 게이트 포함) run: npm run build working-directory: web - - uses: actions/upload-pages-artifact@v5 + - uses: actions/upload-pages-artifact@fc324d3547104276b827a68afc52ff2a11cc49c9 # v5 with: path: web/dist deploy: + permissions: + pages: write + id-token: write needs: build runs-on: ubuntu-latest environment: @@ -75,4 +79,4 @@ jobs: url: ${{ steps.deployment.outputs.page_url }} steps: - id: deployment - uses: actions/deploy-pages@v5 + uses: actions/deploy-pages@368f82528645a54fb793d4d04e342629a3f51346 # v5 From fba64ca34f680c00b8362d97c2046a9e8433bc16 Mon Sep 17 00:00:00 2001 From: developjik <67889389+developjik@users.noreply.github.com> Date: Tue, 24 Nov 2026 14:27:46 +0900 Subject: [PATCH 2/5] Update fetch-candidates.yml --- .github/workflows/fetch-candidates.yml | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/.github/workflows/fetch-candidates.yml b/.github/workflows/fetch-candidates.yml index 879f451..89a75c0 100644 --- a/.github/workflows/fetch-candidates.yml +++ b/.github/workflows/fetch-candidates.yml @@ -10,7 +10,7 @@ on: workflow_dispatch: permissions: - contents: write + contents: read concurrency: group: fetch-candidates @@ -18,12 +18,14 @@ concurrency: jobs: scan: + permissions: + contents: write runs-on: ubuntu-latest steps: - - uses: actions/checkout@v7 + - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7 with: ref: main # detached HEAD 가 아닌 main 브랜치로 체크아웃(푸시 대상) - - uses: actions/setup-node@v7 + - uses: actions/setup-node@949feb2413d6458794dcd2491c4babbbce0c15c1 # v7 with: node-version: 20 - name: 콜드스탠바이 fetch 스윕 (새 후보가 있을 때만 queue/ 에 기록) From 5db34291b3daea29dbf5a361699edd4c779fb133 Mon Sep 17 00:00:00 2001 From: developjik <67889389+developjik@users.noreply.github.com> Date: Tue, 24 Nov 2026 14:27:51 +0900 Subject: [PATCH 3/5] Update news-refresh.yml --- .github/workflows/news-refresh.yml | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/.github/workflows/news-refresh.yml b/.github/workflows/news-refresh.yml index d631503..b65d8a5 100644 --- a/.github/workflows/news-refresh.yml +++ b/.github/workflows/news-refresh.yml @@ -8,8 +8,7 @@ on: workflow_dispatch: permissions: - contents: write - actions: write # deploy.yml 을 workflow_dispatch 로 깨우기 위해 + contents: read concurrency: group: news-refresh @@ -17,12 +16,15 @@ concurrency: jobs: refresh: + permissions: + contents: write + actions: write runs-on: ubuntu-latest steps: - - uses: actions/checkout@v7 + - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7 with: ref: main # detached HEAD 가 아닌 main 브랜치로 체크아웃(푸시 대상) - - uses: actions/setup-node@v7 + - uses: actions/setup-node@949feb2413d6458794dcd2491c4babbbce0c15c1 # v7 with: node-version: 20 - name: 뉴스 수집 (바뀐 게 없으면 파일을 쓰지 않는다) From 6c46ed5c77597e686c13f463d640348e9260190e Mon Sep 17 00:00:00 2001 From: developjik <67889389+developjik@users.noreply.github.com> Date: Tue, 24 Nov 2026 14:27:56 +0900 Subject: [PATCH 4/5] Update watchdog.yml --- .github/workflows/watchdog.yml | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/.github/workflows/watchdog.yml b/.github/workflows/watchdog.yml index a419cad..1806847 100644 --- a/.github/workflows/watchdog.yml +++ b/.github/workflows/watchdog.yml @@ -9,19 +9,21 @@ on: workflow_dispatch: permissions: - issues: write contents: read - actions: read # fetch-candidates 실행 결과 조회(진단) jobs: check: + permissions: + issues: write + contents: read + actions: read runs-on: ubuntu-latest steps: - - uses: actions/checkout@v7 + - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7 with: ref: main fetch-depth: 0 # 진단: 마지막 루틴 커밋 이후 이력 + 원격 브랜치 전부 - - uses: actions/setup-node@v7 + - uses: actions/setup-node@949feb2413d6458794dcd2491c4babbbce0c15c1 # v7 with: node-version: 20 - name: Check last_run freshness From 5c344f6663213b31c47bd77c7ec669c9c7ecb29c Mon Sep 17 00:00:00 2001 From: developjik <67889389+developjik@users.noreply.github.com> Date: Tue, 24 Nov 2026 14:37:08 +0900 Subject: [PATCH 5/5] Add CI workflow for testing and building project --- .github/workflows/ci.yml | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100644 .github/workflows/ci.yml diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 0000000..92c8689 --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,25 @@ +name: CI +on: + pull_request: +permissions: + contents: read +jobs: + test-build: + runs-on: ubuntu-latest + timeout-minutes: 15 + steps: + - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7 + - uses: actions/setup-node@949feb2413d6458794dcd2491c4babbbce0c15c1 # v7 + with: + node-version: 20 + cache: npm + cache-dependency-path: web/package-lock.json + - name: Collector and shorts tests + run: | + python3 -m venv /tmp/tv + /tmp/tv/bin/pip install --quiet pillow + PATH=/tmp/tv/bin:$PATH npm test + - run: npm ci + working-directory: web + - run: npm run build + working-directory: web