blob: f2ed9daa81bad5bfa8c7801099b6ae7bd9903afc [file] [log] [blame]
Kiran Kaminenie2ba7c82019-04-22 17:52:13 -07001{{/*
2# Copyright 2019 Intel Corporation, Inc
Andreas Geissler6fd28212024-10-22 11:33:38 +02003# Modifications Copyright © 2024 Deutsche Telekom
Kiran Kaminenie2ba7c82019-04-22 17:52:13 -07004#
5# Licensed under the Apache License, Version 2.0 (the "License");
6# you may not use this file except in compliance with the License.
7# You may obtain a copy of the License at
8#
9# http://www.apache.org/licenses/LICENSE-2.0
10#
11# Unless required by applicable law or agreed to in writing, software
12# distributed under the License is distributed on an "AS IS" BASIS,
13# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14# See the License for the specific language governing permissions and
15# limitations under the License.
16*/}}
17
kwasield74d38f2020-07-23 10:09:57 +000018apiVersion: apps/v1
Kiran Kaminenie2ba7c82019-04-22 17:52:13 -070019kind: Deployment
Andreas Geissler718fb742023-03-09 09:44:02 +010020metadata: {{- include "common.resourceMetadata" . | nindent 2 }}
Kiran Kaminenie2ba7c82019-04-22 17:52:13 -070021spec:
Andreas Geissler718fb742023-03-09 09:44:02 +010022 selector: {{- include "common.selectors" . | nindent 4 }}
Kiran Kaminenie2ba7c82019-04-22 17:52:13 -070023 replicas: {{ .Values.replicaCount }}
24 template:
Andreas Geissler718fb742023-03-09 09:44:02 +010025 metadata: {{- include "common.templateMetadata" . | nindent 6 }}
Kiran Kaminenie2ba7c82019-04-22 17:52:13 -070026 spec:
Andreas Geissler6fd28212024-10-22 11:33:38 +020027 {{ include "common.podSecurityContext" . | indent 6 | trim }}
Kiran Kaminenie2ba7c82019-04-22 17:52:13 -070028 containers:
Sylvain Desbureaux37dc40c2020-11-21 22:46:57 +010029 - image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.image }}
Kiran Kaminenie2ba7c82019-04-22 17:52:13 -070030 imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
31 name: {{ include "common.name" . }}
32 command: ["/opt/multicloud/k8splugin/k8plugin"]
33 workingDir: /opt/multicloud/k8splugin
Andreas Geissler718fb742023-03-09 09:44:02 +010034 ports: {{ include "common.containerPorts" . | nindent 10 }}
Andreas Geissler6fd28212024-10-22 11:33:38 +020035 {{ include "common.containerSecurityContext" . | indent 10 | trim }}
Kiran Kaminenie2ba7c82019-04-22 17:52:13 -070036 {{- if eq .Values.liveness.enabled true }}
37 livenessProbe:
38 tcpSocket:
39 port: {{ .Values.service.internalPort }}
40 initialDelaySeconds: {{ .Values.liveness.initialDelaySeconds }}
41 periodSeconds: {{ .Values.liveness.periodSeconds }}
42 {{ end -}}
43 readinessProbe:
44 tcpSocket:
45 port: {{ .Values.service.internalPort }}
46 initialDelaySeconds: {{ .Values.readiness.initialDelaySeconds }}
47 periodSeconds: {{ .Values.readiness.periodSeconds }}
48 volumeMounts:
Kiran Kaminenie2ba7c82019-04-22 17:52:13 -070049 - mountPath: /opt/multicloud/k8splugin/k8sconfig.json
50 name: {{ include "common.name" .}}
51 subPath: k8sconfig.json
miroslavmasaryka7ac7f02023-03-01 14:12:26 +010052 resources: {{ include "common.resources" . | nindent 10 }}
Kiran Kaminenie2ba7c82019-04-22 17:52:13 -070053 {{- if .Values.nodeSelector }}
54 nodeSelector:
55{{ toYaml .Values.nodeSelector | indent 10 }}
56 {{- end -}}
57 {{- if .Values.affinity }}
58 affinity:
59{{ toYaml .Values.affinity | indent 10 }}
60 {{- end }}
Sylvain Desbureaux37dc40c2020-11-21 22:46:57 +010061 - image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.global.artifactImage }}
Andreas Geisslerdfa23c82022-05-13 16:54:43 +020062 imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
liboNet80f587a2019-05-17 01:30:16 +080063 name: framework-artifactbroker
64 command: ["/opt/app/distribution/bin/artifact-dist.sh"]
65 args: ["/opt/app/distribution/etc/mounted/config.json"]
Andreas Geissler6fd28212024-10-22 11:33:38 +020066 {{ include "common.containerSecurityContext" . | indent 10 | trim }}
67 resources: {{ include "common.resources" . | nindent 10 }}
liboNet80f587a2019-05-17 01:30:16 +080068 ports:
69 - containerPort: {{ .Values.artifactbroker.internalPort }}
70 protocol: TCP
Andreas Geissler6fd28212024-10-22 11:33:38 +020071 {{- if eq .Values.liveness.enabled true }}
72 livenessProbe:
73 tcpSocket:
74 port: {{ .Values.artifactbroker.internalPort }}
75 initialDelaySeconds: {{ .Values.liveness.initialDelaySeconds }}
76 periodSeconds: {{ .Values.liveness.periodSeconds }}
77 {{ end -}}
78 readinessProbe:
79 tcpSocket:
80 port: {{ .Values.artifactbroker.internalPort }}
81 initialDelaySeconds: {{ .Values.readiness.initialDelaySeconds }}
82 periodSeconds: {{ .Values.readiness.periodSeconds }}
liboNet80f587a2019-05-17 01:30:16 +080083 volumeMounts:
Andreas Geissler6fd28212024-10-22 11:33:38 +020084 - mountPath: "{{ .Values.log.path }}"
85 name: framework-log
liboNet80f587a2019-05-17 01:30:16 +080086 - mountPath: /opt/app/distribution/etc/mounted/config.json
87 name: {{ include "common.name" .}}
88 subPath: config.json
89 - mountPath: /data
90 name: artifact-data
efiacorc8c33162022-11-25 11:36:52 +000091 env:
efiacorc8c33162022-11-25 11:36:52 +000092 - name: SASL_JAAS_CONFIG
david.mcweeney2886a112023-02-10 12:35:20 +000093 valueFrom:
94 secretKeyRef:
95 name: {{ include "common.name" . }}-ku
96 key: sasl.jaas.config
farida azmy72513552021-10-12 18:55:21 +020097 serviceAccountName: {{ include "common.fullname" (dict "suffix" "read" "dot" . )}}
Kiran Kaminenie2ba7c82019-04-22 17:52:13 -070098 volumes:
Andreas Geissler6fd28212024-10-22 11:33:38 +020099 - name: framework-log
100 emptyDir:
101 sizeLimit: {{ .Values.volumes.logSizeLimit }}
Kiran Kaminenie2ba7c82019-04-22 17:52:13 -0700102 - name : {{ include "common.name" . }}
103 configMap:
104 name: {{ include "common.fullname" . }}
liboNet80f587a2019-05-17 01:30:16 +0800105 - name: artifact-data
Andreas Geissler6fd28212024-10-22 11:33:38 +0200106 emptyDir:
107 sizeLimit: {{ .Values.volumes.artifactDataSizeLimit }}
Andreas Geisslerbd0d31a2024-03-20 09:51:32 +0100108 {{- include "common.imagePullSecrets" . | nindent 6 }}