Skip to content
NebulaCtrldocs

CLI reference

The nebula command, its subcommands and flags: the client commands that log in, deploy and read logs from a terminal, the server commands, and the commands that validate nebula.toml and template files before you push them.

The nebula binary is the control plane and its command line. The client commands (nebula login, nebula status, nebula logs, nebula variables, nebula deploy, nebula run and the others that talk to a control plane) work from your terminal. The server commands operate the control plane itself. Two commands check files before you push them: nebula config validate and nebula template validate. This page is generated from the command tree of the release it describes.

Where to run it

The binary is /usr/local/bin/nebula in the control plane image. When the installer sets up the host updater, which is the default, it also copies the binary to bin/nebula in the install directory (/opt/nebula/bin/nebula by default). The commands that read files, nebula config validate and nebula template validate, need no database and no running control plane.

On your own computer, install the client commands with curl -fsSL https://get.nebulactrl.dev/cli.sh | sh. They need no database either: they call the control plane's API with an API token. The CLI guide walks through installing, logging in and the everyday commands.

Settings

Every flag of every command is also a setting. Set it three ways:

  • the flag, such as --base-url;
  • an environment variable named NEBULA_ plus the flag name in capitals with underscores, such as NEBULA_BASE_URL;
  • a key of the same name as the flag in a nebula.yaml file, read from the working directory, from /etc/nebula, or from the path in --config.

A flag wins over the environment variable, and the environment variable wins over the file. The configuration reference groups the nebula serve settings by what they do.

The client commands read only a few settings this way: --url of nebula login, and --project, --env and --service of the commands that take them (NEBULA_URL, NEBULA_PROJECT, NEBULA_ENV and NEBULA_SERVICE). NEBULA_URL together with NEBULA_TOKEN, an API token, replaces nebula login entirely, which is how CI uses them. A flag wins over these, and they win over the directory's nebula link.

Exit codes

CodeMeaning
0The command succeeded.
1The command ran and failed, or a validation command found a problem.
2The command line was wrong: an unknown flag or log level, an argument the command does not take, or a required setting that is missing. nebula config plan --detailed-exit-code also exits 2 when the plan has changes.

nebula run exits with the status of the command it ran.

Global flags

Every command accepts these.

FlagTypeDefaultDescription
--configstringnonepath to a nebula.yaml configuration file; optional
--log-levelstringinfolog level: debug, info, warn or error

nebula

NebulaCtrl is a Kubernetes-native deployment control plane.

The control plane holds projects, environments, services and releases; an agent inside each cluster pulls desired state and reports what it observes.

nebula COMMAND

Commands:

nebula changelog

Print this build's own release feed as JSON.

The same builder GET /api/v1/releases uses turns the embedded CHANGELOG.md into this output, so the two can never list different releases.

nebula changelog

nebula config

Work with nebula.toml repository configuration files.

nebula config COMMAND

Commands:

  • nebula config plan: Show what pushing your nebula.toml files would change, without applying anything
  • nebula config validate: Parse a nebula.toml file (a service's or a project's) and report every problem

nebula config plan

Show what pushing your nebula.toml files would change, without applying anything.

Sends your local nebula.toml files to the control plane, which reads the project as it is now and answers what a push of those files would create, change or release in each environment. Nothing is written, deployed or staged. Secret values are always shown as ••••.

Without FILE arguments it reads ./nebula.toml and every nebula.toml in a directory below the working directory. Paths are sent relative to the repository root (the nearest parent that holds .git), which is how the control plane finds each file; with no .git above, relative to the working directory. Problems in a file print as PATH:LINE: MESSAGE.

Exit status: 0 when nothing would change, 1 on an error, a problem in a file or an environment the control plane would refuse, and, with --detailed-exit-code, 2 when there are changes. Use that in CI to fail a pull request when the file and the project have drifted, or to require a review of the plan. To check a file without a control plane, use nebula config validate.

nebula config plan [FILE...] [flags]
nebula config plan
nebula config plan --project shop --env production
nebula config plan --detailed-exit-code --json services/api/nebula.toml

Flags:

