Skip to content

feat(local): persist registry volume across computer restarts with PVC#69

Merged
patrickleet merged 1 commit into
mainfrom
feat/persistent-registry-volume
Jun 28, 2026
Merged

feat(local): persist registry volume across computer restarts with PVC#69
patrickleet merged 1 commit into
mainfrom
feat/persistent-registry-volume

Conversation

@patrickleet

Copy link
Copy Markdown
Collaborator

Summary

The in-cluster OCI registry used for local dev builds (dev-* tags) and provider snapshot images is now backed by a PersistentVolumeClaim.

Problem

Previously the registry:2 pod had no volume, so its data lived in the ephemeral container filesystem. Any colima restart (explicit, during hops local resize, or after host reboot) wiped all pushed images. This caused MANIFEST_UNKNOWN for Configurations and ImagePullBackOff for Functions/Providers, requiring the painful manual recovery dance.

Solution

  • Added registry-pvc (20Gi ReadWriteOnce).
  • Registry container now mounts /var/lib/registry from the PVC.
  • Data lives on the colima VM disk (provisioned via the default local-path StorageClass).
  • Survives normal computer restarts and colima stop/start cycles.

Details

  • The change is in the bootstrap manifest applied by hops local start (and ensure_registry).
  • PVC + volumeMount added to the Deployment.
  • No behavior change for first-time or existing users (new PVC is created on apply).

This is the primary defense. The recover command (hops local recover) remains useful as a safety net for deliberate full resets (colima delete, etc.) or as a "force latest published" tool. See the updated spec for the full picture:

  • [[specs/hops-cli-local-registry-recover]]
  • [[tasks/hops-cli-local-registry-recover]]

Verification

  • kubectl apply --dry-run=client -f cli/bootstrap/registry/registry.yaml succeeds.
  • Existing ensure_registry() wait loop (for deployment availableReplicas) will cover PVC binding.
  • No other code changes required.

…th PVC

The local in-cluster OCI registry (used for dev-* builds and provider snapshots) now uses a PersistentVolumeClaim.

This ensures /var/lib/registry data lives on the colima VM disk (via local-path), surviving host reboots and colima restarts.

This is the primary solution for the "registry wipe on restart" problem.

See updated spec [[specs/hops-cli-local-registry-recover]] and task for details. Recover command remains as safety net for full resets.
@coderabbitai

coderabbitai Bot commented Jun 28, 2026

Copy link
Copy Markdown

Warning

Review limit reached

@patrickleet, we couldn't start this review because you've reached your PR review rate limit.

More reviews will be available in 6 minutes and 57 seconds. Learn how PR review limits work.

Your organization has used up its prepaid credits, and credit purchases are no longer available. Enable the review add-on in the billing tab to keep reviews running — you're only billed for reviews past your plan's rate limits ($0.25/file).

⌛ How to resolve this issue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based credits.

🚦 How do rate limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please see our Fair Usage Limits Policy for further information.

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 3cf97f82-c7b1-4909-8718-1801e5f7cbca

📥 Commits

Reviewing files that changed from the base of the PR and between 3889108 and 554012c.

📒 Files selected for processing (1)
  • bootstrap/registry/registry.yaml
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feat/persistent-registry-volume

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@patrickleet patrickleet merged commit a7a3151 into main Jun 28, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant