How to create a read-only custom Global Role for Fleet
This document (000021157) is provided subject to the disclaimer at the end of this document.
Environment
Rancher v2.6+
Situation
To permit a user read-only access to Fleet resources a custom Global Role can be created with the required grants.
In this role you need to grant the get, list and watch verbs on the following resources:
Resources | API Group |
---|---|
clusters | fleet.cattle.io |
gitrepos | fleet.cattle.io |
bundles | fleet.cattle.io |
clustergroups | fleet.cattle.io |
fleetworkspaces | management.cattle.io |
Resolution
1. Create the custom Global Role
Navigate within the Rancher UI to Users & Authentication > Role Templates and click Create Global Role. Create a new role granting list, and get and watch the resources listed in the above table.
In the Rancher UI, under Users & Authentication > Role Templates > Global, a new Global Role appears:
2. Assign this role to individual users or groups
After creating this custom Global Role, you can then assign it to individual users or groups. When a non-admin user assigned this role accesses Rancher, the user will not be able to edit any Fleet resources but will be able to view these within the Continuous Delivery UI.
Additional Information
Custom Roles
Disclaimer
This Support Knowledgebase provides a valuable tool for SUSE customers and parties interested in our products and solutions to acquire information, ideas and learn from one another. Materials are provided for informational, personal or non-commercial use within your organization and are presented "AS IS" WITHOUT WARRANTY OF ANY KIND.