Documentation
¶
Overview ¶
Command chartpolicies generates the chart templates that ship the admission policies defined in Go.
Each policy is written once, as a Go value: the controller guards in internal/crdupgrade, the certificate rotator's Secret guard in internal/certrotation. The chart decides a handful of values in them when it renders a release -- the namespace and release name, the ServiceAccounts, the manager image, the controller-state version -- so a template cannot be a fixed document. The generator builds each policy with a sentinel in place of every such value and writes the Helm expression wherever a sentinel appears; everything else is copied out of the Go value as it is.
make chart-policies runs it. verify-source runs it too and refuses a template it did not write, the way it refuses a hand-edited CRD.