FlagTypeDefaultDescription
--detailed-exit-codeboolnoneexit 2 when the plan has changes
--envstringnoneplan only this environment, by slug; default every persistent environment
--jsonboolnoneprint JSON instead of text, for scripts and agents
--projectstringnoneproject slug, name or id; default from nebula link

nebula config validate

Parse a nebula.toml file (a service's or a project's) and report every problem.

Reads FILE, or ./nebula.toml, and reports every problem in it, not only the first. A file with a top-level [services] or [databases] table is checked as a project config. Any other file is checked as a service's nebula.toml, once for each [environments.<name>] table it declares and for production, development and preview.

A problem prints as FILE:LINE: PATH: MESSAGE. A file with none prints FILE: ok and a summary of what it describes. The command exits 1 if it found a problem. A warning, such as a secret(N) that draws more characters than it asks for, prints as FILE:LINE: warning: PATH: MESSAGE and does not change the exit status.

The check needs no database and no control plane, so it sees the file alone. What depends on the project, such as whether a referenced service exists, is checked by the control plane.

nebula config validate [FILE]
nebula config validate
nebula config validate services/api/nebula.toml

nebula deploy

Deploy a service and follow the rollout to its end.

Without --ref, redeploys the service: the release that is serving, run again against the service's newest configuration. With --ref:

  • for a service built from Git, --ref is a branch; the command builds the branch head and deploys the result;
  • for a service that runs an image, --ref is an image reference. A bare tag such as v1.4 or :v1.4 is added to the service's repository.

Then it waits and prints each stage as the rollout moves, and exits 0 only when the new release is healthy. If the deployment fails, it exits 1 and prints the full reason; the previous release keeps serving. In a protected environment the deployment first waits for an approval, and the command prints the link to it. Use --no-wait to start the deployment and return at once.

nebula deploy [flags]
nebula deploy --service api --env development
nebula deploy -s api -e staging --ref feature/checkout
nebula deploy -s worker -e production --ref v1.4.2 --no-wait

Flags:

FlagTypeDefaultDescription
--accept-downtimeboolnoneallow a release that stops a service mounting a volume
--envstringnoneenvironment slug or id; default from nebula link
--jsonboolnoneprint JSON instead of text, for scripts and agents
--no-waitboolnonestart the deployment and return without following it
--projectstringnoneproject slug, name or id; default from nebula link
--refstringnonebranch to build (Git services) or image reference or tag to run (image services)
--servicestringnoneservice slug, name or id; default from nebula link
--timeoutduration0sstop waiting after this long (the deployment continues); 0 waits until it is final

Tie this directory to a project and environment.

Writes .nebula/link.json here, so the other commands default to this project and environment (and service, if you give one) without flags. Commands look for the file in the working directory and every parent, the way git looks for .git. The file holds slugs only, no secrets, so it is safe to commit.

Without flags, and with a terminal, link asks you to choose. A flag always wins over the link, and so do NEBULA_PROJECT, NEBULA_ENV and NEBULA_SERVICE.

nebula link [flags]
nebula link
nebula link --project shop --env development
nebula link --remove

Flags:

FlagTypeDefaultDescription
--envstringnoneenvironment slug or id; default from nebula link
--projectstringnoneproject slug, name or id; default from nebula link
--removeboolnonedelete the link file in this directory
--servicestringnoneservice slug, name or id; default from nebula link

nebula login

Sign the command line in to a control plane.

Opens your browser on the control plane's authorize page, where you pick the role and lifetime of a new API token, then stores that token in the credentials file ($XDG_CONFIG_HOME/nebula/credentials.json, mode 0600). The token is a normal API token: it shows in Settings, API tokens, and you can revoke it there or with nebula logout.

With --token, nothing opens: the token is read from standard input instead. Use that on a machine without a browser, and in scripts. In CI you can skip login and set NEBULA_URL and NEBULA_TOKEN instead.

Creating a token needs the admin role in the organization. Without it, ask an admin for a token and use --token.

nebula login [flags]
nebula login --url https://nebula.example.com
nebula login --url https://nebula.example.com --no-browser
echo "$TOKEN" | nebula login --url https://nebula.example.com --token

Flags:

FlagTypeDefaultDescription
--no-browserboolnoneprint the authorize address instead of opening it
--tokenboolnoneread an API token from standard input instead of opening a browser
--urlstringnonecontrol plane address, such as https://nebula.example.com; default the one you last logged in to

