X-Git-Url: https://gerrit.onap.org/r/gitweb?a=blobdiff_plain;f=kubernetes%2Faai%2Fcomponents%2Faai-resources%2Ftemplates%2Fdeployment.yaml;h=54097faf6d2cca9b281e2e67f1625499808fe1a3;hb=21d48641d6344e9f00523ca15d49d44fcdb277b3;hp=2f60811331da020231c529ab11857cc14738a93c;hpb=74ef268ceb0d9cb3361c5ed252a86ed9d30a7f0d;p=oom.git diff --git a/kubernetes/aai/components/aai-resources/templates/deployment.yaml b/kubernetes/aai/components/aai-resources/templates/deployment.yaml index 2f60811331..54097faf6d 100644 --- a/kubernetes/aai/components/aai-resources/templates/deployment.yaml +++ b/kubernetes/aai/components/aai-resources/templates/deployment.yaml @@ -105,7 +105,7 @@ spec: - --job-name - {{ include "common.release" . }}-aai-graphadmin-create-db-schema {{- else }} - - --container-name + - --app-name {{- if .Values.global.cassandra.localCluster }} - aai-cassandra {{- else }} @@ -135,6 +135,20 @@ spec: echo "*** actual launch of AAI Resources" /bin/bash /opt/app/aai-resources/docker-entrypoint.sh env: + {{- if .Values.config.env }} + {{- range $key,$value := .Values.config.env }} + - name: {{ $key | upper | quote}} + value: {{ $value | quote}} + {{- end }} + {{- end }} + {{- if .Values.config.profiling.enabled }} + - name: PRE_JVM_ARGS + value: '{{ join " " .Values.config.profiling.args }}' + {{- end }} + {{- if .Values.config.debug.enabled }} + - name: POST_JVM_ARGS + value: {{ .Values.config.debug.args | quote }} + {{- end }} - name: LOCAL_USER_ID value: {{ .Values.global.config.userId | quote }} - name: LOCAL_GROUP_ID @@ -178,10 +192,17 @@ spec: ports: - containerPort: {{ .Values.service.internalPort }} name: {{ .Values.service.portName }} + {{- if .Values.config.debug.enabled }} - containerPort: {{ .Values.service.internalPort2 }} name: {{ .Values.service.portName2 }} + {{- end }} - containerPort: {{ .Values.service.internalPort3 }} name: {{ .Values.service.portName3 }} + {{- if .Values.config.profiling.enabled }} + - containerPort: {{ .Values.service.internalPort4 }} + name: {{ .Values.service.portName4 }} + {{- end }} + lifecycle: # wait for active requests (long-running tasks) to be finished # Before the SIGTERM is invoked, Kubernetes exposes a preStop hook in the Pod.