-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathconfig-agents.yaml
43 lines (43 loc) · 962 Bytes
/
config-agents.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
{{- if .Values.vault.agents }}
---
apiVersion: v1
kind: ConfigMap
metadata:
name: qkm-vault-agent-cm
data:
{{- range .Values.vault.agents }}
init-agent-config-{{ .name }}.hcl: |
exit_after_auth = true
auto_auth {
method "kubernetes" {
mount_path = "auth/kubernetes"
config = {
role = "{{ .config.role }}"
}
}
sink "file" {
wrap_ttl = "{{ .config.wrapTTL }}"
config = {
path = "/vault/token/.agent-{{ .name }}-vault-token"
mode = 0444
}
}
}
agent-config-{{ .name }}.hcl: |
auto_auth {
method "kubernetes" {
mount_path = "auth/kubernetes"
config = {
role = "{{ .config.role }}"
}
}
sink "file" {
wrap_ttl = "{{ .config.wrapTTL }}"
config = {
path = "/vault/token/.agent-{{ .name }}-vault-token"
mode = 0444
}
}
}
{{- end }}
{{- end }}