@nerionx/cli
v0.5.0
Published
NerionX Brand Kit CLI — install, run, and operate a NerionX Spoke on your own machine or server.
Maintainers
Readme
@nerionx/cli
Brand Kit CLI for NerionX — provisioning, Hub sync, and day-2 operations (blueprint §8).
Install
Brand operators (needs Node 20 + Docker, no monorepo):
npm install -g @nerionx/cli
nerionx --helpFrom a monorepo checkout:
pnpm --filter @nerionx/cli build
node packages/cli/bin/nerionx.js --helpRun a Brand Kit (local or server)
init and up drive Docker directly — same two commands on a laptop and on a
server. Migrations run inside the Spoke image (the provision compose profile),
so no monorepo, pnpm, or Medusa toolchain is needed on the host.
mkdir my-brand && cd my-brand
nerionx init --slug my-brand # compose + .env + generated secrets, pulls images
# set HUB_API_KEY in .env (issued to your brand on approval)
nerionx up # infra → brand DB → migrations → spoke + storefront
nerionx status # container status
nerionx logs spoke -f # tail one service
nerionx down # stop (add --volumes to delete data)
nerionx update # pull newer images and recreateinit is idempotent: existing secrets and .env values are kept, and only
missing ones are generated. The compose template ships inside this package, so
it is version-locked to the CLI rather than fetched at install time.
Air-gapped / self-hosted registry
No reach to registry.nerionx.dev (regulated vertical or a closed brand
network)? Distribute the images yourself — the runtime stays containerized (no
npm/toolchain on the brand box):
# On a machine that CAN pull the images — save them into one portable bundle:
nerionx kit export --out ./nerionx-kit-latest
# Carry the folder into the private network, then on the target host:
nerionx kit import ./nerionx-kit-latest # docker load — needs no registry
nerionx init --offline --slug my-brand # scaffold; skips docker login + pull
nerionx up # boots from the loaded images
# Or seed a registry you host (Zot / registry:2 / Harbor) so many hosts pull it:
nerionx kit import ./nerionx-kit-latest --registry registry.internal:5000 --pushSee the air-gap runbook.
Config (~/.nerionx/config.json)
nerionx login --api-key nx_live_...
nerionx config set hubUrl http://localhost:9000
nerionx select --slug my-brand
nerionx config get
nerionx config sync-identityBlueprint workflow
nerionx create brand --name 'Brand A' --currency EUR --domain mybranda.com
nerionx select --domain mybranda.com
nerionx request approval --brand-name 'Brand A' --email [email protected] --phone +10000000000 --slug mybranda
nerionx login --api-key nx_live_...
nerionx provision
nerionx request ssl mybranda.com
nerionx pull products --initial
nerionx generate productsCommands
| Category | Commands |
|----------|----------|
| Brand Kit | init [--offline], up, down, status, logs [service], update |
| Air-gap / self-host | kit export, kit import [--registry <host> --push] |
| Identity | login, logout, config get/set/sync-identity |
| Deploy | create brand, select, request approval, provision, request ssl, check ssl, service restart, destroy brand |
| Catalog | pull products --initial\|--recent, sync [--force-event-bus] |
| AI | generate products, agent status |
| Orders | orders list, orders get <id>, pricing --sku |
| Ops | health [--verbose], security rotate-keys, db migrate, theme export/import |
Legacy aliases: brand:create, ssl check|request.
After provision
env $(grep -v '^#' .env.my-brand | xargs) pnpm --filter @nerionx/spoke dev