ab8b011d by Adam Heath

Saving WIP in nfs-server.

1 parent 671dcc94
...@@ -15,13 +15,14 @@ spec: ...@@ -15,13 +15,14 @@ spec:
15 - name: rpcbind 15 - name: rpcbind
16 port: 111 16 port: 111
17 --- 17 ---
18 apiVersion: v1 18 apiVersion: apps/v1
19 kind: ReplicationController 19 kind: Deployment
20 metadata: 20 metadata:
21 name: nfs-server 21 name: nfs-server
22 spec: 22 spec:
23 replicas: 1 23 replicas: 1
24 selector: 24 selector:
25 matchLabels:
25 app: nfs-server 26 app: nfs-server
26 template: 27 template:
27 metadata: 28 metadata:
......
...@@ -12,6 +12,9 @@ environments: ...@@ -12,6 +12,9 @@ environments:
12 service: 12 service:
13 nfs_server: 13 nfs_server:
14 clusterIP: 0 14 clusterIP: 0
15 storageClassName: ""
16 affinity: null
17 tolerations: null
15 --- 18 ---
16 19
17 releases: 20 releases:
...@@ -24,7 +27,7 @@ releases: ...@@ -24,7 +27,7 @@ releases:
24 {{- if .Values.nfs_server.service.nfs_server.clusterIP }} 27 {{- if .Values.nfs_server.service.nfs_server.clusterIP }}
25 - target: 28 - target:
26 kind: Service 29 kind: Service
27 name: {{ .Values.namePrefix }}nfs_server 30 name: {{ .Values.namePrefix }}nfs-server
28 namespace: {{ .Values.namespace }} 31 namespace: {{ .Values.namespace }}
29 version: v1 32 version: v1
30 patch: 33 patch:
...@@ -32,12 +35,23 @@ releases: ...@@ -32,12 +35,23 @@ releases:
32 path: /spec/clusterIP 35 path: /spec/clusterIP
33 value: {{ .Values.nfs_server.service.nfs_server.clusterIP }} 36 value: {{ .Values.nfs_server.service.nfs_server.clusterIP }}
34 {{- end }} 37 {{- end }}
38 {{- if .Values.nfs_server.storageClassName }}
39 - target:
40 kind: PersistentVolumeClaim
41 name: {{ .Values.namePrefix }}nfs-data
42 namespace: {{ .Values.namespace }}
43 version: v1
44 patch:
45 - op: add
46 path: /spec/storageClassName
47 value: {{ .Values.nfs_server.storageClassName }}
48 {{- end }}
35 {{- if not (empty (.Values.nfs_server.jsonPatches)) }} 49 {{- if not (empty (.Values.nfs_server.jsonPatches)) }}
36 {{- .Values.nfs_server.jsonPatches | toYaml | indent 6 }} 50 {{- .Values.nfs_server.jsonPatches | toYaml | indent 6 }}
37 {{- end }} 51 {{- end }}
38 strategicMergePatches: 52 strategicMergePatches:
39 - apiVersion: v1 53 - apiVersion: apps/v1
40 kind: ReplicationController 54 kind: Deployment
41 metadata: 55 metadata:
42 name: {{ .Values.namePrefix }}nfs-server 56 name: {{ .Values.namePrefix }}nfs-server
43 namespace: {{ .Values.namespace }} 57 namespace: {{ .Values.namespace }}
...@@ -48,7 +62,14 @@ releases: ...@@ -48,7 +62,14 @@ releases:
48 - name: nfs-data 62 - name: nfs-data
49 persistentVolumeClaim: 63 persistentVolumeClaim:
50 claimName: {{ .Values.namePrefix }}nfs-data 64 claimName: {{ .Values.namePrefix }}nfs-data
65 {{- if .Values.nfs_server.affinity }}
66 affinity:
67 {{- .Values.nfs_server.affinity | toYaml | nindent 16 }}
68 {{- end }}
69 {{- if .Values.nfs_server.tolerations }}
70 tolerations:
71 {{- .Values.nfs_server.tolerations | toYaml | nindent 16 }}
72 {{- end }}
51 {{- if not (empty (.Values.nfs_server.strategicMergePatches)) }} 73 {{- if not (empty (.Values.nfs_server.strategicMergePatches)) }}
52 {{- .Values.nfs_server.strategicMergePatches | toYaml | indent 6 }} 74 {{- .Values.nfs_server.strategicMergePatches | toYaml | indent 6 }}
53 {{- end }} 75 {{- end }}
54
......