Skip to main content
Version: Next

ClusterBuildPlane

A ClusterBuildPlane is a cluster-scoped variant of BuildPlane that represents the infrastructure layer responsible for executing build workloads in OpenChoreo. Unlike the namespace-scoped BuildPlane, a ClusterBuildPlane is available across all namespaces, making it suitable for shared build infrastructure scenarios.

OpenChoreo uses agent-based communication where the control plane communicates with the build cluster through a WebSocket agent running in the ClusterBuildPlane cluster. The cluster agent establishes a secure WebSocket connection to the control plane's cluster gateway.

API Version​

openchoreo.dev/v1alpha1

Resource Definition​

Metadata​

ClusterBuildPlanes are cluster-scoped resources (no namespace).

apiVersion: openchoreo.dev/v1alpha1
kind: ClusterBuildPlane
metadata:
name: <clusterbuildplane-name>

Spec Fields​

FieldTypeRequiredDefaultDescription
planeIDstringNoCR nameIdentifies the logical plane this CR connects to. Must match clusterAgent.planeId Helm value.
clusterAgentClusterAgentConfigYes-Configuration for cluster agent-based communication
secretStoreRefSecretStoreRefNo-Reference to External Secrets Operator ClusterSecretStore in the ClusterBuildPlane
observabilityPlaneRefObservabilityPlaneRefNo-Reference to a ClusterObservabilityPlane resource for monitoring and logging

PlaneID​

The planeID identifies the logical plane this ClusterBuildPlane CR connects to. Multiple ClusterBuildPlane CRs can share the same planeID to connect to the same physical cluster while maintaining separate configurations.

Validation Rules:

  • Maximum length: 63 characters
  • Pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?$ (lowercase alphanumeric, hyphens allowed)
  • Examples: "shared-builder", "ci-cluster", "us-west-2"
PlaneID Consistency

The planeID in the ClusterBuildPlane CR must match the clusterAgent.planeId Helm value configured during build plane installation. If not specified, it defaults to the CR name for backwards compatibility.

ClusterAgentConfig​

Configuration for cluster agent-based communication with the build cluster. The cluster agent establishes a WebSocket connection to the control plane's cluster gateway.

FieldTypeRequiredDefaultDescription
clientCAValueFromYes-CA certificate to verify the agent's client certificate (base64-encoded PEM)

SecretStoreRef​

Reference to an External Secrets Operator ClusterSecretStore.

FieldTypeRequiredDefaultDescription
namestringYes-Name of the ClusterSecretStore in the ClusterBuildPlane

ObservabilityPlaneRef​

Reference to a ClusterObservabilityPlane for monitoring and logging.

FieldTypeRequiredDefaultDescription
kindstringNoClusterObservabilityPlaneMust be ClusterObservabilityPlane. ClusterBuildPlane can only reference cluster-scoped observability planes.
namestringYes-Name of the ClusterObservabilityPlane resource
Resolution Behavior
  • ClusterBuildPlane can only reference a ClusterObservabilityPlane (not a namespace-scoped ObservabilityPlane). This is enforced by API validation.
  • If observabilityPlaneRef is omitted, the controller attempts to find a ClusterObservabilityPlane named "default". If no default exists, observability is not configured.
  • If the referenced ClusterObservabilityPlane is not found, the controller returns an error and the ClusterBuildPlane will not become ready.

ValueFrom​

Common pattern for referencing secrets or providing inline values. Either secretRef or value should be specified.

FieldTypeRequiredDefaultDescription
secretRefSecretKeyReferenceNo-Reference to a secret key
valuestringNo-Inline value (not recommended for sensitive data)

SecretKeyReference​

Reference to a specific key in a Kubernetes secret.

FieldTypeRequiredDefaultDescription
namestringYes-Name of the secret
namespacestringNo*-Namespace of the secret (required for cluster-scoped resources)
keystringYes-Key within the secret

Status Fields​

FieldTypeDefaultDescription
observedGenerationinteger0The generation observed by the controller
conditions[]Condition[]Standard Kubernetes conditions tracking the ClusterBuildPlane state
agentConnectionAgentConnectionStatus-Tracks the status of cluster agent connections

AgentConnectionStatus​

FieldTypeDefaultDescription
connectedbooleanfalseWhether any cluster agent is currently connected
connectedAgentsinteger0Number of cluster agents currently connected
lastConnectedTimetimestamp-When an agent last successfully connected
lastDisconnectedTimetimestamp-When the last agent disconnected
lastHeartbeatTimetimestamp-When the control plane last received any communication from an agent
messagestring-Additional information about the agent connection status

Examples​

Basic ClusterBuildPlane Configuration​

This example shows a minimal ClusterBuildPlane configuration.

apiVersion: openchoreo.dev/v1alpha1
kind: ClusterBuildPlane
metadata:
name: shared-buildplane
spec:
planeID: "shared-builder"
clusterAgent:
clientCA:
secretRef:
name: buildplane-agent-ca
namespace: openchoreo-system
key: ca.crt

ClusterBuildPlane with Secret Store​

This example demonstrates using External Secrets Operator for managing secrets.

apiVersion: openchoreo.dev/v1alpha1
kind: ClusterBuildPlane
metadata:
name: secure-buildplane
spec:
planeID: "secure-builder"
clusterAgent:
clientCA:
secretRef:
name: agent-ca-cert
namespace: openchoreo-system
key: ca.crt
secretStoreRef:
name: vault-backend

ClusterBuildPlane with Observability​

This example shows a ClusterBuildPlane linked to a ClusterObservabilityPlane for monitoring build jobs.

apiVersion: openchoreo.dev/v1alpha1
kind: ClusterBuildPlane
metadata:
name: monitored-buildplane
spec:
planeID: "prod-ci"
clusterAgent:
clientCA:
secretRef:
name: buildplane-agent-ca
namespace: openchoreo-system
key: ca.crt
secretStoreRef:
name: default
observabilityPlaneRef:
kind: ClusterObservabilityPlane
name: production-observability

Annotations​

ClusterBuildPlanes support the following annotations:

AnnotationDescription
openchoreo.dev/display-nameHuman-readable name for UI display
openchoreo.dev/descriptionDetailed description of the ClusterBuildPlane