Using common template port numbers
[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 "vescollector.fullname" . }}\r
24   generation: 1\r
25   labels:\r
26     app: dcae-ves-collector\r
27     cfydeployment: ves\r
28     cfynode: ves\r
29     cfynodeinstance: ves_uj48fg\r
30     k8sdeployment: dep-dcae-ves-collector\r
31   annotations:\r
32     deployment.kubernetes.io/revision: '1'\r
33 spec:\r
34   replicas: {{ .Values.ves.replicaCount }}\r
35   selector:\r
36     matchLabels:\r
37       app: dcae-ves-collector\r
38       cfydeployment: ves\r
39       cfynode: ves\r
40       cfynodeinstance: ves_uj48fg\r
41       k8sdeployment: dep-dcae-ves-collector\r
42   template:\r
43     metadata:\r
44       labels:\r
45         app: dcae-ves-collector\r
46         cfydeployment: ves\r
47         cfynode: ves\r
48         cfynodeinstance: ves_uj48fg\r
49         k8sdeployment: dep-dcae-ves-collector\r
50     spec:\r
51       volumes:\r
52       - name: component-log\r
53         emptyDir: {}\r
54       - name: dmaap-config-file\r
55         configMap:\r
56           name: dmaap-configmap\r
57       containers:\r
58       - name: {{ include "common.namespace" . }}-{{include "common.name" . }}\r
59         image: {{ .Values.ves.onapRepository }}/{{ .Values.ves.image.name }}:{{ .Values.ves.image.tag }}\r
60         ports:\r
61         - containerPort: {{ include "common.serviceport.ves.http.container" . }}\r
62           protocol: TCP\r
63         - containerPort: {{ include "common.serviceport.ves.https.container" . }}\r
64           protocol: TCP\r
65         env:\r
66         - name: CONSUL_HOST\r
67           value: consul-server.onap\r
68         - name: CONFIG_BINDING_SERVICE\r
69           value: config-binding-service\r
70         - name: POD_IP\r
71           valueFrom:\r
72             fieldRef:\r
73               apiVersion: v1\r
74               fieldPath: status.podIP\r
75         resources: {}\r
76         volumeMounts:\r
77         - name: component-log\r
78           mountPath: "/opt/app/VESCollector/logs/ecomp"\r
79         - name: dmaap-config-file\r
80           mountPath: "/opt/app/VESCollector/etc/DmaapConfig.json"\r
81           subPath: DMaapConfig.json\r
82         readinessProbe:\r
83           httpGet:\r
84             path: "/healthcheck"\r
85             port: {{ include "common.serviceport.ves.http.container" . }}\r
86             scheme: HTTP\r
87           initialDelaySeconds: 5\r
88           timeoutSeconds: 1\r
89           periodSeconds: 15\r
90           successThreshold: 1\r
91           failureThreshold: 1\r
92         terminationMessagePath: "/dev/termination-log"\r
93         terminationMessagePolicy: File\r
94         imagePullPolicy: IfNotPresent\r
95       restartPolicy: Always\r
96       terminationGracePeriodSeconds: 30\r
97       dnsPolicy: ClusterFirst\r
98       securityContext: {}\r
99       imagePullSecrets:\r
100       - name: onap-docker-registry-key\r
101       hostname: dcae-ves-collector\r
102       schedulerName: default-scheduler\r
103   strategy:\r
104     type: RollingUpdate\r
105     rollingUpdate:\r
106       maxUnavailable: 1\r
107       maxSurge: 1\r
108   revisionHistoryLimit: 10\r
109   progressDeadlineSeconds: 600\r