nebula logout

Revoke the stored token and delete the credentials file.

Revokes the token the CLI logged in with, so it stops working everywhere, then deletes the credentials file. If the control plane cannot be reached nothing is deleted, so a token is never left valid without a copy you can still revoke; --local deletes the file anyway.

nebula logout [flags]
nebula logout

Flags:

FlagTypeDefaultDescription
--localboolnonedelete the credentials file without revoking the token

nebula logs

Print or follow the log lines of a service, or of the whole environment.

Prints the newest stored log lines, oldest first. With -f it keeps going and prints new lines live over the same stream the console's Logs tab uses, reconnecting if the stream is closed; lines written while it reconnects are not replayed.

Without --service (and without a linked service) it reads every service of the environment and prefixes each line with the service's slug.

--since takes a duration (30m, 2h, 7d) or a timestamp (2026-10-02T09:30:00Z). --json prints one JSON object per line.

nebula logs [flags]
nebula logs --service api
nebula logs -s api -e production -f
nebula logs --since 2h --level error
nebula logs -s api --filter timeout -n 500 --json

Flags:

FlagTypeDefaultDescription
--envstringnoneenvironment slug or id; default from nebula link
--filterstringnoneonly lines matching this query: words that must all appear, "a phrase", -excluded, OR; the same query the console's log search takes
--followboolnonekeep running and print new lines as they arrive
--jsonboolnoneprint JSON instead of text, for scripts and agents
--levelstringnoneonly lines at this level or worse: debug, info, warn or error
--linesint100how many of the newest stored lines to print first
--podstringnoneonly lines from this pod
--projectstringnoneproject slug, name or id; default from nebula link
--servicestringnoneservice slug, name or id; default from nebula link
--sincestringnoneonly lines newer than this: a duration such as 30m or 2d, or an RFC 3339 timestamp

nebula migrate

Apply or inspect database migrations.

nebula serve applies pending migrations at boot, so these commands exist for an operator who wants the schema moved without starting the server.

nebula migrate COMMAND

Commands:

Flags:

FlagTypeDefaultDescription
--database-urlstringnonePostgreSQL connection URL

nebula migrate status

Show every migration and whether it has been applied.

nebula migrate status

Also takes --database-url from its parent command.

nebula migrate up

Apply every pending migration.

nebula migrate up

Also takes --database-url from its parent command.

nebula open

Open the project, or one service, in the console.

Opens the console on the project's canvas for the environment, or on one service's sheet. The address is always printed, so it also works over SSH where no browser can open.

nebula open [service] [flags]
nebula open
nebula open api --env production
nebula open api --print

Flags:

FlagTypeDefaultDescription
--envstringnoneenvironment slug or id; default from nebula link
--printboolnoneprint the address without opening a browser
--projectstringnoneproject slug, name or id; default from nebula link

nebula openapi

Print the OpenAPI description to stdout.

The document is built from the same route table the server serves, so the generated TypeScript client cannot describe an API this binary does not have. It needs no database and binds no port.

nebula openapi [flags]

Flags:

FlagTypeDefaultDescription
--indentboolnoneindent the JSON, so a committed copy reads as a diff when the API changes
--server-urlstringnoneadd this URL to the document as its server, for generated example requests

nebula projects

List the projects the token can reach.

Lists every project in the organization the token acts in, or the ones a project-limited token was given.

nebula projects [flags]
nebula projects
nebula projects --json

Flags:

FlagTypeDefaultDescription
--jsonboolnoneprint JSON instead of text, for scripts and agents

nebula run

Run a command on this machine with a service's variables.

Fetches the environment a service runs with in the chosen environment, with every ${{ service.KEY }} reference resolved the way a release resolves it and secrets in plain text, and runs COMMAND with those variables added to your own environment. The command's exit status becomes nebula's.

Use it to run a migration, a console or your app against the same configuration as a deployed service. Hosts that point inside the cluster, such as svc-db, only resolve in the cluster; reach the database from your machine through a tunnel or a Tailscale address and override that variable in your shell afterwards.

Reading secrets in plain text needs the deployer role, and every secret returned is recorded in the audit log as revealed. Put -- before the command so its own flags are not read as nebula's.

