Settings
Every setting the server and its tools read from the environment, with what the example settings file says about it.
Every setting the server, its tools and its scripts read from the environment, with what .env.example says about it. 283 settings in 5 groups. Copy .env.example to .env and set what you need: a setting left empty takes its default.
Read API (backend/api)
CCMS_CONTENT_DIR
Path to the content Git repository the API reads and writes (change-set branches). Use a bare repository (git clone --bare): the API never moves a branch checked out in a working tree.
CCMS_API_TOKEN
Machine clients authenticate with their service account's own token ("Authorization: Bearer ccms_sat_..."), issued in Admin or by POST /service-accounts/{id}/tokens; the first one of a deployment with pnpm nx run api:service-token -- <account> --role <role> (printed once). Optional: a shared secret, for local use and demo mode only (required in demo mode). Unset (the default), only service accounts' tokens authenticate; leave it empty in a deployment. At least 32 characters; generate one with: openssl rand -hex 32. pnpm nx run api:setup-local writes one. Refused with sign-in (CCMS_OIDC_ISSUER), but for a loopback issuer in local runs and tests.
CCMS_AUTH_MODE
Who a request with the shared token acts as: token or demo (default: token). token: the shared token (when set) acts as a read-only service (reads every ref, drafts included, changes nothing; the server warns at start-up); an X-Ccms-User header is refused (400). demo: the token is still required, and an "X-Ccms-User: <user ID>" header picks a seeded user (pnpm nx run api:db-seed -- --example) to act as. Anyone with the token can then act as any user, the admin included: for demonstrations only, never where real people sign in. The server warns at start-up. The editor's sign-in page lists the seeded users in demo mode; in token mode it says sign-in is not set up. pnpm nx run api:setup-local writes demo (when unset) and seeds the example users into an empty local database.
CCMS_AUTH_FAILURES_MAX
Failed authentications (a missing, wrong, revoked or expired token) one client address may make per window before its requests are refused with 429 too-many-failed-attempts and Retry-After, until the window ends (a valid service account token still acts). Whole number, 0 = no limit (default: 20). Counted per server, in memory, by the connection's address: behind a reverse proxy all clients share the proxy's, so raise the limit there or set 0.
CCMS_AUTH_FAILURES_WINDOW_MS
The window of CCMS_AUTH_FAILURES_MAX, in milliseconds, 1000 to 86400000 (default: 60000).
CCMS_OIDC_ISSUER
Sign-in with OpenID Connect (#37; backend/api/README.md, "Sign-in"): people sign in to the editor at any OpenID Connect provider, found by discovery (<issuer>/.well-known/openid-configuration). Off unless CCMS_OIDC_ISSUER is set; cannot be on with CCMS_AUTH_MODE=demo (the server refuses to start). Service accounts keep their own tokens. Register the client at the provider with the redirect URL below and, for signing out there too, the post-logout redirect URL <CCMS_EDITOR_URL>sign-in. The provider's issuer, exactly as its discovery document names it, e.g. https://id.example.org/docs. https, or http only on a loopback host (a local test provider).
CCMS_OIDC_CLIENT_ID
The client ID the provider gave this deployment. Required with CCMS_OIDC_ISSUER.
CCMS_OIDC_CLIENT_SECRET
The client's secret (client_secret_basic). Unset: a public client, signing in with PKCE only. In a container, CCMS_OIDC_CLIENT_SECRET_FILE may name a file holding it instead (a Compose secret; "Secrets from files" below).
CCMS_OIDC_REDIRECT_URL
Where the provider sends the browser back: the editor's address plus api/auth/oidc/callback, e.g. https://docs.example.org/api/auth/oidc/callback. Required with CCMS_OIDC_ISSUER; on the editor's origin (the session cookie is the editor's), https or http on loopback only.
CCMS_OIDC_SCOPES
The scopes asked for, space-separated; must include openid (default: openid profile email).
CCMS_OIDC_LINK_BY_EMAIL
Whether a first sign-in joins an existing user whose email address the provider reports as verified (email_verified): pending, off or any (default: pending). pending: only a user who has never signed in with any provider: one an admin created or the seed wrote (the first admin), waiting for their first sign-in. Recorded as user.identity-link. any: any user without an identity at this issuer yet, also one who signs in elsewhere. Only for a provider that guarantees nobody can set an address they do not own and have it reported verified: otherwise whoever sets someone's address takes over their account here. off: never; every first sign-in makes a new user (give roles by group or by hand afterwards). With pending or any, the provider must not let people set an email address it then reports as verified.
CCMS_OIDC_GROUPS_CLAIM
The claim the provider sends a person's groups in (ID token or userinfo): a name, or a dotted path into nested claims, e.g. org.groups (default: groups). Groups give roles through the group mappings (Admin, or POST /group-mappings); roles assigned directly stay.
CCMS_OIDC_NAME
What the editor's sign-in button names, e.g. Company ID: at most 60 characters. Unset: a neutral wording.
CCMS_EDITOR_URL
The editor's address, ending in /, e.g. https://docs.example.org/: where a sign-in comes back to and the origin a signed-in change must come from. Default: the origin of CCMS_OIDC_REDIRECT_URL plus /.
CCMS_SESSION_IDLE_MINUTES
A session ends after this many minutes without a request, 5 to 43200 (default: 480, 8 hours).
CCMS_SESSION_MAX_HOURS
A session ends this many hours after signing in, whatever its use, 1 to 8760 (default: 168, 7 days).
CCMS_PASSWORD_SIGN_IN
Signing in with an email address and a password (#610; backend/api/README.md, "Sign-in"): on or off (default: on, except with CCMS_AUTH_MODE=demo, where it is off and on is refused). Off: only OpenID Connect, codes by email (only if CCMS_EMAIL_CODE_SIGN_IN=on says so) and tokens. Admins invite people (Admin > Users); a one-time link sets the first password. The first admin: pnpm nx run api:first-admin -- <email> (deploy/README.md). "Forgot password" shows when email (CCMS_MAIL_URL) and CCMS_PUBLIC_URL are set, for people who have a password. Failed sign-ins count toward CCMS_AUTH_FAILURES_MAX per client address and CCMS_PASSWORD_FAILURES_MAX per account. Turning it off stops the password sessions. Sessions, sign-out and their limits are the ones above.
CCMS_INVITE_DAYS
How many days an invite link works, 1 to 90 (default: 7). A reset link works one hour.
CCMS_FIRST_ADMIN_EMAIL
The first admin (#373): an email address, made with the role "admin" (every permission) when the API starts on an instance without users, and ignored from then on (default: unset, none; or run first-admin, deploy/README.md, "Quick start"). With password sign-in on, a one-time link to choose their password is printed in the API's log (valid one hour, once, closed too by their first sign-in with a provider or by a code by email; the base is CCMS_PUBLIC_URL, else CCMS_EDITOR_URL). With OpenID Connect, they sign in with the provider, which finds the user by this verified address. With codes by email alone (#639), they sign in with "Email me a code" at this address (no link is printed).
CCMS_FIRST_ADMIN_LINK_LOG
Whether that first start prints the link in the log, true or false (default: true). false: no link is made; print one with first-admin on the command line, which never goes to the log.
CCMS_FIRST_ADMIN_NAME
The first admin's display name, 1 to 200 characters (default: the address's part before the "@").
CCMS_PASSWORD_FAILURES_MAX
Failed password checks one email address may have per window before it is refused (429), 0 to 1000000 (default: 10; 0: no limit); "Forgot password" requests for it count apart, under the same limit. Apart from CCMS_AUTH_FAILURES_MAX, so it holds behind a shared address too. Kept in the database, shared by every server.
CCMS_PASSWORD_FAILURES_WINDOW_MS
The window of CCMS_PASSWORD_FAILURES_MAX, in milliseconds, 1000 to 86400000 (default: 900000, 15 minutes).
CCMS_EMAIL_CODE_SIGN_IN
Signing in with a one-time code by email (#634; backend/api/README.md, "Sign-in"), beside passwords and OpenID Connect or alone (#639): on or off. Default: on wherever email is set up (CCMS_MAIL_URL, and the secret key it needs) and password sign-in is on, off otherwise; never in demo mode (on is refused there). With CCMS_PASSWORD_SIGN_IN=off, only an explicit on offers it: beside the provider (a way in that does not pass through the provider), or as the only way to sign in, with no provider. on needs CCMS_MAIL_URL (refused at start-up without it). The sign-in page then offers "Email me a code": a six-digit code and a link that signs in (the link only with CCMS_PUBLIC_URL), once, for CCMS_EMAIL_CODE_MINUTES. Requests and wrong codes each count per account under CCMS_PASSWORD_FAILURES_MAX (apart from passwords and from each other) and per client address under CCMS_AUTH_FAILURES_MAX; once the wrong codes use up the account's tries, the code is revoked. Turning it off ends the sessions begun with a code.
CCMS_EMAIL_CODE_MINUTES
How many minutes a code by email and its link work, 1 to 60 (default: 10).
CCMS_DEFAULT_REF
Branch, tag or commit used when a request has no ?ref= (default: HEAD).
CCMS_CONTENT_CACHE_MB
CCMS_CONTENT_CACHE_MB: how much parsed content (modules, manifests, terms, translation records) one server keeps in memory, in MiB of the files' text; parsed, it takes five to six times that. A file is parsed once however many commits hold it, and listing every module (search, media, translation status) reads them all, so keep it above the text of every file at the commits read most (git ls-tree -r -l main), or each listing parses them again. Whole number from 1 to 16384 (default: 64, about 30,000 module files and 350 MiB in memory).
CCMS_CONTENT_INDEX_CACHE_MB
CCMS_CONTENT_INDEX_CACHE_MB: how much memory the content's indexes take at most, in MiB, estimated from their strings (#552): blob IDs by path and by folder, the files two commits differ by, file histories, deleted files, folder listings and the module listings per commit, each a fixed share of it; the newest index of each whole folder is kept however large, beside the rest. On top of CCMS_CONTENT_CACHE_MB and of the 64 MiB of file contents kept. This bounds the content's reader; the API's few other Git readers (change sets, change feed, releases) keep small caches of their own, 32 MiB each at most (in practice only changed-file lists). The default holds about 50,000 module files' paths. Raise it when history, change and media reads of a large repository slow down. Whole number from 1 to 4096 (default: 32).
CCMS_SEARCH_INDEXES
CCMS_SEARCH_INDEXES: how many search indexes one server keeps, one per commit and reading scope (readers who may see the same share one), with the rankings of their recent searches; the least recently used goes. Unchanged modules' text is shared between them. Whole number from 1 to 1024 (default: 16).
CCMS_SEARCH_ADAPTER
Search (#54; backend/api/README.md, "Search"). CCMS_SEARCH_ADAPTER: postgres (default) indexes the content in the database: words in any of their forms in the content's language, typos in titles and keywords (pg_trgm, created by the migrations), and every word anywhere in a field as the in-memory search finds it; the index is derived data, made as readers search (a commit once, a later commit only what changed). memory: word matching alone, in each server's memory, rebuilt per commit and reading scope (small installs, no stemming or typos).
CCMS_SEARCH_PER_MINUTE
The search's limits (#539; backend/api/README.md, "Postgres search"). Each server counts its own: behind a load balancer with N servers a reader gets up to N times CCMS_SEARCH_PER_MINUTE. CCMS_SEARCH_PER_MINUTE: searches (GET /search, every page counts) one reader, a person or a service account, may ask for per minute on each server; past it 429 rate-limited with Retry-After. It also bounds the embedder calls a reader's queries make. At most 2 of a reader's searches are in progress at once (another is 429 too). Whole number 1-6000 (default: 120; the editor's palette asks at most about 5 a second while someone types).
CCMS_SEARCH_TIMEOUT_MS
CCMS_SEARCH_TIMEOUT_MS: the most time one search may spend in the database, all of its statements together (each also stops after 5 s); past it 503 database-timeout with Retry-After, and the connection is free again. Writing a commit's index the first time it is searched is not counted. Postgres search only. Milliseconds, 100-60000 (default: 5000).
CCMS_SEARCH_CONCURRENCY
CCMS_SEARCH_CONCURRENCY: searches one server runs in the database at once; more wait up to 2 s for their turn (at most 4 waiting per search running), then 503 search-busy with Retry-After. Keep it well under CCMS_DATABASE_POOL_MAX, so searches never hold the whole pool. Postgres search only. Whole number 1-100 (default: 4).
CCMS_SEARCH_SWEEP_AFTER_DAYS
The search index's sweep (#540; backend/api/README.md, "Postgres search"): every hour, on each server that runs background work (CCMS_ROLE all or worker), bounded per run. Postgres search only. CCMS_SEARCH_SWEEP_AFTER_DAYS: the grace period. A commit's index (scope) no reader searched for this long is dropped, then the documents no scope names that are as old, then the texts (what is embedded) no document has used for this long, with their embeddings of every model. So the text of a deleted draft, or of content changed since an old commit, is gone at most about twice this long after it was last searched. Whole number of days 1-365 (default: 7).
CCMS_SEARCH_MODEL_KEPT_DAYS
CCMS_SEARCH_MODEL_KEPT_DAYS: how long the embeddings of a model no server has configured any more (CCMS_EMBEDDER_MODEL changed, or the embedder turned off) are kept, so switching back within it embeds nothing again; then the sweep drops them, and logs it. Whole number of days 1-365 (default: 7). Not a setting: pnpm nx run api:index-rebuild -- --drop-embeddings also drops every embedding (and the texts), so everything searched afterwards is embedded again, sent to the embedder again (and paid for again, with a hosted one).
CCMS_EMBEDDER_URL
Semantic search (meaning): an embeddings endpoint, off by default. Unset, nothing is sent anywhere and search is full text plus typos. WHEN SET, MODULE TEXT LEAVES THE SERVER: a background job (search.embed) posts every indexed text (titles, keywords, block and FAQ text of what readers searched, drafts included for their authors) and each search posts its query to this URL. Point it at a model you run yourself (beside the API) unless you accept that content goes to a hosted provider. Any endpoint that takes {"model", "input": [texts]} and answers {"data": [{"embedding": [numbers], "index"}]}: the full URL a request is posted to (http:// or https://, no credentials, query or fragment; https:// required with an API key, except to localhost). Needs CCMS_SEARCH_ADAPTER=postgres and pgvector in the database (deploy/README.md, "Semantic search").
CCMS_EMBEDDER_API_KEY
Sent as "Authorization: Bearer <key>"; optional (a model you run yourself may need none). Never logged. Or CCMS_EMBEDDER_API_KEY_FILE (below).
CCMS_EMBEDDER_MODEL
The model name the endpoint expects (the request's "model"); required with CCMS_EMBEDDER_URL. Vectors are kept per model and dimensions: changing either embeds everything again.
CCMS_EMBEDDER_DIMENSIONS
How many numbers the model's vectors have (e.g. 384); required with CCMS_EMBEDDER_URL. Whole number 1-2000.
CCMS_EMBEDDER_TIMEOUT_MS
How long one request to the endpoint may take in milliseconds (a search then goes on without meaning; the job retries); range 100-120000 (default: 10000).
CCMS_EMBEDDER_MIN_SIMILARITY
How close a block's meaning has to be to the query's to be found by meaning alone: cosine similarity in percent, 0-100 (default: 50). Depends on the model: raise it if unrelated results show up, lower it if paraphrases are missed.
CCMS_EDITOR_ORIGINS
Origins allowed to show the HTML previews (GET /modules/:lang/:id/preview, GET /manuals/:id/variants/:variant/:lang/html) in a frame, comma-separated: scheme, host and optional port only, e.g. https://editor.example.com,http://localhost:4200. Sent as the previews' CSP frame-ancestors, next to 'self' (a dev server that proxies the API is 'self'). Default: none.
CCMS_SOURCE_URL
Where this deployment's source code can be downloaded: an http:// or https:// URL without credentials, e.g. the repository of the version you run. The software is AGPL-3.0-only, whose section 13 asks a modified version run as a network service to offer its users its source; GET /about hands the URL to clients and the editor links to it (account menu, sign-in page). Default: none; the editor then shows the licence only, and Admin → System asks the admin to set it. Set it whenever you run a modified version.
CCMS_PUBLIC_URL
Where readers reach this deployment (#450): the base of every manual's stable address (<url>/d/<product>/<manual>/<variant>/<lang>, the latest release; @<revision> after the language for one release) and of the QR codes made of them, for print. An http:// or https:// URL without credentials, query or fragment (a trailing / is added; a path is kept, e.g. https://docs.example.com/manuals/). The editor's web server serves /d/ from the API (deploy/README.md). Default: none; the editor then shows the addresses as paths, and QR codes (and the QR code a release's PDF can print, openfolia.yaml delivery.pdfQrCode) are not made. Who may open an address is the content's configuration, openfolia.yaml delivery.access (public, signed-in by default, or off).
CCMS_DELIVERY_MAX_ACCESS
The most a project's openfolia.yaml delivery.access may open its stable addresses on this deployment (#553): public (no cap), signed-in (a reader with a token) or off (no address opens). A project asking for more is served at this, its PDFs print no QR code unless it is public, and each manual's checks report delivery-access-capped. Default: public.
CCMS_DELIVERY_IGNORED_QUERY
The query parameters a stable address ignores (#553), so a link shared with tracking parameters still opens; any other parameter a route does not take stays a 400. Comma-separated, each a parameter name or a prefix ending in * (letters, digits, _ . -; a bare * is refused), or none. Matched case-sensitively, never dropping a parameter the route takes (theme). E.g. utm_,ref_,<your click-ID parameters>. Default: utm_*.
CCMS_DELIVERY_SHARED_MAX_AGE
How long a shared cache (a proxy, a CDN) may keep a public stable address's image before it must ask again, in seconds (#552): Cache-Control s-maxage with proxy-revalidate. After a release is withdrawn its images can stay in a shared cache this long; a reader's own browser keeps an image a day. Lower: a withdrawal reaches caches sooner, more revalidations (each a cheap 304); 0: every request is revalidated. Whole number from 0 to 86400 (default: 300).
CCMS_BUILD_ID
What identifies this build of the API (#552), e.g. the commit or image tag it was built from: 1 to 128 of A-Za-z0-9._:+-. A stable address page's ETag is known before rendering, from the release, the reader, the theme and this, so a revalidation is a 304 without rendering. Set it to the same value on every server of one build, and to a new one with each build, so the servers' ETags agree and a new build's pages replace the old. Default: none, then each process makes its own (a restart renders each page once again). Never keep one value across builds: caches would keep the old build's pages.
CCMS_TRUST_PROXY
Which proxies in front of the API to believe about the client's address (X-Forwarded-For), for the limits keyed by it: /d/'s rate limit (CCMS_DELIVERY_PER_MINUTE) and failed authentications. none (the default): trust no proxy, the client is the connection's address and a forged header changes nothing. A hop count from 1 to 10 trusts that many proxies nearest the API, whoever they are: only where no client can reach the API but through them. Otherwise comma-separated IP addresses, subnets (172.16.0.0/12, fd00::/16; at least a /8, an IPv6 one a /16) or loopback, linklocal, uniquelocal (the private ranges). true (any client could name any address) is refused. The container setup: deploy/README.md, "Reverse proxy with TLS".
CCMS_DELIVERY_PER_MINUTE
Pages, PDFs and QR codes one client may ask for under /d/ per minute, on each server: a request without a token by its address (see CCMS_TRUST_PROXY), one with a token by its actor. Past it, 429 rate-limited with Retry-After. A 304 revalidation of a page or a PDF counts nothing, nor do a page's images, stylesheets and fonts. 0 to 6000, 0 for no limit (default: 60). Raise it where many readers share one address (a site behind one NAT).
CCMS_DOCS_URL
Where the user guide is (the docs site, or a copy of it): every editor screen's help link, the account menu's "Help for this page", the search palette's Help group and the "Learn more" links open a page under it, in the UI language (guide/writing/content-browser, after de/ in German; each screen names its page by article ID, from the guide index the editor's build ships with the guide of its version). GET /about hands it to clients. An http:// or https:// URL without credentials (a trailing / is added; a sub-path such as https://intranet.example/docs/ is kept), or off for no such links (an offline instance). Default: https://docs.openfolia.com/.
CCMS_RELEASE_TAG
How release tags (annotated, immutable) are named. {product} and {revision} are each filled in once, as a whole path component; the rest may hold only A-Za-z0-9._/- (default: release/{product}/{revision}).
CCMS_MAINTENANCE_BRANCH
How maintenance lines' branches are named (POST /maintenance-lines, one per older product revision being fixed). {product} and {revision} (the base release's) are each filled in once, as a whole path component; the rest may hold only A-Za-z0-9._/- and must not start with change-sets/ or refs/, nor equal CCMS_RELEASE_TAG (default: maintenance/{product}/{revision}).
HOST
Address and port to listen on (port 0 = any free port). Defaults to 127.0.0.1:3100; set HOST=0.0.0.0 only behind TLS.
PORT
See HOST.
CCMS_ROLE
What this process does (#527); the same image and code for each. One of: all (default) everything in one process: the API, the background jobs and loops, the PDF pool. api serves the API and enqueues jobs; consumes none, runs no background loop (sweeps, outbox consumers, recounts), and keeps a small PDF pool (CCMS_PDF_WORKERS, default 2) for what readers ask for (a manual's PDF, page images, checks). Its /health/ready never depends on a worker. worker consumes every job (release planning and files, imports, webhook deliveries, ...) and runs the background loops and the PDF pool; serves no HTTP but GET /health and /health/ready on HOST:PORT (with the job queue's counts: keep HOST=127.0.0.1 unless a probe outside needs it), and never migrates: it waits up to 120 s for the API's migrations. Several workers plan a product's releases one at a time (a Postgres advisory lock, held on one connection of its own beside the pool while a release is planned; like migrating, it needs a direct connection or a session-mode pooler). backup the backup service (#529; the backup image sets it): the arguments are its command (run, now, list, restore ...), no API and no jobs. Run any number of workers beside the API instances (deploy/README.md, "Workers").
CCMS_WORKER_NICE
A worker's CPU priority: the nice value it takes at start, which its PDF worker processes inherit, so on a host shared with the API its renders yield the CPU to the API's readers. Whole number 0 (normal) to 19 (lowest); default: 10. Only raised: a process already started at a higher nice value keeps it. Ignored by other roles.
CCMS_DATABASE_URL
Postgres for operational state (users, roles, locks, the audit log); compose.yaml runs version 18. Required. Format: postgres://user:password@host:5432/database (postgresql:// works too; add ?sslmode=verify-full for TLS; node-postgres verifies the certificate for require too, so a private CA needs NODE_EXTRA_CA_CERTS). A Unix socket: postgres:///database?host=/socket/folder&user=name. Locally: docker compose up -d; setup-local writes this checkout's value.
CCMS_DATABASE_MIGRATE
Apply pending migrations on start: true or false (default: true). Set false when a deployment runs node backend/api/dist/database/migrate.main.js (or pnpm nx run api:db-migrate) itself.
CCMS_DATABASE_POOL_MAX
Most connections in the server's database pool; whole number 1-500 (default: 10). While queries wait for a free connection, GET /health/ready answers 503.
CCMS_DATABASE_LOCK_TIMEOUT_MS
How long a migration statement waits for a table lock, in milliseconds, 1-600000 (default: 10000). Past it that attempt rolls back (a long transaction on a migrated table makes a statement queue every later query on it).
CCMS_DATABASE_MIGRATE_ATTEMPTS
Runs of a migration that keeps hitting that timeout before start-up fails, with 1 s, 2 s, 4 s ... pauses between them; whole number 1-20 (default: 3). Other failures are never repeated.
CCMS_DATABASE_WRITE_LOCK_TIMEOUT_MS
Write transactions that hold rows others wait for (a save point, abandoning a change set, breaking locks) wait at most this long for a row or table lock, in milliseconds, 1-600000 (default: 5000; SET LOCAL lock_timeout). Past it the request rolls back and answers 503 database-timeout with Retry-After, never a 500.
CCMS_DATABASE_WRITE_STATEMENT_TIMEOUT_MS
How long one statement of such a transaction may run, in milliseconds, 1-600000 (default: 30000; SET LOCAL statement_timeout). Past it: the same 503 database-timeout.
CCMS_TEST_PG_URL
Tests only (backend/api): a Postgres server for the specs PGlite cannot run (concurrent transactions: src/change-sets/repos/lock-contention.postgres.spec.ts, save-points.postgres.spec.ts and src/access/repos/email-code-ways-in.postgres.spec.ts). Format as CCMS_DATABASE_URL, e.g. the compose one, postgres://ccms:ccms@127.0.0.1:5432/ccms; the user must be allowed to create databases (each run creates and drops a ccms_test_* database of its own). Unset (the default): those specs are skipped. The slot tooling's test (scripts/tests/slot-databases.test.ts) reads it too: it creates and drops three databases of made-up slots with random names (ccms_zz_db…, ccms_perf_zz_db…) to check pnpm slot remove's drop.
CCMS_BLOB_DRIVER
Blob store: binary files (images, later attachments and downloads) by their SHA-256, never in Git. Which adapter: s3 (any S3-compatible service) or fs (a folder on this machine). Required; no default. Locally setup-local writes s3 with the compose service (compose.yaml, SeaweedFS on 127.0.0.1:8333).
CCMS_BLOB_FS_ROOT
fs only, and then required: absolute path of the folder holding the blobs (created when missing); one machine only, back it up with the database.
CCMS_S3_ENDPOINT
s3 only. The service's address, http:// or https:// without credentials in it, e.g. http://127.0.0.1:8333 (unset, the default: AWS S3 itself, by region).
CCMS_S3_REGION
s3 only. The region (default: us-east-1; most S3-compatible services accept any).
CCMS_S3_BUCKET
s3 only, and then required: the bucket, 3-63 lowercase letters, digits, dots and dashes. It must exist; keep it private (the API serves images itself, never by a bucket URL). setup-local makes ccms (main checkout) or ccms-<slot> (an agent slot).
CCMS_S3_ACCESS_KEY_ID
s3 only. Access key ID and secret, both or neither (default: neither, so the SDK's own chain applies: AWS_* environment variables, shared credential files, an instance or task role). Needs s3:GetObject, s3:PutObject, s3:DeleteObject on the bucket's objects and s3:ListBucket on the bucket (HeadBucket, for readiness).
CCMS_S3_SECRET_ACCESS_KEY
See CCMS_S3_ACCESS_KEY_ID.
CCMS_S3_FORCE_PATH_STYLE
s3 only. true for path-style URLs (<endpoint>/<bucket>/<key>), which most self-hosted services need; true or false (default: false, virtual-hosted style as AWS uses).
CCMS_MAX_UPLOAD_BYTES
Image uploads (POST /change-sets/:id/assets) and translation imports (POST /translations/imports: the XLIFF file, or a ZIP of them, packed and unpacked): the largest file taken, in bytes; a larger one is 422 too-large, and reading the request stops there. Whole number from 1 to 1073741824 (default: 10485760, 10 MiB).
CCMS_MAX_ATTACHMENT_BYTES
Attachments (POST /change-sets/:id/assets?kind=attachment): files of any type readers download from a module. The largest file stored, in bytes; a larger one is 422 too-large and reading stops there. Whole number from 1 to 1073741824 (default: 52428800, 50 MiB).
CCMS_MAX_FONT_BYTES
Fonts for page designs (POST /change-sets/:id/assets?kind=font: TrueType, OpenType, WOFF or WOFF2, told by their bytes). The largest font stored, in bytes; a larger one is 422 too-large and reading stops there. A font is read whole into memory to be checked. Whole number from 1 to 67108864 (default: 10485760, 10 MiB).
CCMS_ATTACHMENT_TYPES_ALLOW
Which attachment types are taken. Each is a comma-separated list of lowercase entries: a media type (application/zip), a top-level type (text/*) or an extension with its dot (.zip). The type is the server's, from the bytes and the file name (never the client's Content-Type). Dangerous types (HTML, SVG, executables, installers, scripts: backend/api/README.md, "Attachments") are always refused unless OPEN names them. ALLOW: when set, only files whose type or extension it names, at least one (default: unset, any type).
CCMS_ATTACHMENT_TYPES_DENY
DENY: refused on top of the dangerous types (default: empty).
CCMS_ATTACHMENT_TYPES_OPEN
OPEN: dangerous types taken all the same, e.g. text/html or .svg (default: empty). They are still only ever sent as downloads (Content-Disposition: attachment, nosniff, a sandboxing CSP), never shown in the app.
CCMS_STORAGE_LIMIT_BYTES
Storage used (GET /storage-usage, administrators): uploaded media (images and attachments) and the archived release PDFs count; the Git content and the database are shown for information only. LIMIT_BYTES: the most bytes media and archived PDFs may hold together. An upload that would go past it is refused (409 storage-limit-reached) and nothing is stored; release PDFs are never refused. The admin view warns from 80 %. A change is audited (storage.limit-change) at the next start. Whole number of bytes from 1 to 9007199254740991, e.g. 53687091200 for 50 GiB (default: unset, no limit).
CCMS_STORAGE_RECOUNT_HOURS
RECOUNT_HOURS: how often the totals (kept up to date on every upload and delete) are counted afresh from the blob store and the database, which corrects any drift. Whole number from 1 to 8760 (default: 24).
CCMS_RENDITION_MAX_PIXELS
Image renditions (GET /assets/:hash?width=320|640|1280): WebPs made on first request with sharp and kept in the blob store. Only PNG, JPEG, GIF and WebP are decoded (every other libvips loader is blocked). MAX_PIXELS: the most pixels (width x height) a source may have; a larger one is 422 too-large, refused from its header before decoding. Whole number from 1 to 268402689 (default: 40000000).
CCMS_RENDITION_TIMEOUT_MS
TIMEOUT_MS: how long making one rendition may take, in milliseconds; past it 422 unprocessable-image. Whole number from 100 to 120000 (default: 10000).
CCMS_RENDITION_CONCURRENCY
CONCURRENCY: how many renditions one server makes at once; four times as many requests wait, more are 503 rendition-busy. Whole number from 1 to 32 (default: 2).
CCMS_RENDITION_MAX_SOURCE_BYTES
MAX_SOURCE_BYTES: the largest file a rendition is made of, in bytes; a larger one is 422 too-large. Whole number from 1 to 1073741824 (default: 52428800, 50 MiB).
CCMS_TEST_S3_ENDPOINT
Tests only (backend/api): an S3-compatible service the blob store's contract tests also run against (src/blobs/repos/blob-stores.spec.ts), e.g. the compose one, http://127.0.0.1:8333. Each run creates and deletes a openfolia-test-* bucket of its own. Unset (the default): those tests are skipped.
CCMS_TEST_S3_ACCESS_KEY_ID
Tests only: credentials for CCMS_TEST_S3_ENDPOINT (default: the compose service's, ccms / ccms-local-secret) and its region (default: us-east-1).
CCMS_TEST_S3_SECRET_ACCESS_KEY
See CCMS_TEST_S3_ACCESS_KEY_ID.
CCMS_TEST_S3_REGION
See CCMS_TEST_S3_ACCESS_KEY_ID.
CCMS_NOTIFICATIONS_POLL_MS
Notifications (GET /me/notifications): the fan-out reads the outbox every so many milliseconds, and at start-up. Whole number from 0 to 3600000 (default: 3000); 0 = not on a timer (tests run it themselves).
CCMS_NOTIFICATIONS_KEEP_DAYS
Read notifications older than this many days are deleted (hourly); unread ones are kept. Whole number from 1 to 36500 (default: 90).
CCMS_SECRET_KEY
The instance secret key (#470; backend/api/README.md, "Secrets"): seals (AES-256-GCM) every secret the server stores and must use itself, such as webhook signing secrets. Never stored in the database, so a database dump alone opens nothing; never logged, never answered by the API. Leave all of these unset for a single server: on its first start the API makes a key file (below) and reads it on every later start. BACK UP THE KEY FILE: without it the stored secrets cannot be read, and the API refuses to start while the database holds secrets it cannot open (it never makes a new key then). Optional: the key itself, 32 random bytes as base64 (44 characters) or 64 hex digits, e.g. openssl rand -base64 32. Set it (the same on every server) for several API servers or a hosted setup, or from a secret store; then no key file is read or written. Default: unset.
CCMS_WEBHOOKS_SECRET_KEY
Deprecated: the old name of CCMS_SECRET_KEY (#42), still read when CCMS_SECRET_KEY is unset (a warning at start-up). Set both only to the same key. Rename it to CCMS_SECRET_KEY. Default: unset.
CCMS_SECRET_KEY_FILE
Where the key file is, when no variable sets the key: an absolute path. It holds the key as base64 and a newline; the API makes it with mode 0600 (its folder with 0700 when missing). Several servers on one machine or a shared volume may share it (they never make two keys). Default: ccms-secret.key in the folder that holds CCMS_CONTENT_DIR (for /srv/ccms/content.git: /srv/ccms/ccms-secret.key), beside the content repository you back up anyway, never inside it.
CCMS_SECRET_KEY_GENERATE
Whether the API makes the key file on its first start when there is none: true or false (default: true). false for hosted setups, where a missing key must not be made up: with no key set and no key file the API starts with webhooks off (404 not-configured; the editor says so), or refuses to start when the database already holds sealed secrets. A key file put there by the operator is still read.
CCMS_SECRET_KEY_NEW
Read only by pnpm nx run api:rotate-secret-key (stop every server first): the new key, same format as CCMS_SECRET_KEY. Required when CCMS_SECRET_KEY sets the key (set CCMS_SECRET_KEY to it afterwards); for the key file a new key is made when unset. Default: unset. Never leave it set.
CCMS_WEBHOOKS_POLL_MS
Webhooks (POST /webhooks; #42); their signing secrets are sealed under the instance secret key above. How often the webhooks read the outbox for new events, in milliseconds, and at start-up. Whole number from 0 to 3600000 (default: 3000); 0 = not on a timer (tests run it themselves).
CCMS_WEBHOOKS_TIMEOUT_MS
One delivery attempt's whole time (resolving, connecting, sending, the answer's status line), in milliseconds; range 1000-60000 (default: 10000). Past it the attempt fails and is retried.
CCMS_WEBHOOKS_KEEP_DAYS
Settled deliveries (succeeded, failed, skipped) older than this many days are deleted (hourly). Whole number from 1 to 3650 (default: 30).
CCMS_WEBHOOKS_ALLOW_HTTP
Local testing only: true also allows http:// subscriber URLs (default: false, https only).
CCMS_WEBHOOKS_ALLOW_PRIVATE
Local testing only: true also allows URLs whose host is or resolves to a private, loopback, link-local or otherwise non-public address, and localhost (default: false). Never in a deployment: it opens the server to request forgery against its own network.
CCMS_MAIL_URL
Email (#609; deploy/README.md, "Email"): branded email through your own mail server (SMTP), in the person's language. Off while CCMS_MAIL_URL is unset: whatever would be emailed (a sign-in link) is offered as a link to copy instead. A queued email's details are sealed under the instance secret key above, so email also needs that key; without one it stays off (Admin, System, Email says why). Shown read-only in Admin, System, Email (never the user or the password), with "Send a test email". The mail server: smtp://host[:port] (STARTTLS, port 587 by default) or smtps://host[:port] (TLS from the start, port 465 by default). No user, password, path or query in it. Default: unset (no email).
CCMS_MAIL_USER
The user name to sign in to the mail server with (SMTP AUTH), one line. Default: unset (no sign-in).
CCMS_MAIL_PASSWORD
Its password (1 to 1024 characters). Never logged or shown. Default: unset. Required with CCMS_MAIL_USER, unless CCMS_MAIL_PASSWORD_FILE is set.
CCMS_MAIL_PASSWORD_FILE
A file holding the password (an absolute path, e.g. a Compose secret under /run/secrets/), read at start-up; its final line break is dropped. Wins over CCMS_MAIL_PASSWORD. Default: unset.
CCMS_MAIL_FROM
The sender's address, bare (docs@example.com, no name: the sender's name is the branding's product name). Required with CCMS_MAIL_URL. Default: unset.
CCMS_MAIL_REQUIRE_TLS
On smtp://: true refuses to send unless the server upgrades the connection with STARTTLS, so nothing (sign-in, addresses, links) crosses the network in plain text; false uses STARTTLS when offered. true or false (default: true). smtps:// always uses TLS. The certificate is always verified.
CCMS_MAIL_CA_FILE
A PEM file of certificate authorities to trust for the mail server, in place of the system's: for a mail server whose certificate a private authority signed. An absolute path. Default: unset.
CCMS_MAIL_LANGUAGE
The language of an email to someone whose language is not known: en or de (default: en).
CCMS_AUDIT_SINK_URL
Audit log sink and retention (#379; backend/api/README.md, "Audit log"; deploy/README.md). Operator settings, read at start; the sink and retention run in a worker or all process (CCMS_ROLE). Where the audit log is copied to as it grows, every event at least once, in order (receivers dedupe by the event's id): https://host[:port]/path (each batch of up to 100 events POSTed as JSON, signed like a webhook) or syslog+tls://host[:port] (RFC 5425 over TLS, port 6514 by default). No credentials in the URL. A sink set on an installation with history sends the whole log first. Default: unset (no sink).
CCMS_AUDIT_SINK_SECRET
The https:// sink's signing secret: whsec_ and 64 lowercase hex digits (openssl rand -hex 32, then whsec_ in front). Required with an https:// URL; unused with syslog. Never logged. Or CCMS_AUDIT_SINK_SECRET_FILE (below). Default: unset.
CCMS_AUDIT_SINK_CA_FILE
Certificates (PEM) to trust for the sink instead of the system's, for a private CA: an absolute path, read at start (a missing file stops it). The sink's certificate is always checked. Default: unset.
CCMS_AUDIT_SINK_POLL_MS
How often new events are delivered, in milliseconds, and at start-up. After a failed delivery the next waits 30 s, doubling to 10 min, until one succeeds. Whole number from 0 to 3600000 (default: 3000); 0 = not on a timer (tests run it themselves).
CCMS_AUDIT_SINK_TIMEOUT_MS
One delivery's whole time (connecting, TLS, sending, the answer's status line), in milliseconds; range 1000-60000 (default: 10000). Past it the delivery fails and is tried again.
CCMS_AUDIT_KEEP_DAYS
Retention: audit events recorded more than this many days ago are removed (at start-up and daily), each removal recorded as an audit-log.prune event; with a sink set, never one it has not sent yet. Whole number from 1 to 36500. Default: unset (kept for ever).
CCMS_BACKUP_WARN_AFTER_HOURS
Backups (#529; deploy/README.md, "Backups"): the backup service (CCMS_ROLE=backup, the backup image) backs up the database, the content repository, the blobs and the instance secret key, encrypted (age) to the backup key, and checks each backup. Set it up in the editor (Admin, Backups); nothing below is needed. Precedence: a CCMS_BACKUP_* variable below, when set, wins over the page and shows read-only there, naming the variable; unset, the page's value counts (stored in the database, read at every pass, no restart); unset on both, the default given. The service reads the database and the instance secret key settings above, CCMS_CONTENT_DIR and CCMS_BLOB_* (with CCMS_BLOB_DRIVER=s3 the blobs stay in their bucket, not in the backup: keep that bucket versioned). Read by the API too: a last good backup older than this many hours shows a warning in Admin and tells the admin.backups holders once. Whole number from 1 to 8760 (default: 26).
CCMS_BACKUP_DIR
Read by the backup service only, from here on. The backup volume: local backups (in a subfolder of it, set in the page). An absolute path (default: /backups; the backup image sets it).
CCMS_BACKUP_STAGING_DIR
Where a run stages its unencrypted parts (the dump, the bundle, a check's unpacked copy) while it lasts: an absolute path to an existing folder owned by the service's user with mode 0700, no symbolic link, and neither inside nor around CCMS_BACKUP_DIR (copied off the host) or the instance's data; refused otherwise. Each run and restore gets a private folder in it, and what a stopped one left is removed at the next start (only those folders: nothing else in it is touched). Needs about twice the size of a backup free during a run. Default: unset, a fresh private folder in the system's temporary folder for each start of the service; the backup image sets /staging, the backup-staging volume of deploy/compose.yaml.
CCMS_BACKUP_POLL_MS
How often the service looks for "Back up now", "Test location" and due runs, in milliseconds. Whole number from 1000 to 600000 (default: 5000).
CCMS_BACKUP_HEALTH_FILE
The file the service records each heartbeat that reached the database in (every 15 s), which the backup image's health check reads (node dist/backups/backup-health.main.js: healthy while the last one is at most 45 s old). An absolute path in a writable folder. Default: unset (none, and that check fails); the backup image sets /tmp/openfolia-backup-alive.
CCMS_BACKUP_VERIFY_DATABASE_URL
Where the check makes its throwaway database (restored from the dump, then dropped; leftovers older than an hour are dropped at start): a Postgres URL like CCMS_DATABASE_URL whose user may CREATEDB. It needs about as much free disk as the database. Default: the instance's own server (CCMS_DATABASE_URL).
CCMS_BACKUP_ENABLED
Backups on or off: true or false. Default: unset (the page; off until it is turned on).
CCMS_BACKUP_SCHEDULE
When to back up: a five-field cron expression (minute hour day month weekday), e.g. "0 2 * * *". Fixes the page's frequency and time. Default: unset (the page; daily at 02:00).
CCMS_BACKUP_TIME_ZONE
The time zone the schedule and retention read days in: an IANA name, e.g. Europe/Berlin. Default: unset (the page; UTC).
CCMS_BACKUP_RETENTION_DAILY
Retention: how many daily, weekly and monthly backups are kept (the newest of each day, ISO week and month); the newest backup is always kept. Whole numbers (daily 0-366, weekly 0-520, monthly 0-1200). Default: unset (the page; 7, 4 and 12).
CCMS_BACKUP_RETENTION_WEEKLY
See CCMS_BACKUP_RETENTION_DAILY.
CCMS_BACKUP_RETENTION_MONTHLY
See CCMS_BACKUP_RETENTION_DAILY.
CCMS_BACKUP_LOCATION
Where backups go: local (a subfolder of CCMS_BACKUP_DIR) or s3 (an S3-compatible bucket). Setting it fixes the whole location, with the variables below. Default: unset (the page; local, the volume's root).
CCMS_BACKUP_LOCAL_SUBFOLDER
With local: the subfolder of CCMS_BACKUP_DIR, relative, e.g. nightly (default: empty, the root).
CCMS_BACKUP_S3_ENDPOINT
With s3: the endpoint URL (unset for AWS itself), the region (default: us-east-1), the bucket (required), a key prefix such as nightly/ (default: empty), and the access key (both required; each may come from <NAME>_FILE). Never logged or answered.
CCMS_BACKUP_S3_REGION
See CCMS_BACKUP_S3_ENDPOINT.
CCMS_BACKUP_S3_BUCKET
See CCMS_BACKUP_S3_ENDPOINT.
CCMS_BACKUP_S3_PREFIX
See CCMS_BACKUP_S3_ENDPOINT.
CCMS_BACKUP_S3_ACCESS_KEY_ID
See CCMS_BACKUP_S3_ENDPOINT.
CCMS_BACKUP_S3_SECRET_ACCESS_KEY
See CCMS_BACKUP_S3_ENDPOINT.
CCMS_BACKUP_S3_ALLOW_PRIVATE
Lets the backup service reach an S3 endpoint on a private or loopback address (an S3 server on the same network, e.g. MinIO beside the stack): true or false. Every connection resolves the endpoint's host and refuses it when any address it resolves to is private or loopback without this, and always when it is link-local or a cloud metadata address (169.254.0.0/16, fe80::/10, fd00:ec2::254, in any IPv6 spelling). Default: false.
CCMS_BACKUP_VERIFY
Check each backup after it is made: true or false. Default: unset (the page; true).
CCMS_BACKUP_VERIFY_BY_DECRYPTING
How it is checked: true decrypts the finished backup with the key the server keeps sealed; false keeps no key on the server and checks the parts before they are encrypted, then the encrypted file by size and SHA-256 (deploy/README.md, "Backups"). Default: unset (the page; true).
CCMS_BACKUP_KEY_FILE
The backup key from a file instead of the page: an absolute path to an age identity file (age-keygen writes one). Backups are encrypted to its public key; backup restore reads it as the default key. Default: unset (the page makes the key and keeps only its public half, and the private half sealed for the check).
CCMS_JOBS_POLL_MS
Background jobs (pg-boss, in the schema pgboss of CCMS_DATABASE_URL's database; installed and upgraded with the migrations). Each job queue is polled every so many milliseconds: 0, or a whole number from 500 to 3600000 (default: 2000). 0 = this server runs no jobs and only enqueues them (tests run them themselves; a deployment may leave the work to other servers, or set CCMS_ROLE=api, which also stops the background loops).
CCMS_JOBS_POOL_MAX
Most connections of the job queue's own pool, beside CCMS_DATABASE_POOL_MAX; whole number 1-100 (default: 4).
CCMS_IMPORT_MAX_BYTES
Imports (POST /imports, #256): an uploaded bundle is checked, then applied into a change set by a background job. The largest upload, in bytes; a larger one is 422 too-large and reading stops there. Whole number from 1 to 1073741824 (default: 67108864, 64 MiB). The upload is held in memory while it is checked.
CCMS_IMPORT_MAX_FILES
The most entries (files and folders) an import archive may hold; whole number 1-65534 (default: 5000).
CCMS_IMPORT_MAX_UNPACKED_BYTES
The most bytes an archive's files may hold together unpacked (decompression bombs are refused against it before anything is unpacked); whole number from 1 to 2147483647 (default: 268435456, 256 MiB). Held in memory while checked.
CCMS_IMPORT_MAX_PATH_DEPTH
The most folders deep a path in an import archive may lie; whole number 1-64 (default: 4; assets/<hash> lies in 1).
CCMS_IMPORT_MAX_JSON_DEPTH
The deepest nesting of arrays and objects in import.json; whole number 16-256 (default: 128).
CCMS_IMPORT_MAX_DOCUMENT_BYTES
The largest import.json an import reads, in bytes, refused before it is parsed (parsing takes up to about 80 times its size in memory, and two checks and one apply job may run at once); whole number from 1 to 33554432 (default: 8388608, 8 MiB; at the most, a check may take about 2 GB). A document with more than 1,000,000 values is refused before it is checked.
CCMS_IMPORT_CONVERT_MAX_MEMORY_MB
A DITA import's conversion runs in a child process of its own (#432): its heap in MiB (whole number 64-16384, default: 1024) and its longest time in milliseconds (whole number 1000-3600000, default: 120000). Past either, the import is refused as 422 import-too-large (meta.reason memory, timeout, or size: an import.json past CCMS_IMPORT_MAX_DOCUMENT_BYTES, refused in the child so the server never receives it); the server is unharmed. The bound is the JavaScript heap: the archive's unpacked files (up to CCMS_IMPORT_MAX_UNPACKED_BYTES) come on top, and the answer (import.json and the assets) about twice while it is sent, so a child takes up to about the heap plus twice the unpacked bytes; the server itself holds about three times the unpacked bytes per running conversion (the archive, the request and the answer). Two checks and, with CCMS_ROLE=all, one apply job may each run one, so plan room for three.
CCMS_IMPORT_CONVERT_TIMEOUT_MS
See CCMS_IMPORT_CONVERT_MAX_MEMORY_MB.
CCMS_IMPORT_COMMIT_FILES
How an import is cut into save points: the most modules and manuals per commit (whole number 1-1000, default 1000) and the most bytes of working copies per commit (whole number 1-33554432, default 33554432, 32 MiB). A larger import becomes several commits on one change set.
CCMS_IMPORT_COMMIT_BYTES
See CCMS_IMPORT_COMMIT_FILES.
CCMS_RELEASE_ARCHIVE_MAX_BYTES
The largest ZIP of a release's files that GET /releases/:id/outputs/archive serves (#469), in bytes, ZIP headers included (whole number 1-4294967295, default 2147483648, 2 GiB; at most 4 GiB less one byte, as no ZIP64 is written). A larger one is refused with 422 release-archive-too-large; its files still download one by one. Also the largest offline package (#59) a release's job builds: a larger one fails with offline-package-too-large.
CCMS_OFFLINE_PACKAGES
Whether each release gets its offline packages (#59): a ZIP per configured language and audience level (up to the highest any manual has), its manuals as HTML pages and PDFs, that opens from the file system without a network. Built by the release's output jobs once its PDFs are done, kept in the blob store, listed with the release's files (GET /releases/:id/outputs?filter[kind]=offline-package). true or false (default true).
CCMS_PACKAGE_SEND_IDLE_TIMEOUT_MS
Package downloads (#654): iiRDS (GET /releases/:id/iirds-packages/:packageId/file) and DITA (GET /releases/:id/dita-packages/:packageId/file). The server sends at most 4 of each kind at once; past that, or past a reader's share, 429 rate-limited before any of the file is sent. These settings apply to both kinds. A download no byte of which is read for this long is cut, freeing its turn (milliseconds, 1000-3600000, default 60000).
CCMS_PACKAGE_SEND_TIMEOUT_MS
A download still going after this long is cut (milliseconds, 1000-86400000, default 1800000, half an hour).
CCMS_PACKAGE_SEND_MIN_BYTES_PER_SECOND
A download read more slowly than this on average, once its first idle timeout has passed, is cut (bytes a second, whole number 1-1073741824, default 16384).
CCMS_PACKAGE_SENDS_PER_ACTOR
How many of those 4 one reader may hold at once, per kind; past it 429 rate-limited (whole number 1-3, default 1; at most 3, so one reader never holds every turn).
CCMS_DITA_SEND_IDLE_TIMEOUT_MS
Deprecated: the old names of the four settings above (#433, from when they bounded the DITA downloads only), with the same formats (CCMS_DITA_SENDS_PER_ACTOR is now 1-3 as well; it was 1-4). Still read when the new name is unset (a warning at start-up); set beside it, each must hold the same value. Rename them to CCMS_PACKAGE_SEND_*. Default: unset.
CCMS_DITA_SEND_TIMEOUT_MS
See CCMS_DITA_SEND_IDLE_TIMEOUT_MS.
CCMS_DITA_SEND_MIN_BYTES_PER_SECOND
See CCMS_DITA_SEND_IDLE_TIMEOUT_MS.
CCMS_DITA_SENDS_PER_ACTOR
See CCMS_DITA_SEND_IDLE_TIMEOUT_MS.
CCMS_RELEASE_MAX_OUTPUTS
The most outputs one release plans (#477): every manual at its tag, in each of its variants and each configured language, and its offline packages (#59) (whole number 1-1000000, default 20000). A release with more gets none: its planning is recorded as refused (meta.outputs of GET /releases/:id: state failed, refused.reason too-many-outputs) and logged once, and POST /releases/:id/outputs/plan answers 422 too-many-outputs until the limit is raised.
CCMS_STYLE_REVIEW_URL
Model-based style review (POST /change-sets/:id/modules/:lang/:moduleId/style-review), off by default: with CCMS_STYLE_REVIEW_URL unset the route answers 404 not-configured and nothing is ever sent anywhere. When set, a module's translatable text and the style guide in openfolia.yaml (styleGuide) are posted to this endpoint, and only when an author asks for a review. Any chat-completions style HTTP endpoint, hosted or self-hosted: the full URL a request is posted to (http:// or https://, no credentials, query or fragment; https:// required when an API key is set, except to localhost / 127.x / [::1]). Default: unset (off).
CCMS_STYLE_REVIEW_API_KEY
Sent as "Authorization: Bearer <key>"; optional (a self-hosted model may need none). Never logged or audited.
CCMS_STYLE_REVIEW_MODEL
The model name the endpoint expects (the request's "model"); required when CCMS_STYLE_REVIEW_URL is set.
CCMS_STYLE_REVIEW_PER_MINUTE
Reviews one person may ask for per minute, on each server (more: 429 with Retry-After); whole number 1-600 (default: 6).
CCMS_STYLE_REVIEW_TIMEOUT_MS
How long one review may take in milliseconds before the request is cut off (503 style-review-timeout with Retry-After); range 1000-300000 (default: 30000).
CCMS_PDF_WORKERS
PDF rendering. Worker processes compiling PDFs; range 1-64 (default: one per spare CPU, at most 64; with CCMS_ROLE=api at most 2, for readers' PDFs only). They start with the first PDF. About 450 MB each at most.
CCMS_PDF_QUEUE
PDF jobs allowed to wait for a free worker before requests get 503; range 0-10000 (default: 4 per worker; 0 = never wait).
CCMS_PDF_TIMEOUT_MS
Deadline for one PDF in milliseconds, waiting included, up to 86400000 (default: 60000).
CCMS_PDF_MEMORY_MB
Memory one PDF worker process may use, in MiB (its resident memory, the compiler's included): past it the process is stopped and that PDF fails (422 render-memory-exceeded), so a page design template that exhausts memory stops there. Range 256-65536 (default: 2048).
CCMS_RENDER_CONCURRENCY
Release files (one PDF per manual, variant and language) one server renders at once, in the background on the same PDF workers; a reader's PDF or preview waiting for a worker goes ahead of them (one already rendering finishes first, so keep this below the workers to leave readers one). Range 1 to the PDF workers (CCMS_PDF_WORKERS, else one per spare CPU); default: half the PDF workers, at least 1; with CCMS_ROLE=worker, which serves no readers, all of them.
CCMS_API_URL
Editor dev server (frontend/editor/proxy.conf.mjs): proxies /api to the API and adds the bearer token (CCMS_API_TOKEN above) itself, so the token never reaches the browser. Address of the API (default: http://127.0.0.1:<PORT in .env.local>, else port 3100). The dev server's own PORT in the environment is never used for this: set CCMS_API_URL to reach an API on another port.
CCMS_MCP_API_URL
MCP server (backend/mcp, #53): agents read the released content through it. Read from the environment of the process that starts it (a desktop assistant's MCP config, or the shell), not by the API. Base URL of the content API (http or https; e.g. http://127.0.0.1:3100). Required.
CCMS_MCP_API_TOKEN
A service account token (ccms_sat_…) whose roles hold content.read alone (pnpm nx run api:service-token -- <account> --role <role>); the server refuses to answer with a wider one. Required. Its scope is what every tool sees.
CCMS_MCP_HTTP_HOST
Streamable HTTP transport (openfolia-mcp --http) only. Address to listen on (default: 127.0.0.1; anything else is reachable from other machines: put TLS in front of it).
CCMS_MCP_HTTP_PORT
Port to listen on, 0-65535 (default: 3200; 0 picks a free one). The endpoint is /mcp.
CCMS_MCP_HTTP_TOKEN
Bearer token HTTP callers send (Authorization: Bearer …). Must come from a random generator (openssl rand -hex 32, 256 bits): a typed one is unsafe even when accepted. At least 32 characters, 12 different ones, no repeated pattern, not CCMS_MCP_API_TOKEN. Required for --http.
CCMS_MCP_HTTP_ALLOWED_ORIGINS
Comma-separated Origins a browser-based caller may send (e.g. https://assistant.example); any other Origin header is 403 (DNS rebinding). Default: none, which only non-browser clients pass.
CCMS_EMBEDDER_MODEL_DIR
Embedding worker (backend/embedder, deploy/compose.embedder.yaml, #532): a sentence-embedding model on the CPU that the API's CCMS_EMBEDDER_URL can point at, so semantic search runs without text leaving the installation. Read by the worker's process, not by the API; with compose.embedder.yaml, Compose reads them from deploy/.env. The worker also reads CCMS_EMBEDDER_MODEL (above: the name the API sends; a request naming another is refused) and CCMS_EMBEDDER_DIMENSIONS (above: checked against the model's vectors as it loads; at most 2000). It makes no network call: the model is a folder a person fills once (deploy/README.md, "Semantic search"). The folder holding the model: model.onnx and tokenizer.json (default: /models, where the image mounts it).
CCMS_EMBEDDER_MODEL_SHA256
The SHA-256 of model.onnx and of tokenizer.json, 64 hexadecimal digits each (sha256sum <file>). Required: a file whose checksum differs is refused and the worker does not start.
CCMS_EMBEDDER_TOKENIZER_SHA256
See CCMS_EMBEDDER_MODEL_SHA256.
CCMS_EMBEDDER_POOLING
How a text's token vectors become one, as the model's card says: mean (default) or cls (the first token's). Unused for a model that answers one vector per text itself (an output named sentence_embedding).
CCMS_EMBEDDER_PREFIX
Text put before every input, for a model that expects one (e.g. "query: "); at most 100 characters (default: none).
CCMS_EMBEDDER_MAX_TOKENS
The most tokens of one text the model reads; the rest is cut. Whole number 8-2048 (default: the tokenizer's own truncation length, else 512).
CCMS_EMBEDDER_THREADS
CPU threads one model run uses, 1-64 (default: 2). One request runs at a time.
CCMS_EMBEDDER_QUEUE
Requests that may wait while one runs, 0-64 (default: 8); one more is answered 503 with Retry-After. Open connections are limited to this plus 8; one more is closed at once.
CCMS_EMBEDDER_HOST
The address and port the worker listens on (default: 127.0.0.1 and 8090; the image: 0.0.0.0, on its internal network only). It has no authentication: never publish it. Port 0-65535 (0: a free one).
CCMS_EMBEDDER_PORT
See CCMS_EMBEDDER_HOST.
CCMS_EMBEDDER_TEST_MODEL_DIR
Tests only (backend/embedder/README.md, "Testing with a real model"): a model folder, its dimensions and an optional prefix for the opt-in test with a real model. Unset: that test is skipped.
CCMS_EMBEDDER_TEST_DIMENSIONS
See CCMS_EMBEDDER_TEST_MODEL_DIR.
CCMS_EMBEDDER_TEST_PREFIX
See CCMS_EMBEDDER_TEST_MODEL_DIR.
CCMS_CONNECTOR_API_URL
Tracker connector (connectors/tracker, #141): imports items of an issue tracker through the import API into a change set for review. Read from the environment of the process that runs it (the shell, cron), not by the API. Base URL of the content API: https, or http to this machine only (e.g. http://127.0.0.1:3100). Required. The connector calls nothing else.
CCMS_CONNECTOR_SESSION_FILE
Path of the cookie file of a signed-in person who may import (admin.roles and content.edit), as curl writes it when signing in (curl -c cookies.txt …, the import format's guide, "Sign in for the import"). Readable by its owner alone (chmod 600), else refused; read again on every run, so signing in again renews it. Required.
CCMS_CONNECTOR_WEBHOOK_SECRET
The secret the source signs its triggers with, when the connector runs with --listen (a signed POST /trigger starts a run: HMAC-SHA256 over <unix seconds>.<body>, header X-Openfolia-Signature). At least 32 characters, e.g. openssl rand -hex 32; the source holds the same value. Required with --listen, unused without. Never printed.
POSTGRES_PASSWORD
Container deployment (deploy/compose.yaml, the guide in deploy/README.md). Compose reads these from the environment or from deploy/.env (beside compose.yaml); any API setting above goes into deploy/api.env instead, except those compose.yaml sets itself (CCMS_AUTH_MODE, CCMS_API_TOKEN, CCMS_EDITOR_ORIGINS, CCMS_SOURCE_URL, CCMS_PUBLIC_URL, CCMS_FIRST_ADMIN_EMAIL, CCMS_FIRST_ADMIN_NAME, CCMS_FIRST_ADMIN_LINK_LOG, CCMS_TRUST_PROXY (default 1 there: the editor's nginx), CCMS_MAIL_* (email): set those here; CCMS_DATABASE_URL it builds from POSTGRES_PASSWORD). The images set HOST=0.0.0.0, PORT=3000, CCMS_CONTENT_DIR=/data/content.git, CCMS_BLOB_DRIVER=fs and CCMS_BLOB_FS_ROOT=/data/blobs themselves. Postgres's password, also put into the API's CCMS_DATABASE_URL. Required, no default. Letters and digits only (it goes into a URL), e.g. openssl rand -hex 24. Read by Postgres on the first start only: changing it later needs ALTER USER in the database too.
OPENFOLIA_IMAGES
Where the images come from: the registry path before /api, /backup, /editor, /mcp and /portal, e.g. ghcr.io/<owner>/openfolia for the public images (default: openfolia, the names compose.build.yaml builds locally).
OPENFOLIA_VERSION
The image tag: a release (v1.2.3), latest (the newest release), main, or a commit SHA of main (default: local, what compose.build.yaml builds).
OPENFOLIA_API_ENV_FILE
The API's settings file beside compose.yaml (default: ./api.env, read when it exists); the smoke test sets /dev/null so it never reads a deployment's. The workers read it too.
OPENFOLIA_WORKER_ENV_FILE
The workers' own settings file beside compose.yaml, read over the API's (default: ./worker.env, read when it exists), e.g. CCMS_PDF_WORKERS and CCMS_RENDER_CONCURRENCY for the workers only (#527).
OPENFOLIA_WORKER_CPUS
The CPU limit of each worker container, in CPUs, e.g. 2 (default: 0, no limit). At most the host's CPUs: Docker refuses to start a container with more. Set CCMS_PDF_WORKERS in worker.env to match it: the PDF pool's default is the host's CPUs less one, not the limit's, and a worker renders on all its PDF workers.
OPENFOLIA_API_ROLE
The api service's CCMS_ROLE (default: api, the worker service runs the jobs). all runs everything in the api container instead; then start with --scale worker=0.
OPENFOLIA_BACKUP_ENV_FILE
The backup service's settings file beside compose.yaml, read after api.env (default: ./backup.env, read when it exists): the CCMS_BACKUP_* settings above. The smoke test sets /dev/null.
OPENFOLIA_BIND
The address the published ports listen on (default: 127.0.0.1, for a reverse proxy on the same machine; 0.0.0.0 publishes them to every network, plain HTTP included, past ufw/firewalld rules: then only on a network you trust, with TLS in front for everyone else).
OPENFOLIA_API_BIND
The address the API's own published port listens on (default: 127.0.0.1, whatever OPENFOLIA_BIND says). Readers and clients reach the API through the editor (/api/, /d/). Publishing this port wider lets anyone who reaches it name their own address to CCMS_TRUST_PROXY's hop count (deploy/README.md, "Reverse proxy with TLS"): then set CCMS_TRUST_PROXY=none, and raise or turn off CCMS_DELIVERY_PER_MINUTE (every reader through the editor shares one budget then, and one failed-sign-in window).
OPENFOLIA_EMBEDDER_MODEL_DIR
The embedding worker (compose.embedder.yaml): the folder with the model's files, mounted read-only at /models (default: ./embedder-model beside compose.yaml), its memory limit (default: 2g; the model's file size about twice while it loads, plus one request's working memory) and its CPU limit in CPUs (default: 0, no limit; at most the host's CPUs). Set CCMS_EMBEDDER_THREADS to match a limit.
OPENFOLIA_EMBEDDER_MEMORY
See OPENFOLIA_EMBEDDER_MODEL_DIR.
OPENFOLIA_EMBEDDER_CPUS
See OPENFOLIA_EMBEDDER_MODEL_DIR.
OPENFOLIA_EDITOR_PORT
The published ports of the editor (default: 8080), the API (default: 3000), the MCP server (default: 3200; only with --profile mcp) and the reader portal (default: 8090; only with --profile portal, which also reads CCMS_PORTAL_TOKEN, CCMS_PORTAL_AUDIENCE and the other CCMS_PORTAL_* settings of "Portal" below from here). Whole numbers 1-65535.
OPENFOLIA_API_PORT
See OPENFOLIA_EDITOR_PORT.
OPENFOLIA_MCP_PORT
See OPENFOLIA_EDITOR_PORT.
OPENFOLIA_PORTAL_PORT
See OPENFOLIA_EDITOR_PORT.
CCMS_EDITOR_PORT
The editor image (its web server, deploy/docker/editor/): the port it listens on inside the container (default: 8080) and the API's address, http(s)://host[:port] without a path (default: http://api:3000, the compose service). It serves the editor and proxies /api to that address, looking the host up through the container's DNS resolver every 10 s (never /etc/hosts: use a DNS name or an IP address).
CCMS_EDITOR_API_URL
See CCMS_EDITOR_PORT.
CCMS_EDITOR_HOSTS
The host names the editor answers for, comma-separated host[:port] (the port is not compared), e.g. docs.example.com,127.0.0.1. Any other Host gets 421 from a default server and is never proxied (DNS rebinding). Required with CCMS_EDITOR_API_TOKEN. Default: unset, any Host.
CCMS_EDITOR_API_TOKEN
Optional: a token the editor's proxy adds to /api requests (32-512 characters of A-Z a-z 0-9 . _ ~ + / = -), replacing any the browser sent. Only for CCMS_EDITOR_HOSTS, and only for requests from the editor's own page (its Origin, or Sec-Fetch-Site: same-origin, which browsers send only over HTTPS or to localhost: so open such an editor over HTTPS or on localhost); anything else is refused. For a demo instance only (with CCMS_AUTH_MODE=demo and the same CCMS_API_TOKEN): anyone who reaches the editor then acts with it, so keep it on a private network (deploy/README.md, "Signing in"). Default: unset, the browser's own Authorization is passed on.
CCMS_EDITOR_API_TOKEN_FILE
Instead of CCMS_EDITOR_API_TOKEN: the path of a file holding it, e.g. a Compose secret /run/secrets/editor-token (default: unset). Setting both is refused.
CCMS_DATABASE_URL_FILE
Secrets from files (the API, backup and MCP images' entrypoint, deploy/docker/node-entrypoint.sh): the path of a file holding the value, e.g. a Compose secret under /run/secrets/, instead of the value itself; trailing newlines are dropped. Setting a value and its _FILE is refused. Default: unset. (The instance secret key has its own CCMS_SECRET_KEY_FILE above, which the API reads itself.)
CCMS_API_TOKEN_FILE
See CCMS_DATABASE_URL_FILE.
CCMS_S3_ACCESS_KEY_ID_FILE
See CCMS_DATABASE_URL_FILE.
CCMS_S3_SECRET_ACCESS_KEY_FILE
See CCMS_DATABASE_URL_FILE.
CCMS_STYLE_REVIEW_API_KEY_FILE
See CCMS_DATABASE_URL_FILE.
CCMS_EMBEDDER_API_KEY_FILE
See CCMS_DATABASE_URL_FILE.
CCMS_AUDIT_SINK_SECRET_FILE
See CCMS_DATABASE_URL_FILE.
CCMS_OIDC_CLIENT_SECRET_FILE
See CCMS_DATABASE_URL_FILE.
CCMS_MCP_API_TOKEN_FILE
See CCMS_DATABASE_URL_FILE.
CCMS_MCP_HTTP_TOKEN_FILE
See CCMS_DATABASE_URL_FILE.
CCMS_BACKUP_VERIFY_DATABASE_URL_FILE
See CCMS_DATABASE_URL_FILE.
CCMS_BACKUP_S3_ACCESS_KEY_ID_FILE
See CCMS_DATABASE_URL_FILE.
CCMS_BACKUP_S3_SECRET_ACCESS_KEY_FILE
See CCMS_DATABASE_URL_FILE.
SMOKE_PROJECT
The smoke test (deploy/smoke-test.sh), read from the shell: the Compose project (default: openfolia-smoke), the ports it publishes on 127.0.0.1 for the API, the editor and the MCP server (defaults: 3103, 4303 and 3203), 0 to use the images as they are instead of building them (default: 1), 1 to leave the stack running (default: 0), and a path to copy the rendered PDF to (default: none).
SMOKE_API_PORT
See SMOKE_PROJECT.
SMOKE_EDITOR_PORT
See SMOKE_PROJECT.
SMOKE_MCP_PORT
See SMOKE_PROJECT.
SMOKE_BUILD
See SMOKE_PROJECT.
SMOKE_KEEP
See SMOKE_PROJECT.
SMOKE_PDF_OUT
See SMOKE_PROJECT.
OPENFOLIA_ENV_FILE
The one-command self-host (deploy/self-host.sh, #373), read from the shell: the settings file it makes when missing and Compose reads (default: deploy/.env beside compose.yaml), and how long it waits for the services to be healthy, in seconds (default: 300).
OPENFOLIA_WAIT_TIMEOUT
See OPENFOLIA_ENV_FILE.
SELF_HOST_PROJECT
Its test (deploy/self-host-test.sh), read from the shell: the Compose project (default: openfolia-self-host), the ports it publishes on 127.0.0.1 for the API, the editor and the test OpenID Connect provider (defaults: 3104, 4304 and 9404), and 1 to leave the stack running (default: 0). The test provider (deploy/smoke-oidc.yaml) reads SMOKE_OIDC_PORT (its port, default 9404) and SMOKE_ADMIN_EMAIL (the address of its one login, admin; default admin@example.com), which the test sets.
SELF_HOST_API_PORT
See SELF_HOST_PROJECT.
SELF_HOST_EDITOR_PORT
See SELF_HOST_PROJECT.
SELF_HOST_OIDC_PORT
See SELF_HOST_PROJECT.
SELF_HOST_KEEP
See SELF_HOST_PROJECT.
SMOKE_OIDC_PORT
See SELF_HOST_PROJECT.
SMOKE_ADMIN_EMAIL
See SELF_HOST_PROJECT.
DIGESTS_TEST_REGISTRY_PORT
The test of the images pinned by their digests (deploy/digests-test.sh, #739), read from the shell: the port of the registry of its own it starts on 127.0.0.1 (default: 5739).
Docs site (frontend/docs, pnpm nx build docs).
Read from the build's environment, not from this file: the values are written into the static site, so set them for the build of the site you publish.
| Setting | In .env.example |
|---|---|
DOCS_ | empty |
DOCS_ | empty |
DOCS_ | empty |
DOCS_ | empty |
DOCS_ | empty |
DOCS_ | empty |
DOCS_ | empty |
DOCS_ | empty |
DOCS_ | empty |
DOCS_ | empty |
DOCS_ | empty |
DOCS_API_BASE_URL
The API base URL the API reference's playground sends requests to, and the server its pages name. An absolute http(s) URL (default: http://localhost:3000, the container setup's API).
DOCS_SITE_URL
The docs site's own address, for the absolute links in /llms.txt and /llms-full.txt. An absolute http(s) URL without a trailing slash (default: http://localhost:3000).
DOCS_REPOSITORY_URL
The repository's web address: the GitHub link in the site's navigation, and links to files in it (for example the import format's guide). An absolute http(s) URL of a GitHub repository (default: https://github.com/openfolia/openfolia, the project's own; set it for a fork).
DOCS_RELEASE
The release these docs belong to, as its tag names it: v1.2.3 (not a pre-release: only a release gets the files the guide downloads). The install guide for coding agents (/agents) pins it: the images it pulls and the compose file it downloads. Set it for the build of a release's docs; DOCS_SITE_URL must then be set, and it and DOCS_RELEASE_URL be https (plain http only on 127.0.0.1 or localhost, for a test). Default: unset, the development docs, whose guide pins no release and says so.
DOCS_RELEASE_URL
Where the release's files (compose.yaml, compose.digests.yaml, SHA256SUMS) are downloaded from: an absolute URL, the folder that holds them, without query or fragment. Set only together with DOCS_RELEASE. Default: <DOCS_REPOSITORY_URL>/releases/download/<DOCS_RELEASE>, the GitHub Release.
DOCS_IMAGES
The image repository the install guide pulls from, without a tag (registry[:port]/path, lowercase): each image is <DOCS_IMAGES>/<image>:<DOCS_RELEASE>. Default: ghcr.io/<owner>/openfolia, the owner of a GitHub DOCS_REPOSITORY_URL (else ghcr.io/openfolia/openfolia).
DOCS_RELEASE_DIGESTS
The release's images by their digests (#739): the text of the images.lock the release workflow attaches to the release, one <DOCS_IMAGES>/<image>:<DOCS_RELEASE>@sha256:<digest> per line (or separated by spaces). The install guide pins every image by it: it names the SHA-256 of the release's compose.digests.yaml, which it downloads, and checks the running containers against the digests. Required for a release's docs (with DOCS_RELEASE), and set only together with it. Default: unset.
DOCS_RELEASE_SIGNATURES
The release's signatures (#745), when the release workflow signed its images (repository variable SIGN_IMAGES): the text of the signatures.sha256 it attaches to the release, one "<sha256> <file>" per line (or separated by spaces), for trusted_root.json and <image>.sigstore.json of every image. The install guide then names each file's SHA-256 and checks the images' signatures with cosign, offline, before pulling. Set only together with DOCS_RELEASE. Default: unset, the release is not signed and the guide says so.
DOCS_RELEASE_SIGNER_IDENTITY
The identity the signatures must carry (cosign --certificate-identity): an https URL or an email, only letters, digits and . _ ~ : / % @ + -. Set only with DOCS_RELEASE_SIGNATURES. Default: the release workflow of the GitHub repository DOCS_REPOSITORY_URL at the release's tag, https://github.com/<owner>/<repository>/.github/workflows/images.yml@refs/tags/<DOCS_RELEASE>; required when DOCS_REPOSITORY_URL is not on github.com.
DOCS_RELEASE_SIGNER_ISSUER
The OIDC issuer the signatures must carry (cosign --certificate-oidc-issuer): an https URL. Set only with DOCS_RELEASE_SIGNATURES. Default: https://token.actions.githubusercontent.com, GitHub Actions'.
DOCS_PUBLISH_IMAGE
Where pnpm docs:publish (scripts/docs-publish.mjs) tags and pushes the docs site's image: an image repository without a tag (registry[:port]/path, lowercase). Read by that command only, not by the site's build. Default: ghcr.io/<owner>/openfolia-docs, the owner of a GitHub DOCS_REPOSITORY_URL (else ghcr.io/openfolia/openfolia-docs).
Portal (frontend/portal, pnpm nx run portal:site): one audience's static portal, a site per language.
Read from the build's environment, not from this file. Keep the token out of files: set it in the build job's secret store. The build refuses a token that reads above the audience or may do more than read released content. The portal image (docker compose --profile portal, deploy/README.md, "The static portal") reads the same settings from the stack's settings file beside compose.yaml, where deploy/self-host.sh writes the token (readable by its owner only); compose.yaml sets CCMS_PORTAL_API_URL (http://api:3000) and CCMS_PORTAL_HTTP_HOSTS (api), and the image CCMS_PORTAL_OUT_DIR.
The build sets CCMS_PORTAL_SNAPSHOT, CCMS_PORTAL_SITE_OUT and CCMS_PORTAL_SITE_BASE for Astro's own process (the snapshot file, the language's output folder, its path): not settings, never set by hand.
| Setting | In .env.example |
|---|---|
CCMS_ | empty |
CCMS_ | empty |
CCMS_ | empty |
CCMS_ | empty |
CCMS_ | empty |
CCMS_ | empty |
CCMS_ | empty |
CCMS_ | empty |
CCMS_ | empty |
CCMS_ | empty |
CCMS_ | empty |
CCMS_PORTAL_API_URL
The API's base URL. An absolute https URL; http only to this machine (127.0.0.1, localhost, [::1]) or a host of CCMS_PORTAL_HTTP_HOSTS. No user, password, query or fragment. Required.
CCMS_PORTAL_TOKEN
A service account token (ccms_sat_<16 hex>_<64 hex>) whose roles hold only content.read, each with a maxAudience of at most CCMS_PORTAL_AUDIENCE (Admin -> Service accounts). Sent only in the Authorization header. Required.
CCMS_PORTAL_AUDIENCE
The audience level the portal is for (an audience ID of openfolia.yaml, e.g. public). Nothing above it reaches the site: one build per audience. Required.
CCMS_PORTAL_LANGUAGES
The languages to build, one site each: comma-separated language tags of openfolia.yaml (default: every configured language).
CCMS_PORTAL_RELEASES
The releases to build: comma-separated release IDs (UUIDs), none withdrawn (default: each product's newest release that is not withdrawn).
CCMS_PORTAL_OUT_DIR
Where the sites are written: <dir>/<lang>/ and <dir>/index.html; a path, relative to frontend/portal (default: dist). Replaced as a whole once every language is built.
CCMS_PORTAL_BASE_PATH
The path the sites are served under, starting and ending with "/" (default: /): each language at <path><lang>/.
CCMS_PORTAL_BRANDING
The organisation's branding (Admin -> Branding, the API's public GET /branding): its name, logos, favicon and colours on every page. on (default) or off for a neutral site with OpenFolia's default look. Without branding set, the site has the default look either way.
CCMS_PORTAL_HTTP_HOSTS
Host names besides this machine's that CCMS_PORTAL_API_URL may name over plain http, comma-separated, e.g. api (the API's service on the Compose stack's own network, which deploy/compose.yaml sets). Default: none, https only.
CCMS_PORTAL_REFRESH_SECONDS
The portal image only (deploy/docker/portal/, docker compose --profile portal): how often it reads the API's releases and builds the portal again when one was published or withdrawn, in whole seconds from 5 to 86400 (default: 300). A build that failed is tried again after one interval, then after twice as long each time (at most an hour), or at once when the releases change; the last good build is served meanwhile.
CCMS_PORTAL_TOKEN_FILE
The portal image only: a file holding CCMS_PORTAL_TOKEN instead (a Docker or Compose secret, mounted under /run/secrets/); not both. Default: unset.
Workflow scripts (scripts/, .githooks/). Read from the shell's environment, not from this file.
| Setting | In .env.example |
|---|---|
BASE_ | empty |
SKIP_ | empty |
NX_ | empty |
GH_ | empty |
GH_ | empty |
BASE_BRANCH
Base branch for pnpm review:diff when no --base is given (e.g. origin/sprint-2; default: the agent slot's base, else origin/main); sync:main takes --base instead.
SKIP_POST_MERGE_CHECK
Set to 1 to skip the post-merge hook's pnpm check:changed (.githooks/post-merge) once.
NX_DAEMON
Nx's own: false runs Nx without its daemon. An agent slot's settings set it (#615): in a worktree the daemon's watcher sees no edit, so it would hash tasks as the files were when it started. pnpm check sets it in any worktree unless given. Default (unset): the daemon runs.
GH_PROJECT_OWNER
GitHub project board pnpm merge:pr moves closed issues to Done on: the owner (org or user) and the project number. pnpm setup:board writes them; gh needs the project scope.
GH_PROJECT_NUMBER
See GH_PROJECT_OWNER.
Demo videos (scripts/demo/, docs/demo-videos.md). Read from the shell's environment, not from this file.
| Setting | In .env.example |
|---|---|
FFMPEG | empty |
FFPROBE | empty |
DEMO_ | empty |
DEMO_ | empty |
ELEVENLABS_ | empty |
DEMO_ | empty |
DEMO_ | empty |
DEMO_ | empty |
DEMO_ | empty |
FFMPEG
The ffmpeg and ffprobe the assembly and the encodes run (default: those on the PATH).
FFPROBE
See FFMPEG.
DEMO_VOICE_EN
The ElevenLabs voice per language for a tab video's voice-over (node scripts/demo/voice.mjs): the ID of a voice in the account's voices (no default: the script refuses without one).
DEMO_VOICE_DE
See DEMO_VOICE_EN.
ELEVENLABS_API_BASE
The ElevenLabs API key. Never put it in this file or any other: voice.mjs asks for it without echo when it is not in the environment, and never writes or prints it. ELEVENLABS_API_KEY= The ElevenLabs API's base URL, for a test against a local stub (default: https://api.elevenlabs.io).
DEMO_MUSIC
The hero's music (node scripts/demo/assemble.mjs hero): an audio file whose sting plays under the intro card and whose ending plays under the end card (default: none, no music). Check the track's licence first.
DEMO_MUSIC_STING_FROM
Seconds into DEMO_MUSIC where the sting starts (default: 0).
DEMO_MUSIC_HIT
Seconds into DEMO_MUSIC of its last hit, which lands on the end card's logo (default: half a second before its end).
DEMO_BED
A tab video's music bed (node scripts/demo/assemble.mjs <tab video>): an audio file laid very quietly under the voice in the cut with sound, looped if shorter than the film (default: none, no bed). Never committed; check its licence.