-
Notifications
You must be signed in to change notification settings - Fork 30
Restrict cluster role of the amazon cloudwatch agent controller manager #83
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
Changes from 5 commits
41dfee2
ebbee7d
22f94d7
91bb1c5
26ae844
b1d5f30
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,7 +5,11 @@ metadata: | |
rules: | ||
- apiGroups: [ "" ] | ||
resources: [ "configmaps" ] | ||
verbs: [ "create", "delete", "get", "list", "patch", "update", "watch" ] | ||
verbs: [ "create", "delete", "get", "list", "watch" ] | ||
- apiGroups: [ "" ] | ||
resources: [ "configmaps" ] | ||
resourceNames: ["cloudwatch-agent", "cloudwatch-agent-windows", "cwagent-clusterleader", "dcgm-exporter-config-map", "fluent-bit-config", "fluent-bit-windows-config", "neuron-monitor-config-map", "kube-root-ca.crt"] | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Restricting these by names is going to be tricky. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Also, curious, why do we need the There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. yeah, I was hoping there would be a way to do this by namespace, but it doesn't seem like thats possible. What if we pull the actual names from the values.yaml?
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
In the scenario of customers installing their own CRs, it wouldnt come from the values. But perhaps thats just setting an expectation that they have to modify the RBAC accordingly when they do such customizations. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Interesting. Is it actually created/modified by our service account though? |
||
verbs: [ "patch", "update" ] | ||
- apiGroups: [ "" ] | ||
resources: [ "events" ] | ||
verbs: [ "create", "patch" ] | ||
|
@@ -14,10 +18,18 @@ rules: | |
verbs: [ "get","list","patch","update","watch" ] | ||
- apiGroups: [ "" ] | ||
resources: [ "serviceaccounts" ] | ||
verbs: [ "create","delete","get","list","patch","update","watch" ] | ||
verbs: [ "create","delete", "get", "list", "watch" ] | ||
- apiGroups: [ "" ] | ||
resources: [ "serviceaccounts" ] | ||
resourceNames: [ "amazon-cloudwatch-observability-controller-manager", "cloudwatch-agent", "dcgm-exporter-service-acct", "neuron-monitor-service-acct"] | ||
verbs: ["patch","update" ] | ||
- apiGroups: [ "" ] | ||
resources: [ "services" ] | ||
verbs: [ "create","delete","get","list","patch","update","watch" ] | ||
verbs: [ "create","delete","get","list","watch" ] | ||
- apiGroups: [ "" ] | ||
resources: [ "services" ] | ||
resourceNames: [ "amazon-cloudwatch-observability-webhook-service", "cloudwatch-agent", "cloudwatch-agent-headless", "cloudwatch-agent-monitoring", "cloudwatch-agent-windows", "cloudwatch-agent-windows-headless", "cloudwatch-agent-windows-monitoring", "dcgm-exporter-service", "neuron-monitor-service" ] | ||
verbs: [ "patch","update" ] | ||
- apiGroups: [ "apps" ] | ||
resources: [ "daemonsets" ] | ||
verbs: [ "create","delete","get","list","patch","update","watch" ] | ||
|
@@ -41,13 +53,4 @@ rules: | |
verbs: [ "get","patch","update" ] | ||
- apiGroups: [ "cloudwatch.aws.amazon.com" ] | ||
resources: [ "instrumentations" ] | ||
verbs: [ "get","list","patch","update","watch" ] | ||
- apiGroups: [ "coordination.k8s.io" ] | ||
resources: [ "leases" ] | ||
verbs: [ "create","get","list","update" ] | ||
- apiGroups: [ "networking.k8s.io" ] | ||
resources: [ "ingresses" ] | ||
verbs: [ "create","delete","get","list","patch","update","watch" ] | ||
- apiGroups: [ "route.openshift.io" ] | ||
resources: [ "routes", "routes/custom-host" ] | ||
verbs: [ "create","delete","get","list","patch","update","watch" ] | ||
verbs: [ "get","list","patch","update","watch" ] |
Uh oh!
There was an error while loading. Please reload this page.