blob: 794c6548b8066ad8e85b95beac3a15b0aa5c832e [file] [log] [blame]
Mandeep Khindad6ea9872017-06-24 11:49:37 -04001apiVersion: extensions/v1beta1
2kind: Deployment
3metadata:
4 name: pap
Mandeep Khinda0e8f8892017-08-25 03:31:17 +00005 namespace: "{{ .Values.nsPrefix }}-policy"
Mandeep Khindad6ea9872017-06-24 11:49:37 -04006spec:
7 selector:
8 matchLabels:
9 app: pap
10 template:
11 metadata:
12 labels:
13 app: pap
14 name: pap
15 annotations:
16 pod.beta.kubernetes.io/init-containers: '[
17 {
18 "args": [
19 "--container-name",
20 "nexus",
21 "--container-name",
22 "mariadb"
23 ],
24 "command": [
25 "/root/ready.py"
26 ],
27 "env": [
28 {
29 "name": "NAMESPACE",
30 "valueFrom": {
31 "fieldRef": {
32 "apiVersion": "v1",
33 "fieldPath": "metadata.namespace"
34 }
35 }
36 }
37 ],
Eric Aucdaafde2017-08-31 16:18:11 -040038 "image": "{{ .Values.image.readiness }}:{{ .Values.image.readinessVersion }}",
kerenj3b697f62017-08-23 11:21:21 +000039 "imagePullPolicy": "{{ .Values.pullPolicy }}",
Mandeep Khindad6ea9872017-06-24 11:49:37 -040040 "name": "pap-readiness"
41 },
42 {
43 "env": [
44 {
45 "name": "POD_IP",
46 "valueFrom": {
47 "fieldRef": {
48 "apiVersion": "v1",
49 "fieldPath": "status.podIP"
50 }
51 }
52 }
53 ],
54 "command": ["/bin/bash", "-c", "echo $POD_IP > /config/ip_addr.txt"],
55 "volumeMounts": [
56 {
57 "mountPath": "/config/",
58 "name": "pe"
59 }
60 ],
kerenj3b697f62017-08-23 11:21:21 +000061 "image": "{{ .Values.image.ubuntu }}",
62 "imagePullPolicy": "{{ .Values.pullPolicy }}",
Mandeep Khindad6ea9872017-06-24 11:49:37 -040063 "name": "generate-ip-addr-txt"
64 }
65 ]'
66 spec:
67 containers:
68 - command:
69 - /bin/bash
70 - ./do-start.sh
71 - pap
Eric Aucdaafde2017-08-31 16:18:11 -040072 image: "{{ .Values.image.policyPe }}:{{ .Values.image.policyPeVersion }}"
kerenj3b697f62017-08-23 11:21:21 +000073 imagePullPolicy: {{ .Values.pullPolicy }}
Mandeep Khindad6ea9872017-06-24 11:49:37 -040074 name: pap
75 ports:
76 - containerPort: 8443
77 - containerPort: 9091
78 readinessProbe:
79 tcpSocket:
80 port: 9091
81 initialDelaySeconds: 5
82 periodSeconds: 10
83 volumeMounts:
yuryn8b3bc5a2017-09-13 19:21:03 +030084 - mountPath: /etc/localtime
85 name: localtime
86 readOnly: true
Mandeep Khindad6ea9872017-06-24 11:49:37 -040087 - mountPath: /tmp/policy-install/config/
88 name: pe
89 volumes:
yuryn8b3bc5a2017-09-13 19:21:03 +030090 - name: localtime
91 hostPath:
92 path: /etc/localtime
Mandeep Khindad6ea9872017-06-24 11:49:37 -040093 - name: pe
94 hostPath:
Mandeep Khinda0e8f8892017-08-25 03:31:17 +000095 path: /dockerdata-nfs/{{ .Values.nsPrefix }}/policy/opt/policy/config/pe/
Borislav Glozman5197e2e2017-07-24 10:45:28 +030096 imagePullSecrets:
Mandeep Khinda0e8f8892017-08-25 03:31:17 +000097 - name: "{{ .Values.nsPrefix }}-docker-registry-key"