用户“system:serviceaccount:gitlab-runner:default”无法列出名称空间“gitlab-runner”中 API 组“”中的资源“事件”

问题描述 投票:0回答:0

我正在尝试使用我的 aws eks 集群设置 gitlab runner。我已经能够毫无问题地创建命名空间。但是,当我触发 gitlab CICD 管道时,我收到以下错误

ERROR: Error retrieving events list: events is forbidden: User "system:serviceaccount:gitlab-runner:default" cannot list resource "events" in API group "" in the namespace "gitlab-runner"
.

这是我的 gitlab-runner-role.yaml 文件

piVersion: rbac.authorization.k8s.io/v1
kind: Role
metadata:
  name: gitlab-runner
  namespace: gitlab-runner
rules:
  - apiGroups: [""]
    resources: ["pods", "pods/exec", "pods/log", "pods/attach", "secrets", "events"]
    verbs: ["list", "get", "watch", "create", "delete", "update"]

有关我为何收到此错误以及如何解决该问题的任何帮助

gitlab gitlab-ci kubernetes-helm amazon-eks gitlab-ci-runner
© www.soinside.com 2019 - 2024. All rights reserved.