05040f8d88344cfe69a2c54f7de15ec2079b02ca
[it/dep.git] / ric-aux / 80-Auxiliary-Functions / helm / ves / templates / ves-deployment.yaml
1 ################################################################################\r
2 #   Copyright (c) 2019 AT&T Intellectual Property.                             #\r
3 #   Copyright (c) 2019 Nokia.                                                  #\r
4 #                                                                              #\r
5 #   Licensed under the Apache License, Version 2.0 (the "License");            #\r
6 #   you may not use this file except in compliance with the License.           #\r
7 #   You may obtain a copy of the License at                                    #\r
8 #                                                                              #\r
9 #       http://www.apache.org/licenses/LICENSE-2.0                             #\r
10 #                                                                              #\r
11 #   Unless required by applicable law or agreed to in writing, software        #\r
12 #   distributed under the License is distributed on an "AS IS" BASIS,          #\r
13 #   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.   #\r
14 #   See the License for the specific language governing permissions and        #\r
15 #   limitations under the License.                                             #\r
16 ################################################################################\r
17 \r
18 \r
19 \r
20 kind: Deployment\r
21 apiVersion: extensions/v1beta1\r
22 metadata:\r
23   name: {{ include "common.deploymentname.ves" . }}\r
24   generation: 1\r
25   labels:\r
26     app: {{ include "common.namespace.aux" . }}-{{ include "common.name.ves" . }}\r
27     chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}\r
28     release: {{ .Release.Name }}\r
29     heritage: {{ .Release.Service }}\r
30   annotations:\r
31     deployment.kubernetes.io/revision: '1'\r
32 spec:\r
33   replicas: {{ .Values.ves.replicaCount }}\r
34   selector:\r
35     matchLabels:\r
36       app: {{ include "common.namespace.aux" . }}-{{ include "common.name.ves" . }}\r
37       release: {{ .Release.Name }}\r
38   template:\r
39     metadata:\r
40       labels:\r
41         app: {{ include "common.namespace.aux" . }}-{{ include "common.name.ves" . }}\r
42         release: {{ .Release.Name }}\r
43     spec:\r
44       hostname: {{ include "common.name.ves" . }}\r
45       volumes:\r
46       - name: component-log\r
47         emptyDir: {}\r
48       - name: dmaap-config-file\r
49         configMap:\r
50           name: {{ include "common.configmapname.ves" . }}\r
51         imagePullPolicy: {{ include "common.pullPolicy" . }}\r
52       imagePullSecrets:\r
53       - name: onap-docker-registry-key\r
54       containers:\r
55       - name: {{ include "common.containername.ves" . }}\r
56         image: {{ .Values.ves.onapRepository }}/{{ .Values.ves.image.name }}:{{ .Values.ves.image.tag }}\r
57         ports:\r
58         - containerPort: {{ include "common.serviceport.ves.http.container" . }}\r
59           protocol: TCP\r
60         - containerPort: {{ include "common.serviceport.ves.https.container" . }}\r
61           protocol: TCP\r
62         volumeMounts:\r
63         - name: component-log\r
64           mountPath: "/opt/app/VESCollector/logs/ecomp"\r
65         - name: dmaap-config-file\r
66           mountPath: "/opt/app/VESCollector/etc/DmaapConfig.json"\r
67           subPath: DMaapConfig.json\r
68         readinessProbe:\r
69           httpGet:\r
70             path: "/healthcheck"\r
71             port: {{ include "common.serviceport.ves.http.container" . }}\r
72             scheme: HTTP\r
73           initialDelaySeconds: 5\r
74           timeoutSeconds: 1\r
75           periodSeconds: 15\r
76           successThreshold: 1\r
77           failureThreshold: 1\r
78         terminationMessagePath: "/dev/termination-log"\r
79         terminationMessagePolicy: File\r
80       restartPolicy: Always