-
Notifications
You must be signed in to change notification settings - Fork 139
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Restrict tigera-operator secret access to namespace only #3630
Conversation
3feb8e6
to
046006e
Compare
c5e209c
to
34f0c59
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm
@@ -186,6 +186,8 @@ func (mc *monitorComponent) Objects() ([]client.Object, []client.Object) { | |||
render.CreateNamespace(common.TigeraPrometheusNamespace, mc.cfg.Installation.KubernetesProvider, render.PSSBaseline, mc.cfg.Installation.Azure), | |||
} | |||
|
|||
toCreate = append(toCreate, render.CreateOperatorSecretsRoleBinding(common.TigeraPrometheusNamespace)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
On line 239 we may be creating a secret for which the operator requires permissions. Should we render a binding in that namespace prior to rendering the secret?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
See the comment in monitor.go
…watch/list cluster-wide
34f0c59
to
5fd7a16
Compare
5fd7a16
to
ad4b1b3
Compare
/merge-when-ready |
OK, I will merge the pull request when it's ready, leave the commits as is when I merge it, and leave the branch after I've merged it. |
… only (#3653) * Restrict tigera-operator secret access to namespace only, retain get/watch/list cluster-wide * Add secrets rolebinding for external prometheus * Trigger Build
(Per pattern of tigera#3630) Also fix a log typo
(Per pattern of tigera#3630) Also fix a log typo
Restrict tigera-operator secret access to namespace only, retain get/list/watch cluster-wide
https://tigera.atlassian.net/browse/EV-5410
Tested external prometheus ,
bz addons run external-prometheus:setup
bz addons run wireguard:setup
External-prometheus E2E passed
Description
For PR author
make gen-files
make gen-versions
For PR reviewers
A note for code reviewers - all pull requests must have the following:
kind/bug
if this is a bugfix.kind/enhancement
if this is a a new feature.enterprise
if this PR applies to Calico Enterprise only.