Skip to content

chore(k8s): measure the first Renovate runs in the cluster #4909

Open

Description

@dan-petty

Update 2026-11-26 (infra move): the sections above the proposed design describe the Renovate CronJob that devops-cli no longer has. Follow the design below. dan-petty/homelab#366, dan-petty/homelab#367 and #6129 hold the open counts.


Problem or Motivation

The Renovate CronJob of #4905 has five facts that nobody measured:

  1. The paths that need a writable volume under a read-only root file system.
  2. The GitHub requests of one run, with a cold and a warm cache.
  3. The run time of each repository with postUpgradeTasks.
  4. The Docker Hub limits for 31 docker.io references.
  5. The push load on CI.

Proposed Solution & Architectural Design

  • Do this after feat(deps): track regular version updates with Renovate #4893 owner steps 1 to 6 (the App, the keyring rows, devops k8s push-secrets, Dependabot alerts, no hosted Renovate app).
  • Run the CronJob once with RENOVATE_DRY_RUN=lookup. Then remove the dry run.
  • Read the HTTP statistics and the timings of the run log.
  • Change the volumes, the split of the repositories or the schedule only where a number is over its budget.
  • Record the numbers in a pull request comment and in the Renovate section of docs/CLUSTER.md.
  • Budgets: GitHub gives each App installation 5,000 REST requests an hour. Secondary limits apply to each App: 100 concurrent requests, 900 REST points a minute, 80 content-creating requests a minute and 500 an hour. prHourlyLimit 2 keeps pull request creation far below them.

Target Subsystem

Kubernetes & Minikube Automation (self-hosted Renovate).

Existing Tool Considered

Renovate's own run log (HTTP statistics, repository timings) and kubectl. No new code.

Acceptance Criteria

  • One run of all repositories ends in less than 40 minutes.
  • One run uses at most 2,500 GitHub requests and gets no 403 or 429.
  • The pod runs with readOnlyRootFilesystem: true.
  • The Dependency Dashboard exists in devops-cli.
  • The first Monday window opens update pull requests for the measured backlog.
  • Renovate pushes on devops-cli stay at 40 or fewer in the first full week.
  • One security pull request path works: an OSV or Dependabot alert gives a [SECURITY] pull request, or the Dashboard summary lists no unresolved CVE.

Dependencies

#4896 (the repository config) and #4905 (the CronJob), plus #4893 owner steps 1 to 6. Child 5 of #4893.

Source: #4893

Alternatives check of 2026-11-26: not-applicable.
Class: chore, no model call.
Tool: none found.

Proposed design

Problem statement

Issue #6684 deleted k8s/devops/renovate and moved the Renovate workload to dan-petty/homelab#95. That repository runs the upstream chart in namespace devops. The earlier design measured the deleted deployment, so it cannot be built. This change records the measured facts of the first homelab run in the Renovate section of docs/CLUSTER.md, beside their budgets, after dan-petty/homelab#95. The request counts, the post-upgrade run time and the first-week push count stay in dan-petty/homelab#366, dan-petty/homelab#367 and #6129.

Acceptance criteria

Requirement: First run record

The Renovate section of docs/CLUSTER.md SHALL record the first homelab run with its run time, its repository counts and the 40-minute budget.

Scenario: The docs row accepts the record

  • WHEN uv run devops ci --check --only docs runs on the change.
  • THEN It exits 0.

Requirement: Writable paths and read-only root

The record SHALL name each writable path with its backing volume, and SHALL give the readOnlyRootFilesystem value.

Scenario: The docs row accepts the paths

  • WHEN uv run devops ci --check --only docs runs on the change.
  • THEN It exits 0.

Requirement: Warnings of the run

The record SHALL give each warning with its cause, or state that the run logged no warning.

Scenario: The docs row accepts the warnings

  • WHEN uv run devops ci --check --only docs runs on the change.
  • THEN It exits 0.

Requirement: Dashboard and security pull request

The record SHALL state that the first Monday window opened update pull requests, with the Dependency Dashboard number and each security pull request number, or none.

Scenario: The docs row accepts the numbers

  • WHEN uv run devops ci --check --only docs runs on the change.
  • THEN It exits 0.

Requirement: Request budget and open counts

The record SHALL give the 2,500 request budget with no 403 or 429 and name dan-petty/homelab#366, dan-petty/homelab#367 and #6129 for open counts.

Scenario: The docs row accepts the budget

  • WHEN uv run devops ci --check --only docs runs on the change.
  • THEN It exits 0.

