Skip to content
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

Replace namespaced roles with cluster role #46

Merged
merged 1 commit into from
Apr 17, 2019

Conversation

djzager
Copy link
Contributor

@djzager djzager commented Apr 16, 2019

Instead of creating roles in the openshift-console and kube-public
namespaces + associated role bindings, give the operator permission to
access configmaps in all namespaces.

This makes it possible, in a follow-up PR, to generate a CSV so that
web-ui is installable via OLM.

Instead of creating roles in the openshift-console and kube-public
namespaces + associated role bindings, give the operator permission to
access configmaps in all namespaces.

This makes it possible, in a follow-up PR, to generate a CSV so that
web-ui is installable via OLM.
@mareklibra
Copy link
Contributor

I don't like granting wider permissions than required, especially something like permission to read/write all configmaps in all namespaces.

David, can you please briefly explain why is this needed by the "CSV generator"?

@djzager
Copy link
Contributor Author

djzager commented Apr 17, 2019

In a ClusterServiceVersion (CSV) you specify permissions and clusterPermissions that basically map a collection of rules to a service account name. When your CSV is installed the service account is created with the name you specified in the namespace where the Subscription is made. You cannot create Roles or ServiceAccounts in other namespaces and you cannot bind a Service Account to a Role in another namespace.

https://github.com/operator-framework/operator-lifecycle-manager/blob/master/Documentation/design/building-your-csv.md#operator-install

@mareklibra
Copy link
Contributor

@djzager , ok, thanks for the explanation.

@mareklibra mareklibra merged commit ea3d6b8 into kubevirt:master Apr 17, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants