2 # Copyright © 2020 AT&T, Orange
4 # Licensed under the Apache License, Version 2.0 (the "License");
5 # you may not use this file except in compliance with the License.
6 # You may obtain a copy of the License at
8 # http://www.apache.org/licenses/LICENSE-2.0
10 # Unless required by applicable law or agreed to in writing, software
11 # distributed under the License is distributed on an "AS IS" BASIS,
12 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 # See the License for the specific language governing permissions and
14 # limitations under the License.
17 {{- define "aaf.deployment" -}}
20 metadata: {{- include "common.resourceMetadata" . | nindent 2 }}
22 selector: {{- include "common.selectors" . | nindent 4 }}
23 replicas: {{ .Values.replicaCount }}
25 metadata: {{- include "common.templateMetadata" . | nindent 6 }}
26 spec: {{ include "aaf.initContainers" . | nindent 6 }}
28 - name: {{ include "common.name" . }}
29 workingDir: /opt/app/aaf
30 command: ["bin/{{ .Values.binary }}"]
31 image: {{ include "repositoryGenerator.repository" . }}/{{.Values.global.aaf.image}}
32 imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
33 ports: {{ include "common.containerPorts" . | nindent 10 }}
35 - mountPath: "/opt/app/osaaf"
37 - mountPath: /etc/localtime
40 - mountPath: /opt/app/osaaf/etc/org.osaaf.aaf.log4j.props
42 subPath: org.osaaf.aaf.log4j.props
43 - mountPath: /opt/app/osaaf/data/
45 {{- if eq .Values.liveness.enabled true }}
48 port: {{.Values.liveness.port }}
49 initialDelaySeconds: {{ .Values.liveness.initialDelaySeconds }}
50 periodSeconds: {{ .Values.liveness.periodSeconds }}
54 port: {{ .Values.readiness.port }}
55 initialDelaySeconds: {{ .Values.readiness.initialDelaySeconds }}
56 periodSeconds: {{ .Values.readiness.periodSeconds }}
57 resources: {{ include "common.resources" . | nindent 12 }}
58 {{- if .Values.nodeSelector }}
59 nodeSelector: {{ toYaml .Values.nodeSelector | nindent 10 }}
61 {{- if .Values.affinity }}
62 affinity: {{ toYaml .Values.affinity | nindent 10 }}
68 - name: aaf-config-vol
72 name: {{ include "common.release" . }}-aaf-log
73 - name: config-init-identity
75 name: {{ include "common.release" . }}-aaf-identity
76 - name: config-identity
79 - name: "{{ include "common.namespace" . }}-docker-registry-key"