Running Ipseity under Orbit Deploy

This is the recommended way to run Ipseity at scale. Ipseity is deployed by Orbit Deploy against an Internet-scale cluster. The deployment manifests live in this repo's orbit-deployment/default/ and are reconciled from the tak-os-orbit-deployments/ipseity deployment repository.

What Orbit Deploy provides

  • A two- or multi-replica Deployment of the ipseity container.
  • A Service and an Ingress (TLS via cert-manager, nginx ingress) exposing https://ipseity.<domain>/.
  • The ClusterRole/ClusterRoleBinding that lets Ipseity read and write its ConfigMap/Secret/namespace state (realm discovery and per-realm data).
  • A Secret of SMTP credentials (TurboSMTP) wired into the Deployment's env so email verification works.

Files in orbit-deployment/default

File Objects
010-rbac.yaml Namespace ipseity, ServiceAccount ipseity (in kube-system), ClusterRole ipseity (get/list/watch/create/update/patch/delete on namespaces, configmaps, secrets), ClusterRoleBinding.
030-deployments.yaml Deployment ipseity (replicas 2, rolling update, readiness + liveness on /healthz, non-root via the image default).
040-services.yaml Service ipseity (port 8080).
050-ingress.yaml Ingress ipseity for ipseity.<domain>, TLS via cert-manager.
100-ESO-turboSMTP.yaml An ExternalSecret (External Secrets Operator) fetching TurboSMTP credentials into turbo-smtp-credentials, referenced by the Deployment env.
999-orbit-deploy.yaml The OrbitDeployment CRD instance represely managing the whole set.
deployment.json Image pinning: images.ipseity = the container tag (e.g. 1.10.0).

The Deployment sets these env vars:

  • IPSEITY_HOST=0.0.0.0, IPSEITY_PORT=8080, IPSEITY_NAMESPACE=ipseity, IPSEITY_LABEL_APP=ipseity, IPSEITY_LABEL_MANAGED_BY=ipseity.
  • IPSEITY_OIDC_ISSUER=https://ipseity.<domain>/oidc so the public issuer, discovery document and JWKS URLs match the ingress host.
  • SMTP: IPSEITY_SMTP_HOST/PORT/USERNAME/PASSWORD from the turbo-smtp-credentials Secret, plus IPSEITY_SMTP_FROM/FROM_NAME.

Audit collection and session cleanup

Collect container stdout from every Ipseity replica with the platform's Loki collector. Audit events start with AUDIT and contain a single JSON object including the realm, actor, outcome and event details. /healthz reports "audit": "stdout". Configure retention in Loki; IPSEITY_AUDIT_MAX_EVENTS only controls the recent per-process API cache. See monitoring for log queries and migration from audit ConfigMaps.

Refresh-token cleanup runs automatically on startup and every five minutes across all realms. No CronJob or extra RBAC is required. Consumed/revoked tokens are deleted immediately; active sessions retain their configured lifetime.

Deploying an update

  1. Run the full test suite: python3 -m unittest discover -s tests.
  2. Tag a release and push (this repository's release process).
  3. In the deployment repo, bump deployment.json → images.ipseity to the new tag and push the manifests. Orbit Deploy applies them (image pull, rolling update).
  4. If the SMTP credentials or ingress settings change, update the manifests (not the code).

Multi-realm under Orbit Deploy

Realms are Kubernetes namespaces carrying the IPSEITY_REALM_LABEL label (default ipseity.io/realm); the ClusterRole above grants what realm discovery + create/delete need. Super principals manage realms from the console Realms page or /api/realms. A realm's namespace may be shared with the user's own applications — Ipseity stores its data and Secrets beside them.

Tenant admins and users open https://ipseity.<domain>/realms/<realm-name>. Root and /realms/ipseity open the main realm with the default namespace. Each realm's console client is provisioned automatically, including during upgrades of existing realms. The catch-all ingress must forward /realms/ without path rewriting; no per-realm Ingress or Service is required. New tenant admins can be seeded through GitOps or created by a main super admin, then manage only their own realm. See console access for session and privacy details.

Production certs and private keys

Ipseity provisions three secret-bearing Kubernetes Secrets on first start when Kubernetes is available:

  • ipseity-oidc-signing-key (per-realm RS256 key; data private.pem, retired private.<kid>.pem),
  • ipseity-encryption-key (data encryption.key), and
  • per-realm signing secrets ipseity-oidc-signing-key-ipseity-<realm> in the corresponding realm namespaces.

For CI/GitOps workflows (External Secrets Operator), you may pre-provision these instead of relying on auto-creation. See kubernetes-resources.md and bootstrap-and-gitops.md.