Skip to main content
Dorgu extends Kubernetes with five Custom Resource Definitions (CRDs) that capture application identity, cluster context, and the self-healing record. These CRDs are the central data model that connects the CLI, Operator, and integrations — and they mean your incident history and remediation record live in your own cluster, not a vendor’s database.

CRD Overview

The primary CRD is ApplicationPersona, which describes a single application’s desired operational profile and the Operator’s observed state. ClusterPersona captures cluster-level context. The remaining three are the self-healing loop’s memory — see Self-healing.

Ownership Model

The spec and status of an ApplicationPersona are owned by different actors. This separation is fundamental to Dorgu’s design. The CLI and GitOps tools define the desired state in the spec. The Operator observes the cluster and writes its findings to the status. The one exception is remediation: when you approve a RemediationAction, the Operator applies that action’s JSON merge patch to the ApplicationPersona spec. That is a change you explicitly authorized, scoped to the fields in the proposal you reviewed. Nothing else lets the Operator write a spec.
The Operator never creates or modifies Deployments, Services, or any other workload resource — with or without approval. Applying workload changes stays with the CLI, ArgoCD, Flux, or kubectl. See the trust model.
If you manage personas through GitOps, an approved remediation’s patch will show as drift on the next sync — mirror the change back into your repo so your pipeline does not revert the fix. dorgu remediation approve --no-heal does not avoid this: it skips the Deployment patch only, and the persona is still updated by the Operator once the action is Approved.

API Group and Scope

All CRDs belong to the dorgu.io/v1 API group. ApplicationPersonas live in the same namespace as the workloads they describe. ClusterPersona is cluster-scoped since it represents the entire cluster.

ApplicationPersona Spec Fields

The spec defines the desired operational profile for an application.

ApplicationPersona Status Fields

The status is populated entirely by the Operator and reflects the observed state of the application.

Full ApplicationPersona Example

A complete ApplicationPersona for a critical API service:

ClusterPersona

ClusterPersona is a cluster-scoped resource that captures the overall cluster context. The Operator’s ClusterPersona controller automatically discovers and populates its status.

ClusterPersona Spec Fields

ClusterPersona Status Fields

The ClusterPersona controller reconciles every 5 minutes, scanning nodes, namespaces, and well-known add-on namespaces to keep the status current.

Self-healing policy

spec.policies.selfHealing configures how the cluster heals.
mode is enforced by the proposer: observe records the incident and proposes nothing, propose proposes with approval required, and auto-approve is not implemented — it is accepted but degraded to propose with a warning. maxRemediationsPerHour and excludeNamespaces are enforced by the safety checker. enabled and trustLevel are not enforced: trustLevel is only fed to the AI planner as context, and detection/diagnosis/proposal run regardless of enabled — use mode: observe to stop at diagnosis. The operator’s auto-created persona uses mode: propose.

IncidentMemory

IncidentMemory is the record of a detected problem: what was seen, what caused it, and how it ended. It is created and maintained by the operator’s health-check reconciler. Read them with dorgu incidents.

Spec Fields

rootCause.provider is rule-based or ai-enhanced. resolution.outcome is resolved, partial, failed, or rollback — written by the remediation controller when the loop finishes.

Status Fields

An incident auto-resolves once its signal has been absent for 5 minutes.

RemediationAction

RemediationAction is a proposed fix. The operator creates it, you approve or reject it, and the operator records what happened. Work with them via dorgu remediation.

Spec Fields

action.type is one of persona-update, notification, or git-pr. action.patch is a JSON merge patch applied to the Persona spec — never to a workload.

Step Fields

Each entry in steps[]:
autoExecutable may only be true on a persona-update step. This is enforced at the Kubernetes API server by a CEL validation rule on the CRD (!self.autoExecutable || self.type == 'persona-update'), not just in operator code. Every other step type is advisory, which is what preserves the operator’s guarantee that it never writes workloads.

Status Fields

steps[] is populated, validated, and rendered by the CLI, and currentStep / stepStatuses[] exist in the schema — but the controller currently executes the single spec.action patch rather than walking the plan step by step. autoApproveRule is likewise present in the CRD and ignored by controllers: auto-approve graduation is not implemented.

DorguEvent

DorguEvent is a write-once, classified Kubernetes event record with TTL-based cleanup. The event pipeline watches core Kubernetes events, classifies them by severity and category, correlates them to a persona and incident where it can, and stores them. There is no status subresource — the record is immutable. Stream them live with dorgu watch events.