diff --git a/.github/CLAUDE.md b/.github/CLAUDE.md index e384561be..230df5e2a 100644 --- a/.github/CLAUDE.md +++ b/.github/CLAUDE.md @@ -21,11 +21,11 @@ workflows (`> …`, prefixed `_`) are called via `uses:`. | `claude-code-interactive.yml` | `@claude` mentions + workflow_dispatch | `_claude-code` (interactive) | | `claude-code-automation-pr-review.yml` | PR with `claude` label or `ready_for_review` | `_claude-code` (automation) | | `claude-code-automation-operational-excellence-weekly.yml` | schedule + workflow_dispatch | `_claude-code` (automation) | -| `scheduled-testing-staging-hourly.yml` | cron `0 * * * *` | `_scheduled-test-hourly` (staging) | -| `scheduled-testing-staging-daily.yml` | cron `0 12 * * *` | `_scheduled-test-daily` (staging) | -| `scheduled-testing-production-hourly.yml` | cron `0 * * * *` | `_scheduled-test-hourly` (production) | -| `scheduled-testing-production-daily.yml` | cron `0 12 * * *` | `_scheduled-test-daily` (production) | -| `scheduled-audit-hourly.yml` | cron `0 * * * *` | `_scheduled-audit` | +| `scheduled-testing-staging-hourly.yml` | cron `17 * * * *` | `_scheduled-test-hourly` (staging) | +| `scheduled-testing-staging-daily.yml` | cron `31 12 * * *` | `_scheduled-test-daily` (staging) | +| `scheduled-testing-production-hourly.yml` | cron `17 * * * *` | `_scheduled-test-hourly` (production) | +| `scheduled-testing-production-daily.yml` | cron `31 12 * * *` | `_scheduled-test-daily` (production) | +| `scheduled-audit-hourly.yml` | cron `43 * * * *` | `_scheduled-audit` | | `codeql-scheduled.yml` | cron `22 3 * * 2` (Tue 03:22) | `_codeql` | | `labels-sync.yml` | push to label config | — | @@ -148,10 +148,11 @@ or GCP credentials. ## Scheduled jobs -- **Testing** — staging and production each run **hourly** (`0 * * * *`, via - `_scheduled-test-hourly.yml`) and **daily at 12:00 UTC** (`0 12 * * *`, via - `_scheduled-test-daily.yml`). Run `make test_scheduled`, send a BetterStack - heartbeat. Staging → `https://platform-staging.aignostics.com`, production → +- **Testing** — staging and production each run **hourly** (`17 * * * *`, via + `_scheduled-test-hourly.yml`) and **daily at 12:31 UTC** (`31 12 * * *`, via + `_scheduled-test-daily.yml`). The crons avoid minute 0: GitHub documents + that `schedule` events are delayed most at the start of every hour. Run + `make test_scheduled`, send a BetterStack heartbeat. Staging → `https://platform-staging.aignostics.com`, production → `https://platform.aignostics.com`. - **Audit** — hourly (`_scheduled-audit.yml`): `pip-audit`, `pip-licenses`, Trivy SBOM scan + BetterStack heartbeat. diff --git a/.github/workflows/_scheduled-test-daily.yml b/.github/workflows/_scheduled-test-daily.yml index 106c586df..4be501d87 100644 --- a/.github/workflows/_scheduled-test-daily.yml +++ b/.github/workflows/_scheduled-test-daily.yml @@ -260,7 +260,7 @@ jobs: FAILED_TESTS="${{ steps.test-status.outputs.failed_tests }}" # Send heartbeat to Sentry, defining the schedule on the fly - SENTRY_EXIT_CODE=$(sentry-cli monitors run -e CI --schedule "0 12 * * *" --check-in-margin 30 --max-runtime 1 scheduled-testing-${{ inputs.platform_environment }}-hourly --timezone "Europe/Berlin" -- sh -c "exit $EXIT_CODE") + SENTRY_EXIT_CODE=$(sentry-cli monitors run -e CI --schedule "31 12 * * *" --check-in-margin 60 --max-runtime 1 scheduled-testing-${{ inputs.platform_environment }}-daily --timezone "Europe/Berlin" -- sh -c "exit $EXIT_CODE") # Provide heartbeat to BetterStack for monitoring/alerting if heartbeat url is configured as secret if [ -n "$BETTERSTACK_HEARTBEAT_URL" ]; then diff --git a/.github/workflows/_scheduled-test-hourly.yml b/.github/workflows/_scheduled-test-hourly.yml index 4513f835f..77a62bdd6 100644 --- a/.github/workflows/_scheduled-test-hourly.yml +++ b/.github/workflows/_scheduled-test-hourly.yml @@ -122,7 +122,7 @@ jobs: fi # Send heartbeat to Sentry, defining the schedule on the fly - SENTRY_EXIT_CODE=$(sentry-cli monitors run -e CI --schedule "0 * * * *" --check-in-margin 30 --max-runtime 1 scheduled-testing-${{ inputs.platform_environment }}-hourly --timezone "Europe/Berlin" -- sh -c "exit $EXIT_CODE") + SENTRY_EXIT_CODE=$(sentry-cli monitors run -e CI --schedule "17 * * * *" --check-in-margin 60 --max-runtime 1 scheduled-testing-${{ inputs.platform_environment }}-hourly --timezone "Europe/Berlin" -- sh -c "exit $EXIT_CODE") # Provide heartbeat to BetterStack for monitoring/alerting if heartbeat url is configured as secret if [ -n "$BETTERSTACK_HEARTBEAT_URL" ]; then diff --git a/.github/workflows/scheduled-audit-hourly.yml b/.github/workflows/scheduled-audit-hourly.yml index 4392ca3c6..ed50aa971 100644 --- a/.github/workflows/scheduled-audit-hourly.yml +++ b/.github/workflows/scheduled-audit-hourly.yml @@ -2,7 +2,7 @@ name: "+ Scheduled Audit (Hourly)" on: schedule: - - cron: '0 * * * *' + - cron: '43 * * * *' workflow_dispatch: inputs: branch: diff --git a/.github/workflows/scheduled-testing-production-daily.yml b/.github/workflows/scheduled-testing-production-daily.yml index a00b0b774..84e8490e8 100644 --- a/.github/workflows/scheduled-testing-production-daily.yml +++ b/.github/workflows/scheduled-testing-production-daily.yml @@ -2,7 +2,7 @@ name: "+ Scheduled Testing / Production (Daily)" on: schedule: - - cron: '0 12 * * *' + - cron: '31 12 * * *' workflow_dispatch: inputs: branch: diff --git a/.github/workflows/scheduled-testing-production-hourly.yml b/.github/workflows/scheduled-testing-production-hourly.yml index 4dd960dee..25e1a09c0 100644 --- a/.github/workflows/scheduled-testing-production-hourly.yml +++ b/.github/workflows/scheduled-testing-production-hourly.yml @@ -2,7 +2,7 @@ name: "+ Scheduled Testing / Production (Hourly)" on: schedule: - - cron: '0 * * * *' + - cron: '17 * * * *' workflow_dispatch: inputs: branch: diff --git a/.github/workflows/scheduled-testing-staging-daily.yml b/.github/workflows/scheduled-testing-staging-daily.yml index 64d9b6f2d..6286508a4 100644 --- a/.github/workflows/scheduled-testing-staging-daily.yml +++ b/.github/workflows/scheduled-testing-staging-daily.yml @@ -2,7 +2,7 @@ name: "+ Scheduled Testing / Staging (Daily)" on: schedule: - - cron: '0 12 * * *' + - cron: '31 12 * * *' workflow_dispatch: inputs: branch: diff --git a/.github/workflows/scheduled-testing-staging-hourly.yml b/.github/workflows/scheduled-testing-staging-hourly.yml index 878b8106e..b3d9dd94d 100644 --- a/.github/workflows/scheduled-testing-staging-hourly.yml +++ b/.github/workflows/scheduled-testing-staging-hourly.yml @@ -2,7 +2,7 @@ name: "+ Scheduled Testing / Staging (Hourly)" on: schedule: - - cron: '0 * * * *' + - cron: '17 * * * *' workflow_dispatch: inputs: branch: