Role or ClusterRole?

Three ways to combine a role and a binding, and the question that tells you which one you need.

Skill labintermediate~25 minPro

What you'll do

  • ✓Identify resources that no Role can ever grant
  • ✓Reuse a built-in ClusterRole with a namespace-scoped binding
  • ✓Choose deliberately between the three role/binding combinations
  • ✓Keep a cluster-wide grant narrow

Lab outline

  1. 01Some resources have no namespace
  2. 02Someone else's definition, your scope
  3. 03Genuinely cluster-wide

Before you start

  • Writing Roles, ClusterRoles, and both kinds of binding

Every lab runs on a real machine of your own in the browser — no installs, nothing to clean up — and checks your work automatically as you go.

← All Kubernetes labs

Your first machine is
8 seconds away.

Learn by doing on real machines — and give every AI agent one of its own.

Free forever · No credit card · Cancel anytime

Role or ClusterRole? — Kubernetes lab | Kube Labs