How do you enable least-privilege access for OPA Gatekeeper?

Learn how to enable least-privilege access for OPA Gatekeeper to enhance security and compliance in your Kubernetes environment.
OPA Gatekeeper, least-privilege access, Kubernetes security, compliance, policy management
apiVersion: rbac.authorization.k8s.io/v1 kind: Role metadata: namespace: gatekeeper-system name: gatekeeper-controller-manager rules: - apiGroups: [""] resources: ["pods", "pods/status"] verbs: ["get", "list", "watch"] - apiGroups: ["cmi.gatekeeper.sh"] resources: ["constrainttemplates"] verbs: ["get", "list"] - apiGroups: ["constraints.gatekeeper.sh"] resources: ["*"] verbs: ["get", "list", "watch"]

OPA Gatekeeper least-privilege access Kubernetes security compliance policy management