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

Follow
Table of Contents

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.

Pre-requisites

  • A Rancher v2.x managed Kubernetes cluster

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 Security -> Roles from the Global namespace.

  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
    Create pods/exec
    Get, List pods
    Get, List pods/log
  5. Select Create at the bottom.

Further reading

Was this article helpful?
0 out of 0 found this helpful

Comments

0 comments

Please sign in to leave a comment.