Skip to main content
Version: 3.0.0

Values Injection & Pausing

The Composition Dynamic Controller (CDC) automatically injects metadata and operational flags into the Helm chart values and resource labels. This enables charts to be "Krateo-aware."

Injected Metadata​

When the CDC reconciles a Composition, it injects the following values into the Helm release (.Values.global) and resource labels:

Helm Value (global.*)Resource Label (krateo.io/*)Description
compositionIdcomposition-idUnique UID of the Composition resource.
compositionNamecomposition-nameName of the Composition resource.
compositionNamespacecomposition-namespaceNamespace of the Composition resource.
compositionInstalledVersioncomposition-installed-versionCurrent version of the chart installed.
compositionGroupcomposition-groupAPI Group of the Composition.
compositionResourcecomposition-resourcePlural name of the resource.
compositionKindcomposition-kindKind of the resource.
krateoNamespacekrateo-namespaceNamespace where Krateo is installed.
gracefullyPausedNot injected as labelBoolean indicating if the stack should pause.

Graceful Pausing​

Krateo supports two ways to pause reconciliation, depending on whether you want to pause just the controller or the entire application stack.

1. Immediate Pause (krateo.io/paused)​

Setting this annotation to "true" on a Composition resource causes the CDC to stop reconciliation immediately. No further changes will be applied to the cluster until the annotation is removed.

2. Graceful Pause (krateo.io/gracefully-paused)​

Setting this annotation to "true" triggers a coordinated pause across the entire stack:

  1. Trigger: You set the annotation on the Composition.
  2. Injection: The CDC performs one final Helm upgrade, setting .Values.global.gracefullyPaused to true.
  3. Propagation: Resources within the chart (like other Krateo providers) can use this value to pause themselves.
  4. Activation: The CDC only stops its own reconciliation after the Helm upgrade is successful.

Template Example​

To make a resource within your chart respect the graceful pause:

apiVersion: git.krateo.io/v1alpha1
kind: Repo
metadata:
name: {{ include "my-app.fullname" . }}-repo
annotations:
# This will pause the Repo provider when the Composition is gracefully paused
krateo.io/paused: "{{ default false (and .Values.global .Values.global.gracefullyPaused) }}"

Comparison Summary​

Featurekrateo.io/pausedkrateo.io/gracefully-paused
ScopeComposition controller onlyComposition + all chart resources
TimingImmediateAfter the next successful Helm upgrade
Best ForEmergency debuggingScheduled maintenance of full stacks