What is Kubernetes role-based access control (RBAC)?

Published June 22, 20212-minute read
Copy URL

Jump to section

OverviewWhat is Kubernetes?What are roles?How it worksWhy Red Hat?

What is Kubernetes?

Kubernetes (also known as k8s or kube) is anopen source container orchestration platform thatautomates many of the manual processes involved indeploying,managing, and scaling containerized applications. 

When managed by Kubernetes, Linux containers givemicroservice-based apps an ideal application deployment unit and self-contained execution environment. And because Kubernetes deployments are written inYAML, the code is human-readable.

Learn more about Kubernetes

Red Hat resources

What are roles?

Roles grant various levels of access topods and nodes. Roles can be authorized to access a specific group ofclusters working together as an application workload (known simply as as roles) or entire clusters (known as cluster roles).

  • Roles grant permission to virtually linked groups of clusters known as namespaces. Roles are a type of namespaced resource because user access to a workload is determined by what clusters are included in the specific namespace. Users, groups of users, or service account names can be consolidated into a single role throughrole binding.
  • Cluster roles grant permission to entire clusters, which are groups of individual hardware nodes. Cluster roles can span multiple namespaces.Cluster role binding ties a cluster role to every namespace in a cluster. For example, the cluster administrator cluster role name has unfettered access to all clusters.

Role binding and cluster role permissions can be combined and stacked using metadata. This grants permissions defined in a cluster role to resources inside the role binding's namespace—helping define common roles across a cluster that can be reused across multiple namespaces.

Here are 5 common Kubernetes RBAC mistakes

How does Kubernetes RBAC work?

The Kubernetesapplication programming interface (API) is the front end of the Kubernetes control plane. TheKubernetes API communicates interactions with a computer or system to retrieve information or perform afunction

Kubernetes RBAC collects related function requests into API groups, which communicate with API servers when connecting certain roles to API endpoints.

For more information on using Kubernetes RBAC—including Kubernetes documentation, rbac.authorization.k8s.io authentication, the kubectl command line tool, add-ons, kubelet TLS bootstrapping, and setting up network policies, visitthe open source project's RBAC docs.

Why Red Hat?

Red Hat was one of the first companies to work with Kubernetes’ creator—Google—on the project even prior to launch. Since then, it has become the 2nd leading contributor to the Kubernetes upstream project and became one of the first to market with an enterprise Kubernetes platform. 

Red Hat® OpenShift® is Kubernetes for the enterprise, including all the extra pieces of technology that make Kubernetes more powerful and viable. These components include networking, authentication, monitoring,security, and automation, among others. 

Unlike other vendor platforms that require proprietary components—as well as complex processes—Red Hat OpenShift is a single, integrated platform for operations and development teams, validating popularstorage and networking plug-ins for Kubernetes and including built-in monitoring, logging, and analytics solutions.

Keep reading
Hub

The official Red Hat blog

Get the latest information about our ecosystem of customers, partners, and communities.

All Red Hat product trials

Our no-cost product trials help you gain hands-on experience, prepare for a certification, or assess if a product is right for your organization.

Keep reading

What is a Linux container?

Find out more about Linux containers, which are a set of 1 or more processes that are isolated from the rest of the system.

What is container orchestration?

Container orchestration automates the deployment, management, scaling, and networking of containers.

What is Kubernetes?

Kubernetes is a container orchestration platform that eliminates many manual processes involved in deploying and scaling containerized applications.

Containers resources

Related articles