rancher-partner-charts/charts/hpe/hpe-csi-driver/templates/primera-3par-csp.yaml

101 lines
2.4 KiB
YAML

{{- if not .Values.disable.alletra9000 }}
---
### Alletra9000 CSP Service ###
kind: Service
apiVersion: v1
metadata:
name: alletra9000-csp-svc
namespace: {{ .Release.Namespace }}
labels:
app: alletra9000-csp-svc
spec:
ports:
- port: 8080
protocol: TCP
selector:
app: primera3par-csp
{{- end }}
{{- if not .Values.disable.primera }}
---
### Primera3par CSP Service ###
kind: Service
apiVersion: v1
metadata:
name: primera3par-csp-svc
namespace: {{ .Release.Namespace }}
labels:
app: primera3par-csp-svc
spec:
ports:
- port: 8080
protocol: TCP
selector:
app: primera3par-csp
{{- end }}
{{- if or (not .Values.disable.alletra9000) (not .Values.disable.primera) }}
---
### CSP deployment ###
kind: Deployment
apiVersion: apps/v1
metadata:
name: primera3par-csp
labels:
app: primera3par-csp
namespace: {{ .Release.Namespace }}
spec:
selector:
matchLabels:
app: primera3par-csp
replicas: 1
template:
metadata:
labels:
app: primera3par-csp
{{- if .Values.csp.labels }}
{{ toYaml .Values.csp.labels | indent 8 }}
{{- end }}
spec:
serviceAccountName: hpe-csp-sa
{{- if and (eq .Capabilities.KubeVersion.Major "1") ( ge ( trimSuffix "+" .Capabilities.KubeVersion.Minor ) "17") }}
priorityClassName: system-cluster-critical
{{- end }}
containers:
- name: primera3par-csp
{{- if .Values.registry }}
image: {{ .Values.registry }}/hpestorage/alletra-9000-primera-and-3par-csp:v2.3.0
{{- else }}
image: quay.io/hpestorage/alletra-9000-primera-and-3par-csp:v2.3.0
{{- end }}
imagePullPolicy: {{ .Values.imagePullPolicy | quote }}
env:
- name: CRD_CLIENT_CONFIG_QPS
value: "35"
- name: CRD_CLIENT_CONFIG_BURST
value: "20"
ports:
- containerPort: 8080
volumeMounts:
- name: log-dir
mountPath: /var/log
volumes:
- name: log-dir
hostPath:
path: /var/log
{{- if .Values.csp.nodeSelector }}
nodeSelector:
{{ toYaml .Values.csp.nodeSelector | indent 8 }}
{{- end }}
{{- if .Values.csp.tolerations }}
tolerations:
{{ toYaml .Values.csp.tolerations | indent 8 }}
{{- end }}
{{- if .Values.csp.affinity }}
affinity:
{{ toYaml .Values.csp.affinity | indent 8 }}
{{- end }}
{{- end }}