Skip to main content

Set up the file

For Docker Compose, put server settings in .env beside your Compose file. Start with the complete installation guide, then use this page to add optional features. For the sample environment file, see the example .env file.

Core configuration

General URLs

For the bundled image, set KANEO_CLIENT_URL and leave KANEO_API_URL unset. The API URL defaults to your client URL plus /api. Set both explicitly only for a separate API deployment or a different proxy path. The web container embeds only KANEO_API_URL, KANEO_CLIENT_URL, and KANEO_TURNSTILE_SITE_KEY into browser assets at startup. These values are public; other KANEO_* variables are not substituted into frontend files. Values are encoded as JavaScript strings. The standalone web image serves its generated MCP discovery documents as JSON files, without modifying the nginx configuration. Configure actual public service URLs; escaping a value does not make an invalid URL usable. Recreate the container when changing its environment.

Database

The bundled Compose setup derives its database connection from POSTGRES_*. Set DATABASE_URL when using an external database; it takes precedence. The API needs a server-reachable database address, not a browser URL.

Authentication

Keep AUTH_SECRET stable across restarts and include it in your protected configuration backup. The bundled image can generate a temporary secret if it is unset; a host-native API requires you to provide one. The Docker Compose quick-start pins image 2.28.3, which predates _FILE support. Raise KANEO_IMAGE_TAG to a release containing this feature before following Keep secrets in files. For the supported _FILE variables, a non-empty direct value takes precedence. Kaneo removes trailing line endings from secret files but keeps other whitespace. Missing, unreadable, or empty files fail startup instead of silently using a fallback. Secrets are read at startup; restart Kaneo after rotating a file. DATABASE_URL takes precedence over both PostgreSQL password variables.

Optional variables

MCP

Object Storage

Kaneo uses S3-compatible object storage for private uploads in task descriptions and task comments. For self-hosted storage, follow the Silo setup. For managed storage, see AWS S3 and other providers. The endpoint must be reachable by both the API and the browser.

Access Control

Browser WebSocket connections require an exact origin matching KANEO_CLIENT_URL, KANEO_API_URL, or a comma-separated CORS_ORIGINS entry. Wildcards, null, and missing browser origins are rejected. Production deployments must configure their public URLs. Native clients without an Origin header must provide a valid bearer token or API key; cookies alone are not sufficient. Both real-time endpoints accept only the small {"type":"ping"} text keepalive, with a 64-byte message limit.
Before enabling SSO-only access with DISABLE_LOGIN_FORM=true or CUSTOM_OAUTH_AUTO_LOGIN=true on an existing installation, make sure existing local accounts have verified email addresses. OAuth/OIDC identities cannot be linked to an unverified local account, and affected users will receive error=account_not_linked. Keep the login form available until those users have signed in with an email OTP or magic link. If SSO-only access is already enabled, temporarily set both options to false, recreate the Kaneo container, and let affected users complete an email sign-in before restoring the SSO-only settings.

Proxies

Only list addresses you control. Any host in this range can set X-Forwarded-For and have it believed, so do not include a range that clients can reach Kaneo from directly. The client IP is used for rate limiting and session records.

Notifications

Imports

The in-app importer reads from the source on the API server. Sources on a private network, such as a PLANKA container in the same Docker network, also need KANEO_ALLOW_PRIVATE_WEBHOOK_DESTINATIONS=true (see Notifications).

GitHub SSO

Sign in with GitHub uses a GitHub OAuth App. Set GITHUB_OAUTH_CLIENT_ID and GITHUB_OAUTH_CLIENT_SECRET (or rely on the legacy variables below).

GitHub integration

Repository sync and webhooks use a GitHub App. These variables do not enable GitHub sign-in; configure GitHub SSO separately if you want both.

Google SSO

Discord SSO

Custom OAuth/OIDC

Redis

Kaneo supports Redis for horizontal scaling of WebSocket broadcasts. When any Redis mode is configured, multiple API instances can relay real-time updates via Redis Pub/Sub. When none are set, an in-memory adapter is used (single-instance only). Three deployment modes are supported: Standalone, Sentinel, and Cluster. Only one mode should be configured at a time. If multiple are set, the priority is: Cluster > Sentinel > Standalone.

Standalone (single server)

Sentinel (high-availability with automatic failover)

Cluster (horizontal sharding)

Shared (used by Sentinel and Cluster modes)

SMTP Configuration

When upgrading, remove SMTP_IGNORE_TLS=true and verify delivery with the corrected certificate trust configuration before rollout. Fix invalid certificates instead of disabling validation. Nodemailer documents the difference between STARTTLS and certificate validation.

Key points

  • If you enable GitHub SSO, create a GitHub OAuth App in GitHub Developer Settings and set GITHUB_OAUTH_CLIENT_ID / GITHUB_OAUTH_CLIENT_SECRET (or the legacy GITHUB_CLIENT_* variables). See the GitHub SSO guide.
  • If you use the GitHub repository integration, configure a GitHub App and set the integration variables in GitHub integration. See the GitHub integration configuration guide.
  • If you enable Google SSO, you need to set up the Google app which is used to authenticate users in the Google Cloud Console. See the Google SSO guide.
  • If you enable Discord SSO, you need to set up the Discord application which is used to authenticate users in the Discord Developer Portal. See the Discord SSO guide.
  • If you enable Custom OAuth/OIDC, you need to configure your identity provider with the appropriate redirect URI. See the Custom OAuth/OIDC guide.
  • If you have enabled SMTP, sign-in uses email verification codes by default. Set DISABLE_EMAIL_OTP_SIGN_IN=true to use email/password sign-in instead. The password form includes Forgot password?, which emails a single-use reset link valid for one hour. Resetting a password revokes existing sessions. Password reset requires SMTP and is unavailable when DISABLE_LOGIN_FORM=true.
  • If you need device authorization for clients beyond the defaults (kaneo-cli, kaneo-mcp when DEVICE_AUTH_CLIENT_IDS is unset), set DEVICE_AUTH_CLIENT_IDS to the full comma-separated list of trusted client IDs for your deployment.

Authentication CAPTCHA

When TURNSTILE_SECRET_KEY is configured on the API, set the matching public KANEO_TURNSTILE_SITE_KEY on the bundled container or standalone web container. For local Vite development, use VITE_TURNSTILE_SITE_KEY in apps/web/.env.local instead. The API validates the token at password signup, social/OIDC initiation, guest sign-in, OTP sending (including resend), magic-link initiation, and password-reset requests. Tokens are single-use; clients must obtain a fresh token for each attempt. OAuth callbacks and OTP redemption validate their own state/code and do not redeem the CAPTCHA token again. The widget uses the action auth. The API requires that action and the exact frontend hostname from KANEO_CLIENT_URL, and rejects verification failures, redirects and timeouts. Update the API and web app together when adopting this check. Custom clients must include the token in the x-turnstile-token header. Automatic OIDC redirection pauses at the sign-in page when a CAPTCHA widget is configured so the user can complete it. No secret configured means CAPTCHA is disabled, as on self-hosted instances that opt out. This does not bypass registration or guest-access restrictions.

Error reporting

API reporting is opt-in. Leave SENTRY_DSN unset to disable it. The browser reads VITE_SENTRY_DSN when it is built. The current web container renderer does not replace KANEO_SENTRY_DSN at startup, so setting that variable on a running container does not enable browser reporting.

Cloud mode

KANEO_CLOUD=true enables hosted-service behavior, including cloud billing and additional signup and invitation restrictions. Leave it unset for a normal self-hosted instance. CAPTCHA is controlled by TURNSTILE_SECRET_KEY independently of this flag.