hull controller crd

Synopsis

hull controller crd prints the HullRelease CustomResourceDefinition as YAML to stdout. This is the exact definition the controller reconciles, and the same YAML that controller install-crd applies — this command only prints it, it never touches the cluster.

When to use it

  • To read the CRD schema before you register it.
  • To commit the CRD into a GitOps repo so your delivery tool applies it.
  • To pipe it into kubectl from a machine that has hull but where you’d rather apply through your own tooling.

What happens

  1. Hull writes the embedded CRD definition (group hull.dev, kind HullRelease) to stdout.
  2. Nothing else — no cluster contact, no files written, exit 0.

Usage

hull controller crd

Flags

Inherits the global flags.

Flag Type Default Description
--debug print debug output while running
--kube-context string (current) Kubernetes context to use
--kubeconfig string (default) path to the kubeconfig file
-n, --namespace string Kubernetes namespace

(This command reads none of them; they are accepted because every hull command carries them.)

Worked example

Print the CRD and save it for review:

hull controller crd > hullrelease-crd.yaml

Output (hullrelease-crd.yaml):

apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
  name: hullreleases.hull.dev
spec:
  group: hull.dev
  scope: Namespaced
  names:
    plural: hullreleases
    singular: hullrelease
    kind: HullRelease
    shortNames: [hr]
  versions:
    - name: v1
      served: true
      storage: true
      subresources:
        status: {}
      schema:
        openAPIV3Schema:
          type: object
          properties:
            spec:
              type: object
              required: [package]
              properties:
                releaseName: { type: string }
                package:     { type: string }
                version:     { type: string }
                profile:     { type: string }
                values:
                  type: object
                  x-kubernetes-preserve-unknown-fields: true
            status:
              type: object
              properties:
                phase:          { type: string }
                message:        { type: string }
                revision:       { type: integer }
                lastTransition: { type: string }

Apply it through kubectl instead of install-crd:

hull controller crd | kubectl apply -f -

See also