nebula run -- COMMAND [ARGS...] [flags]
nebula run --service api --env development -- npm run migrate
nebula run -s api -e staging -- sh -c 'echo $DATABASE_URL'
nebula run -s api --clean -- ./bin/server

Flags:

FlagTypeDefaultDescription
--cleanboolnonestart from an empty environment (plus PATH, HOME and TERM) instead of yours
--envstringnoneenvironment slug or id; default from nebula link
--projectstringnoneproject slug, name or id; default from nebula link
--servicestringnoneservice slug, name or id; default from nebula link

nebula secrets

Maintain credentials sealed in the database.

nebula secrets COMMAND

Commands:

Flags:

FlagTypeDefaultDescription
--database-urlstringnonePostgreSQL connection URL
--master-keystringnonenew current master key, base64 of exactly 32 bytes
--previous-master-keyslistnonecomma-separated previous base64 master keys accepted while resealing

nebula secrets reseal

Re-encrypt every stored credential under the current master key.

Re-encrypts every credential the database holds under the current master key (--master-key). Run it after rotating the master key, with the key you are retiring in --previous-master-keys so the old ciphertext can still be read.

It prints the current key id and how many rows it resealed in each table. Once it has finished, drop the previous keys from the configuration. It needs --database-url and --master-key.

nebula secrets reseal

Also takes --database-url, --master-key, --previous-master-keys from its parent command.

nebula serve

Run the API, the user interface and the cluster agent link.

nebula serve [flags]

Flags:

FlagTypeDefaultDescription
--acme-directory-urlstringhttps://acme-v02.api.letsencrypt.org/directoryACME directory the control plane issues DNS-01 certificates from; point it at Let's Encrypt staging when testing
--acme-dns-resolverslistnonerecursive DNS servers (host:port) used to find a hostname's zone and check DNS-01 propagation; defaults to the system resolver. Set it for split-horizon DNS or a private test CA
--agent-imagestringnonecontainer image the cluster install manifest deploys; an image in ghcr.io/nebulactrl/nebula-agent must be pinned by digest; defaults to the digest of the agent image published with this binary's version
--agent-update-deadlineduration10m0show long a running agent update may go without the new agent reporting in before it is automatically rolled back
--base-urlstringnonepublic URL this installation is reached at, for example https://nebula.example.com
--cloudflare-api-basestringhttps://api.cloudflare.com/client/v4Cloudflare API base URL; override for an end-to-end test fake
--community-templatesbooltrueread the public community template repository; false turns it off entirely, for an air-gapped install
--community-templates-repostringnebulactrl/nebula-templatesthe community template repository, as owner/name; every instance reads its main branch
--database-urlstringnonePostgreSQL connection URL
--github-api-basestringhttps://api.github.comGitHub API base URL; override for GitHub Enterprise Server or an end-to-end test fake
--github-web-basestringhttps://github.comGitHub web base URL used for the App manifest flow; override for GitHub Enterprise Server or an end-to-end test fake
--k3s-channels-urlstringhttps://update.k3s.io/v1-release/channelsK3s public release-channel feed a cluster's available patch/minor upgrades are computed against; override for an end-to-end test fake
--k3s-versionstringv1.36.4+k3s1K3s version the install script pins with INSTALL_K3S_VERSION, for example v1.36.4+k3s1
--listenstring:8080address the API and the user interface listen on
--master-keystringnonebase64 of exactly 32 bytes; every stored secret is sealed under it
--metrics-listenstring127.0.0.1:9090address Prometheus metrics listen on
--oidc-acr-valuesstringnoneoptional acr_values sent on every sign-in, for a provider that only reports a second factor when asked for a stronger context, for example urn:okta:loa:2fa:any
--oidc-client-idstringnoneOIDC client id registered with the issuer
--oidc-client-secretstringnoneOIDC client secret registered with the issuer
--oidc-insecure-httpboolnoneallow a plain http issuer; development and end-to-end tests only
--oidc-issuerstringnoneOIDC issuer URL; this installation delegates all authentication to it
--oidc-provider-namestringyour identity providername shown on the sign-in button
--oidc-scopesstringopenid profile emailspace-separated OIDC scopes to request
--organization-creationstringoperatorswho may create an organization on this installation: operators (owners of the organization the first sign-in created), members (anyone who belongs to an organization) or anyone (any signed-in person)
--pagerduty-events-urlstringhttps://events.pagerduty.comPagerDuty Events API origin notification channels deliver to; override for an end-to-end test fake
--pprofboolnoneexpose /debug/pprof on the metrics listener
--previous-master-keyslistnoneolder base64 32-byte master keys, comma-separated; retain them only until nebula secrets reseal has re-encrypted every stored secret
--rate-limit-buildsint30builds and deployments one session or API token may start per minute; 0 turns the limit off
--rate-limit-database-queriesint60database queries per minute per session or API token; 0 turns the limit off
--rate-limit-requestsint1200requests per minute one session or API token may make; 0 turns the limit off
--rate-limit-token-creationint10API tokens one session or API token may create per minute; 0 turns the limit off
--rate-limit-variable-readsint60resolved-variable and secret-reveal requests per minute per session or API token; 0 turns the limit off
--rate-limit-writesint120requests that change something, per minute per session or API token; 0 turns the limit off
--release-feed-urlstringhttps://get.nebulactrl.dev/changelog.jsonrelease feed checked for a newer release, in the shape GET /api/v1/releases serves, for example a mirror. Requests carry no instance id or version, only a plain "NebulaCtrl" User-Agent
--simulated-clusterboolnonerun an in-process simulated cluster instead of waiting for a real one
--simulated-cluster-expandable-storageboolnonegive the simulated cluster an expandable default storage class (longhorn) next to local-path, which cannot expand
--trusted-proxieslistnoneproxy IP addresses or CIDRs allowed to supply client IP headers; use cloudflare for its reviewed edge ranges, and include the exact local reverse-proxy or Docker bridge CIDR. A proxy on loopback may supply X-Forwarded-For unlisted, but CF-Connecting-IP is believed only from a listed proxy, so list 127.0.0.1 too when a local proxy forwards Cloudflare traffic
--update-checkbooltruecheck the release feed for a newer NebulaCtrl release; false turns update checks off entirely, for an air-gapped install
--updater-tokenstringnonesecret the host updater presents when it polls the control plane; the installer generates it as NEBULA_UPDATER_TOKEN in .env. Empty turns console updates of the control plane off

