Skip to content
ConfigHub for coding agents
Reference / examples/walkthroughs/story-12-laptop-connects-out.md Source on GitHub

A hub on your laptop that nothing connects to, and your work copied up to the team's hub

For a developer whose agents change his services' configuration on a laptop, and whose team keeps its hub on a server. Sam's rule is that the laptop connects out and nothing connects in, so the laptop never becomes a server he has to secure and leave on. Here the laptop's hub listens on the laptop only, and Sam's work, with its reason, goes up to the team's shared hub over a connection the laptop makes.

Quick start

You need: an unpacked confighub mini package (installing the local hub), and an account in your team's organization on a shared hub on confighub.com.

By handAsk your agent
Start a hub on the laptopcub mini install --name laptopYour agent can run the same command.
Keep a value with its reasoncub mini set $APP TIMEOUT_SECONDS=120 --variant live --change-desc "Production waits longer for the model"Your agent can run the same command.
Copy it up to the team's hubCUB_CONTEXT=team cub mini copy --from-context "$LAPTOP" "$APP""My app is in the hub on my laptop (its context is in $LAPTOP, the app's name in $APP). Copy it, with its reasons, up to the team's hub, which I am signed in to as team. Don't open anything on my laptop to the network."
Read it on the team's hubcub --context team unit data settings --space "$APP-live"Your agent can run the same command.

The laptop's hub listens on the laptop only, and the team's shared hub holds your work with its reason.

Without ConfigHub: you send your settings to the team as a file or a commit, and the reason behind production's value goes along only if you write it down somewhere.

Deeper dive

The rest of this page is the full version: every command, how to see that nothing on the laptop listens to the network, the sign-in to the team's hub, and how this was tested.

Show the full walkthrough

Human

What you need

An unpacked confighub mini package, 0.11.1-mini.2 or later (installing the local hub), and an account in your team's organization on a shared hub on confighub.com, which you sign in to in a browser. A hub is ConfigHub running somewhere: here one on your laptop, and the team's. cub is ConfigHub's command-line tool; a context is one hub it can talk to. This walkthrough uses your own cub configuration, since that is where your sign-in to the team's shared hub lives, and changes none of your existing contexts.

Steps

  1. Set up a terminal: the package's cub first on your PATH, and the cub mini commands added to your cub:
    export MINI=/absolute/path/to/unpacked-confighub-mini
    export PATH="$MINI/bin:$PATH"
    unset CUB_CONFIG CUB_CONTEXT
    confighub-mini-app mini install-plugin "$HOME/.confighub"
  2. Start a hub on the laptop. Your current context is left as it was; this terminal uses the laptop's hub through CUB_CONTEXT:
    cub mini install --name laptop
    export LAPTOP=$(cat ~/.confighub/servers/laptop/owner-context) CUB_CONTEXT=$(cat ~/.confighub/servers/laptop/owner-context)
  3. See that it listens on the laptop only. Every address it accepts connections on is 127.0.0.1, which no other computer can reach:
    port=$(cub context get -o json | python3 -c 'import json,sys; print(json.load(sys.stdin)["coordinate"]["serverURL"].rsplit(":",1)[1])')
    lsof -nP -iTCP:"$port" -sTCP:LISTEN | awk 'NR>1 {print $9}'
    127.0.0.1:PORT
  4. Sam's work: a small app's settings, with production's own timeout and the reason. The app's name starts with your user name, so it meets nobody else's in the team's shared hub:
    export PREFIX="${WALKTHROUGH_PREFIX:-$USER-}"; export APP="${PREFIX}devlab"
    mkdir -p ~/walkthrough/$APP && cd ~/walkthrough
    printf 'MODEL=large-2026-09\nTIMEOUT_SECONDS=30\nLOG_LEVEL=info\n' > $APP/settings.env
    cub mini upload $APP --variant live
    cub mini set $APP TIMEOUT_SECONDS=120 --variant live --change-desc "Production waits longer for the model"
  5. Sign in to the team's shared hub, as one more context, team. The second command opens your browser:
    cub context create team --server https://hub.confighub.com
    cub --context team auth login
  6. Copy the work up. The laptop makes the connection and the team's shared hub takes it, with the kept value and its reason; nothing on the laptop changes:
    CUB_CONTEXT=team cub mini copy --from-context "$LAPTOP" "$APP"
    cub mini: writing to team, at https://hub.confighub.com.
    …
    Not copied: history (each Unit keeps only its last reason), delivery targets, views and filters.
  7. Read it on the team's shared hub. A colleague sees the same, with the laptop closed:
    cub --context team unit data settings --space "$APP-live"
    MODEL=large-2026-09
    TIMEOUT_SECONDS=120
    LOG_LEVEL=info
    …

    Production's copy on the team's shared hub is not behind anyone's approval yet: the copy does not carry approval rules. Putting it behind approval there is a step of its own (approvals).

Undo it

This deletes the app from the team's shared hub, removes the laptop's hub with its data, and removes the team context and the walkthrough's folder:

cub --context team space delete --recursive --where "Slug LIKE '$APP-%'"
cub --context team component delete "$APP"
cub mini uninstall --name laptop --delete-data
unset CUB_CONTEXT; cub context delete team; cd ~ && rm -rf ~/walkthrough

