Kiran Kamineni | e2ba7c8 | 2019-04-22 17:52:13 -0700 | [diff] [blame] | 1 | {{/* |
| 2 | # Copyright 2019 Intel Corporation, Inc |
Andreas Geissler | 6fd2821 | 2024-10-22 11:33:38 +0200 | [diff] [blame] | 3 | # Modifications Copyright © 2024 Deutsche Telekom |
Kiran Kamineni | e2ba7c8 | 2019-04-22 17:52:13 -0700 | [diff] [blame] | 4 | # |
| 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 | |
kwasiel | d74d38f | 2020-07-23 10:09:57 +0000 | [diff] [blame] | 18 | apiVersion: apps/v1 |
Kiran Kamineni | e2ba7c8 | 2019-04-22 17:52:13 -0700 | [diff] [blame] | 19 | kind: Deployment |
Andreas Geissler | 718fb74 | 2023-03-09 09:44:02 +0100 | [diff] [blame] | 20 | metadata: {{- include "common.resourceMetadata" . | nindent 2 }} |
Kiran Kamineni | e2ba7c8 | 2019-04-22 17:52:13 -0700 | [diff] [blame] | 21 | spec: |
Andreas Geissler | 718fb74 | 2023-03-09 09:44:02 +0100 | [diff] [blame] | 22 | selector: {{- include "common.selectors" . | nindent 4 }} |
Kiran Kamineni | e2ba7c8 | 2019-04-22 17:52:13 -0700 | [diff] [blame] | 23 | replicas: {{ .Values.replicaCount }} |
| 24 | template: |
Andreas Geissler | 718fb74 | 2023-03-09 09:44:02 +0100 | [diff] [blame] | 25 | metadata: {{- include "common.templateMetadata" . | nindent 6 }} |
Kiran Kamineni | e2ba7c8 | 2019-04-22 17:52:13 -0700 | [diff] [blame] | 26 | spec: |
Andreas Geissler | 6fd2821 | 2024-10-22 11:33:38 +0200 | [diff] [blame] | 27 | {{ include "common.podSecurityContext" . | indent 6 | trim }} |
Kiran Kamineni | e2ba7c8 | 2019-04-22 17:52:13 -0700 | [diff] [blame] | 28 | containers: |
Sylvain Desbureaux | 37dc40c | 2020-11-21 22:46:57 +0100 | [diff] [blame] | 29 | - image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.image }} |
Kiran Kamineni | e2ba7c8 | 2019-04-22 17:52:13 -0700 | [diff] [blame] | 30 | imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} |
| 31 | name: {{ include "common.name" . }} |
| 32 | command: ["/opt/multicloud/k8splugin/k8plugin"] |
| 33 | workingDir: /opt/multicloud/k8splugin |
Andreas Geissler | 718fb74 | 2023-03-09 09:44:02 +0100 | [diff] [blame] | 34 | ports: {{ include "common.containerPorts" . | nindent 10 }} |
Andreas Geissler | 6fd2821 | 2024-10-22 11:33:38 +0200 | [diff] [blame] | 35 | {{ include "common.containerSecurityContext" . | indent 10 | trim }} |
Kiran Kamineni | e2ba7c8 | 2019-04-22 17:52:13 -0700 | [diff] [blame] | 36 | {{- 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: |
Andreas Geissler | a00b903 | 2024-11-27 13:21:36 +0100 | [diff] [blame^] | 49 | - mountPath: /tmp |
| 50 | name: tmp-dir-k8s |
| 51 | - mountPath: /opt/multicloud/k8splugin/k8sconfig.json |
| 52 | name: {{ include "common.name" .}} |
| 53 | subPath: k8sconfig.json |
miroslavmasaryk | a7ac7f0 | 2023-03-01 14:12:26 +0100 | [diff] [blame] | 54 | resources: {{ include "common.resources" . | nindent 10 }} |
Kiran Kamineni | e2ba7c8 | 2019-04-22 17:52:13 -0700 | [diff] [blame] | 55 | {{- if .Values.nodeSelector }} |
| 56 | nodeSelector: |
| 57 | {{ toYaml .Values.nodeSelector | indent 10 }} |
| 58 | {{- end -}} |
| 59 | {{- if .Values.affinity }} |
| 60 | affinity: |
| 61 | {{ toYaml .Values.affinity | indent 10 }} |
| 62 | {{- end }} |
Sylvain Desbureaux | 37dc40c | 2020-11-21 22:46:57 +0100 | [diff] [blame] | 63 | - image: {{ include "repositoryGenerator.repository" . }}/{{ .Values.global.artifactImage }} |
Andreas Geissler | dfa23c8 | 2022-05-13 16:54:43 +0200 | [diff] [blame] | 64 | imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} |
liboNet | 80f587a | 2019-05-17 01:30:16 +0800 | [diff] [blame] | 65 | name: framework-artifactbroker |
| 66 | command: ["/opt/app/distribution/bin/artifact-dist.sh"] |
| 67 | args: ["/opt/app/distribution/etc/mounted/config.json"] |
Andreas Geissler | 6fd2821 | 2024-10-22 11:33:38 +0200 | [diff] [blame] | 68 | {{ include "common.containerSecurityContext" . | indent 10 | trim }} |
| 69 | resources: {{ include "common.resources" . | nindent 10 }} |
liboNet | 80f587a | 2019-05-17 01:30:16 +0800 | [diff] [blame] | 70 | ports: |
| 71 | - containerPort: {{ .Values.artifactbroker.internalPort }} |
| 72 | protocol: TCP |
Andreas Geissler | 6fd2821 | 2024-10-22 11:33:38 +0200 | [diff] [blame] | 73 | {{- if eq .Values.liveness.enabled true }} |
| 74 | livenessProbe: |
| 75 | tcpSocket: |
| 76 | port: {{ .Values.artifactbroker.internalPort }} |
| 77 | initialDelaySeconds: {{ .Values.liveness.initialDelaySeconds }} |
| 78 | periodSeconds: {{ .Values.liveness.periodSeconds }} |
| 79 | {{ end -}} |
| 80 | readinessProbe: |
| 81 | tcpSocket: |
| 82 | port: {{ .Values.artifactbroker.internalPort }} |
| 83 | initialDelaySeconds: {{ .Values.readiness.initialDelaySeconds }} |
| 84 | periodSeconds: {{ .Values.readiness.periodSeconds }} |
liboNet | 80f587a | 2019-05-17 01:30:16 +0800 | [diff] [blame] | 85 | volumeMounts: |
Andreas Geissler | a00b903 | 2024-11-27 13:21:36 +0100 | [diff] [blame^] | 86 | - mountPath: /tmp |
| 87 | name: tmp-dir-broker |
Andreas Geissler | 6fd2821 | 2024-10-22 11:33:38 +0200 | [diff] [blame] | 88 | - mountPath: "{{ .Values.log.path }}" |
| 89 | name: framework-log |
liboNet | 80f587a | 2019-05-17 01:30:16 +0800 | [diff] [blame] | 90 | - mountPath: /opt/app/distribution/etc/mounted/config.json |
| 91 | name: {{ include "common.name" .}} |
| 92 | subPath: config.json |
| 93 | - mountPath: /data |
| 94 | name: artifact-data |
efiacor | c8c3316 | 2022-11-25 11:36:52 +0000 | [diff] [blame] | 95 | env: |
efiacor | c8c3316 | 2022-11-25 11:36:52 +0000 | [diff] [blame] | 96 | - name: SASL_JAAS_CONFIG |
david.mcweeney | 2886a11 | 2023-02-10 12:35:20 +0000 | [diff] [blame] | 97 | valueFrom: |
| 98 | secretKeyRef: |
| 99 | name: {{ include "common.name" . }}-ku |
| 100 | key: sasl.jaas.config |
farida azmy | 7251355 | 2021-10-12 18:55:21 +0200 | [diff] [blame] | 101 | serviceAccountName: {{ include "common.fullname" (dict "suffix" "read" "dot" . )}} |
Kiran Kamineni | e2ba7c8 | 2019-04-22 17:52:13 -0700 | [diff] [blame] | 102 | volumes: |
Andreas Geissler | a00b903 | 2024-11-27 13:21:36 +0100 | [diff] [blame^] | 103 | - name: tmp-dir-k8s |
| 104 | emptyDir: |
| 105 | sizeLimit: {{ .Values.volumes.tmpK8SSizeLimit }} |
| 106 | - name: tmp-dir-broker |
| 107 | emptyDir: |
| 108 | sizeLimit: {{ .Values.volumes.tmpBrokerSizeLimit }} |
Andreas Geissler | 6fd2821 | 2024-10-22 11:33:38 +0200 | [diff] [blame] | 109 | - name: framework-log |
| 110 | emptyDir: |
| 111 | sizeLimit: {{ .Values.volumes.logSizeLimit }} |
Kiran Kamineni | e2ba7c8 | 2019-04-22 17:52:13 -0700 | [diff] [blame] | 112 | - name : {{ include "common.name" . }} |
| 113 | configMap: |
| 114 | name: {{ include "common.fullname" . }} |
liboNet | 80f587a | 2019-05-17 01:30:16 +0800 | [diff] [blame] | 115 | - name: artifact-data |
Andreas Geissler | 6fd2821 | 2024-10-22 11:33:38 +0200 | [diff] [blame] | 116 | emptyDir: |
| 117 | sizeLimit: {{ .Values.volumes.artifactDataSizeLimit }} |
Andreas Geissler | bd0d31a | 2024-03-20 09:51:32 +0100 | [diff] [blame] | 118 | {{- include "common.imagePullSecrets" . | nindent 6 }} |