Notebook hourly health #1107
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: Notebook hourly health | |
| # Solo-ops heartbeat. Runs every hour against Convex prod. | |
| # Silent on green; posts to OPS_NTFY_URL when degraded. | |
| on: | |
| schedule: | |
| # Hourly at :07 (off-peak minute) so we don't collide with :00 cron jobs. | |
| - cron: "7 * * * *" | |
| workflow_dispatch: {} | |
| concurrency: | |
| group: notebook-hourly | |
| cancel-in-progress: false | |
| jobs: | |
| health: | |
| runs-on: ubuntu-latest | |
| timeout-minutes: 5 | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - uses: actions/setup-node@v6 | |
| with: | |
| package-manager-cache: false | |
| node-version: "20" | |
| - name: Install minimal dependencies | |
| run: npm ci --omit=dev --no-audit --no-fund || npm install --no-audit --no-fund | |
| - name: Run hourly health check | |
| env: | |
| VITE_CONVEX_URL: ${{ secrets.CONVEX_URL || vars.CONVEX_URL || 'https://agile-caribou-964.convex.cloud' }} | |
| CONVEX_URL: ${{ secrets.CONVEX_URL || vars.CONVEX_URL || 'https://agile-caribou-964.convex.cloud' }} | |
| OPS_NTFY_URL: ${{ secrets.OPS_NTFY_URL }} | |
| HEALTH_P95_MS_BUDGET: "500" | |
| HEALTH_ERROR_RATE_BUDGET: "0.01" | |
| HEALTH_APPEND_COUNT: "60" | |
| run: node scripts/ops/hourlyHealthCheck.mjs | |
| - name: Save health log (always) | |
| if: always() | |
| run: | | |
| mkdir -p .tmp | |
| node scripts/ops/hourlyHealthCheck.mjs > .tmp/notebook-hourly-health.json || true | |
| - name: Upload health artifact | |
| if: always() | |
| uses: actions/upload-artifact@v7 | |
| with: | |
| name: hourly-health-${{ github.run_id }} | |
| path: .tmp/notebook-hourly-health.json | |
| retention-days: 7 |