-
Notifications
You must be signed in to change notification settings - Fork 76
/
controller.yaml
68 lines (67 loc) · 2.32 KB
/
controller.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
apiVersion: apps/v1
kind: Deployment
metadata:
name: {{ include "helm.fullname" . }}-controller
labels:
{{- include "helm.labels" . | nindent 4 }}
spec:
replicas: {{ .Values.controllerService.replicaCount }}
selector:
matchLabels:
{{- include "helm.selectorLabels" . | nindent 6 }}-controller
template:
metadata:
labels:
{{- include "helm.selectorLabels" . | nindent 8 }}-controller
spec:
serviceAccountName: {{ include "helm.serviceAccountName" . }}
priorityClassName: system-cluster-critical
tolerations:
- key: CriticalAddonsOnly
operator: Exists
containers:
- name: fsx-plugin
image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}"
imagePullPolicy: {{ .Values.image.pullPolicy }}
args:
- --endpoint=$(CSI_ENDPOINT)
env:
- name: CSI_ENDPOINT
value: unix:///var/lib/csi/sockets/pluginproxy/csi.sock
- name: AWS_ACCESS_KEY_ID
valueFrom:
secretKeyRef:
name: aws-secret
key: key_id
optional: true
- name: AWS_SECRET_ACCESS_KEY
valueFrom:
secretKeyRef:
name: aws-secret
key: access_key
optional: true
volumeMounts:
- name: socket-dir
mountPath: /var/lib/csi/sockets/pluginproxy/
resources:
{{- toYaml .Values.controllerService.fsxPlugin.resources | nindent 12 }}
- name: csi-provisioner
image: "{{ .Values.controllerService.csiProvisioner.image.repository }}:{{ .Values.controllerService.csiProvisioner.image.tag }}"
args:
- --csi-address=$(ADDRESS)
- --timeout=5m
env:
- name: ADDRESS
value: /var/lib/csi/sockets/pluginproxy/csi.sock
volumeMounts:
- name: socket-dir
mountPath: /var/lib/csi/sockets/pluginproxy/
resources:
{{- toYaml .Values.controllerService.csiProvisioner.resources | nindent 12 }}
volumes:
- name: socket-dir
emptyDir: {}
{{- with .Values.controllerService.nodeSelector }}
nodeSelector:
{{- toYaml . | nindent 8 }}
{{- end }}