ConfigHub · Durable config for coding agents
Docs / docs/learn.md Source on GitHub →

Learn ConfigHub, step by step

Ship faster with coding agents—with durable config that remembers every setting and why it changed. Spin up isolated previews, approve production rollouts on your terms, and carry your config across chats, sandboxes, hosts, and service migrations.

In short, plain-English steps (2–3 minutes each), you’ll unlock four everyday basics:

You can stop whenever you want. Stop after Step 2 (offline plugin only) or Step 4 (previews + production approvals) and you already have something genuinely useful every day.

PartStepsWhat you unlockTime
Part 1 · Your laptop, zero serversStep 1 – Step 2Cross-session memory, prod-write holds, key locks, easy undo~4 min
Part 2 · Durable config & safe environmentsStep 3 – Step 4Isolated local previews + human-approved production pipeline~6 min
Part 3 · Deploy anywhere & move servicesStep 5 – Step 7Deploy to any host, survive sandboxes, migrate across services~9 min
Part 4 · Teams, upgrades & going backStep 8Upstream upgrades, PR reviews, shared hub, easy exit anytime~5 min

Before you start (10 seconds · macOS & Linux)

Install the free, open-source plugin once (macOS & Linux only; Security review). It runs completely offline with zero background servers to start—no account, no Docker.

Claude Code:

claude plugin marketplace add confighubai/confighub-mini-plugin && claude plugin install confighub@confighub

Codex CLI:

curl -sSfL https://raw.githubusercontent.com/confighubai/confighub-mini-plugin/main/install-codex.sh | bash

(In Codex, run /hooks once afterward to approve ConfigHub hooks. See Codex setup for manual clone & checksum steps.)

Good to know before installing: On first use in a folder, the plugin reads the last 30 days of local Claude Code transcripts for that folder so you can immediately ask why last week’s edit happened (opt out with CUB_MINI_EARLIER_SESSIONS=0). Add --scope project to install for one repo only. Secret values matching credential patterns are redacted—avoid pasting unnamed secrets (Security review).


Part 1 · Your laptop, zero servers

Step 1: No more fiddly env variables, give every chat a memory

The moment: Fiddly .env files and config tweaks are the easiest thing to lose track of. Yesterday’s chat turned on a setting for a weekend sale and left it uncommitted. Today you open a fresh chat—and instead of hunting through .env files or guessing why the flag is on, your agent picks up right where you left off.

Try this (2 minutes):

  1. Open Claude Code (or Codex) in any folder and ask:

    Create app-config.json with {"cache": false}, then turn cache to true for Saturday’s sale and leave it uncommitted.
  2. Close that chat, open a brand-new chat in the same folder, and ask:

    Why is the cache on?

    (You can also type /confighub:why cache in Claude Code, or run ~/.codex/confighub/bin/confighub mini changes in Codex.)

What you’ll see:

╭─ ConfigHub · Why cache changed ───────────────────────────────────────╮
│ └── app-config.json · cache (true in the file now)                    │
│     ├── false → true  session sess-1                                  │
│     └── asked: "Create app-config.json ... for Saturday’s sale..."    │
├───────────────────────────────────────────────────────────────────────┤
│ recorded locally in ~/.confighub (offline, no hub needed)             │
╰───────────────────────────────────────────────────────────────────────╯

What you just learned: Your settings now have a memory that outlives any single chat. Git tracks committed code; ConfigHub quietly records each setting change and the reason behind it locally (~/.confighub/agent-changes, 30-day local retention; durable in PostgreSQL once connected to a hub)—even for uncommitted edits or .env files Git ignores. (Pattern-based secret redaction skips named secrets and credentials; avoid pasting unnamed secrets—see Security review.)


Step 2: Agents make changes without breaking things (and you can always go back)

The moment: You want your coding agent to make changes fast—without breaking your app, silently overwriting an earlier tweak, pushing straight to production, or making it hard to go back if you don’t like the result.

Try this (2 minutes):

  1. See earlier work stay protected: In that fresh chat, ask your agent to turn cache back to false. In Claude Code, ConfigHub surfaces the earlier value and your Saturday sale reason before overwriting it. (Across the 190-session silent-undo subset of our 440-session vendor-run eval, ConfigHub recorded 0 silent undos vs 144 without it—see evidence & method.)
  2. Approve production on your terms: The plugin alone refuses direct production secret/env commands (fly secrets set, heroku config:set, vercel env add ... production, unikraft instances run -e) once so the agent pauses and asks you (plain fly deploy / vercel --prod are not blocked by hooks); adding a hub in Part 2 enforces a hard server-side approval gate where the agent proposes and you approve (cub inbox approve BASE/ORDER) and deliver (cub repo deliver) in your terminal.
  3. Lock sensitive keys: Freeze any key you want untouched until you say otherwise:

    cub agent lock STRIPE_MODE --reason "Keep test mode"

    (Check active locks and recent reasons anytime with cub agent card; unlock later with cub agent lock --unlock STRIPE_MODE.)

  4. Undo only config edits cleanly: Roll back agent config changes while keeping all your source-code edits intact:

    cub agent undo --dry-run

    Run cub agent undo when you’re ready to apply it.

What you just learned: Confidence comes built in—no giant CLAUDE.md required. Every chat builds on your earlier decisions, production writes wait for your yes, sensitive keys stay locked, and config reverts stay clean.

Checkpoint 1 — You already have daily superpowers. With just Steps 1 and 2, every chat remembers why, earlier edits stay intact, direct production writes wait for you, and config-only undo is one command away—100% offline with zero servers. Stop here if you like, or continue to Part 2 for live previews and a dedicated staging → production workflow.


Part 2 · Durable config & safe environments

Step 3: Preview ideas live without touching your files

The moment: You want to see a setting change running live in your app right now—keeping your repo spotless, leaving staging and production untouched, and finding that exact preview again tomorrow in a new chat.

Try this (3 minutes):

  1. In an app folder (or a tiny sample app like greeter with a GREETING setting), type:

    /confighub:staging

    On first use, this installs the lightweight local hub (cub mini)—still on your laptop, still no account or Docker.

  2. Ask your agent:

    Try a warmer greeting in preview.

What you’ll see:

╭─ ConfigHub · greeter ──────────────────────────────────────────────────╮
│ ├── preview     ● http://127.0.0.1:49210  GREETING="Welcome!"          │
│ ├── staging     ✓ ready (agent updates)   GREETING="Hello, world!"     │
│ └── production  ✓ in sync (protected)     GREETING="Hello, world!"     │
├────────────────────────────────────────────────────────────────────────┤
│ repo files untouched · tomorrow’s chat still finds the preview URL     │
╰────────────────────────────────────────────────────────────────────────╯

What you just learned: This is durable config. Your settings now live above individual chats, files on disk, and any single host. Your preview runs on its own local port, tomorrow’s chat still knows where it is and why, and—as you’ll see in Part 3—that same durable config is what lets your settings survive disposable sandboxes and move cleanly when you switch services. (You can also run a preview yourself anytime with cub env preview --staging.)


Step 4: Let agents ship to staging while you approve production

The moment: You want your coding agent to iterate at full speed in staging, while production rolls out cleanly on your schedule and your approval.

Try this (3 minutes):

  1. Ask your agent to promote the warmer greeting to staging—it updates immediately.
  2. Now ask your agent to promote that change to production. Instead of writing straight to production, ConfigHub queues it cleanly at ⏳ waiting.
  3. Review the exact diff and reason, then approve it yourself:

    cub inbox list --card

Every ConfigHub status card uses the same three clear states:

BadgeWhat it meansWhat you do
⏳ waitingReady for your yes (prod approval, sandbox promotion, upgrade)Review & approve (cub inbox list --card)
↻ syncing / ⚠ driftedDelivering to your host, or live host differs from approved configInspect 1:1 check (cub repo deliver --compare --card)
✓ recorded / ✓ in syncSaved to memory or matching your live hostNothing—you’re good

What you just learned: Speed and safety go together. Your agent moves fast in preview and staging, and production rolls out with a clear, human-approved diff every time.

Checkpoint 2 — A complete local workflow for solo builders. You now have cross-session memory, isolated local previews, fast staging iteration, and human-approved production rollouts right on your laptop. Continue to Part 3 when you connect live cloud hosts, sandboxes, or multiple apps.


Part 3 · Deploy anywhere & move services

Step 5: Deploy apps to any service easily (and stay in sync)

The moment: Deploying an app shouldn’t mean clicking through fiddly env-variable screens on every cloud dashboard. Whether your app runs on Vercel, Fly.io, Heroku, Unikraft, or Kubernetes, you want to deploy cleanly with your approved settings—and know immediately if anything live ever drifts.

Try this (3 minutes):

  1. Connect your app’s host target inside your project folder: run /confighub:staging in Claude Code (or cub repo adopt . --name APP in your terminal), then follow your platform’s guide: Vercel · Fly · Heroku · Unikraft.
  2. Compare your approved config against what is actually running live:

    cub repo deliver --compare --card

What you’ll see: A 1:1 live check showing either ✓ in sync or ⚠ drifted with the exact key that differs.