nebula status

Show every service of an environment: state, release, replicas and domain.

Shows one line per service in the environment: its state, the live release (r-N), how many replicas are ready out of how many are wanted, and its domain. A service whose newest deployment failed gets the full reason underneath, because the live release keeps serving.

nebula status [flags]
nebula status
nebula status --project shop --env production
nebula status --json

Flags:

FlagTypeDefaultDescription
--envstringnoneenvironment slug or id; default from nebula link
--jsonboolnoneprint JSON instead of text, for scripts and agents
--projectstringnoneproject slug, name or id; default from nebula link

nebula template

Work with app template files.

nebula template COMMAND

Commands:

nebula template validate

Parse one or more template files and report every problem.

Parses each FILE as an app template and reports every problem in it. The file name, minus .yaml or .yml, must equal the template's slug.

A file with no problem prints FILE: ok and the template's name and service count. A warning, such as a secret(N) that draws more characters than it asks for, prints under it as FILE:LINE: warning: PATH: MESSAGE and does not change the exit status. The command exits 1 if any file has a problem. It needs no database and no control plane.

nebula template validate FILE...
nebula template validate templates/redis-cache.yaml

nebula updater

Run the host service that performs console-requested control plane updates.

The updater runs on the control plane's host, not in its container. Every interval it polls the control plane over the host's loopback listener with the token in <dir>/.env (NEBULA_UPDATER_TOKEN). When an owner asked for an update it runs that version's install.sh from the get site, the command an operator would run by hand, verifies the new version, reinstalls the previous one if that fails, and reports the outcome. install.sh installs it as the nebula-updater systemd service.

nebula updater [flags]

Flags:

FlagTypeDefaultDescription
--control-plane-urlstringnonecontrol plane base URL; default http://<NEBULA_HOST_LISTEN from <dir>/.env>
--dirstringnoneinstall directory holding .env, bin and updater; required
--get-urlstringhttps://get.nebulactrl.devrelease site serving versions.json and each version's install.sh
--intervalduration15show often to poll the control plane, which is also its heartbeat