What you have now

Your own cub as it was. While it ran, the laptop's hub accepted connections from the laptop alone, and the team's shared hub held Sam's work with its reason, reached by a connection the laptop made. The full story adds Sam's agents on the laptop behind his approval, a CI job and a VM taking settings, the laptop's hub connected to the team's so later versions come back down, and a customer's hub at another site. From your laptop to a shared hub covers connecting the two hubs.

Agent

For an AI agent doing this for a person.

  • The request: "Copy my app, with its reasons, up to the team's hub (the cub context team). Don't open anything on my laptop to the network."
  • What to run: with the Claude plugin, /confighub:to-hub copies the Claude plugin's record into a hub. By hand, the Human steps 6 and 7: CUB_CONTEXT=team cub mini copy --from-context <the laptop's context> APP, then read it back with cub --context team unit data. If the person is not signed in to team, give them cub --context team auth login to run themselves.
  • Never: start a hub that listens beyond 127.0.0.1, or expose the laptop's hub with a tunnel; change the person's current cub context; tell the person production on the team's shared hub is behind approval when it is not.
  • Done when: the team's shared hub returns TIMEOUT_SECONDS=120 for the app's live copy, and the person has been told it is not yet behind approval there.

Testing

The scripted run follows the Human steps against a shared hub on confighub.com, in its test organization, and compares the quoted output. Arm a, without the local hub, is not applicable: there is no laptop hub to copy from. A correct agent result is the app's live copy on the team's shared hub with the kept timeout. The checks below can be run by hand after step 7:

This proves: stored, on a shared hub on confighub.com, with the laptop's hub listening on the laptop only; nothing is delivered, and production on the team's shared hub is not behind approval. The next step this aims to win: putting the team's copy behind the person's approval. Tested on the checksum-verified published confighub mini 0.11.1-mini.4 with the Claude plugin 0.87.0, 14 November 2026: environment, a shared hub on confighub.com (the test organization) and a local hub; approval, no approval step. The Claude plugin says one line at this moment, such as "ConfigHub plugin: copied the app from tiny-cub to team, with the reasons kept beside its values; nothing on tiny-cub changed." The next-step line names words from that line.

My app is in the hub on my laptop (its context is in $LAPTOP, the app's name in $APP). Copy it, with its reasons, up to the team's hub, which I am signed in to as team. Don't open anything on my laptop to the network.

cub --context team unit data settings --space "$APP-live"
lsof -nP -iTCP -sTCP:LISTEN | awk '/confighub|postgres/ {print $9}' | sort -u
Test results

Results, 14 November 2026, confighub mini 0.11.1-mini.4. Figures from this page's own test runs, shown here for whoever checks the page; they are not a promise.

  • Scripted run: passed, 50 seconds for the steps, within the page's budget of 120.
  • Agent runs (on confighub mini 0.11.1-mini.4, 14 November 2026): a pilot, 3 runs per arm on each of claude-sonnet-5-5, claude-opus-5-5. Arms: b is the Claude plugin, the local hub and this page as reading.
ArmModelChecks passedMedian secondsMedian costCommands left for the person (median)
bclaude-opus-5-53/346.0$0.1820
bclaude-sonnet-5-53/321.8$0.0730

No agent approved or refused a change to production.

Simulated persons, not people: 10 per run, each a claude-haiku-5-5 model playing one of ten fixed personas, reading only what a person would see. The next step they were offered: "Put production's copy on the team's hub behind your approval?"

The Claude plugin offers it once, after the answer at whose end it showed the moment the offer names ("copied"). Offered is the share of persons it was shown to; want it now and later are over them.

ArmModelPersonsOfferedNoticedWant the next step nowLaterIn the way
bclaude-opus-5-530100%100%40%57%43%
bclaude-sonnet-5-530100%100%30%63%50%
  • Agent runs (on confighub mini 0.11.1-mini.2, 13 November 2026): a pilot, 3 runs per arm on each of claude-sonnet-5-5, claude-opus-5-5. Arms: b is the Claude plugin, the local hub and this page as reading; c is the Claude plugin and the local hub, without this page.
ArmModelChecks passedMedian secondsMedian costCommands left for the person (median)
bclaude-opus-5-53/336.5$0.1720
cclaude-opus-5-53/346.1$0.1890
bclaude-sonnet-5-53/328.2$0.0690
cclaude-sonnet-5-53/333.6$0.1080

No agent approved or refused a change to production.

Simulated persons, not people: 10 per run, each a claude-haiku-5-5 model playing one of ten fixed personas, reading only what a person would see. The next step they were offered: "Keep the hub on your laptop for your agents' next changes, and copy the work up to the team's hub whenever you choose?"

The Claude plugin offers it once, after the answer at whose end it showed the moment the offer names ("recorded"). Offered is the share of persons it was shown to; want it now and later are over them.

ArmModelPersonsOfferedNoticedWant the next step nowLaterIn the way
bclaude-opus-5-5300%100%n/an/a43%
cclaude-opus-5-5300%100%n/an/a53%
bclaude-sonnet-5-5300%100%n/an/a40%
cclaude-sonnet-5-5300%100%n/an/a53%