Requirement: No change without a number over budget

The record SHALL state that no volume, repository split or schedule changes unless a measured number is over its budget.

Scenario: The docs row accepts the rule

  • WHEN uv run devops ci --check --only docs runs on the change.
  • THEN It exits 0.

Requirement: Pending a person after the merge

A person with kubectl SHALL create one Job from the Renovate CronJob in namespace devops and post its log to the pull request.

Scenario: The measurement Job

  • WHEN A person runs kubectl -n devops create job --from=cronjob/<name> <name> and kubectl -n devops logs job/<name> -c renovate.
  • THEN The pull request holds the log or its key lines.

Existing Tool Considered

The alternatives check of 2026-11-15 in the issue body gave not-applicable for this chore and named no tool. The measurement uses the open, maintained Renovate from the upstream chart in the homelab instance that docs/CLUSTER.md:271 names, and kubectl. The change builds no code, so the cost to build, keep and fix it is 0 tokens and no elapsed time.

Key questions

  • What does the issue measure after refactor(k8s): move self-hosted Renovate out of the product #6684?: It measures the first runs of the homelab Renovate instance from the upstream chart in namespace devops, after dan-petty/homelab#95. It does not document the deleted k8s/devops/renovate CronJob. [sources: docs/CLUSTER.md:271]
  • Where does the measurement record live?: In the Renovate section of docs/CLUSTER.md, beside the statement that the homelab instance runs the upstream chart. (best practice) [sources: docs/CLUSTER.md:271, k8s/README.md:12]
    • Chosen: The Renovate section of docs/CLUSTER.md. docs/CLUSTER.md:271 names the homelab instance, and the file holds the service facts of the cluster.
    • Rejected: The Renovate section of k8s/README.md. k8s/README.md:12 calls the folder the environment tree, and it holds no run record of one service.
    • Rejected: A new document under docs/. A second document adds a second place for the service facts that docs/CLUSTER.md already holds.
  • How does a person start a measurement run without the schedule?: Create a Job from the Renovate CronJob in namespace devops with kubectl -n devops create job --from=cronjob/<name> <name>, then read its log with kubectl -n devops logs job/<name> -c renovate. The homelab chart gives the CronJob name. (best practice) [sources: docs/CLUSTER.md:265]
    • Chosen: Create one Job from the CronJob with kubectl. docs/CLUSTER.md:265 documents the command, and it copies the CronJob template with its volumes and cache.
    • Rejected: Wait for the next schedule. The schedule chooses the time and the cache state of each run.
  • Can a roadmap runner create the measurement Job?: No. The runner pod holds no Kubernetes API token, and only a person with kubectl on the homelab cluster creates the Job and reads its log. [sources: docs/CLUSTER.md:5, docs/CLUSTER.md:67]
  • How are the run time and the request count read?: Read the Renovate log with LOG_FORMAT=json. The repository finished lines give the time of each repository, and the Job start and completion times give the total. The HTTP statistics give the request count. (best practice) [sources: docs/CLUSTER.md:271]
    • Chosen: The Renovate JSON log. The Renovate documentation defines LOG_FORMAT=json, and the log holds the repository timings and the HTTP statistics.
    • Rejected: The OTLP trace of the run. Nothing shows that Renovate emits an HTTP client span for each request.

Fit

Fits in one pull request.

Suspected block

dan-petty/homelab#95 must deploy the upstream-chart Renovate, and the first run must finish, before the record can hold its numbers.

Dependencies

None.

Moved to new items

dan-petty/homelab#366, dan-petty/homelab#367, #6129

