Configuration

Configure Kubey using environment variables.

Environment Variables

VariableDefaultDescription
PORT8080Port for the web server
HOST0.0.0.0Host to bind to
AUTH_MODEsingleAuthentication mode (single, shared, hybrid)
DATABASE_URLPostgreSQL connection string (required for shared mode)
JWT_SECRETSecret for JWT token signing
ENCRYPTION_KEYKey for encrypting stored kubeconfigs
KUBECONFIG~/.kube/configPath to kubeconfig file
LOG_LEVELinfoLogging level (debug, info, warn, error)
LICENSE_KEYLicense key for Pro/Hosted features (JWT)

Authentication Modes

Single Mode

No authentication required. Anyone with network access can use Kubey. Best for local development or internal networks.

AUTH_MODE=single

Shared Mode

Full multi-user support with OAuth. Requires PostgreSQL. Users authenticate and see clusters shared with them.

AUTH_MODE=shared
DATABASE_URL=postgres://user:pass@host:5432/kubey
JWT_SECRET=your-secret-key
GITHUB_CLIENT_ID=xxx
GITHUB_CLIENT_SECRET=xxx

Hybrid Mode

Like shared mode, but users can also see clusters from the mounted kubeconfig.

AUTH_MODE=hybrid

OAuth Configuration

GitHub

VariableDescription
GITHUB_CLIENT_IDGitHub OAuth App Client ID
GITHUB_CLIENT_SECRETGitHub OAuth App Client Secret

Google

VariableDescription
GOOGLE_CLIENT_IDGoogle OAuth Client ID
GOOGLE_CLIENT_SECRETGoogle OAuth Client Secret

Licensing

A license key is required to unlock Pro and Hosted features. After purchasing a subscription at kubey.app/pricing, you'll receive a license key via email.

Setting Your License Key

Pass the license key as an environment variable when running Kubey:

Dockerbash
docker run -e LICENSE_KEY="eyJ..." kubey/kubey
Docker Composebash
services:
  kubey:
    image: kubey/kubey
    environment:
      - LICENSE_KEY=eyJ...
Kubernetesbash
apiVersion: v1
kind: Secret
metadata:
  name: kubey-license
type: Opaque
stringData:
  LICENSE_KEY: "eyJ..."
---
apiVersion: apps/v1
kind: Deployment
spec:
  template:
    spec:
      containers:
      - name: kubey
        envFrom:
        - secretRef:
            name: kubey-license

License Tiers

TierClustersFeatures
FreeUp to 6Basic monitoring
ProUnlimitedOAuth, Admin Panel
HostedUnlimitedOAuth, Admin Panel
EnterpriseUnlimitedOAuth, Admin Panel, SSO, Audit Logs

License keys are valid for one year from purchase and automatically renew with your subscription. Your current license status can be viewed in the Admin Panel under Settings.

Admin Settings

These settings can be configured through the Admin Panel UI:

  • Allowed Domains — Restrict sign-ups to specific email domains (e.g., @yourcompany.com)
  • Invite Only — Disable self-registration, only invited users can sign up
  • Cluster Sharing — Share clusters between users

Example Configuration

.envbash
# Server
PORT=8080
HOST=0.0.0.0
LOG_LEVEL=info

# Authentication
AUTH_MODE=shared
JWT_SECRET=change-me-to-a-secure-random-string
ENCRYPTION_KEY=change-me-to-another-secure-string

# Database
DATABASE_URL=postgres://kubey:kubey@localhost:5432/kubey?sslmode=disable

# OAuth - GitHub
GITHUB_CLIENT_ID=your_github_client_id
GITHUB_CLIENT_SECRET=your_github_client_secret

# OAuth - Google (optional)
GOOGLE_CLIENT_ID=your_google_client_id
GOOGLE_CLIENT_SECRET=your_google_client_secret

# Kubernetes (optional, defaults to ~/.kube/config)
KUBECONFIG=/path/to/your/kubeconfig