Reference
CLI
nebla is a command line client for the panel. It uses the same REST API as the web panel and signs in with a project API token.
Install
With Homebrew on macOS or Linux:
brew install nebla-cloud/tap/nebla
Or download the archive for your platform from GitHub Releases, along with checksums.txt. There are builds for Linux, macOS and Windows on amd64 and arm64. Check the download, then put nebla on your PATH:
sha256sum --ignore-missing -c checksums.txt # macOS: shasum -a 256 --ignore-missing -c checksums.txt
tar -xzf nebla_*_linux_amd64.tar.gz nebla
sudo install nebla /usr/local/bin/
The binaries are not signed. If you download by hand on macOS, run xattr -d com.apple.quarantine nebla before the first run. Homebrew does this for you.
With Go:
go install github.com/nebla-cloud/nebla/cmd/nebla@latest
The CLI and the panel share version numbers, and a CLI works best with a panel of the same version. nebla version prints the version, commit and build date.
Contexts
A context is a panel URL plus a project token. Create one per project you work in:
nebla context create home --endpoint https://panel.example.com # asks for the token
nebla context list
nebla context use home
nebla context delete home
context create checks the URL and token before it saves them. The first context becomes active, and --activate switches to a later one. When stdin isn't a terminal, the token is read from NEBLA_TOKEN or from one line of stdin.
Contexts live in cli.yaml in your user config directory (~/.config/nebla on Linux, ~/Library/Application Support/nebla on macOS). The file is mode 0600, and the token is never printed after it's stored.
The CLI picks the context in this order:
--context NAMENEBLA_ENDPOINTandNEBLA_TOKEN, both set. The config file isn't read, which suits CI.NEBLA_CONTEXT- The active context in the config file.
Commands
# SSH keys
nebla ssh-key create --name laptop --public-key-from-file ~/.ssh/id_ed25519.pub
nebla ssh-key list
nebla ssh-key delete laptop
# What you can create
nebla location list
nebla image list
nebla server-type list
# Servers
nebla server create --name web1 --type small-2 --image debian-13 --location home --ssh-key laptop
nebla server list --status running
nebla server describe web1
nebla server rename web1 web2
nebla server poweroff web2 # also: poweron, reboot, reset, shutdown
nebla server rebuild web2 --image ubuntu-24.04
nebla server change-type web2 --type medium-4 --upgrade-disk
nebla server ssh web2
nebla server delete web2
# Volumes
nebla volume create --name data --size 50 --server web1
nebla volume list
nebla volume resize data --size 100
nebla volume detach data
nebla volume attach data --server web2
nebla volume delete data
# Firewalls
nebla firewall create --name web --label env=prod
nebla firewall add-rule web --direction in --protocol tcp --port 22 --source-ips 0.0.0.0/0
nebla firewall apply-to-resource web --type server --server web1
nebla firewall apply-to-resource web --type label_selector --label-selector role=web
nebla firewall list
nebla firewall delete web
nebla completion zsh # also: bash, fish, powershell
Run nebla help or nebla <command> --help for every flag. Servers, keys and other objects can be named by ID or by name. A number is tried as an ID first, then as a name.
server create also takes --user-data-from-file, --label key=value, --without-ipv4, --with-ipv6 and --start-after-create=false. server list takes --selector key=value.
Waiting for actions
Commands that start an action, such as create, delete, power, rebuild and change-type, wait until it finishes. Progress goes to stderr, so stdout stays clean for -o json.
--no-waitprints the action ID and returns.--timeout 5mstops waiting after that long. The action keeps running on the panel.- Ctrl-C stops waiting, prints the action ID and exits with 130.
Output
-o table (the default), -o json or -o yaml. List commands print every page. --no-header drops the table header.
| Exit code | Meaning |
|---|---|
| 0 | Success |
| 1 | Any error, including a failed action |
| 130 | Interrupted while waiting for an action |
nebla server ssh
nebla server ssh <server> runs your system ssh against the server's IPv4 address, or IPv6 with --ipv6 or when the server has no IPv4. Arguments after -- are passed to ssh as options, for example -- -A -L 8080:localhost:80. Without -u, the user comes from the image's OS:
| Image OS | User |
|---|---|
debian | debian |
ubuntu | ubuntu |
rocky | rocky |
almalinux | almalinux |
fedora | fedora |
centos | cloud-user |
| anything else | root |
Cloud-init installs the project's SSH keys you picked at create time for that user.