nebula variables

List, set and unset a service's variables.

Reads and changes variables the way the console does. list prints them with secrets masked. set and unset stage the edit in your draft change set and apply it, which redeploys the services that read the variable. In a protected environment (production by default) the apply opens an approval instead, and the command prints its link: nothing changes until an admin approves it.

A variable that nebula.toml owns cannot be changed here; the control plane says which file and commit set it. Values may contain references such as ${{ db.DATABASE_URL }}; quote them so your shell leaves them alone.

nebula variables COMMAND

Commands:

nebula variables list

List a service's variables.

Lists the variables a service has in an environment: its own and the environment-wide ones it inherits. Secret values are masked unless you pass --reveal, which needs the deployer role and writes one "revealed" entry per secret to the audit log.

nebula variables list [flags]
nebula variables list --service api
nebula variables list -s api -e production --reveal
nebula variables list -s api --json

Flags:

FlagTypeDefaultDescription
--envstringnoneenvironment slug or id; default from nebula link
--jsonboolnoneprint JSON instead of text, for scripts and agents
--projectstringnoneproject slug, name or id; default from nebula link
--revealboolnoneshow secret values in plain text (audited)
--servicestringnoneservice slug, name or id; default from nebula link
--sharedboolnonelist only the environment-wide variables, not a service's

nebula variables set

Set one or more variables and apply the change.

Stages each KEY=VALUE in your draft change set for the environment and applies it. The services that read the variables redeploy once. If your draft already holds staged changes, set stops without touching them; apply or discard them in the console, or pass --include-staged to apply them together.

In a protected environment the apply opens an approval and prints its link; the variables are written when an admin approves. With --wait the command follows each deployment to its end and exits non-zero if one fails.

Without --service the variables are set for the whole environment only with --shared.

nebula variables set KEY=VALUE... [flags]
nebula variables set LOG_LEVEL=debug --service api --env development
nebula variables set --secret STRIPE_KEY=sk_live_… -s api -e production --message "rotate Stripe key"
nebula variables set DATABASE_URL='${{ db.DATABASE_URL }}' -s api

Flags:

FlagTypeDefaultDescription
--accept-downtimeboolnoneallow a redeploy that stops a release which mounts a volume
--envstringnoneenvironment slug or id; default from nebula link
--include-stagedboolnoneapply changes already staged in your draft together with these
--messagestringnonewhat the change is for; shown in the approval and the audit log (at most 500 characters)
--projectstringnoneproject slug, name or id; default from nebula link
--secretboolnonemark the variables secret: masked in the console and in list
--servicestringnoneservice slug, name or id; default from nebula link
--sharedboolnonechange environment-wide variables instead of a service's
--waitboolnonefollow each started deployment until it is final

nebula variables unset

Remove one or more variables and apply the change.

Stages the removal of each KEY in your draft change set and applies it, with the same approval, --wait and --include-staged behavior as set. Removing a key that another service still references is refused by the control plane with the services that read it.

nebula variables unset KEY... [flags]
nebula variables unset OLD_FLAG --service api --env development

Flags:

FlagTypeDefaultDescription
--accept-downtimeboolnoneallow a redeploy that stops a release which mounts a volume
--envstringnoneenvironment slug or id; default from nebula link
--include-stagedboolnoneapply changes already staged in your draft together with these
--messagestringnonewhat the change is for; shown in the approval and the audit log (at most 500 characters)
--projectstringnoneproject slug, name or id; default from nebula link
--servicestringnoneservice slug, name or id; default from nebula link
--sharedboolnonechange environment-wide variables instead of a service's
--waitboolnonefollow each started deployment until it is final

nebula version

Print the build version.

Prints the version, the Go version and the operating system and architecture the binary was built for.

nebula version

nebula whoami

Show which control plane, organization and token the CLI uses.

Asks the control plane about the token the CLI would use: its organization, role and expiry. The token itself is never printed.

nebula whoami [flags]
nebula whoami
nebula whoami --json

Flags:

FlagTypeDefaultDescription
--jsonboolnoneprint JSON instead of text, for scripts and agents

On this page