blob: 92f72f2b97d32dc07d0ef6b68977f806e0fed06a [file] [log] [blame]
Sean Condond7d18342021-10-11 14:25:27 +01001# SPDX-FileCopyrightText: 2021-present Open Networking Foundation <info@opennetworking.org>
2#
Sean Condon160ec1d2022-02-08 12:58:25 +00003# SPDX-License-Identifier: Apache-2.0
Sean Condond7d18342021-10-11 14:25:27 +01004
5apiVersion: apps/v1
6kind: Deployment
7metadata:
8 name: {{ include "aether-roc-websocket.fullname" . }}
9 namespace: {{ .Release.Namespace }}
10 labels:
11 {{- include "aether-roc-websocket.labels" . | nindent 4 }}
12spec:
13 replicas: {{ .Values.replicaCount }}
14 selector:
15 matchLabels:
16 name: {{ template "aether-roc-websocket.fullname" . }}
17 app: aether
18 type: ws
19 resource: {{ template "aether-roc-websocket.fullname" . }}
20 {{- include "aether-roc-websocket.selectorLabels" . | nindent 6 }}
21 template:
22 metadata:
23 labels:
24 name: {{ template "aether-roc-websocket.fullname" . }}
25 app: aether
26 type: ws
27 resource: {{ template "aether-roc-websocket.fullname" . }}
28 {{- include "aether-roc-websocket.selectorLabels" . | nindent 8 }}
29 spec:
30 serviceAccountName: aether-roc-websocket
31 securityContext:
32 {{- toYaml .Values.podSecurityContext | nindent 8 }}
33 {{- with .Values.imagePullSecrets }}
34 imagePullSecrets:
35 {{- toYaml . | nindent 8 }}
36 {{- end }}
37 containers:
38 - name: {{ .Chart.Name }}
39 image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}"
40 imagePullPolicy: {{ .Values.image.pullPolicy }}
41 env:
42 - name: NAMESPACE
43 valueFrom:
44 fieldRef:
45 fieldPath: metadata.namespace
46 args: []
47 ports:
48 - name: http
49 containerPort: {{ .Values.port }}
50 startupProbe:
51 tcpSocket:
52 port: {{ .Values.port }}
53 periodSeconds: 5
54 failureThreshold: 60
55 readinessProbe:
56 tcpSocket:
57 port: {{ .Values.port }}
58 initialDelaySeconds: 10
59 periodSeconds: 10
60 livenessProbe:
61 tcpSocket:
62 port: {{ .Values.port }}
63 initialDelaySeconds: 10
64 periodSeconds: 10
65 resources:
66 {{- toYaml .Values.resources | nindent 12 }}
67 securityContext: {}
68 volumes:
69 - name: secret
70 secret:
71 secretName: {{ template "aether-roc-websocket.fullname" . }}-secret
72 - name: config
73 configMap:
74 name: {{ template "aether-roc-websocket.fullname" . }}-config
75 {{- with .Values.nodeSelector }}
76 nodeSelector:
77 {{- toYaml . | nindent 8 }}
78 {{- end }}
79 {{- with .Values.affinity }}
80 affinity:
81 {{- toYaml . | nindent 8 }}
82 {{- end }}
83 {{- with .Values.tolerations }}
84 tolerations:
85 {{- toYaml . | nindent 8 }}
86 {{- end }}