Kiran Kamineni | e2ba7c8 | 2019-04-22 17:52:13 -0700 | [diff] [blame] | 1 | {{/* |
| 2 | # Copyright 2019 Intel Corporation, Inc |
| 3 | # |
| 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 |
| 7 | # |
| 8 | # http://www.apache.org/licenses/LICENSE-2.0 |
| 9 | # |
| 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. |
| 15 | */}} |
| 16 | |
| 17 | apiVersion: extensions/v1beta1 |
| 18 | kind: Deployment |
| 19 | metadata: |
| 20 | name: {{ include "common.fullname" . }} |
| 21 | namespace: {{ include "common.namespace" . }} |
| 22 | labels: |
| 23 | app: {{ include "common.name" . }} |
| 24 | chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }} |
Krzysztof Opasiak | 137d7cc | 2020-01-24 23:49:11 +0100 | [diff] [blame] | 25 | release: {{ include "common.release" . }} |
Kiran Kamineni | e2ba7c8 | 2019-04-22 17:52:13 -0700 | [diff] [blame] | 26 | heritage: {{ .Release.Service }} |
| 27 | spec: |
| 28 | replicas: {{ .Values.replicaCount }} |
| 29 | template: |
| 30 | metadata: |
| 31 | labels: |
| 32 | app: {{ include "common.name" . }} |
Krzysztof Opasiak | 137d7cc | 2020-01-24 23:49:11 +0100 | [diff] [blame] | 33 | release: {{ include "common.release" . }} |
Kiran Kamineni | e2ba7c8 | 2019-04-22 17:52:13 -0700 | [diff] [blame] | 34 | spec: |
| 35 | containers: |
| 36 | - image: "{{ include "common.repository" . }}/{{ .Values.image }}" |
| 37 | imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} |
| 38 | name: {{ include "common.name" . }} |
| 39 | command: ["/opt/multicloud/k8splugin/k8plugin"] |
| 40 | workingDir: /opt/multicloud/k8splugin |
| 41 | ports: |
| 42 | - containerPort: {{ .Values.service.internalPort }} |
| 43 | {{- if eq .Values.liveness.enabled true }} |
| 44 | livenessProbe: |
| 45 | tcpSocket: |
| 46 | port: {{ .Values.service.internalPort }} |
| 47 | initialDelaySeconds: {{ .Values.liveness.initialDelaySeconds }} |
| 48 | periodSeconds: {{ .Values.liveness.periodSeconds }} |
| 49 | {{ end -}} |
| 50 | readinessProbe: |
| 51 | tcpSocket: |
| 52 | port: {{ .Values.service.internalPort }} |
| 53 | initialDelaySeconds: {{ .Values.readiness.initialDelaySeconds }} |
| 54 | periodSeconds: {{ .Values.readiness.periodSeconds }} |
| 55 | volumeMounts: |
| 56 | - mountPath: /etc/localtime |
| 57 | name: localtime |
| 58 | readOnly: true |
| 59 | - mountPath: /opt/multicloud/k8splugin/k8sconfig.json |
| 60 | name: {{ include "common.name" .}} |
| 61 | subPath: k8sconfig.json |
| 62 | resources: |
| 63 | {{ include "common.resources" . | indent 10 }} |
| 64 | {{- if .Values.nodeSelector }} |
| 65 | nodeSelector: |
| 66 | {{ toYaml .Values.nodeSelector | indent 10 }} |
| 67 | {{- end -}} |
| 68 | {{- if .Values.affinity }} |
| 69 | affinity: |
| 70 | {{ toYaml .Values.affinity | indent 10 }} |
| 71 | {{- end }} |
liboNet | 80f587a | 2019-05-17 01:30:16 +0800 | [diff] [blame] | 72 | - image: "{{ include "common.repository" . }}/{{ .Values.global.artifactImage }}" |
| 73 | name: framework-artifactbroker |
| 74 | command: ["/opt/app/distribution/bin/artifact-dist.sh"] |
| 75 | args: ["/opt/app/distribution/etc/mounted/config.json"] |
| 76 | ports: |
| 77 | - containerPort: {{ .Values.artifactbroker.internalPort }} |
| 78 | protocol: TCP |
| 79 | volumeMounts: |
| 80 | - mountPath: /opt/app/distribution/etc/mounted/config.json |
| 81 | name: {{ include "common.name" .}} |
| 82 | subPath: config.json |
| 83 | - mountPath: /data |
| 84 | name: artifact-data |
| 85 | |
Kiran Kamineni | e2ba7c8 | 2019-04-22 17:52:13 -0700 | [diff] [blame] | 86 | volumes: |
| 87 | - name: localtime |
| 88 | hostPath: |
| 89 | path: /etc/localtime |
| 90 | - name : {{ include "common.name" . }} |
| 91 | configMap: |
| 92 | name: {{ include "common.fullname" . }} |
liboNet | 80f587a | 2019-05-17 01:30:16 +0800 | [diff] [blame] | 93 | - name: artifact-data |
| 94 | emptyDir: {} |
Kiran Kamineni | e2ba7c8 | 2019-04-22 17:52:13 -0700 | [diff] [blame] | 95 | imagePullSecrets: |
| 96 | - name: "{{ include "common.namespace" . }}-docker-registry-key" |