logout
crabbox logout clears the stored broker token from your user config so the CLI no longer authenticates to the broker.
crabbox logout
crabbox logout --json
#What it changes
Logout edits only the user config file (the path printed by crabbox config path). It clears both token fields the broker reads:
- the broker section's
token, and - the top-level
coordinatorToken.
Everything else is left in place:
- the broker
urlandprovider, so a latercrabbox logincan - the broker admin token (
broker.adminToken), if one is stored — logout - per-lease SSH keys, repo claims, and recorded run history.
reuse the configured endpoint;
does not touch it;
On success it prints:
logged out config=/path/to/config.yaml broker_auth=missing
With --json it emits the resolved config path and the new auth state:
{ "config": "/path/to/config.yaml", "brokerAuth": "missing" }
#Flags
| Flag | Description |
|---|---|
--json | Print machine-readable JSON. |
#After logout
- Broker-backed commands such as
crabbox whoami,crabbox run, - Direct-provider mode keeps working when local provider credentials are present
and crabbox warmup fail to authenticate against the broker because no token is sent. Re-run crabbox login (or crabbox login --token-stdin) to restore access.
(for example AWS SDK credentials or HCLOUD_TOKEN), since direct mode talks to the cloud API and does not need a broker token.
#When to use it
- A token has leaked or you want to rotate it.
- You are switching the operator identity on a shared workstation.
- You are exercising the unauthenticated path.
To remove everything — broker URL, provider, both tokens, and profile defaults — edit the user config file directly.