From aa03b973d3efa36af9bac6dd8d9180e0143d0251 Mon Sep 17 00:00:00 2001 From: des Date: Wed, 11 Nov 2026 18:02:44 +0100 Subject: [PATCH] Add Renovate config for Go modules, Docker images and GitHub Actions Renovate runs Monday mornings (Europe/Berlin) with at most 5 open PRs and a Dependency Dashboard. Go modules (non-major), GitHub Actions and the Go toolchain (go directive + golang builder image) each get one grouped PR. Majors wait for dashboard approval; vulnerability fixes open immediately. Automerge is limited to minor/patch Actions and patch updates of direct Go modules, after CI passes. Dockerfile base images get pinned to digests and are never automerged. Pin staticcheck in CI to 2026.2.2 (what "latest" resolves to today) so Renovate can track it instead of lint changing underneath us. --- .github/workflows/ci.yml | 3 +- CLAUDE.md | 10 +++ renovate.json | 144 +++++++++++++++++++++++++++++++++++++++ 3 files changed, 156 insertions(+), 1 deletion(-) create mode 100644 renovate.json diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index d0b45c1..2205f69 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -30,7 +30,8 @@ jobs: - name: Staticcheck uses: dominikh/staticcheck-action@v1 with: - version: latest + # renovate: datasource=github-releases depName=dominikh/go-tools + version: "2026.2.2" test: runs-on: ubuntu-latest diff --git a/CLAUDE.md b/CLAUDE.md index 694ef8b..22dcb9d 100644 --- a/CLAUDE.md +++ b/CLAUDE.md @@ -46,6 +46,16 @@ docker compose up -d # Run with PostgreSQL + Streamable HTTP (via supergatewa - Never add Claude as a co-author in commit messages (no `Co-Authored-By: Claude` lines). +## Dependency Updates (Renovate) + +`renovate.json` drives the Renovate GitHub App (Dependency Dashboard issue in this repo): +- Runs Mondays before 9am Europe/Berlin, max 5 open PRs; vulnerability fixes (GitHub + OSV) open immediately, labelled `security`. +- Covers go.mod (`gomodTidy` keeps go.sum in sync), Dockerfile + docker-compose images, GitHub Actions, and the staticcheck version in `ci.yml` (via the `# renovate:` comment). +- Groups: "Go modules (non-major)", "GitHub Actions", and "Go toolchain" (go directive + `golang` builder image move together). +- Major updates wait for approval on the Dependency Dashboard. Dockerfile base images are pinned to digests. +- Automerge only for minor/patch GitHub Actions and patch updates of direct Go modules, after CI is green. Never for Docker images, the toolchain, or majors. +- Merging Renovate PRs does not release anything; releases still need a `v*` tag. + ## MCP Library Uses `github.com/mark3labs/mcp-go` for MCP protocol support (stdio + SSE transports). diff --git a/renovate.json b/renovate.json new file mode 100644 index 0000000..20346bb --- /dev/null +++ b/renovate.json @@ -0,0 +1,144 @@ +{ + "$schema": "https://docs.renovatebot.com/renovate-schema.json", + "extends": [ + "config:recommended" + ], + "ignorePresets": [ + "group:monorepos" + ], + "timezone": "Europe/Berlin", + "schedule": [ + "before 9am on monday" + ], + "prConcurrentLimit": 5, + "postUpdateOptions": [ + "gomodTidy" + ], + "platformAutomerge": true, + "automergeType": "pr", + "osvVulnerabilityAlerts": true, + "vulnerabilityAlerts": { + "enabled": true, + "schedule": [ + "at any time" + ], + "dependencyDashboardApproval": false, + "labels": [ + "security" + ] + }, + "customManagers": [ + { + "customType": "regex", + "description": "staticcheck version pinned in CI (dominikh/staticcheck-action input)", + "managerFilePatterns": [ + "/^\\.github/workflows/[^/]+\\.ya?ml$/" + ], + "matchStrings": [ + "# renovate: datasource=(?\\S+) depName=(?\\S+)\\s+version: [\"']?(?[^\"'\\s]+)" + ], + "versioningTemplate": "regex:^(?\\d+)\\.(?\\d+)(\\.(?\\d+))?$" + } + ], + "packageRules": [ + { + "description": "Major updates only after approval on the Dependency Dashboard", + "matchUpdateTypes": [ + "major" + ], + "dependencyDashboardApproval": true + }, + { + "description": "Pin Dockerfile base images to digests", + "matchManagers": [ + "dockerfile" + ], + "pinDigests": true + }, + { + "description": "One PR for Go module minor/patch updates", + "matchManagers": [ + "gomod" + ], + "matchUpdateTypes": [ + "minor", + "patch", + "digest" + ], + "groupName": "Go modules (non-major)", + "groupSlug": "go-modules-non-major" + }, + { + "description": "Automerge patch updates of direct Go modules once CI is green", + "matchManagers": [ + "gomod" + ], + "matchDepTypes": [ + "require" + ], + "matchUpdateTypes": [ + "patch" + ], + "automerge": true + }, + { + "description": "One PR for GitHub Actions; minor/patch automerge once CI is green", + "matchManagers": [ + "github-actions" + ], + "groupName": "GitHub Actions" + }, + { + "matchManagers": [ + "github-actions" + ], + "matchUpdateTypes": [ + "minor", + "patch", + "digest", + "pin", + "pinDigest" + ], + "automerge": true + }, + { + "description": "Bump the go directive in go.mod (it is a minimum, so Renovate would otherwise never raise it)", + "matchManagers": [ + "gomod" + ], + "matchDepTypes": [ + "golang" + ], + "rangeStrategy": "bump" + }, + { + "description": "Move the Go toolchain together: go directive in go.mod + golang builder image", + "matchDepNames": [ + "go", + "golang" + ], + "groupName": "Go toolchain", + "automerge": false, + "groupSlug": "go-toolchain", + "matchDatasources": [ + "golang-version", + "docker" + ] + }, + { + "description": "Never automerge Dockerfile base images", + "matchManagers": [ + "dockerfile" + ], + "automerge": false + }, + { + "description": "Self-reference: never update our own published image", + "matchPackageNames": [ + "ghcr.io/giglabocom/watchword", + "ghcr.io/giglabo/watchword" + ], + "enabled": false + } + ] +}