-
Notifications
You must be signed in to change notification settings - Fork 187
/
provider-azure-installer.yaml
136 lines (136 loc) · 4.77 KB
/
provider-azure-installer.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
{{- if .Values.linux.enabled}}
apiVersion: apps/v1
kind: DaemonSet
metadata:
name: {{ template "sscdpa.fullname" . }}
namespace: {{ .Release.Namespace }}
{{ include "sscdpa.labels" . | indent 2 }}
spec:
updateStrategy:
{{ toYaml .Values.linux.updateStrategy | indent 4 }}
selector:
matchLabels:
app: {{ template "sscdpa.name" . }}
template:
metadata:
{{ include "sscdpa.labels" . | indent 6 }}
{{- if .Values.linux.podLabels }}
{{- toYaml .Values.linux.podLabels | nindent 8 }}
{{- end }}
{{- if or .Values.linux.podAnnotations .Values.enableArcExtension }}
annotations:
{{- if .Values.linux.podAnnotations}}
{{- toYaml .Values.linux.podAnnotations | nindent 8 }}
{{- end }}
{{- if .Values.enableArcExtension }}
{{- if .Values.arc.enableMonitoring }}
prometheus.io/scrape: "true"
prometheus.io/port: "8898"
{{- end }}
{{- end }}
# this will ensure pods are rolled in next helm upgrade if cert files are updated.
{{- if .Values.enableArcExtension }}
{{- if .Values.Azure.proxySettings.isProxyEnabled }}
checksum/arc-proxy-config: {{ include (print $.Template.BasePath "/arc-proxy-secret.yaml") . | sha256sum }}
{{- end }}
{{- end }}
{{- end }}
spec:
{{- if .Values.imagePullSecrets }}
imagePullSecrets:
{{ toYaml .Values.imagePullSecrets | indent 8 }}
{{- end }}
serviceAccountName: csi-secrets-store-provider-azure
hostNetwork: true
containers:
- name: provider-azure-installer
image: "{{ .Values.linux.image.repository }}:{{ .Values.linux.image.tag }}"
imagePullPolicy: {{ .Values.linux.image.pullPolicy }}
args:
- --endpoint=unix:///provider/azure.sock
{{- if .Values.logFormatJSON }}
- --log-format-json={{ .Values.logFormatJSON }}
{{- end }}
{{- if .Values.logVerbosity }}
- -v={{ .Values.logVerbosity }}
{{- end }}
{{- if .Values.constructPEMChain }}
- --construct-pem-chain={{ .Values.constructPEMChain }}
{{- end }}
{{- if .Values.linux.customUserAgent }}
- --custom-user-agent={{ .Values.linux.customUserAgent }}
{{- end }}
- --healthz-port={{ .Values.linux.healthzPort }}
- --healthz-path={{ .Values.linux.healthzPath }}
- --healthz-timeout={{ .Values.linux.healthzTimeout }}
livenessProbe:
httpGet:
path: {{ .Values.linux.healthzPath }}
port: {{ .Values.linux.healthzPort }}
failureThreshold: 3
initialDelaySeconds: 5
timeoutSeconds: 10
periodSeconds: 30
resources:
{{ toYaml .Values.linux.resources | indent 12 }}
securityContext:
{{- if not .Values.linux.privileged }}
allowPrivilegeEscalation: false
{{- end }}
readOnlyRootFilesystem: true
runAsUser: 0
capabilities:
drop:
- ALL
{{- if .Values.linux.privileged }}
privileged: true
{{- end }}
{{- if .Values.enableArcExtension }}
{{- if .Values.Azure.proxySettings.isProxyEnabled }}
envFrom:
- secretRef:
name: arc-proxy-config
{{- end }}
{{- end }}
volumeMounts:
- name: provider-vol
mountPath: /provider
{{- if .Values.linux.volumeMounts }}
{{- toYaml .Values.linux.volumeMounts | nindent 12 }}
{{- end}}
{{- if .Values.enableArcExtension }}
{{- if and .Values.Azure.proxySettings.isProxyEnabled .Values.Azure.proxySettings.proxyCert }}
- mountPath: /etc/ssl/certs/proxy-cert.crt
subPath: proxy-cert.crt
name: proxy-certstore
{{- end }}
{{- end }}
affinity:
{{ toYaml .Values.linux.affinity | indent 8 }}
{{- if .Values.linux.priorityClassName }}
priorityClassName: {{ .Values.linux.priorityClassName | quote }}
{{- end }}
volumes:
- name: provider-vol
hostPath:
path: {{ .Values.linux.providersDir }}
{{- if .Values.linux.volumes }}
{{- toYaml .Values.linux.volumes | nindent 8 }}
{{- end}}
{{- if .Values.enableArcExtension }}
{{- if and .Values.Azure.proxySettings.isProxyEnabled .Values.Azure.proxySettings.proxyCert }}
- name: proxy-certstore
secret:
secretName: arc-proxy-cert
{{- end }}
{{- end }}
nodeSelector:
kubernetes.io/os: linux
{{- if .Values.linux.nodeSelector }}
{{- toYaml .Values.linux.nodeSelector | nindent 8 }}
{{- end }}
{{- with .Values.linux.tolerations }}
tolerations:
{{ toYaml . | indent 8 }}
{{- end }}
{{- end -}}