Environment & Settings Reference
FynnCloud Server divides configuration into two layers:
- Boot-Time Environment Variables — Infrastructure, cryptography, database, storage, proxy trust, push overrides, and orchestrator plumbing read at process startup. Changing these requires restarting
fynncloud-server. - Dynamic Application Settings (73
AppSettings) — Operational settings editable live from Administration → Settings (stored in PostgreSQLapp_settingsand cached in memory with Redis Pub/Sub invalidation). Environment Lock Rule: If you set a dynamic setting’s environment variable (or<KEY>_FILE), the environment value takes precedence and locks that setting read-only in the Admin UI until removed.
Secret File Support (<KEY>_FILE)
Section titled “Secret File Support (<KEY>_FILE)”Every ServerConfig boot variable and every dynamic AppSettings variable resolved via Environment.first(matching:) automatically supports Docker/Kubernetes mounted secret files by appending _FILE:
# Reads the secret value from /run/secrets/jwt_secret (trimmed of trailing newlines)AUTH_JWT_SECRET_FILE=/run/secrets/jwt_secretSECURITY_ENCRYPTION_KEY_FILE=/run/secrets/encryption_keyDATABASE_URL_FILE=/run/secrets/database_urlIf both <KEY> and <KEY>_FILE are set, the direct environment variable wins.
Boot-Time Environment Variables
Section titled “Boot-Time Environment Variables”Core, Security & Cryptography
Section titled “Core, Security & Cryptography”| Canonical Variable | Aliases | Default | Required | Description |
|---|---|---|---|---|
SECURITY_ENCRYPTION_KEY |
APP_ENCRYPTION_KEY, ENCRYPTION_KEY |
— | Always | Master symmetric key (SecretBox, AES-256-GCM) for encrypting 2FA TOTP seeds and .secret app_settings at rest. Must be ≥ 32 bytes in release/production or startup aborts. Generate with openssl rand -base64 32. |
ENCRYPTION_PREVIOUS_KEYS |
— | (empty) | No | Comma-separated previous encryption keys for zero-downtime key rotation. SecretBox decrypts existing v2. ciphertexts with old keys while encrypting new writes with SECURITY_ENCRYPTION_KEY. |
AUTH_JWT_SECRET |
JWT_SECRET |
Ephemeral random (dev only) | Prod | HS256 signing key for user, app, upload, and share JWTs. Must be ≥ 32 bytes in release/production or startup aborts. |
SUBSCRIPTION_KEY |
APP_LICENSE_KEY |
(unset) | No | Signed FynnCloud Enterprise/Pro subscription key (lifts the default 10-user free tier limit). Can also be installed via Admin UI. |
COOKIE_SECURE |
— | true (prod) / false (dev) |
No | Force Secure flag on auth cookies (true / false). |
COOKIE_DOMAIN |
— | (unset) | No | Optional Domain attribute for auth cookies. |
Networking, Proxies & CORS
Section titled “Networking, Proxies & CORS”| Canonical Variable | Aliases | Default | Description |
|---|---|---|---|
APP_FRONTEND_URL |
SERVER_FRONTEND_URL, FRONTEND_URL |
https://localhost |
Public browser origin of your FynnCloud instance (used for CORS default, share links, OIDC callbacks, and email links). |
SERVER_CORS_ALLOWED_ORIGINS |
CORS_ALLOWED_ORIGINS |
APP_FRONTEND_URL |
Comma-separated origins allowed by ScopedCORSMiddleware. |
SERVER_TRUSTED_PROXIES |
TRUSTED_PROXIES |
(empty) | Comma-separated reverse-proxy IPs/CIDRs (e.g. 127.0.0.1/32,172.16.0.0/12). Only requests whose TCP peer matches may honor X-Forwarded-For / X-Real-IP. |
TRUST_CLOUDFLARE_HEADERS |
— | false |
When true and the connecting peer matches SERVER_TRUSTED_PROXIES, honors CF-Connecting-IP and True-Client-IP. |
STORAGE_MAX_CHUNK_SIZE |
MAX_CHUNK_SIZE |
100mb |
Maximum size per multipart upload chunk. |
MAX_BODY_SIZE |
SERVER_MAX_BODY_SIZE, STORAGE_MAX_BODY_SIZE |
STORAGE_MAX_CHUNK_SIZE (100mb) |
Global Vapor request body cap. |
Database & Redis
Section titled “Database & Redis”| Canonical Variable | Aliases | Default | Description |
|---|---|---|---|
DATABASE_URL |
— | (unset) | PostgreSQL connection URL only (postgresql://user:pass@host:5432/db?sslmode=require). Supports standard libpq sslmode values (disable, prefer [default], require, verify-ca, verify-full) with hardened TLS 1.2+ (ECDHE+AEAD, hybrid X25519MLKEM768). Does not accept sqlite://. |
DATABASE_SQLITE_PATH |
SQLITE_PATH |
db.sqlite |
SQLite file path used when DATABASE_URL is unset (development / testing only; semantic search pgvector and multi-replica HA require PostgreSQL). |
DATABASE_AUTO_MIGRATE |
AUTO_MIGRATE |
false |
Run Fluent migrations automatically at startup (true / false). Production Compose defaults this to true; Kubernetes runs a dedicated migrate Job instead. |
REDIS_URL |
— | redis://127.0.0.1:6379 |
Redis connection URL (supports redis://:password@host:6379 and rediss:// TLS). |
Storage (Local Disk vs S3)
Section titled “Storage (Local Disk vs S3)”| Canonical Variable | Aliases | Default | Description |
|---|---|---|---|
STORAGE_PATH |
LOCAL_STORAGE_PATH |
<workdir>/Storage/ |
Local filesystem root used when STORAGE_S3_BUCKET is empty. |
STORAGE_S3_BUCKET |
S3_BUCKET |
(unset) | Setting a non-empty bucket switches FynnCloud from local disk to S3-compatible storage. |
STORAGE_AWS_ACCESS_KEY_ID |
AWS_ACCESS_KEY_ID |
"" |
S3 access key ID. |
STORAGE_AWS_SECRET_ACCESS_KEY |
AWS_SECRET_ACCESS_KEY |
"" |
S3 secret access key. |
STORAGE_AWS_REGION |
AWS_REGION |
us-east-1 |
S3 region identifier. |
STORAGE_AWS_ENDPOINT |
AWS_ENDPOINT, S3_ENDPOINT |
https://s3.amazonaws.com |
Custom S3-compatible endpoint URL (Cloudflare R2, MinIO, Hetzner, Backblaze B2). |
STORAGE_S3_TIMEOUT |
S3_TIMEOUT |
900 |
End-to-end timeout in seconds for a single S3 request (accommodates large streaming multipart chunks on slow uplinks). |
App Orchestration, AIO & Internal Callbacks
Section titled “App Orchestration, AIO & Internal Callbacks”| Variable | Aliases | Default | Description |
|---|---|---|---|
AIO_SOCKET_PATH |
— | (unset) | Path to AIO supervisor Unix socket (/run/fynncloud-aio/aio.sock). Also activates BackupFreezeMiddleware (backup.lock detection). |
AIO_MANAGER_URL |
— | (unset) | Alternative HTTP base URL for AIO manager (used instead of Unix socket if set). |
AIO_HMAC_SECRET |
— | (unset) | Shared HMAC-SHA256 secret for signing server → AIO control plane requests. |
DOCKER_SOCKET_PROXY_URL |
— | (unset) | Legacy Docker socket proxy URL for standalone Compose app orchestration (ignored when AIO manages apps). |
DOCKER_APPS_NETWORK |
APP_DOCKER_NETWORK |
(unset) | Shared Docker network name for standalone Compose app containers. |
DOCKER_APPS_SHARED_NETWORK |
— | false |
Force legacy shared app network instead of per-app isolated networks. |
APPS_ALLOWED_REGISTRIES |
— | (unset) | Comma-separated container registry allowlist for installed app images (e.g. ghcr.io). |
FYNNCLOUD_INTERNAL_API_URL |
INTERNAL_API_URL |
auto-detected | Internal HTTP URL injected into app containers so app backends can call FynnCloud Server directly without external hairpinning. |
POSTGRES_HOST / POSTGRES_PORT / POSTGRES_DB |
— | localhost / 5432 / fynncloud |
Host/port/DB used when provisioning isolated schemas/roles for apps declaring database: postgres. |
POSTGRES_SSLMODE / POSTGRES_REQUIRE_SSL |
— | (unset) / false |
TLS mode appended to provisioned app database connection strings. |
DOCS_SERVER_INTERNAL_URL |
— | (unset) | Optional internal HTTP URL to EuroOffice (avoids NAT hairpinning when FynnCloud Server fetches document-server assets or callbacks). |
LDAP_STARTTLS |
— | false |
Upgrade plaintext port 389 LDAP connections with StartTLS when SSO_LDAP_USE_SSL=false. |
Push Notifications & Logging
Section titled “Push Notifications & Logging”| Variable | Default | Description |
|---|---|---|
PUSH_CORE_GATEWAYS |
https://push.fynncloud.ch/v1/push |
Comma-separated allowlisted PushRelay URLs for official core Apple/mobile clients. |
PUSH_GATEWAY_OVERRIDES |
(empty) | Comma-separated appId=https://relay.example.com/v1/push map overriding a specific app’s manifest push gateway (including core=...). |
PUSH_GATEWAY_SECRETS |
(empty) | Comma-separated https://relay.example.com/v1/push=<bearer-secret> map sent as Authorization: Bearer to private PushRelay instances. |
PUSH_ALLOW_UNIFIEDPUSH |
false |
Allow clients to register arbitrary public https:// UnifiedPush distributor endpoints. |
PUSH_CORE_FILEPROVIDER_ENABLED |
true |
Enable apns-fileprovider wakeups for official core Apple clients. |
PUSH_CORE_VOIP_ENABLED |
false |
Allow apns-voip registrations under the core app ID (Talk uses its own talk app ID with notifications:send + rtc:rooms). |
MAIL_DRIVER |
default |
Mail transport driver label (default SMTP or log). |
LOG_FORMAT |
text |
Set json for structured JSON log lines to stdout. |
DISABLE_BANNER / NO_COLOR |
(unset) | Disable ASCII startup banner / ANSI colors. |
Dynamic Application Settings (All 73 AppSettings)
Section titled “Dynamic Application Settings (All 73 AppSettings)”All 73 keys below can be changed live in Administration → Settings (or via PATCH /api/settings) unless locked by setting one of their corresponding environment variables (or <KEY>_FILE).
Visibility levels:
public— Returned byGET /api/settings/public(unauthenticated, used by the login/branding UI).internal— Returned only to authenticated administrators viaGET /api/settings.secret— Stored AES-256-GCM encrypted inapp_settingsviaSecretBox(v2.prefix) and masked asisSet: truein admin read responses (never echoed back in plaintext).
1. Branding (8 keys)
Section titled “1. Branding (8 keys)”| Canonical JSON Key | Environment Variables | Visibility | Default | Validation / Notes |
|---|---|---|---|---|
brandingAppName |
BRANDING_APP_NAME, APP_NAME |
public |
"FynnCloud" |
Instance display name |
brandingPrimaryColor |
BRANDING_PRIMARY_COLOR, PRIMARY_COLOR |
public |
"#007bff" |
Tailwind color preset (slate..rose) or 3–8 digit hex |
brandingShowLogoAndName |
BRANDING_SHOW_LOGO_AND_NAME, SHOW_LOGO_AND_NAME |
public |
false |
Show instance name next to custom logo |
brandingSvgColorMode |
BRANDING_SVG_COLOR_MODE, SVG_COLOR_MODE |
public |
"monochrome" |
original, monochrome, or tinted |
customLogoUpdatedAt |
BRANDING_CUSTOM_LOGO_UPDATED_AT, CUSTOM_LOGO_UPDATED_AT |
public |
"" |
Cache-buster timestamp (managed automatically on upload) |
customLogoMimeType |
BRANDING_CUSTOM_LOGO_MIME_TYPE, CUSTOM_LOGO_MIME_TYPE |
public |
"" |
image/png, image/jpeg, image/webp, image/svg+xml |
customIconUpdatedAt |
BRANDING_CUSTOM_ICON_UPDATED_AT, CUSTOM_ICON_UPDATED_AT |
public |
"" |
Cache-buster timestamp for custom favicon/icon |
customIconMimeType |
BRANDING_CUSTOM_ICON_MIME_TYPE, CUSTOM_ICON_MIME_TYPE |
public |
"" |
image/png, image/jpeg, image/webp, image/svg+xml |
2. Document Editing (4 keys)
Section titled “2. Document Editing (4 keys)”| Canonical JSON Key | Environment Variables | Visibility | Default | Notes |
|---|---|---|---|---|
docsServerUrl |
DOCS_SERVER_URL, DOCUMENT_SERVER_URL, EUROOFFICE_URL |
public |
"" |
Empty disables browser document editing |
docsProvider |
DOCS_PROVIDER, OFFICE_PROVIDER |
public |
"eurooffice" |
eurooffice (native DocsAPI) or wopi |
docsJwtSecret |
DOCS_JWT_SECRET, EUROOFFICE_JWT_SECRET, DOCUMENT_SERVER_JWT_SECRET |
secret |
"" |
Shared HS256 secret with EuroOffice |
docsWopiPublicUrl |
DOCS_WOPI_PUBLIC_URL, WOPI_PUBLIC_URL |
internal |
"" |
Public FynnCloud Server base URL for WOPI callbacks |
3. Real-Time Media / LiveKit RTC (4 keys)
Section titled “3. Real-Time Media / LiveKit RTC (4 keys)”| Canonical JSON Key | Environment Variables | Visibility | Default | Notes |
|---|---|---|---|---|
livekitUrl |
LIVEKIT_URL, RTC_LIVEKIT_URL |
internal |
"" |
Browser-facing WebSocket URL (wss://...); empty disables SFU mode |
livekitInternalUrl |
LIVEKIT_INTERNAL_URL, RTC_LIVEKIT_INTERNAL_URL |
internal |
"" |
Optional internal HTTP URL for Twirp moderation (e.g. http://fynncloud-livekit:7880) |
livekitApiKey |
LIVEKIT_API_KEY, RTC_LIVEKIT_API_KEY |
internal |
"" |
LiveKit API key (iss claim) |
livekitApiSecret |
LIVEKIT_API_SECRET, RTC_LIVEKIT_API_SECRET |
secret |
"" |
LiveKit HS256 API secret |
4. Access & Storage (3 keys)
Section titled “4. Access & Storage (3 keys)”| Canonical JSON Key | Environment Variables | Visibility | Default | Range / Notes |
|---|---|---|---|---|
accessRegistrationEnabled |
ACCESS_REGISTRATION_ENABLED, AUTH_REGISTRATION_ENABLED, REGISTRATION_ENABLED |
public |
false |
Allow public self-registration |
storageTrashRetentionDays |
STORAGE_TRASH_RETENTION_DAYS, TRASH_RETENTION_DAYS |
internal |
30 |
Min 1 (no upper bound) |
storageMaxFileVersions |
STORAGE_MAX_FILE_VERSIONS, MAX_FILE_VERSIONS |
internal |
30 |
Range 0..500; 0 disables automatic version snapshots |
5. Single Sign-On — LDAP, OIDC, Trusted Headers & Sync (32 keys)
Section titled “5. Single Sign-On — LDAP, OIDC, Trusted Headers & Sync (32 keys)”| Canonical JSON Key | Environment Variables | Visibility | Default |
|---|---|---|---|
ssoLdapEnabled |
SSO_LDAP_ENABLED, LDAP_ENABLED |
internal |
false |
ssoLdapHost |
SSO_LDAP_HOST, LDAP_HOST |
internal |
"localhost" |
ssoLdapPort |
SSO_LDAP_PORT, LDAP_PORT |
internal |
nil (auto: 636 if SSL, 389 otherwise) |
ssoLdapUseSsl |
SSO_LDAP_USE_SSL, LDAP_USE_SSL |
internal |
true |
ssoLdapBaseDn |
SSO_LDAP_BASE_DN, LDAP_BASE_DN |
internal |
"" |
ssoLdapBindDn |
SSO_LDAP_BIND_DN, LDAP_BIND_DN |
internal |
"" |
ssoLdapBindPassword |
SSO_LDAP_BIND_PASSWORD, LDAP_BIND_PASSWORD, LDAP_PASSWORD |
secret |
"" |
ssoLdapUserFilter |
SSO_LDAP_USER_FILTER, LDAP_USER_FILTER |
internal |
"(uid={username})" |
ssoLdapGroupBaseDn |
SSO_LDAP_GROUP_BASE_DN, LDAP_GROUP_BASE_DN |
internal |
"" |
ssoLdapGroupFilter |
SSO_LDAP_GROUP_FILTER, LDAP_GROUP_FILTER |
internal |
"" |
ssoLdapTrustEmail |
SSO_LDAP_TRUST_EMAIL, LDAP_TRUST_EMAIL |
internal |
false |
ssoLdapUuidAttribute |
SSO_LDAP_UUID_ATTRIBUTE, LDAP_UUID_ATTRIBUTE |
internal |
"auto" |
ssoOidcEnabled |
SSO_OIDC_ENABLED, OIDC_ENABLED |
internal |
false |
ssoOidcProviderKey |
SSO_OIDC_PROVIDER_KEY, OIDC_PROVIDER_KEY |
internal |
"main" |
ssoOidcDisplayName |
SSO_OIDC_DISPLAY_NAME, OIDC_DISPLAY_NAME |
internal |
"Single Sign-On" |
ssoOidcIssuerUrl |
SSO_OIDC_ISSUER_URL, OIDC_ISSUER_URL |
internal |
"" |
ssoOidcClientId |
SSO_OIDC_CLIENT_ID, OIDC_CLIENT_ID |
internal |
"" |
ssoOidcClientSecret |
SSO_OIDC_CLIENT_SECRET, OIDC_CLIENT_SECRET |
secret |
"" |
ssoOidcScopes |
SSO_OIDC_SCOPES, OIDC_SCOPES |
internal |
"openid email profile" |
ssoOidcGroupsClaim |
SSO_OIDC_GROUPS_CLAIM, OIDC_GROUPS_CLAIM |
internal |
"groups" |
ssoHeaderEnabled |
SSO_HEADER_ENABLED, TRUSTED_HEADER_ENABLED |
internal |
false |
ssoHeaderEmail |
SSO_HEADER_EMAIL, TRUSTED_EMAIL_HEADER |
internal |
"" |
ssoHeaderName |
SSO_HEADER_NAME, TRUSTED_NAME_HEADER |
internal |
"" |
ssoHeaderGroups |
SSO_HEADER_GROUPS, TRUSTED_GROUPS_HEADER |
internal |
"" |
ssoHeaderRole |
SSO_HEADER_ROLE, TRUSTED_ROLE_HEADER |
internal |
"" |
ssoHeaderSecret |
SSO_HEADER_SECRET, TRUSTED_HEADER_SECRET, AUTH_TRUSTED_HEADER_SECRET |
secret |
"" |
ssoGroupImport |
SSO_GROUP_IMPORT |
internal |
false |
ssoGroupAutoMatch |
SSO_GROUP_AUTO_MATCH |
internal |
false |
ssoGroupPrefix |
SSO_GROUP_PREFIX |
internal |
"" |
ssoGroupMap |
SSO_GROUP_MAP |
internal |
"" |
ssoUserSync |
SSO_USER_SYNC |
internal |
false |
ssoAutoProvision |
SSO_AUTO_PROVISION |
internal |
true |
6. AI Assistant & Vector Embeddings (10 keys)
Section titled “6. AI Assistant & Vector Embeddings (10 keys)”| Canonical JSON Key | Environment Variables | Visibility | Default | Range / Notes |
|---|---|---|---|---|
aiEnabled |
AI_ENABLED |
internal |
true |
Enable Ask AI assistant (requires valid API URL/key) |
aiApiUrl |
AI_API_URL, AI_URL, OPENAI_BASE_URL |
internal |
"https://api.openai.com/v1/chat/completions" |
OpenAI-compatible chat endpoint |
aiApiKey |
AI_API_KEY, OPENAI_API_KEY |
secret |
"" |
Bearer API key |
aiModel |
AI_MODEL |
internal |
"gpt-4o-mini" |
Chat completion model ID |
aiMaxToolIterations |
AI_MAX_TOOL_ITERATIONS |
internal |
12 |
Range 1..50 |
aiEmbeddingEnabled |
AI_EMBEDDING_ENABLED, EMBEDDING_ENABLED |
internal |
true |
Enable pgvector semantic indexing |
aiEmbeddingUrl |
AI_EMBEDDING_URL, EMBEDDING_URL |
internal |
"http://localhost:8000" |
OpenAI-compatible embeddings endpoint |
aiEmbeddingApiKey |
AI_EMBEDDING_API_KEY, EMBEDDING_API_KEY |
secret |
"" |
Optional Bearer key for embeddings |
aiEmbeddingModel |
AI_EMBEDDING_MODEL, EMBEDDING_MODEL |
internal |
"jinaai/jina-clip-v2" |
Multimodal/text embedding model |
aiSemanticSearchThreshold |
AI_SEMANTIC_SEARCH_THRESHOLD, SEMANTIC_SEARCH_THRESHOLD |
internal |
0.75 |
Range 0.0..1.0 |
7. Rate Limiting (5 keys)
Section titled “7. Rate Limiting (5 keys)”| Canonical JSON Key | Environment Variables | Visibility | Default | Range |
|---|---|---|---|---|
rateLimitEnabled |
RATE_LIMIT_ENABLED |
internal |
true |
true / false |
rateLimitAuth |
RATE_LIMIT_AUTH |
internal |
10 req/min |
1..100000 |
rateLimitShare |
RATE_LIMIT_SHARE |
internal |
60 req/min |
1..100000 |
rateLimitApi |
RATE_LIMIT_API |
internal |
300 req/min |
1..100000 |
rateLimitAi |
RATE_LIMIT_AI, AI_RATE_LIMIT |
internal |
20 req/min |
1..1000 |
8. Mail / SMTP (7 keys)
Section titled “8. Mail / SMTP (7 keys)”| Canonical JSON Key | Environment Variables | Visibility | Default | Range / Notes |
|---|---|---|---|---|
mailSmtpHost |
MAIL_SMTP_HOST, SMTP_HOST |
internal |
"" |
Empty returns 503 in prod, logs in dev |
mailSmtpPort |
MAIL_SMTP_PORT, SMTP_PORT |
internal |
587 |
1..65535 |
mailSmtpUsername |
MAIL_SMTP_USERNAME, SMTP_USERNAME |
internal |
"" |
SMTP auth username |
mailSmtpPassword |
MAIL_SMTP_PASSWORD, SMTP_PASSWORD |
secret |
"" |
SMTP auth password |
mailSmtpEncryption |
MAIL_SMTP_ENCRYPTION, SMTP_ENCRYPTION |
internal |
"starttls" |
none, starttls, or ssl |
mailFromAddress |
MAIL_FROM_ADDRESS |
internal |
"" |
Sender email address |
mailFromName |
MAIL_FROM_NAME |
internal |
"" |
Sender display name |