emberstack / kubernetes-reflector

Custom Kubernetes controller that can be used to replicate secrets, configmaps and certificates.
MIT License
1.11k stars 96 forks source link

possible to use wildcard? #444

Closed dberardo-com closed 5 months ago

dberardo-com commented 5 months ago

is it possible to enable auto reflection in all namespaces matching a pattern? such as:

reflector.v1.k8s.emberstack.com/reflection-auto-namespaces: "important-guy-*"

to match all of "important-guy-robert","important-guy-max", etc ... ?

winromulus commented 5 months ago

@dberardo-com Use regex for allowed namespaces. This is more flexible than plain wildcards.

dberardo-com commented 5 months ago

i see, so you are saying to use:

reflector.v1.k8s.emberstack.com/reflection-allowed: "true"
reflector.v1.k8s.emberstack.com/reflection-auto-enabled: "true"
reflector.v1.k8s.emberstack.com/reflection-allowed-namespaces: "important-guy-*"

?

and is it regex or simple wildcard ?

winromulus commented 5 months ago

@dberardo-com It's RegEx. Please have a look at the readme