› kube_cluster › Source › Kube › Cluster › Standard › Role

class Role

A Role with an ergonomic rules shorthand. Each rule maps a resource spec to its verbs; the spec grammar ("resource", "resource/subresource", "group/resource", "group/resource/subresource") is RbacRules':

Role.new(rules: [ "secrets" => %w[get list], "pods/log" => %w[get], "batch/cronjobs" => %w[get], ])

Definitions

attr_reader :rules_input

The original rules shorthand, so a named copy can be rebuilt from it (rebuild downgrades the class; reconstructing keeps it a Standard::Role).