Platform Features

Nimbuz CLI: Deploy and Manage Apps from Your Terminal

By Manoranjith··6 min read
View as Markdown

Introduction

The Nimbuz portal makes it easy to create projects, deploy applications and install managed tools with a few clicks. But many developers live in the terminal, and every team eventually wants to automate deployments from a CI/CD pipeline.

The Nimbuz CLI brings the whole platform to your command line. Projects, environments, apps, managed databases, logs, metrics and billing are all one command away, and every command works the same way in your terminal, in a shell script, in GitHub Actions or when an AI agent runs it.

The CLI is open source (nimbuz-tech/nimbuz-cli) and published to npm as @nimbuz-tech/cli.

Why a CLI for Nimbuz?

  • One-command deploys: nimbuz deploy creates the app if it does not exist, rolls out changes if it does, and waits until it is live.
  • Managed tools in seconds: install PostgreSQL, MongoDB, n8n and more from the catalog, then resize, stop or start them.
  • Environments with guardrails: keep production and staging apart, each with its own CPU, memory and storage limits.
  • Built for scripts, CI and AI agents: JSON output, quiet mode, non-interactive flags and stable exit codes.
  • Zero dependencies: pure Node.js 18+, so it installs in seconds.
  • Safe by default: scoped API keys stored with restricted file permissions, secrets redacted in debug logs, and confirmations before destructive actions.

Installing the CLI

The CLI needs Node.js 18 or newer.

npm install -g @nimbuz-tech/cli

This installs the nimbuz command. You can also run it without installing anything:

npx @nimbuz-tech/cli --help

Logging In with an API Key

The CLI authenticates with an account API key (it starts with nmz_). Create one in the Nimbuz portal under Account Information → API keys, then run:

nimbuz login

Paste the key when asked. The CLI checks it, saves it together with your account ID, and only ever shows it masked.

API keys are scoped: when you create a key in the portal, you choose which projects, environments and actions it can reach. A key for your CI pipeline can deploy to staging only, while a key on your laptop can do more.

How Nimbuz Is Organised

The CLI follows the same structure as the portal:

Project  (shop-api)
 └─ Environment  (production, staging, …)   ← resource limits & quotas
     ├─ Apps   (api, web, worker …)          ← built from Git or an archive
     └─ Tools  (PostgreSQL, MongoDB, n8n …)  ← managed, one-command installs

Pick a project and an environment once with nimbuz use, and every following command works inside it:

nimbuz use shop-api production

Names match exactly, case-insensitively or by a unique prefix, so nimbuz use sho also selects shop-api. You can still override the scope on any command with --project / -p and --env / -E.

Quick Start: From Zero to a Live App

Five commands take you from an empty account to a running application:

nimbuz login                         # save your API key
nimbuz projects create shop-api      # creates the project and a "production" environment
nimbuz init                          # writes nimbuz.json from your git remote / package.json
nimbuz deploy                        # create-or-update the app, then wait until it is live
nimbuz status                        # overview of the current environment

Run nimbuz <command> --help at any time to see every flag with examples.

Working with Projects and Environments

A project groups everything that belongs to one product or service. Environments such as production, staging or dev isolate workloads and carry their own resource limits.

nimbuz projects create shop-api -d "Backend for the web shop"
nimbuz envs create staging --use
nimbuz envs update production --cpu 4 --memory 8 --storage 20
nimbuz envs usage                    # remaining resource quota

Deploying Apps

Apps are built from Git (GitHub, GitLab or Bitbucket) or from a local archive, and run as containers.

From a Git repository

nimbuz apps create shop-api --repo acme/shop-api -b main --port 3000 \
  -i small.m --health /health -e NODE_ENV=production --secret-file .env.secrets --wait

owner/repo is shorthand for a GitHub repository. --wait follows the build and rollout and returns once the app is live.

From a local archive

nimbuz apps create site --archive ./dist.zip --port 80

Scaling, variables and secrets

Updates send only what you pass, so the rest of the configuration stays as it is:

nimbuz apps update shop-api --instance medium.m --replicas 2
nimbuz apps scale shop-api --autoscale 2:6
nimbuz apps env set shop-api LOG_LEVEL=info --wait
nimbuz apps secrets set shop-api --from-file .env.production
nimbuz apps redeploy shop-api --branch release/2.0 --wait

Watching what happens

nimbuz apps status shop-api --watch  # live rollout and pod status
nimbuz apps releases shop-api        # build and release history
nimbuz logs shop-api -f              # follow runtime logs
nimbuz apps open shop-api            # open the app in your browser

The nimbuz.json Manifest

For repeatable deployments, keep your app’s configuration in a nimbuz.json file next to your code. nimbuz init writes one for you, and nimbuz deploy reads it:

{
  "name": "shop-api",
  "project": "shop-api",
  "environment": "production",
  "source": { "repo": "https://github.com/acme/shop-api.git", "branch": "main", "dockerfile": "Dockerfile" },
  "build": { "install": "npm ci", "build": "npm run build", "start": "npm start" },
  "instance": "small.m",
  "replicas": 1,
  "autoscale": { "min": 1, "max": 4 },
  "port": 3000,
  "health": "/health",
  "vars": { "NODE_ENV": "production" },
  "secrets": { "DATABASE_URL": "${DATABASE_URL}" }
}

Values written as ${VAR} (or ${VAR:-default}) are read from your shell when you deploy, so secrets never need to be committed to Git. Flags on the command line override the manifest, and you can keep one manifest per environment:

nimbuz deploy -f deploy/prod.json --env production

Installing Managed Tools

Databases and services from the Nimbuz catalog are installed and operated for you:

nimbuz tools catalog postgresql      # see the settings a tool accepts
nimbuz tools install postgresql orders-db --set auth.postgresPassword=change-me
nimbuz tools get orders-db           # host, port and credentials
nimbuz tools resize orders-db small.r

nimbuz tools delete removes a tool and its data, so the CLI asks for confirmation first.

Using the CLI in CI/CD

The CLI is designed to run without a person at the keyboard:

  • --json prints machine-readable JSON on stdout, while progress goes to stderr.
  • --quiet prints only names or IDs, ready to pipe into other commands.
  • --yes skips confirmations. Without a terminal, destructive commands require it.
  • NIMBUZ_API_KEY provides the key without running nimbuz login.

Exit codes are stable, so your scripts can branch on them: 0 for success, 2 for a usage error, 4 for a missing or invalid API key and 5 when something is not found.

GitHub Actions example

- uses: actions/setup-node@v4
  with: { node-version: 22 }
- run: npx @nimbuz-tech/cli deploy --env production --yes
  env:
    NIMBUZ_API_KEY: ${{ secrets.NIMBUZ_API_KEY }}
    DATABASE_URL: ${{ secrets.DATABASE_URL }}

Every push now builds and deploys your app on Nimbuz, using the nimbuz.json in your repository.

Beyond Apps and Tools

The CLI covers the rest of the portal as well:

  • nimbuz domains for public endpoints and custom domains
  • nimbuz ai for AI model endpoints and their API keys
  • nimbuz logs and nimbuz metrics for observability
  • nimbuz billing for invoices, costs and account limits

The full command reference is in the Nimbuz documentation.

Conclusion

The Nimbuz CLI turns everything you do in the portal into commands you can type, script and automate. Deploy with one command, keep configuration in a nimbuz.json manifest, install managed databases in seconds and plug Nimbuz into any CI/CD pipeline, all with a scoped API key that can only do what you allow.

Install it with npm i -g @nimbuz-tech/cli and get started on Nimbuz today.

More in Platform Features

View all →