CLI Reference
The atomo CLI streamlines local development, code generation, and service ops.
Usage
# Run CLI from repo root
pnpm atomo -- <command> [options]
# Or use package scripts inside a service (e.g., CRM)
cd services/crm-service
pnpm dev # atomo dev --service crm
pnpm migrate # atomo migrate --service crmCommands & Options
# Start dev pipeline (codegen, server, admin UI)
atomo dev [-p, --port 3000] [--workspace] [--isolated] [--service-path services/<name>] [--strict-schema] [--verify-schema]
# Build service for production
atomo build --service <name>
# Database operations
atomo migrate [--database-url <url>] [--generate --name <migration>]
# Code generation
atomo codegen [-o, --output generated]
# Seed database (run inside a service directory)
atomo seed [--file ./seed.sql]
# Run service tests (runs `cargo test` in the service directory)
atomo test [--service-path <path>] [-f, --filter <name>]Workspace Dev
For core contributors working on the core crates and a service together:
atomo dev --workspace [--service-path services/<name>] [-p 3000]Note: atomo workspace-dev has been removed. Use atomo dev --workspace.
Flags
--workspace— run from the monorepo context (faster rebuilds, Admin UI proxy)--isolated— force isolated mode (no workspace); useful to test service-only flow inside the monorepo--service-path <path>— explicit service directory in workspace mode--strict-schema— treat schema validation problems as errors (default strict in isolated mode; warnings in workspace)--verify-schema— run schema validations (enabled by default; flag is a no-op enable switch)
Init/build/deploy:
atomo init <project-name> [--template <name>]
atomo build
atomo deploy [-e, --env production]See also: package.json scripts at repo root and in services/<name>/package.json.
Multi-Project Control Plane
Provision and manage many isolated projects on shared infrastructure (silo per project: a dedicated database + atomo-server instance each). See the Multi-Project Platform design for the full model.
atomo project create --id <slug> --name "<Display>" --hostname <host> \
--database-url-ref <ssm-ref> (--schema-git <repo> --schema-path <p> --schema-ref <sha> | --schema-volume <path>)
atomo project start <slug>
atomo project stop <slug>
atomo project list
atomo project delete <slug> [--drop-database --yes]Configured via env (see .env.example): ATOMO_CP_DATABASE_URL (registry DB), ATOMO_ADMIN_DATABASE_URL, ATOMO_SECRET_STORE (ssm|env), ATOMO_SERVER_IMAGE, ATOMO_SCHEMA_VOLUME_ROOT, ATOMO_PORT_BASE, ATOMO_CADDY_CONFIG, ATOMO_CADDY_ADMIN. A control-plane HTTP API (atomo_control_plane::api) exposes the same lifecycle for automation.
Seed Command
- Runs from the service root (where
schema.tslives). - Reads
.envin the current directory forDATABASE_URL. - Executes the given SQL file in a transaction (defaults to
./seed.sql).
Examples:
cd services/crm-service
# Using .env DATABASE_URL and default seed file
atomo seed
# Specify a custom seed file
atomo seed --file ./seed-demo.sql