mirror of
https://github.com/kubernetes-sigs/kustomize.git
synced 2026-06-13 18:10:59 +00:00
helper methods, types, and unit tests for transformer annotations
This commit is contained in:
@@ -497,7 +497,7 @@ func (kt *KustTarget) accumulateFile(
|
||||
if err != nil {
|
||||
return errors.Wrapf(err, "cannot add path annotation for '%s'", path)
|
||||
}
|
||||
err = resources.AnnotateAll(utils.OriginAnnotation, originAnno)
|
||||
err = resources.AnnotateAll(utils.OriginAnnotationKey, originAnno)
|
||||
if err != nil || originAnno == "" {
|
||||
return errors.Wrapf(err, "cannot add path annotation for '%s'", path)
|
||||
}
|
||||
|
||||
@@ -3,6 +3,7 @@ package utils
|
||||
import "sigs.k8s.io/kustomize/api/konfig"
|
||||
|
||||
const (
|
||||
// build annotations
|
||||
BuildAnnotationPreviousKinds = konfig.ConfigAnnoDomain + "/previousKinds"
|
||||
BuildAnnotationPreviousNames = konfig.ConfigAnnoDomain + "/previousNames"
|
||||
BuildAnnotationPrefixes = konfig.ConfigAnnoDomain + "/prefixes"
|
||||
@@ -17,7 +18,9 @@ const (
|
||||
BuildAnnotationAllowNameChange = konfig.ConfigAnnoDomain + "/allowNameChange"
|
||||
BuildAnnotationAllowKindChange = konfig.ConfigAnnoDomain + "/allowKindChange"
|
||||
|
||||
OriginAnnotation = "config.kubernetes.io/origin"
|
||||
// for keeping track of origin and transformer data
|
||||
OriginAnnotationKey = "config.kubernetes.io/origin"
|
||||
TransformerAnnotationKey = "config.kubernetes.io/transformations"
|
||||
|
||||
Enabled = "enabled"
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user