-
-
Notifications
You must be signed in to change notification settings - Fork 2
Config Env Vars
← Configuration | Config-Postgres →
All ɳSelf project configuration lives in .env (and optionally .env.local for local overrides). This page documents every supported environment variable, grouped by service.
Auto-generated vars: A set of derived variables (e.g. DATABASE_URL, DOCKER_NETWORK) are written to .env.computed by the orchestration layer. Never hand-edit .env.computed, it is overwritten on every nself build and nself start.
Plugin-managed vars: Plugins that require additional configuration (e.g. nself-ai, nself-notify, nself-livekit) inject their own *_ENABLED, *_KEY, and *_PORT vars into .env when installed. Those are documented in each plugin's own wiki page. Only core CLI vars appear here.
- Load Order (Cascade)
- Core Project Settings
- PostgreSQL
- Backup and Restore
- Hasura (GraphQL API)
- Auth
- Nginx and SSL
- ɳSelf Admin
- AI (Zero-Config AI Pool)
- Optional Service Toggles
- Custom Services (CS_N)
- Licensing
- Observability / Profiling
- Computed Variables
nSelf resolves config from several .env* files, later files overriding earlier ones for any variable they both set:
.env → .env.{dev|staging|prod} → .env.secrets → .env.local
| File | Committed? | Purpose |
|---|---|---|
.env |
Yes | Shared base every environment starts from. |
.env.dev / .env.staging / .env.prod
|
Yes | Exactly one loads, matching ENV. |
.env.secrets |
Never | Real secrets (passwords, admin keys, the AI master secret). Generated by nself init --full and appended to by the build orchestrator when it auto-generates a value. |
.env.local |
Never | Your personal override. Always wins — use it for anything you don't want to share with teammates. |
.env.ai no longer exists as a cascade layer (removed in CLI-R18). Its AI-tier config (AI_* vars, NSELF_MASTER_SECRET) is folded into .env.secrets, the file it always belonged with.
Inspect the cascade for your project:
nself env explain # every file, whether it exists, precedence order
nself env explain VAR # which file wins for VAR (redacted; add --reveal for the value)Escape hatch: NSELF_LEGACY_ENV_ORDER=1 restores the pre-CLI-R18 order (.env.dev → .env.{staging|prod} → .env.secrets → .env.local → .env → .env.ai) for exactly one minor version, printing a warning naming the variable and removal version on every use. This exists only to unblock a project mid-migration — run nself migrate to move off it permanently. See cmd-migrate for exactly what the migration shim auto-fixes versus flags for manual review.
These vars control the top-level identity and behavior of a project.
| Variable | Type | Default | Required | Description |
|---|---|---|---|---|
PROJECT_NAME |
string | (none) | Yes | Docker container and network namespace. Must be lowercase, 2–30 characters. |
BASE_DOMAIN |
string | local.nself.org |
No | Root domain used to construct all service subdomains. |
ENV |
enum | dev |
No | Deployment environment. Accepted values: dev, staging, prod. |
PROJECT_DESCRIPTION |
string | "" |
No | Human-readable description of the project. |
ADMIN_EMAIL |
string | "" |
No | Admin contact email for notifications and certificates. |
DB_ENV_SEEDS |
bool | true |
No | When true, database seed files run automatically on first boot. |
| Variable | Type | Default | Required | Description |
|---|---|---|---|---|
POSTGRES_VERSION |
string | 16-alpine |
No | Docker image tag for the Postgres container. |
POSTGRES_IMAGE |
string | (unset) | No | Explicit image override for the Postgres container (e.g. pgvector/pgvector:pg16). Wins over every other resolution, including the POSTGRES_EXTENSIONS pgvector inference below. Set this to pin a running image across nself build regens. |
BACKUP_CRITICAL_TABLES |
string | np_users,np_licenses,np_audit_log,np_plugins,np_billing |
No | Comma-separated tables nself backup drill looks for after restoring into its scratch database. The check is presence-only and advisory: an empty table counts as present, and missing tables are reported without failing the drill. Set this when your schema does not use the np_ prefix, or the defaults will all read as missing. See cmd-backup. |
POSTGRES_HOST |
string | postgres |
No | Internal container hostname. Change only if running Postgres externally. |
POSTGRES_PORT |
int | 5432 |
No | Port exposed to the host machine. |
POSTGRES_DB |
string | derived from the project name | No | Database created on first start. nself init writes a name derived from the project directory, lowercased with hyphens, dots and spaces folded to underscores, since a database name must be a valid SQL identifier and a directory name often is not. my-app becomes my_app. Only if nothing sets it at all does it fall back to nself. Set it explicitly to control the name. |
POSTGRES_USER |
string | postgres |
No | Superuser account name. |
POSTGRES_PASSWORD |
string | (none) | Yes | Superuser password. Minimum 16 characters. |
POSTGRES_EXTENSIONS |
string | uuid-ossp |
No | Comma-separated list of extensions to install automatically. When this list contains pgvector and POSTGRES_IMAGE is unset, nself build selects the pgvector/pgvector:pg<major> image instead of plain postgres:<POSTGRES_VERSION>. |
POSTGRES_EXPOSE_PORT |
enum | auto |
No | Controls host-port binding. auto exposes in dev and hides in prod. Accepted values: auto, true, false. |
POSTGRES_MEM_LIMIT |
string | 2g |
No | Docker memory limit for the Postgres container. |
POSTGRES_CPU_LIMIT |
string | 2.0 |
No | Docker CPU core limit for the Postgres container. |
PGVECTOR_ENABLED |
bool | false |
No | Installs the pgvector extension for embedding storage and similarity search (RAG). |
PGVECTOR_DIMENSIONS |
int | 1536 |
No | Vector column width. Must match the embedding model's output size. |
PGVECTOR_HNSW_M |
int | 16 |
No | HNSW index m parameter (max connections per node). Higher values improve recall at the cost of index size. |
PGVECTOR_HNSW_EF_CONSTRUCTION |
int | 64 |
No | HNSW index ef_construction parameter. Higher values improve index quality at the cost of build time. |
Computed: DATABASE_URL is derived automatically:
DATABASE_URL=postgresql://{POSTGRES_USER}:{POSTGRES_PASSWORD}@postgres:5432/{POSTGRES_DB}
This value is written to .env.computed and should not be set manually.
Credentials may come from these variables or from rclone.conf / RCLONE_CONFIG_*.
Leaving both key variables empty is valid and means "configured elsewhere".
Setting exactly one of the pair is always rejected, because it is never a
meaningful state: it is a typo or a partial migration between the two accepted
name pairs, and rclone would otherwise fail silently or send an empty secret.
| Variable | Type | Default | Required | Description |
|---|---|---|---|---|
BACKUP_S3_BUCKET |
string | (unset) | No | Destination bucket for off-box backup copies. App-level: consumed by app backup scripts, not read into the CLI's config struct. |
BACKUP_S3_ACCESS_KEY_ID |
string | (unset) | No | Access key for the backup bucket. Must be set together with BACKUP_S3_SECRET_ACCESS_KEY. |
BACKUP_S3_SECRET_ACCESS_KEY |
string | (unset) | No | Secret key for the backup bucket. Must be set together with BACKUP_S3_ACCESS_KEY_ID. |
BACKUP_S3_REGION |
string | (unset) | No | Region passed to the storage provider. |
BACKUP_S3_ENDPOINT |
string | (unset) | No | Custom endpoint for S3-compatible providers (Backblaze B2, Cloudflare R2, MinIO). Leave unset for AWS S3. |
BACKUP_S3_PREFIX |
string | (unset) | No | Key prefix applied to uploaded objects, for sharing one bucket across projects. App-level, like BACKUP_S3_BUCKET. |
BACKUP_ACCESS_KEY |
string | (unset) | No |
Accepted alias for BACKUP_S3_ACCESS_KEY_ID. The canonical name wins when both are set. |
BACKUP_SECRET_KEY |
string | (unset) | No |
Accepted alias for BACKUP_S3_SECRET_ACCESS_KEY. The canonical name wins when both are set. |
Why the aliases exist. BACKUP_ACCESS_KEY / BACKUP_SECRET_KEY were already
in use in the wild (they are the names in ntask/backend/.env.example) but were
never read into the backup config, so every deployment using them had remote
upload silently disabled while appearing configured. Both spellings are now
accepted. Prefer the canonical BACKUP_S3_* names in new configuration.
See also BACKUP_CRITICAL_TABLES under PostgreSQL, and
cmd-backup for the commands that consume these.
| Variable | Type | Default | Required | Description |
|---|---|---|---|---|
HASURA_VERSION |
string | v2.44.0 |
No | Docker image tag for Hasura. |
HASURA_GRAPHQL_ADMIN_SECRET |
string | (none) | Yes | Admin API secret used to authenticate privileged requests. Minimum 32 characters. |
HASURA_JWT_KEY |
string | (none) | Yes | Secret key used to sign and verify JWTs. Minimum 32 characters. |
HASURA_JWT_TYPE |
string | HS256 |
No | JWT signing algorithm. Common values: HS256, RS256. |
HASURA_GRAPHQL_ENABLE_CONSOLE |
bool |
true (dev) / false (prod) |
No | Enable the Hasura web console. Automatically disabled in production. |
HASURA_GRAPHQL_DEV_MODE |
bool |
true (dev) / false (prod) |
No | Enable developer mode. Automatically disabled in production. |
HASURA_GRAPHQL_CORS_DOMAIN |
string |
http://localhost:* (dev) |
No | Allowed CORS origins. In production, set to your actual domain(s). |
HASURA_GRAPHQL_LOG_LEVEL |
string | warn |
No | Hasura log verbosity. Accepted values: debug, info, warn, error. |
HASURA_PORT |
int | 8080 |
No | Internal port the Hasura container listens on. |
HASURA_ROUTE |
string | api |
No | Nginx subdomain route (e.g. api → api.yourdomain.com). |
HASURA_MEM_LIMIT |
string | 1g |
No | Docker memory limit for the Hasura container. |
HASURA_CPU_LIMIT |
string | 1.0 |
No | Docker CPU core limit for the Hasura container. |
Authentication is provided by nHost Auth. These variables configure the Auth service container.
| Variable | Type | Default | Required | Description |
|---|---|---|---|---|
AUTH_ENABLED |
bool | true |
No | Whether the Auth container is generated at all. Written by nself init; set to false for a project that provides its own auth. |
AUTH_VERSION |
string | 0.36.0 |
No | Docker image tag for the Auth service. |
AUTH_PORT |
int | 4000 |
No | Internal port the Auth service listens on. |
AUTH_CLIENT_URL |
string | http://localhost:3000 |
No | URL the Auth service redirects to after OAuth flows complete. |
AUTH_ACCESS_TOKEN_EXPIRES_IN |
int | 900 |
No | Access token lifetime in seconds (default: 15 minutes). |
AUTH_REFRESH_TOKEN_EXPIRES_IN |
int | 2592000 |
No | Refresh token lifetime in seconds (default: 30 days). |
AUTH_RATE_LIMIT |
string | 30r/m |
No | Nginx rate limit applied to auth endpoints. |
AUTH_MEM_LIMIT |
string | 256m |
No | Docker memory limit for the Auth container. |
AUTH_CPU_LIMIT |
string | 0.25 |
No | Docker CPU core limit for the Auth container. |
AUTH_LOG_LEVEL |
string | info |
No | Auth service log verbosity. Accepted values: debug, info, warn, error. |
| Variable | Type | Default | Required | Description |
|---|---|---|---|---|
AUTH_SMTP_HOST |
string | mailpit |
No | SMTP server hostname. Defaults to the local Mailpit container in dev. |
AUTH_SMTP_PORT |
int | 1025 |
No | SMTP server port. |
AUTH_SMTP_USER |
string | (empty) | No | SMTP authentication username. |
AUTH_SMTP_PASS |
string | (empty) | No | SMTP authentication password. |
AUTH_SMTP_SECURE |
bool | false |
No | When true, connect using TLS. |
AUTH_SMTP_SENDER |
string | noreply@{BASE_DOMAIN} |
No | From address for outgoing auth emails. |
All OAuth provider vars are optional. Set client ID and secret for each provider you want to enable.
| Variable | Type | Default | Required | Description |
|---|---|---|---|---|
AUTH_PROVIDER_GOOGLE_CLIENT_ID |
string | (empty) | No | Google OAuth 2.0 client ID. |
AUTH_PROVIDER_GOOGLE_CLIENT_SECRET |
string | (empty) | No | Google OAuth 2.0 client secret. |
AUTH_PROVIDER_GITHUB_CLIENT_ID |
string | (empty) | No | GitHub OAuth app client ID. |
AUTH_PROVIDER_GITHUB_CLIENT_SECRET |
string | (empty) | No | GitHub OAuth app client secret. |
AUTH_PROVIDER_APPLE_CLIENT_ID |
string | (empty) | No | Apple Sign In service ID. |
AUTH_PROVIDER_FACEBOOK_CLIENT_ID |
string | (empty) | No | Facebook app client ID. |
| Variable | Type | Default | Required | Description |
|---|---|---|---|---|
NGINX_VERSION |
string | alpine |
No | Docker image tag for Nginx. |
NGINX_HTTP_PORT |
int | 80 |
No | Host port for HTTP traffic. |
NGINX_HTTPS_PORT |
int | 443 |
No | Host port for HTTPS traffic. |
NGINX_BIND_IP |
string |
127.0.0.1 (dev) / 0.0.0.0 (prod) |
No | IP address Nginx binds on. Set to 0.0.0.0 to accept external connections. |
NGINX_CLIENT_MAX_BODY_SIZE |
string | 100M |
No | Maximum allowed size for client request bodies (controls upload limits). |
NGINX_FRONTED_BY |
string | (empty) | No | Names the stack whose Nginx already serves this project's domains. When set, nself build generates no Nginx service for this project and nself status stops expecting one. See Config-Nginx. |
SSL_MODE |
enum | local |
No | SSL certificate strategy. Accepted values: local (self-signed), letsencrypt, custom, none. |
EXTRA_SSL_DOMAINS |
string | (empty) | No | Additional domains to include in the certificate SAN (comma-separated). |
The ɳSelf Admin dashboard is an optional local GUI companion that runs at localhost:3021. It is not deployed to any server.
| Variable | Type | Default | Required | Description |
|---|---|---|---|---|
NSELF_ADMIN_ENABLED |
bool | false |
No | When true, the Admin container is included in docker-compose. |
NSELF_ADMIN_PORT |
int | 3021 |
No | Host port for the Admin dashboard. |
NSELF_ADMIN_VERSION |
string | latest |
No | Docker image tag for nself/nself-admin. |
This block is written once by nself init into .env.secrets (never .env, never committed). It replaces the retired .env.ai cascade layer (CLI-R18); the vars and their values are unchanged, only the file moved.
| Variable | Type | Default | Required | Description |
|---|---|---|---|---|
AI_PROFILE |
enum | auto |
No | Routing profile. Accepted values: auto, local_only, pool_only, oauth_only, custom. |
AI_AUTO_INSTALL |
bool | true |
No | When true and NSELF_MASTER_SECRET is set, nself start runs the local AI setup wizard automatically if Ollama isn't already healthy. |
AI_DEFAULT_MODEL |
string | gemma2:2b |
No | Local model pulled and used for general-purpose requests. |
AI_EMBEDDING_MODEL |
string | nomic-embed-text |
No | Local model used for embedding generation (RAG, similarity search). |
AI_POOL_AUTO_PROVISION |
bool | true |
No | Automatically provisions a pooled GCP API key when the local/OAuth tiers can't serve a request. |
AI_BACKGROUND_LOCAL_ONLY |
bool | true |
No | Restricts background/non-interactive AI tasks to the local tier only, never spending pool or paid budget. |
AI_DAILY_BUDGET_USD |
float | 0 |
No | Hard daily cap on paid-tier spend. 0 disables paid tiers entirely (free tiers only). |
AI_MONTHLY_BUDGET_USD |
float | 0 |
No | Hard monthly cap on paid-tier spend. 0 disables paid tiers entirely (free tiers only). |
AI_TIMEOUT_LOCAL_MS |
int | 0 |
No | Timeout override for the local tier, in milliseconds. 0 falls back to the router's built-in default. |
AI_TIMEOUT_OAUTH_MS |
int | 0 |
No | Timeout override for the OAuth tier, in milliseconds. 0 falls back to the router's built-in default. |
AI_TIMEOUT_POOL_MS |
int | 0 |
No | Timeout override for the pool tier, in milliseconds. 0 falls back to the router's built-in default. |
AI_TIMEOUT_PAID_MS |
int | 0 |
No | Timeout override for the paid tier, in milliseconds. 0 falls back to the router's built-in default. |
AI_POOL_OAUTH_CLIENT_ID |
string | (empty) | No | OAuth client ID for the pooled-key provisioning flow. |
AI_POOL_OAUTH_CLIENT_SECRET |
string | (empty) | No | OAuth client secret for the pooled-key provisioning flow. |
NSELF_MASTER_SECRET |
string | (generated) | Yes (once AI is configured) | Key-encryption-key protecting stored OAuth refresh tokens and pooled API keys. Generated once by nself init and must never be regenerated or changed afterward — doing so makes all previously-encrypted material unreadable. |
These boolean flags enable optional bundled services. Each defaults to false. When set to true, the service is included in the generated docker-compose.yml.
| Variable | Type | Default | Required | Description |
|---|---|---|---|---|
ADMIN_ENABLED |
bool | false |
No | Bare (non-NSELF_-prefixed) form written by nself init's generated .env template alongside the other optional-service toggles. Distinct from NSELF_ADMIN_ENABLED above, which is the toggle the Admin dashboard actually reads. |
REDIS_ENABLED |
bool | false |
No | Enable Redis (caching, sessions, queues). |
MINIO_ENABLED |
bool | false |
No | Enable MinIO (S3-compatible object storage). |
SEARCH_ENABLED |
bool | false |
No | Enable MeiliSearch (full-text search). |
FUNCTIONS_ENABLED |
bool | false |
No | Enable the serverless Functions runtime. |
MAILPIT_ENABLED |
bool | false |
No | Enable Mailpit (local email testing UI). |
MLFLOW_ENABLED |
bool | false |
No | Enable MLflow (ML experiment tracking). |
Note: Each optional service also exposes its own
*_VERSION,*_PORT,*_MEM_LIMIT, and*_CPU_LIMITvars. See the dedicated page for each service.
ɳSelf supports up to 10 user-defined services, numbered CS_1 through CS_10. Each slot uses a consistent set of vars with N replaced by the slot number.
| Variable | Type | Default | Required | Description |
|---|---|---|---|---|
CS_N |
string | (empty) | No | Service definition string. Format: name:template[:port][:route]. Example: ping_api:node:8001:ping. |
| Variable | Type | Default | Required | Description |
|---|---|---|---|---|
CS_N_PORT |
int | (from definition) | No | Port the custom service listens on. |
CS_N_NAME |
string | (from definition) | No | Service name used in container labels and Nginx routing. |
CS_N_MEMORY |
string | 256m |
No | Docker memory limit. |
CS_N_CPU |
string | 0.5 |
No | Docker CPU core limit. |
CS_N_PUBLIC |
bool | false |
No | When true, the service is reachable from outside the Docker network via Nginx. |
CS_N_REPLICAS |
int | 1 |
No | Number of container instances to run. |
CS_N_HEALTHCHECK |
string | /health |
No | Healthcheck override: a path, a full CMD .../CMD-SHELL ... command, or disabled/none/false to omit it. See Config-Custom-Services. |
CS_N_ENV_PASSTHROUGH |
string | (empty) | No | Comma-separated allowlist of project .env var names to forward into this service. CS_N_ENV wins on conflict. See Config-Custom-Services. |
CS_N_IMAGE |
string | (empty) | No | Run a pre-built image (optionally digest-pinned, e.g. repo/name@sha256:...) instead of building from a Dockerfile. Mutually exclusive with CS_N_PATH. |
CS_N_ENV_FILE |
string | (empty) | No | Project-relative path to a dotenv-format file of extra env vars, injected at build time. Applied after CS_N_ENV_PASSTHROUGH; CS_N_ENV always wins on conflict. Subject to the same path-traversal check as CS_N_PATH. |
CS_N_VOLUMES |
string | (empty) | No | Comma-separated host:container[:mode] bind mounts, subject to the same traversal check as CS_N_PATH. |
Example (from web/, nself.org infrastructure):
CS_1=ping_api:node:8001:ping
CS_1_PORT=8001
CS_1_NAME=ping_api
CS_1_MEMORY=128m
CS_1_CPU=0.25
CS_1_PUBLIC=true
CS_1_REPLICAS=1
This registers a Node.js service named ping_api accessible at ping.{BASE_DOMAIN}.
| Variable | Type | Default | Required | Description |
|---|---|---|---|---|
NSELF_DEPLOY_KEY_PATH |
string | (empty) | No | Path to the SSH private key used for remote deploys. Overrides NSELF_DEPLOY_SSH_KEY when set. Example: ~/.ssh/nself_deploy_ed25519. |
HETZNER_NSELF_TOKEN |
string | (empty) | No | Hetzner Cloud API token. When set, nself access grant calls the Hetzner Cloud API after a successful grant and warns about any SSH key registered at the Hetzner project level that is absent from the target server's authorized_keys — a key added to the project believing it grants access everywhere does nothing for an already-running server. Unset skips the check entirely; it is never required for nself access itself to work. |
| Variable | Type | Default | Required | Description |
|---|---|---|---|---|
NSELF_EMBEDDED_PG |
bool | false |
No | When true, uses embedded PostgreSQL via pglite/wasmtime instead of a Docker Postgres container. Hasura connects via a Unix-domain socket bridge. Requires a CGO_ENABLED=1 build of the CLI. Pass --embedded-pg to nself start as well. |
NSELF_POSTGRES_MODE |
string | docker |
No | Selects the Postgres runtime. docker runs the standard Postgres container (default, fully supported). wasm runs the experimental embedded pglite/wasmtime lane. The wasm mode is gated behind the Emscripten ABI shim and is not yet production ready. |
Paid Bundle plugins validate a licence key against ping.nself.org. The core
CLI is MIT and needs none of these.
| Variable | Default | Purpose |
|---|---|---|
NSELF_LICENSE_KEY |
unset | Your Bundle or ɳSelf+ licence key. |
LICENSE_PING_URL |
https://ping.nself.org |
Validation endpoint. Point it elsewhere only for testing. |
LICENSE_CACHE_PATH |
~/.cache/nself/license.json |
Where the signed entitlement cache is stored. |
LICENSE_CHECK_INTERVAL |
6h |
How often a running stack re-validates. |
LICENSE_OFFLINE_MODE |
false |
Use the exported cache only; never contact the network. |
LICENSE_SUNSET_AT |
unset | Optional hard cutoff. Zero means no sunset. |
LICENSE_PUBLIC_KEY_OVERRIDE |
unset | Hex Ed25519 public key. Testing only. |
When the validation server cannot be reached, a valid cached entitlement keeps
paid plugins running on a fixed ladder: silent for the first period, then a
warning, then closed. Those lengths are constants in
internal/license/grace.go (GraceSoftThreshold, GraceHardThreshold) and
are deliberately not exposed as environment variables. An operator-settable
ceiling on licence enforcement is not a knob we want to ship. nself license status prints the live values.
A LICENSE_GRACE_DAYS variable was declared in the config struct and
advertised in a code comment as the way to tune this. Nothing ever read it, so
setting it did nothing. It was removed rather than wired up, for the reason
above. If you set it today, delete it. It has never had any effect.
| Variable | Effect |
|---|---|
NSELF_LICENSE_FAIL_OPEN=1 |
On a network failure only, trust the cached entitlement with no age limit. Intended for CI and air-gapped builds. It never overrides a server that answers, and never overrides a revoked key. |
NSELF_LICENSE_SKIP_VERIFY=1 |
Let nself license import accept an unsigned cache file. Requires NSELF_LICENSE_SKIP_VERIFY_FORCE=1 and --force. Affects import only, never plugin install. |
Both defeat protections that exist for a reason. Leave them unset on any installation that matters.
| Variable | Type | Default | Required | Description |
|---|---|---|---|---|
NSELF_PROFILING_TOKEN |
string | (empty) | No | Bearer token required in the X-Profile-Token header to reach any /debug/pprof/* endpoint (internal/observability). Empty means no token is configured — see NSELF_PPROF_DEV below for the only way to still reach pprof in that case. |
NSELF_PPROF_BIND |
string | 127.0.0.1:6060 |
No | Bind address for the standalone pprof HTTP server started by ServeProfiling. Keep this loopback-only; it is never exposed publicly via nginx. |
NSELF_PPROF_DEV |
bool ("1") |
unset | No | Local-dev escape hatch for pprof when NSELF_PROFILING_TOKEN is unset. Pprof normally fails closed (403) with no token configured — set NSELF_PPROF_DEV=1 to allow unauthenticated access, but only when the pprof handler's bind address is loopback (127.0.0.1, ::1, or localhost). On any non-loopback bind this variable has no effect and pprof stays closed. Every request served through this escape hatch logs a slog.Warn line so it is never silently active. |
PYROSCOPE_ENABLED |
bool | false |
No | Enables continuous profiling push to a Pyroscope server. |
PYROSCOPE_SERVER_URL |
string | (empty) | No | Pyroscope server address; required when PYROSCOPE_ENABLED=true. |
PYROSCOPE_APPLICATION_NAME |
string |
OTEL_SERVICE_NAME, else (empty)
|
No | Application name reported to Pyroscope. Falls back to OTEL_SERVICE_NAME when unset. |
nSelf was called "BIOS" internally before v1.0. Variables using that prefix
(BIOS_DOMAIN, BIOS_PROJECT_NAME, BIOS_LICENSE_KEY and the rest) are not
read. A compatibility shim mapping them to their NSELF_* equivalents was
present in the source until v1.3.5, but it was never wired into any startup
path, so it never promoted a value in any released build. It has been removed.
If you are upgrading a long-lived deployment, rename any BIOS_* entry in your
.env to its NSELF_* counterpart. The names map one to one:
BIOS_DOMAIN and BIOS_BASE_DOMAIN become NSELF_BASE_DOMAIN, BIOS_ENV and
BIOS_ENVIRONMENT become NSELF_ENV, BIOS_PROJECT and BIOS_PROJECT_NAME
become NSELF_PROJECT_NAME, and the others drop the prefix change directly
(BIOS_ADMIN_EMAIL to NSELF_ADMIN_EMAIL, and so on).
The following variables are derived automatically and written to .env.computed on every nself build and nself start. Do not set these manually, they will be overwritten.
| Variable | Derived From | Description |
|---|---|---|
DATABASE_URL |
POSTGRES_* vars |
Full PostgreSQL connection string. |
DOCKER_NETWORK |
PROJECT_NAME |
Docker network name: nself_{PROJECT_NAME}. |
AUTH_SMTP_SENDER |
BASE_DOMAIN |
Defaults to noreply@{BASE_DOMAIN} if not explicitly set. |
← Configuration | Config-Postgres →
ɳSelf CLI v1.0.9. MIT licensed. Docs CC BY 4.0.
GitHub · Issues · Discussions · nself.org · nself.org/docs
Getting Started
Commands
- Commands, Overview
- Lifecycle: cmd-init · cmd-build · cmd-start · cmd-stop · cmd-restart · cmd-dev
- Monitoring: cmd-status · cmd-logs · cmd-health · cmd-urls · cmd-doctor · cmd-monitor · cmd-alerts · cmd-sentry · cmd-watchdog
- Data: cmd-db · cmd-backup · cmd-dr · cmd-queue · cmd-webhooks
- Config: cmd-config · cmd-service · cmd-env · cmd-promote
- Networking: cmd-ssl · cmd-trust · cmd-dns-setup
- Security: cmd-access · cmd-security · cmd-secrets
- Tenancy: cmd-tenant · cmd-billing
- Plugins: cmd-plugin · cmd-license · cmd-dogfood (extracted, CLI-R11) · cmd-k8s (extracted, CLI-R11) · cmd-encryption (extracted, CLI-R11) · cmd-waf (extracted, CLI-R11) · cmd-federation (extracted, CLI-R11) · cmd-mail (extracted, CLI-R11) · cmd-dlq (extracted, CLI-R11)
- AI: cmd-ai · cmd-claw · cmd-model
- Templates: cmd-template
- Utilities: cmd-exec · cmd-clean · cmd-reset · cmd-update · cmd-upgrade · cmd-version · cmd-admin · cmd-migrate · cmd-migrate-firebase · cmd-migrate-supabase · cmd-completion
Features
- Features, Overview
- Feature-Auth
- Feature-Storage
- Feature-Search
- Feature-Functions
- Feature-Email
- Feature-Monitoring
- Feature-Plugins
- Feature-nClaw, AI Assistant
- Feature-nChat, Messaging
- Feature-nTV, Media Player
- Feature-nFamily, Family Social
- Feature-nCloud, Managed Hosting
- Feature-Memory-Rooms, Knowledge Organization
- Feature-Agent-Dashboard, Agent Metrics
- Feature-Image-Generation, AI Image Generation
Configuration
- Configuration, Overview
- Config-Env-Vars
- Config-Postgres
- Config-Hasura
- Config-Auth
- Config-Nginx
- Config-Optional-Services
- Config-Custom-Services
- Config-System
Plugins (87 + 10 monitoring)
Free (25)
- plugin-backup
- plugin-content-acquisition
- plugin-content-progress
- plugin-cron
- plugin-donorbox
- plugin-feature-flags
- plugin-github
- plugin-github-runner
- plugin-invitations
- plugin-jobs
- plugin-link-preview
- plugin-mdns
- plugin-mlflow
- plugin-monitoring
- plugin-notifications
- plugin-notify
- plugin-paypal
- plugin-search
- plugin-shopify
- plugin-stripe
- plugin-subtitle-manager
- plugin-tokens
- plugin-torrent-manager
- plugin-vpn
- plugin-webhooks
Pro (62)
- plugin-access-controls
- plugin-activity-feed
- plugin-admin-api
- plugin-nself-ai-gateway
- plugin-nself-ai-mcp
- plugin-nself-ai-mcp
- plugin-analytics
- plugin-auth
- plugin-backup-pro
- plugin-bots
- plugin-browser
- plugin-calendar
- plugin-cdn
- plugin-chat
- plugin-claw
- plugin-claw-budget
- plugin-claw-news
- plugin-claw-web
- plugin-cloudflare
- plugin-cms
- plugin-compliance
- plugin-cron-pro
- plugin-ddns
- plugin-devices
- plugin-documents
- plugin-donorbox-pro
- plugin-entitlements
- plugin-epg
- plugin-file-processing
- plugin-game-metadata
- plugin-geocoding
- plugin-geolocation
- plugin-google
- plugin-home
- plugin-idme
- plugin-knowledge-base
- plugin-linkedin
- plugin-livekit
- plugin-media-processing
- plugin-meetings
- plugin-moderation
- plugin-mux
- plugin-notify-pro
- plugin-object-storage
- plugin-observability
- plugin-paypal-pro
- plugin-photos
- plugin-podcast
- plugin-post
- plugin-realtime
- plugin-recording
- plugin-retro-gaming
- plugin-rom-discovery
- plugin-shopify-pro
- plugin-social
- plugin-sports
- plugin-stream-gateway
- plugin-streaming
- plugin-stripe-pro
- plugin-support
- plugin-tmdb
- plugin-voice
- plugin-web3
- plugin-workflows
Planned (26)
plugin-auditplugin-blogplugin-checkoutplugin-commerceplugin-drmplugin-exportplugin-flowplugin-importplugin-ldapplugin-mailgunplugin-mediaplugin-oauth-providersplugin-pagesplugin-postmarkplugin-rate-limitplugin-reportsplugin-samlplugin-schedulerplugin-sendgridplugin-ssoplugin-subscriptionplugin-thumbplugin-transcoderplugin-twilioplugin-wafplugin-watermark
Guides
- Guide-Production-Deployment
- Guide-SSL-Setup
- Guide-Multi-Tenancy
- Guide-Security-Hardening
- Guide-Monitoring-Setup
- Guide-Backup-Restore
- Guide-Custom-Services
- Guide-Migration-from-v1
Architecture
Reference
- API-Reference
- error-codes, Error Codes
Licensing
Security
Brand
Operations
- operations/release-cascade, Release Cascade
- operations/self-healing, Self-Healing Schema
- operations/redis-tuning, Redis Pool Tuning
- operations/meilisearch-warmup, MeiliSearch Warm-Up
- operations/jwt-rotation, JWT Key Rotation
- operations/windows-wsl2-setup, Windows / WSL2 Setup
- operations/gemini-oauth-reauth, Gemini OAuth Reauth
Contributing
Admin
- USER-ACTION-QUEUE, Pending Admin Actions
All commands (52)
- A: cmd-access · cmd-account · cmd-admin
- B: cmd-backup · cmd-build · cmd-bundle
- C: cmd-ci · cmd-clean · cmd-completion · cmd-config
- D: cmd-db · cmd-deploy · cmd-dev · cmd-doctor
- E: cmd-env · cmd-exec
- F: cmd-functions
- G: cmd-generate
- H: cmd-health · cmd-help-topics
- I: cmd-init · cmd-install
- L: cmd-license · cmd-login · cmd-logout · cmd-logs
- M: cmd-man · cmd-mcp · cmd-migrate
- O: cmd-oauth · cmd-ops
- P: cmd-plugin · cmd-promote
- R: cmd-remove · cmd-reset · cmd-restart · cmd-runner
- S: cmd-secrets · cmd-security · cmd-self-heal · cmd-server · cmd-service · cmd-start · cmd-status · cmd-stop
- T: cmd-telemetry · cmd-template · cmd-trust
- U: cmd-update · cmd-urls
- V: cmd-verify-sbom · cmd-version