SUSE Support

Here When You Need Us

How to create a custom Project RBAC role to grant log access and exec permission on Pods, in a Rancher v2.x managed cluster

This document (000020073) is provided subject to the disclaimer at the end of this document.

Environment

Pre-requisites

  • A Rancher v2.x managed Kubernetes cluster

Situation

Task

This article details how to create a custom Project RBAC role to grant log access and exec permission on Pods, in a Rancher v2.x managed Kubernetes cluster.

 

     

      Resolution

      Resolution

      In Rancher v2.x you can create a custom Project Role that provides the permissions to enable a user to view Pods, Pod logs and to exec into Pods. You can then grant this role to users on Projects to provide them this access where necessary.
       

      Pod Reader Permissions in Rancher UI
       

      1. Navigate to Users & Authentication > Roles.

      2. From the Projects tab, select Add Project Role.

      3. Provide a name for the role.

      4. Under Grant Resources, select Add Resource and fill in the information for each of the following:

        Permission(s)Resource
        Get, Createpods/exec
        Get, Listpods
        Get, Listpods/log
      5. Select Create at the bottom.

      Further reading

      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.

      • Document ID:000020073
      • Creation Date: 06-May-2021
      • Modified Date:12-Dec-2023
        • SUSE Rancher

      < Back to Support Search

      For questions or concerns with the SUSE Knowledgebase please contact: tidfeedback[at]suse.com

      tick icon

      SUSE Support Forums

      Get your questions answered by experienced Sys Ops or interact with other SUSE community experts.

      tick icon

      Support Resources

      Learn how to get the most from the technical support you receive with your SUSE Subscription, Premium Support, Academic Program, or Partner Program.

      tick icon

      Open an Incident

      Open an incident with SUSE Technical Support, manage your subscriptions, download patches, or manage user access.