This example shows how the [annotate-apply-time-mutations] function works.
Running annotate-apply-time-mutations function on the example package will:
- Set
config.k8s.io/apply-time-mutationannotation on resources generated from anApplyTimeMutationresource object.
Get the example package by running the following commands:
kpt pkg get https://github.com/kptdev/krm-functions-catalog.git/contrib/examples/annotate-apply-time-mutations-custom-resourceInvoke the function with the following command:
kpt fn eval annotate-apply-time-mutations-custom-resource --image ghcr.io/kptdev/krm-functions-catalog/krm-fn-contrib/annotate-apply-time-mutations:latest- File resources.yaml will include
config.k8s.io/apply-time-mutationannotation matching the mutation spec.
[annotate-apply-time-mutations] https://catalog.kpt.dev/annotate-apply-time-mutations/v0.1/?id=definitions