Skip to content

CLI

The kubrain CLI hits the same HTTP API as the MCP tools, with the same auth — use it for scripting and CI. Commands are grouped; the MCP tool create_cluster is kubrain cluster create, deploy is kubrain deploy ship, and so on.

kubrain [global options] <command> [subcommand] [options]

Global options:
  --api    <url>     api-server base URL (default https://api.kubrain.dev; or ~/.kubrain/config)   [$KUBRAIN_API]
  --token  <token>   tenant bearer token (default ~/.kubrain/config; set via `kubrain auth login`) [$KUBRAIN_TOKEN]

Top-level commands

CommandWhat it does
authSign up / sign in; manage credentials in ~/.kubrain/config.
vpcManage VPCs (isolated networks).
clusterManage Kubernetes clusters.
addonInstall curated add-ons into clusters.
deployApp deployments — a named handle on a cluster you ship code to.
zoneHost DNS zones for your domains (free).
registryShow the hosted container registry push coordinates.
bucketS3-compatible object storage.
export / plan / applyDeclarative blueprint workflow.
versionsKubernetes versions you can create/upgrade to.
regionsRegions and zones with coarse free capacity.
quotaYour limits and usage with the €/month view.
usageMonth-to-date consumption (GiB-hours + €) per resource, including deleted ones; --month YYYY-MM for a past month.
pricingThe rate card — no token needed.
estimatePrice a cluster or a blueprint file — no token needed.
mcpRun the MCP server (stdio) for Claude / agents.
adminAdminister tenants (requires an admin token).

kubrain cluster

SubcommandWhat it does
createPlan/create a cluster in a VPC.
listList your clusters.
statusShow a cluster’s status.
scaleChange the worker count (normal/ha).
resizeChange worker RAM; CAPI rolls the worker pool.
upgradeUpgrade the Kubernetes version (CP first, then workers).
reapplyRe-apply the manifest unchanged to pick up new platform features.
kubeconfigPrint a kubeconfig, or write it to --output.
deleteDelete a cluster (cascades to its VMs).

kubrain deploy

The busiest group — build, ship, observe, and secure an app.

SubcommandWhat it does
createCreate a deployment handle on a cluster (idempotent); --repo auto-builds on push.
list / getInventory / show one deployment.
shipBuild the local source in the cloud and roll it out (or --image for prebuilt).
rollbackRe-point to a prior release (default: last good).
promoteShip one deployment’s tested image on another — no rebuild.
set-triggerAuto-build policy: manual | commit:<glob> | tag:<glob> | schedule:<cron>.
deploy-keyPrint the read-only Git deploy key to add to your repo.
logsTail recent pod logs live from the cluster (nothing stored).
metricsGolden signals (req rate, 5xx rate, p95) — no instrumentation.
alertArm alerts on a deployment (evaluated server-side; webhook/email).
set-secret / unset-secretSet/remove a secret (value from --value-file or --from-env).
detect / scaffold / validate / renderLocal: inspect stack, write starter manifest, lint, render manifests to stdout.
deleteTear down a deployment.

kubrain zone

SubcommandWhat it does
createHost a domain (idempotent, free); prints the NS set to delegate.
list / getList zones / show a zone with its records and NS set.
set / unsetCreate-or-replace / delete a record set (repeat values for round-robin).
recordsList a zone’s records.
deleteStop hosting a domain (removes all records).

kubrain bucket

SubcommandWhat it does
createCreate a bucket (the first one also provisions your S3 user).
list / getInventory / show a bucket with live stats.
credentialsPrint your S3 endpoint + key pair, or write to --output.
deleteDelete an empty bucket (non-empty is refused).

kubrain addon

SubcommandWhat it does
listInstallable add-ons with versions and cost — no token needed.
installInstall an add-on into a running cluster (idempotent).
uninstallRemove an add-on (ingress-nginx also releases its LB IP).

Blueprints

kubrain export  > tenant.yaml     # snapshot live resources as a blueprint
kubrain plan    --file tenant.yaml   # diff spec vs. live (read-only)
kubrain apply   --file tenant.yaml   # converge (add --prune to delete orphans)
kubrain estimate --file tenant.yaml  # price the whole document

See the MCP tools reference for return shapes; the two surfaces are the same engine.