Sean Condon | fe2c974 | 2022-03-25 16:42:49 +0000 | [diff] [blame] | 1 | # SPDX-FileCopyrightText: 2022-present Open Networking Foundation <info@opennetworking.org>
|
| 2 | #
|
| 3 | # SPDX-License-Identifier: Apache-2.0
|
| 4 |
|
| 5 | apiVersion: apps/v1
|
| 6 | kind: Deployment
|
| 7 | metadata:
|
| 8 | name: {{ template "rasa-action-server.fullname" . }}
|
| 9 | namespace: {{ .Release.Namespace }}
|
| 10 | labels:
|
| 11 | name: {{ template "rasa-action-server.fullname" . }}
|
| 12 | spec:
|
| 13 | replicas: {{ .Values.replicaCount }}
|
| 14 | selector:
|
| 15 | matchLabels:
|
| 16 | {{- include "rasa-action-server.selectorLabels" . | nindent 6 }}
|
| 17 | template:
|
| 18 | metadata:
|
| 19 | labels:
|
| 20 | name: {{ template "rasa-action-server.fullname" . }}
|
| 21 | {{- include "rasa-action-server.selectorLabels" . | nindent 8 }}
|
| 22 | spec:
|
| 23 | {{- with .Values.imagePullSecrets }}
|
| 24 | imagePullSecrets:
|
| 25 | {{- toYaml . | nindent 6 }}
|
| 26 | {{- end }}
|
| 27 | securityContext:
|
| 28 | {{- toYaml .Values.podSecurityContext | nindent 8 }}
|
| 29 | containers:
|
| 30 | - name: {{ .Chart.Name }}
|
| 31 | image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}"
|
| 32 | imagePullPolicy: {{ .Values.image.pullPolicy }}
|
| 33 | env:
|
| 34 | - name: POD_NAMESPACE
|
| 35 | valueFrom:
|
| 36 | fieldRef:
|
| 37 | fieldPath: metadata.namespace
|
| 38 | - name: POD_NAME
|
| 39 | valueFrom:
|
| 40 | fieldRef:
|
| 41 | fieldPath: metadata.name
|
| 42 | - name: NODE_NAME
|
| 43 | valueFrom:
|
| 44 | fieldRef:
|
| 45 | fieldPath: spec.nodeName
|
| 46 | args:
|
| 47 | - "/usr/local/bin/rasa-action-server"
|
| 48 | - "--smtpServer"
|
| 49 | - {{.Values.smtp.server | quote }}
|
| 50 | - "--smtpSerPort"
|
| 51 | - {{.Values.smtp.port | quote}}
|
| 52 | ports:
|
| 53 | - name: action
|
| 54 | containerPort: 8081
|
| 55 | readinessProbe:
|
| 56 | httpGet:
|
| 57 | path: /webhook
|
| 58 | port: 8081
|
| 59 | initialDelaySeconds: 5
|
| 60 | periodSeconds: 10
|
| 61 | livenessProbe:
|
| 62 | httpGet:
|
| 63 | path: /webhook
|
| 64 | port: 8081
|
| 65 | initialDelaySeconds: 15
|
| 66 | periodSeconds: 20
|