Activity

  1. added
    source/agent
    on Nov 12, 2026
  2. added
    type/chore
    scope/k8s
    status/new
    value/medium
    effort/low
    on Nov 12, 2026
  3. dan-petty commented on Nov 12, 2026

    @dan-petty
    OwnerAuthor

    Intake placed this item to the backlog: intake puts every new item in the backlog. A person plans the milestones.

    • Type: type/chore. The chore prefix of the title gives the type.
    • Scope: scope/k8s. The (k8s) scope of the title gives the scope.
    • Priority: P2-Medium. It validates the Renovate setup against budgets before the first scheduled window, but it is a one-time measurement, not a blocking defect.
    • Value: Medium. It confirms the Renovate CronJob stays within GitHub rate limits and pod resource budgets before production use.
    • Effort: Low. The task is to run the CronJob once, read its log, and record numbers; no new code is needed.
    • Related: chore(roadmap): measure the GitHub request drop after refine skips comments #3866, which asks for a different change. Both record GitHub request counts after a deployment, but the candidate measures the initial Renovate CronJob in a k8s cluster while dan-petty/devops-cli#3866 measures the roadmap-service after a refine-skip change.
  4. devops-cli-service commented on Nov 15, 2026

    @devops-cli-service
    Contributor

    Alternatives check: not-applicable

    Class: chore. The check makes no search and no model call for an item of this class.

    Tool: none found

    Checked on 2026-11-15. A person decides what this means for the item. The check changes no label and closes no issue.

  5. devops-cli-service commented on Nov 16, 2026

    @devops-cli-service
    Contributor

    The proposal at fccb781 needs splitting into 2 items. A person splits the item into the items below, or replies in a comment or edits the body to keep one item, and the next refine round looks at the item again.

    1. The two lookup runs, the lookup numbers, the read-only root and the dry-run removal in one pull request.
    2. The first Monday window, the first full week of pushes, the Dependency Dashboard and the security pull request path in a follow-up pull request after the dry-run removal merges.
  6. dan-petty commented on Nov 16, 2026

    @dan-petty
    OwnerAuthor

    Notes from the #4905 build for the first runs (PR #6014, not merged yet):

    1. Writable paths. The pod keeps readOnlyRootFilesystem: true. The plan named emptyDir volumes on /opt/containerbase and /var/lib/containerbase, but the image layers show build files in both: an emptyDir would hide them. So init container seed copies /opt/containerbase and /home/ubuntu of the image into the emptyDir seeded (6Gi), and Renovate mounts the two copies on the same paths. /tmp is a plain emptyDir (4Gi); the entrypoint runs containerbase-cli init tool all on it. /var/lib/containerbase stays on the read-only root: root owns it with mode 0755.
    2. What was proved, and what was not. With the pinned image (44.239.1), user 12021:12021, all capabilities dropped and a read-only root, the seed copy exited 0, renovate-config-validator validated config.js, and node, git and renovate ran. A tool install (install-tool python, then uv) under this layout was not measured. Check it in the first run without the dry run: a postUpgradeTasks rule with installTools.
    3. The dry run. Remove RENOVATE_DRY_RUN=lookup from k8s/devops/renovate/cronjob.yaml.
    4. The scope. onboarding: false with requireConfig: required: Renovate runs on devops-cli only, and skips the 6 repositories with no config until chore(deps): onboard the other Service repos to Renovate #4913 turns onboarding on.
    5. The logs. LOG_FORMAT=json gives one object per line. The spans go to the collector with the service name renovate. The JSON report is in the emptyDir /report, so it goes with the pod.
    6. The resources. First values: requests 500m and 1Gi, limits 2 CPU and 4Gi, emptyDir limits 4Gi and 6Gi. Set them again from the run.
    7. A run at once. kubectl -n devops create job --from=cronjob/renovate renovate-manual, then kubectl -n devops logs job/renovate-manual -c renovate.
    8. Where to record the numbers. The Renovate section is in docs/CLUSTER.md, next to SearXNG, not in k8s/README.md.
  7. dan-petty commented on Nov 16, 2026

    @dan-petty
    OwnerAuthor

    From the review of PR #6014, check these before the dry run ends:

    • devops install-tools writes to ~/.local/bin (defaults.py, about line 49), but the PATH of the Renovate image is /home/ubuntu/bin:/usr/local/sbin:..., so the task devcontainer upgrade will likely fail with "not found".
    • The config sets no gitAuthor or username for the ghs_ token: check that Renovate does not see its own platformCommit branches as changed by another author.
    • cronjob.yaml (about lines 65-66) says the group of the image user is 12021, but /etc/passwd gives ubuntu:x:12021:0. The comment is wrong; nothing breaks.
    • The token-exposure item (filed today) must land before RENOVATE_DRY_RUN is removed.
  8. dan-petty commented on Nov 16, 2026

    @dan-petty
    OwnerAuthor

    First run, 2026-11-16 (manual Job renovate-manual-1931 from CronJob renovate, owner request, RENOVATE_DRY_RUN=lookup, Renovate 44.239.1):

    • Init seed: completed in about 10 s. Init token: wrote the installation token of dan-petty-renovate[bot] (token life to 20:32:16Z). Main container: 19:32:18Z to 19:34:14Z, exit 0. Pod start to end: 151 s, far below executionTimeout (900 s) and activeDeadlineSeconds (3000 s).
    • Log: 53 lines, all info; no warning and no error. Trace id c2a788d0ffef6fe83df668019683d8a9 (OTLP to the collector).
    • Autodiscovery found 16 repositories (the owner keeps the App on all repositories). Only dan-petty/devops-cli was processed; the others were disabled (no Renovate config), empty or forks.
    • devops-cli: cloned, 80.9 s. Dependencies extracted by manager: pep621 277, github-actions 164, kubernetes 129, pip-compile 89, argocd 53, dockerfile 38, devcontainer 9, helm-values 3, npm 3, pre-commit 2, and single-file managers.
    • Not measured yet: the updates that the run found (the info log does not list them, and the JSON report is in an emptyDir), the GitHub requests of the run, and the tool install under the read-only root (no postUpgradeTasks run in lookup mode). For the next measured run: keep the report (a PVC path or a log line of the update count) or run once at LOG_LEVEL=debug, and count the GitHub requests from the trace.
  9. devops-cli-service commented on Nov 16, 2026

    @devops-cli-service
    Contributor

    Owner question: The lookup runs need the homelab cluster and the owner steps 1 to 6 of #4893: the App, the keyring rows, devops k8s push-secrets, the Dependabot alerts and no hosted Renovate app. The CronJob of #4905 must be merged before the two measurement Jobs can be created.

    Options

    1. Decide the question: The job refines the item with your answer.
    2. Leave it to the job: The job records the best-practice answer and goes on.

    Recommendation: Decide the question: only a person can answer it.

    Evidence

  10. dan-petty commented on Nov 16, 2026

    @dan-petty
    OwnerAuthor

    First live run, 2026-11-16 (manual Job renovate-manual-2010 after #6023 removed the dry run; allowedCommands empty):

  11. added
    status/ready
    and removed
    status/new
    on Nov 17, 2026
  12. devops-cli-service commented on Nov 17, 2026

    @devops-cli-service
    Contributor

    Status set to Ready at c58b592 (see proposed design in issue body).

    Moved to new items: dan-petty/homelab#366, dan-petty/homelab#367, #6129.

  13. dan-petty commented on Nov 21, 2026

    @dan-petty
    OwnerAuthor

    #6684 removes k8s/devops/renovate, and dan-petty/homelab#95 runs the same Renovate from the upstream chart in namespace devops. Measure the runs of the homelab instance after dan-petty/homelab#95.

  14. dan-petty commented on Nov 24, 2026

    @dan-petty
    OwnerAuthor

    The self-hosted Renovate workload moves out of the product into dan-petty/homelab#95.

  15. dan-petty commented on Nov 25, 2026

    @dan-petty
    OwnerAuthor

    Returning #4909 to New with evidence. The November 17 proposed design requires documenting the deleted k8s/devops/renovate/ deployment layout in docs/CLUSTER.md (lines 76-82 of the issue design: /opt/containerbase and /home/ubuntu on seeded, and /cache on PVC renovate-cache), citing k8s/devops/renovate/cronjob.yaml and k8s/devops/renovate/pvc.yaml. Commit ec554c65ea (PR dan-petty/devops-cli#6938, Closes dan-petty/devops-cli#6684) deleted k8s/devops/renovate/ from this repository, updated docs/CLUSTER.md lines 271-277 to state that Renovate runs as a homelab instance in dan-petty/homelab#95 from the upstream chart, and comments of 2026-11-21 and 2026-11-24 state that the self-hosted Renovate workload moved to dan-petty/homelab#95 and to measure the homelab instance there. Re-refine or close #4909 in light of #6684/#6938 and dan-petty/homelab#95.

  16. added
    status/new
    and removed
    status/ready
    on Nov 25, 2026
  17. devops-cli-service commented on Nov 25, 2026

    @devops-cli-service
    Contributor

    Owner question: See Suspected block in the section Proposed design of the body.

    Options

    1. Decide the question: The job refines the item with your answer.
    2. Leave it to the job: The job records the best-practice answer and goes on.

    Recommendation: Decide the question: only a person can answer it.

    Evidence

  18. devops-cli-service commented on Nov 26, 2026

    @devops-cli-service
    Contributor

    Owner question: See Suspected block in the section Proposed design of the body.

    Options

    1. Decide the question: The job refines the item with your answer.
    2. Leave it to the job: The job records the best-practice answer and goes on.

    Recommendation: Decide the question: only a person can answer it.

    Evidence

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    effort/lowpriority/p2-mediumscope/k8ssource/agentstatus/newtype/chorevalue/medium

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions