# Scoped operator access for forgejo-admins: the gitea Deployment + admin # creds only. forgejo-db-*, forgejo-oidc, forgejo-tls, and the helm-managed # forgejo-gitea-inline-config stay excluded. Inert until kube-apiserver's # OIDC wiring lands. apiVersion: rbac.authorization.k8s.io/v1 kind: Role metadata: name: forgejo-operator namespace: cicd rules: - apiGroups: ["apps"] resources: ["deployments"] resourceNames: ["forgejo-gitea"] verbs: ["get", "list", "watch", "update", "patch"] - apiGroups: [""] resources: ["secrets"] resourceNames: ["forgejo-admin"] verbs: ["get", "list", "watch", "update", "patch"] --- apiVersion: rbac.authorization.k8s.io/v1 kind: RoleBinding metadata: name: forgejo-admins-binding namespace: cicd subjects: - kind: Group name: "oidc:forgejo-admins" apiGroup: rbac.authorization.k8s.io roleRef: kind: Role name: forgejo-operator apiGroup: rbac.authorization.k8s.io