mirror of
https://github.com/kubernetes-sigs/kustomize.git
synced 2026-06-14 10:30:59 +00:00
Add Role / ClusterRole resourceNames to ConfigMap nameref resolver
While it is possible to use a kustomizeconfig.yml for this, with a custom namereference, this functionality should probably be built-in. This is similar to previous PRs, like this one: https://github.com/kubernetes-sigs/kustomize/pull/592
This commit is contained in:
@@ -217,6 +217,7 @@ func TestNameReferenceHappyRun(t *testing.T) {
|
|||||||
"secret1",
|
"secret1",
|
||||||
"secret1",
|
"secret1",
|
||||||
"secret2",
|
"secret2",
|
||||||
|
"cm1",
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
@@ -420,6 +421,7 @@ func TestNameReferenceHappyRun(t *testing.T) {
|
|||||||
"someprefix-secret1-somehash",
|
"someprefix-secret1-somehash",
|
||||||
"someprefix-secret1-somehash",
|
"someprefix-secret1-somehash",
|
||||||
"secret2",
|
"secret2",
|
||||||
|
"someprefix-cm1-somehash",
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -121,6 +121,10 @@ nameReference:
|
|||||||
kind: CronJob
|
kind: CronJob
|
||||||
- path: spec/configSource/configMap
|
- path: spec/configSource/configMap
|
||||||
kind: Node
|
kind: Node
|
||||||
|
- path: rules/resourceNames
|
||||||
|
kind: Role
|
||||||
|
- path: rules/resourceNames
|
||||||
|
kind: ClusterRole
|
||||||
|
|
||||||
- kind: Secret
|
- kind: Secret
|
||||||
version: v1
|
version: v1
|
||||||
|
|||||||
Reference in New Issue
Block a user