Workers Invocations Chart #30
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Workers Invocations Chart | |
| on: | |
| schedule: | |
| # 한국시간 00:20 = UTC 15:20 (전날) | |
| - cron: '20 15 * * *' | |
| workflow_dispatch: | |
| inputs: | |
| worker_script_name: | |
| description: 'Cloudflare Workers 스크립트 이름' | |
| required: false | |
| default: 'daiso-mcp' | |
| days: | |
| description: '그래프 기간(일)' | |
| required: false | |
| default: '30' | |
| start_date: | |
| description: '그래프 시작일(YYYY-MM-DD)' | |
| required: false | |
| default: '2026-03-01' | |
| permissions: | |
| contents: write | |
| jobs: | |
| update-chart: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v6 | |
| - name: Setup Node.js | |
| uses: actions/setup-node@v6 | |
| with: | |
| node-version: '20' | |
| cache: npm | |
| - name: Install Korean fonts | |
| run: | | |
| sudo apt-get update | |
| sudo apt-get install -y fonts-noto-cjk fonts-nanum | |
| - name: Install dependencies | |
| run: npm ci | |
| - name: Update workers invocations chart | |
| env: | |
| CLOUDFLARE_ACCOUNT_ID: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }} | |
| CLOUDFLARE_API_TOKEN: ${{ secrets.CLOUDFLARE_API_TOKEN }} | |
| CF_WORKER_SCRIPT_NAME: ${{ inputs.worker_script_name || vars.CF_WORKER_SCRIPT_NAME || 'daiso-mcp' }} | |
| WORKERS_CHART_DAYS: ${{ inputs.days || '30' }} | |
| WORKERS_CHART_START_DATE: ${{ inputs.start_date || vars.WORKERS_CHART_START_DATE || '2026-03-01' }} | |
| run: npm run update:workers-chart | |
| - name: Commit changes | |
| uses: stefanzweifel/git-auto-commit-action@v7 | |
| with: | |
| commit_message: 'chore: 워커 호출량 그래프 자동 갱신' | |
| file_pattern: 'README.md assets/analytics/workers-invocations.*' |