This repository has been archived by the owner on Dec 20, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathgarm-config.yaml
190 lines (190 loc) · 5.94 KB
/
garm-config.yaml
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
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
apiVersion: v1
data:
config.yaml: |
---
version: v1.0.0
logger:
log_path: /var/log/athenz/webhook.log
log_trace: athenz,server
server:
port: 443
health_check_port: 8080
health_check_path: /healthz
timeout: 30s
shutdown_duration: 10s
probe_wait_time: 9s
tls:
enabled: true
cert: _cert_
key: _key_
athenz:
auth_header: Athenz-Principal-Auth
url: https://www.athenz.io:4443/zts/v1
timeout: 30s
root_ca: _root_ca_
token:
athenz_domain: _athenz_domain_
service_name: _service_name_
ntoken_path: ""
private_key: _athenz_private_key_
validate_token: false
refresh_duration: 5s
key_version: v1.1
expiration: 5s
map_rule:
tld:
name: garm
platform:
name: k8s
# service_athenz_domains:
# - {{TLD}}.k8s.{{ENV}} # {{ENV}} = [prod, tool, dev]
service_athenz_domains:
- k8s.k8s.dev
resource_mappings:
verb_mappings:
api_group_control: true
api_group_mappings:
"": "core"
empty_namespace: allnamespaces
non_resource_api_group: nonres
non_resource_namespace: nonres
resource_name_control: true
resource_name_mappings:
"https:kubernetes-dashboard:": "kubernetes-dashboard"
resource_name_replacer:
":": "-"
"--": "-"
athenz_user_prefix: user.
athenz_service_account_prefix: user.
service_account_prefixes:
- ""
- ""
# admin_access_list: # verb.namespace.api_group.resource.name
# - verb: *
# namespace: kube-system
# api_group: '*'
# resource: '*'
# name: '*'
# - verb: *
# namespace: allnamespaces
# api_group: '*'
# resource: '*'
# name: '*'
black_list: # verb.namespace.api_group.resource.name
- verb: 'get'
namespace: 'allnamespaces'
api_group: '*'
resource: 'secrets'
name: '*'
- verb: 'list'
namespace: 'allnamespaces'
api_group: '*'
resource: 'secrets'
name: '*'
- verb: '*'
namespace: 'kube-system'
api_group: '*'
resource: '*'
name: '*'
white_list: # verb.namespace.api_group.resource.name first
- verb: 'get'
namespace: 'kube-system'
api_group: '*'
resource: 'configmaps'
name: '*'
- verb: 'list'
namespace: 'kube-system'
api_group: '*'
resource: 'configmaps'
name: '*'
- verb: 'get'
namespace: 'kube-system'
api_group: '*'
resource: 'services'
name: '*'
- verb: 'list'
namespace: 'kube-system'
api_group: '*'
resource: 'services'
name: '*'
- verb: 'get'
namespace: 'kube-system'
api_group: '*'
resource: 'services.proxy'
name: '*'
- verb: 'get'
namespace: 'kube-system'
api_group: 'extensions'
resource: 'ingresses'
name: '*'
- verb: 'list'
namespace: 'kube-system'
api_group: 'extensions'
resource: 'ingresses'
name: '*'
- verb: 'update'
namespace: 'kube-system'
api_group: '*'
resource: 'configmaps'
name: 'grafana-dashboards-extra'
- verb: 'patch'
namespace: 'kube-system'
api_group: '*'
resource: 'configmaps'
name: 'grafana-dashboards-extra'
- verb: 'update'
namespace: 'kube-system'
api_group: '*'
resource: 'configmaps'
name: 'prometheus-custom-rules'
- verb: 'patch'
namespace: 'kube-system'
api_group: '*'
resource: 'configmaps'
name: 'prometheus-custom-rules'
- verb: 'update'
namespace: 'kube-system'
api_group: '*'
resource: 'configmaps'
name: 'prometheus-alert-config'
- verb: 'patch'
namespace: 'kube-system'
api_group: '*'
resource: 'configmaps'
name: 'prometheus-alert-config'
- verb: 'update'
namespace: 'kube-system'
api_group: '*'
resource: 'secrets'
name: 'alertmanager'
- verb: 'patch'
namespace: 'kube-system'
api_group: '*'
resource: 'secrets'
name: 'alertmanager'
- verb: 'get'
namespace: 'kube-system'
api_group: '*'
resource: 'secrets'
name: 'alertmanager'
- verb: 'update'
namespace: 'kube-system'
api_group: 'rbac.authorization.k8s.io'
resource: 'rolebindings'
name: 'k8s-addon-manager-admin'
- verb: 'patch'
namespace: 'kube-system'
api_group: 'rbac.authorization.k8s.io'
resource: 'rolebindings'
name: 'k8s-addon-manager-admin'
- verb: 'get'
namespace: 'kube-system'
api_group: 'rbac.authorization.k8s.io'
resource: 'rolebindings'
name: 'k8s-addon-manager-admin'
admin_athenz_domain: k8s.caas.system-role
kind: ConfigMap
metadata:
name: garm-config
namespace: kube-public
selfLink: /api/v1/namespaces/kube-public/configmaps/garm-config