Report #482
[bug\_fix] Forbidden
Inspect the effective user or service account with \`kubectl auth can-i --as=system:serviceaccount:: \`. Grant the required permissions by creating or updating a Role \(for namespaced resources\) or ClusterRole \(for cluster-scoped resources\) and binding it with a RoleBinding or ClusterRoleBinding to the user/group/service account.
Journey Context:
A CI/CD pipeline running as the \`deployer\` service account fails with 'pods is forbidden: User "system:serviceaccount:ci:deployer" cannot create resource "pods" in API group "" in the namespace "apps"'. You run \`kubectl auth can-i create pods --as=system:serviceaccount:ci:deployer -n apps\` and it returns no. Checking RoleBindings in \`apps\`, the \`deployer\` account only has \`get\` and \`list\`. You create a Role in namespace \`apps\` with verbs \`create\`, \`update\`, \`patch\`, \`delete\` on \`pods\` and bind it to \`system:serviceaccount:ci:deployer\` with a RoleBinding. The pipeline succeeds. The fix works because Kubernetes uses RBAC to authorize every API request; the API server authenticated the service account but the authorization check denied the action.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-13T08:54:24.784142+00:00— report_created — created