| apiVersion: extensions/v1beta1 |
| kind: Deployment |
| metadata: |
| name: aai-service |
| namespace: "{{ .Values.nsPrefix }}-aai" |
| spec: |
| selector: |
| matchLabels: |
| app: aai-service |
| template: |
| metadata: |
| labels: |
| app: aai-service |
| name: aai-service |
| annotations: |
| pod.beta.kubernetes.io/init-containers: '[{ |
| "args": [ |
| "--container-name", "aai-resources", |
| "--container-name", "aai-traversal" |
| ], |
| "command": [ |
| "/root/ready.py" |
| ], |
| "env": [{ |
| "name": "NAMESPACE", |
| "valueFrom": { |
| "fieldRef": { |
| "apiVersion": "v1", |
| "fieldPath": "metadata.namespace" |
| } |
| } |
| }], |
| "image": "{{ .Values.image.readiness }}", |
| "imagePullPolicy": "{{ .Values.pullPolicy }}", |
| "name": "aai-service-readiness" |
| }]' |
| spec: |
| containers: |
| - name: aai-service |
| image: "{{ .Values.image.aaiProxy }}:{{ .Values.image.aaiProxyVersion}}" |
| imagePullPolicy: {{ .Values.pullPolicy }} |
| volumeMounts: |
| - mountPath: /etc/localtime |
| name: localtime |
| readOnly: true |
| - mountPath: /dev/log |
| name: aai-service-log |
| - mountPath: /usr/local/etc/haproxy/haproxy.cfg |
| name: haproxy-cfg |
| ports: |
| - containerPort: 8080 |
| - containerPort: 8443 |
| readinessProbe: |
| tcpSocket: |
| port: 8443 |
| initialDelaySeconds: 5 |
| periodSeconds: 10 |
| volumes: |
| - name: localtime |
| hostPath: |
| path: /etc/localtime |
| - name: aai-service-log |
| hostPath: |
| path: "/dockerdata-nfs/{{ .Values.nsPrefix }}/aai/haproxy/log/" |
| - name: haproxy-cfg |
| hostPath: |
| path: "/dockerdata-nfs/{{ .Values.nsPrefix }}/aai/haproxy/haproxy.cfg" |
| restartPolicy: Always |
| imagePullSecrets: |
| - name: "{{ .Values.nsPrefix }}-docker-registry-key" |