# The following patch enables a conversion webhook for the CRD
apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
  name: k3sconfigs.bootstrap.cluster.x-k8s.io
spec:
  conversion:
    strategy: Webhook
    webhook:
      conversionReviewVersions: ["v1", "v1beta1"]
      clientConfig:
        # this is "\n" used as a placeholder, otherwise it will be rejected by the apiserver for being blank,
        # but we're going to set it later using the cert-manager (or potentially a patch if not using cert-manager)
        caBundle: Cg==
        service:
          namespace: system
          name: webhook-service
          path: /convert
