Update annotations to spec for vid
[oom.git] / kubernetes / appc / templates / appc-deployment.yaml
1 #{{ if not .Values.disableAppcAppc }}
2 apiVersion: extensions/v1beta1
3 kind: Deployment
4 metadata:
5   name: appc
6   namespace: "{{ .Values.nsPrefix }}-appc"
7 spec:
8   selector:
9     matchLabels:
10       app: appc
11   template:
12     metadata:
13       labels:
14         app: appc
15       name: appc
16       annotations:
17         pod.beta.kubernetes.io/init-containers: '[
18           {
19               "args": [
20                   "--container-name",
21                   "appc-db-container"
22               ],
23               "command": [
24                   "/root/ready.py"
25               ],
26               "env": [
27                   {
28                       "name": "NAMESPACE",
29                       "valueFrom": {
30                           "fieldRef": {
31                               "apiVersion": "v1",
32                               "fieldPath": "metadata.namespace"
33                           }
34                       }
35                   }
36               ],
37               "image": "{{ .Values.image.readiness }}",
38               "imagePullPolicy": "{{ .Values.pullPolicy }}",
39               "name": "appc-readiness"
40           }
41           ]'
42     spec:
43       containers:
44       - command:
45         - /opt/openecomp/appc/bin/startODL.sh
46         env:
47         - name: MYSQL_ROOT_PASSWORD
48           value: openECOMP1.0
49         - name: SDNC_CONFIG_DIR
50           value: /opt/openecomp/appc/data/properties
51         - name: APPC_CONFIG_DIR
52           value: /opt/openecomp/appc/data/properties
53         - name: DMAAP_TOPIC_ENV
54           value: SUCCESS
55         image: {{ .Values.image.appc }}
56         imagePullPolicy: {{ .Values.pullPolicy }}
57         name: appc-controller-container
58         volumeMounts:
59         - mountPath: /etc/localtime
60           name: localtime
61           readOnly: true
62         - mountPath: /opt/openecomp/appc/data/properties/appc.properties
63           name: appc-properties
64         - mountPath: /opt/openecomp/appc/data/properties/aaiclient.properties
65           name: appc-aaiclient-properties
66         - mountPath: /opt/onap/sdnc/data/properties/aaiclient.properties
67           name: sdnc-aaiclient-properties
68         - mountPath: /var/log/onap
69           name: appc-logs
70         - mountPath: /opt/opendaylight/current/etc/org.ops4j.pax.logging.cfg
71           name: appc-log-config
72         ports:
73         - containerPort: 8181
74         - containerPort: 1830
75         readinessProbe:
76           tcpSocket:
77             port: 8181
78           initialDelaySeconds: 5
79           periodSeconds: 10
80       - image: {{ .Values.image.filebeat }}
81         imagePullPolicy: {{ .Values.pullPolicy }}
82         name: filebeat-onap
83         volumeMounts:
84         - mountPath: /usr/share/filebeat/filebeat.yml
85           name: filebeat-conf
86         - mountPath: /var/log/onap
87           name: appc-logs
88         - mountPath: /usr/share/filebeat/data
89           name: appc-data-filebeat
90       volumes:
91         - name: localtime
92           hostPath:
93             path: /etc/localtime
94         - name: filebeat-conf
95           hostPath:
96             path: /dockerdata-nfs/{{ .Values.nsPrefix }}/log/filebeat/log4j/filebeat.yml
97         - name: appc-log-config
98           hostPath:
99             path: /dockerdata-nfs/{{ .Values.nsPrefix }}/log/appc/org.ops4j.pax.logging.cfg
100         - name: appc-logs
101           emptyDir: {}
102         - name: appc-data-filebeat
103           emptyDir: {}
104         - name: appc-properties
105           hostPath:
106             path: /dockerdata-nfs/{{ .Values.nsPrefix }}/appc/conf/appc.properties
107         - name: appc-aaiclient-properties
108           hostPath:
109             path: /dockerdata-nfs/{{ .Values.nsPrefix }}/appc/conf/aaiclient.properties
110         - name: sdnc-aaiclient-properties
111           hostPath:
112             path: /dockerdata-nfs/{{ .Values.nsPrefix }}/sdnc/conf/aaiclient.properties
113       imagePullSecrets:
114       - name: "{{ .Values.nsPrefix }}-docker-registry-key"
115 #{{ end }}