Annotation based selector
mhkarimi1383 opened this issue · 0 comments
mhkarimi1383 commented
I want to select Secret
and ConfigMap
based on their annotations
Is your feature request related to a problem? Please describe.
If I select all of the ConfigMap
s and handle my job by an if
that compares annotations I have to handle lots of resources and that's not efficient.
Describe the solution you'd like to see
Extra field for annotation selector that will do something like this
but instead of returning some values return all of them
kubectl get service -A -o jsonpath='{range .items[?(@.metadata.annotations.prometheus\.io/scrape=="true")]}{ .metadata.namespace },{ .metadata.name}{"\n"}{end}'
Describe alternatives you've considered
Watching for all of them, select them if annotation set by using if
Additional context