forked from GokulAnanthNkp/ChaosProject1
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathrbac.yml
37 lines (37 loc) · 928 Bytes
/
rbac.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
---
apiVersion: v1
kind: ServiceAccount
metadata:
name: ec2-terminate-sa
namespace: default
labels:
name: ec2-terminate-sa
app.kubernetes.io/part-of: litmus
---
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
metadata:
name: ec2-terminate-sa
labels:
name: ec2-terminate-sa
app.kubernetes.io/part-of: litmus
rules:
- apiGroups: ["","litmuschaos.io","batch"]
resources: ["pods","jobs","secrets","events","pods/log","pods/exec","chaosengines","chaosexperiments","chaosresults"]
verbs: ["create","list","get","patch","update","delete"]
---
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRoleBinding
metadata:
name: ec2-terminate-sa
labels:
name: ec2-terminate-sa
app.kubernetes.io/part-of: litmus
roleRef:
apiGroup: rbac.authorization.k8s.io
kind: ClusterRole
name: ec2-terminate-sa
subjects:
- kind: ServiceAccount
name: ec2-terminate-sa
namespace: default