G/co/crd/setup May 2026

kubectl apply -f my-resource-crd.yaml To follow the g/co/crd/setup pattern, you could wrap this in a script or Makefile:

Try building a simple controller (e.g., with Kubebuilder) that reacts to your new CRD. Have questions about CRD setup? Drop a comment below or reach out to our team. g/co/crd/setup

apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: name: databasebackups.stable.example.com spec: group: stable.example.com versions: - name: v1 served: true storage: true schema: openAPIV3Schema: type: object properties: spec: type: object properties: backupSchedule: type: string retentionDays: type: integer scope: Namespaced names: plural: databasebackups singular: databasebackup kind: DatabaseBackup shortNames: - dbb Use kubectl to apply your CRD: kubectl apply -f my-resource-crd

Now go ahead, create your first custom resource, and extend your cluster’s API with confidence. create your first custom resource