Install · v2.0.0 · AGPL-3.0-only

Run it on machines you already operate.

OpsKnight Community is self-hosted. Compose is the shortest path. Helm is the production path. After boot, open port 3000 and create the first admin on /setup. Full steps live in the docs — this page is the operational checklist.

Prerequisites

  • Docker Engine 20+ and Compose 2+, or a Kubernetes 1.24+ cluster
  • PostgreSQL 14+ (Compose automatically provisions PostgreSQL 15)
  • NEXTAUTH_SECRET, ENCRYPTION_KEY, and API_KEY_SECRET configured before first start
  • A stable HTTPS reverse proxy in production (for auth callbacks and webhook ingestion)
First-Boot SecretsRequired
NEXTAUTH_SECRET

Generating...

ENCRYPTION_KEY

Generating...

API_KEY_SECRET

Generating...

PostgreSQL 14+ is required (bundled in Compose).

Docker Compose (Recommended Starter)

Clone the repository, copy env.example to .env, inject your generated secrets, and launch the stack:

compose

git clone https://github.com/opsknight-labs/OpsKnight.git
cd OpsKnight
cp env.example .env
# Set NEXTAUTH_SECRET, ENCRYPTION_KEY, and API_KEY_SECRET in .env
docker compose -f deploy/compose/docker-compose.yml up -d

Then navigate to http://localhost:3000/setup to initialize the primary administrator account.

Docker Compose deployment guide →

Docker Swarm (Multi-Node HA)

Native multi-node Swarm deployment with automated Raft-encrypted secrets, rolling zero-downtime updates, and isolated worker lanes:

swarm

git clone https://github.com/opsknight-labs/OpsKnight.git
cd OpsKnight/deploy/swarm
# Initialize Docker Swarm (if not already active)
docker swarm init
# Deploy multi-node HA cluster with automatic Raft secrets & validation
./scripts/deploy.sh

Docker Swarm operations & secrets guide →

Split Production Runtime (v2.0)

For high-throughput installations, OpsKnight separates Web, Scheduler, General Worker, Critical Worker, Bulk Worker, and Status Projector into independently scalable containers:

split-compose

cp env.example .env
# Set NEXTAUTH_SECRET, ENCRYPTION_KEY, and API_KEY_SECRET in .env
export OPSKNIGHT_IMAGE="ghcr.io/opsknight-labs/opsknight:2.0.0"

# Deploy 6 dedicated split roles + migration runner
docker compose \
  -f deploy/compose/docker-compose.yml \
  -f deploy/compose/docker-compose.split.yml \
  up -d

Split runtime architecture & worker tuning →

Kubernetes (Helm Chart)

For versioned, repeatable Kubernetes deployments with Horizontal Pod Autoscaling (HPA), Ingress TLS, and Enterprise HA:

helm

# 1. Create namespace & production secrets
kubectl create namespace opsknight
kubectl -n opsknight create secret generic opsknight-secrets \
  --from-literal=DATABASE_URL='postgresql://opsknight:<password>@postgres:5432/opsknight?sslmode=require&connection_limit=20' \
  --from-literal=DIRECT_DATABASE_URL='postgresql://opsknight:<password>@postgres:5432/opsknight?sslmode=require&connection_limit=5' \
  --from-literal=NEXTAUTH_SECRET="$(openssl rand -base64 32)" \
  --from-literal=ENCRYPTION_KEY="$(openssl rand -hex 32)" \
  --from-literal=API_KEY_SECRET="$(openssl rand -base64 32)"

# 2. Deploy OpsKnight Helm Chart with Enterprise HA values
helm upgrade --install opsknight deploy/kubernetes/helm/opsknight \
  --namespace opsknight \
  -f deploy/kubernetes/helm/opsknight/examples/values-enterprise-ha.yaml

Helm configuration & values.yaml guide →

Other Supported Topologies

  • · Kustomize & GitOps:Declarative base and overlay manifests designed for ArgoCD and Flux pipelines. Kustomize guide
  • · PgBouncer & External Postgres:Connection-pool overlays (`docker-compose.pgbouncer.yml`) for high concurrency. Capacity & deployment guide
  • · Cloud & Serverless Containers:Deploy to AWS ECS / Fargate with RDS PostgreSQL, or GCP Cloud Run with Cloud SQL. Cloud container deployment
  • · Upgrading from 1.x:Database migrations, env variable updates, and rollback procedure for existing 1.x installs. Migration from v1 guide

Hardware Sizing Matrix

Recommended capacity for OpsKnight and PostgreSQL based on monthly alert volume:

TierAlert VolumeComputeTopology
Starter / Eval< 10k / mo1 vCPU · 1 GB RAMIntegrated Compose ($5 VPS)
Team / Growth10k – 100k / mo2 vCPU · 2 GB RAMSplit Compose or Docker Swarm
Enterprise scale100k+ / mo4+ vCPU · 4–8 GBHelm / Kustomize Split + PgBouncer

Community and commercial boundary

This page installs the self-hosted OpsKnight Community application under AGPL-3.0-only. Separately licensed Enterprise modules, support, or hosted offerings may be documented and packaged independently. Check the current release documentation for exact Community feature availability and limits. The canonical installation reference is the quickstart guide.