-
Notifications
You must be signed in to change notification settings - Fork 2
Open
Description
Hi
Do I need add RBAC permissions ?
File "kuberstack-monitoring-events.py", line 28, in main
last_event = get_sorted_events()[-1]
File "kuberstack-monitoring-events.py", line 19, in get_sorted_events
events = kubeapi.list_event_for_all_namespaces().items
File "/usr/local/lib/python3.6/site-packages/kubernetes/client/apis/core_v1_api.py", line 11306, in list_event_for_all_namespaces
(data) = self.list_event_for_all_namespaces_with_http_info(**kwargs)
File "/usr/local/lib/python3.6/site-packages/kubernetes/client/apis/core_v1_api.py", line 11399, in list_event_for_all_namespaces_with_http_info
collection_formats=collection_formats)
File "/usr/local/lib/python3.6/site-packages/kubernetes/client/api_client.py", line 329, in call_api
_return_http_data_only, collection_formats, _preload_content, _request_timeout)
File "/usr/local/lib/python3.6/site-packages/kubernetes/client/api_client.py", line 153, in __call_api
_request_timeout=_request_timeout)
File "/usr/local/lib/python3.6/site-packages/kubernetes/client/api_client.py", line 361, in request
headers=headers)
File "/usr/local/lib/python3.6/site-packages/kubernetes/client/rest.py", line 240, in GET
query_params=query_params)
File "/usr/local/lib/python3.6/site-packages/kubernetes/client/rest.py", line 231, in request
raise ApiException(http_resp=r)
kubernetes.client.rest.ApiException: (403)
Reason: Forbidden
HTTP response headers: HTTPHeaderDict({'Content-Type': 'application/json', 'X-Content-Type-Options': 'nosniff', 'Date': 'Fri, 29 Mar 2019 12:23:47 GMT', 'Content-Length': '253'})
HTTP response body: {"kind":"Status","apiVersion":"v1","metadata":{},"status":"Failure","message":"events is forbidden: User \"system:serviceaccount:kube-system:default\" cannot list events at the cluster scope","reason":"Forbidden","details":{"kind":"events"},"code":403}
Metadata
Metadata
Assignees
Labels
No labels