What you just learned: ConfigHub works beside Git and your hosting platform—never replacing them. And because your approved settings live in durable config rather than only inside one vendor’s dashboard, you stay in sync today and stay free to move hosts tomorrow.


Step 6: Keep your best settings when sandboxes vanish

The moment: You run coding agents inside disposable cloud sandboxes (like Daytona) so they can experiment freely. When the agent finds the winning setting and the sandbox is deleted, you want that setting—and the reason it worked—waiting for you back home.

Try this (3 minutes):

  1. Run your preview inside a Daytona sandbox with staging’s settings (with no production credentials or ConfigHub key inside the sandbox):

    cub env preview --staging --daytona SANDBOX
  2. Tear down the sandbox—then inspect your settings back in ConfigHub. The winning value and why it worked are still there, ready for your review.

(See the full Daytona sandbox walkthrough and CI & sandboxes guide.)

What you just learned: Ephemeral chats and disposable sandboxes are meant to come and go. Your durable config—and the story of why each setting works—outlives them all.


Step 7: Migrate across services keeping your config

The moment: You’re ready to move an app to a new host (say, Heroku to Fly.io or Vercel)—or launch a second service that shares your proven baseline settings—without hand-copying 30 environment variables or losing the history behind them.

Try this (3 minutes):

What you just learned: Your configuration belongs to your app, not to one platform’s dashboard. Migrating across services or spinning up your next app becomes fast, clean, and repeatable.


Part 4 · Teams, upgrades & growing up

Step 8: Upgrade cleanly and grow into a team

The moment: An upstream starter or Helm chart ships a new release (and you want the upgrade while keeping all your overrides)—or teammates, pull requests, and CI agents join the project.

Four upgrades you can turn on whenever you’re ready:

  1. Map any unfamiliar GitOps repo (read-only): Run /confighub:inventory to see everything a repository deploys before anyone edits a file (Inventory).
  2. Put recorded reasons on every GitHub PR: Add the GitHub PR review Action so teammates automatically see every changed setting and *why*—even without a hub.
  3. Take upstream updates while keeping your overrides: When a starter or Helm chart updates, ConfigHub previews the incoming change while preserving your custom values and reasons.
  4. Graduate from laptop to team: Run /confighub:to-hub to copy your local history into a shared hub (confighub.com or self-hosted Helm + OIDC/SSO). From there, the exact same durable config you used on one app becomes shared operational truth across your whole team and fleet:
Same durable config1 app today (plugin + local hub)1,000 apps tomorrow (shared hub + cub)
Operational truthNo fiddly .env files—settings & reasons survive chats, sandboxes, and host switchesQuery across every app, cloud, and cluster (cub resource list --where ..., cub unit blame)
Creation & reuseStart a second app or let a colleague fork yours keeping their overridesGolden bases across a fleet: push one fix to 50 services while each app’s overrides stay intact
Built-in guardrailsAgents update staging, production waits for your yes, keys lock, easy undoNamed human approvers, per-agent keys, instant revocation, signed audit trail, OIDC/SSO
Sandboxes to handLocal port previews, Friday replays, disposable Daytona sandboxesUnattended CI agents running for weeks, plus OCI delivery to Argo CD / Flux

What you just learned: You never have to start over. The same 10-second plugin grows smoothly from one developer’s laptop to a full team and Kubernetes fleet.

Always easy to go back — zero lock-in. Made a change you don’t like? Run cub agent undo to revert only config edits while keeping your code, or roll back to any earlier approved setting. Want to stop using ConfigHub completely? Export your settings as plain files, run cub local uninstall --delete-data, and wipe local plugin records with rm -rf ~/.confighub/agent-changes—your repo, Git history, and hosting platform keep working as normal (Going back).


Quick cheat sheet of everything you unlocked

What you want to doCommand
See why a setting changed/confighub:why SETTING
Summarize all agent config edits in this folder/confighub:changes
Lock a sensitive key against agent editscub agent lock KEY --reason "..."
Undo only config edits (leave code untouched)cub agent undo --dry-run
Add previews, staging, and gated production/confighub:staging (Zero → Local Hub)
Review & approve changes waiting for youcub inbox list --card / cub inbox approve
Check live host vs. approved config (1:1 drift)cub repo deliver --compare --card
Start a new app inheriting shared defaultscub local start-from APP or cub repo starter
Map an unfamiliar GitOps repo (read-only)/confighub:inventory
Copy local history into a Cloud Hub/confighub:to-hub (Zero/Local → Cloud Hub)
Remove everything cleanly if you ever stopcub local uninstall --delete-data (Going back)

Where to go next