summaryrefslogtreecommitdiffstats
path: root/kubernetes/aai/charts/aai-sparky-be/templates
diff options
context:
space:
mode:
authorMandeep Khinda <mandeep.khinda@amdocs.com>2018-04-09 21:09:51 +0000
committerMandeep Khinda <mandeep.khinda@amdocs.com>2018-04-09 21:09:51 +0000
commit9ed650535002af727f79bb33af89ed4f9947bb84 (patch)
treefdac36fd32b563edfdffddba5ca67b07e506c163 /kubernetes/aai/charts/aai-sparky-be/templates
parentd96413f48c8a5709a54bdb22a565035313ecef02 (diff)
Removing aai oxm files from configmaps
-they have no parameterization, are huge files, and are breaching the configmap space removing them and finding an alternate way of getting them into the containers if they need to be externalized that can be done in a separate issue. for now emptyDir{} is good enough. Issue-ID: OOM-858 Change-Id: I05602302890dd3e0363dc355f1697b76fea509a1 Signed-off-by: Mandeep Khinda <mandeep.khinda@amdocs.com>
Diffstat (limited to 'kubernetes/aai/charts/aai-sparky-be/templates')
-rw-r--r--kubernetes/aai/charts/aai-sparky-be/templates/configmap.yaml8
-rw-r--r--kubernetes/aai/charts/aai-sparky-be/templates/deployment.yaml22
2 files changed, 17 insertions, 13 deletions
diff --git a/kubernetes/aai/charts/aai-sparky-be/templates/configmap.yaml b/kubernetes/aai/charts/aai-sparky-be/templates/configmap.yaml
index 68fa1e4966..d827c4eb36 100644
--- a/kubernetes/aai/charts/aai-sparky-be/templates/configmap.yaml
+++ b/kubernetes/aai/charts/aai-sparky-be/templates/configmap.yaml
@@ -9,14 +9,6 @@ data:
apiVersion: v1
kind: ConfigMap
metadata:
- name: {{ include "common.fullname" . }}-model
- namespace: {{ include "common.namespace" . }}
-data:
-{{ tpl (.Files.Glob "resources/config/model/*").AsConfig . | indent 2 }}
----
-apiVersion: v1
-kind: ConfigMap
-metadata:
name: {{ include "common.fullname" . }}-portal
namespace: {{ include "common.namespace" . }}
data:
diff --git a/kubernetes/aai/charts/aai-sparky-be/templates/deployment.yaml b/kubernetes/aai/charts/aai-sparky-be/templates/deployment.yaml
index 278a32728e..05a808e805 100644
--- a/kubernetes/aai/charts/aai-sparky-be/templates/deployment.yaml
+++ b/kubernetes/aai/charts/aai-sparky-be/templates/deployment.yaml
@@ -34,6 +34,19 @@ spec:
release: {{ .Release.Name }}
name: {{ include "common.name" . }}
spec:
+ initContainers:
+ - name: {{ include "common.name" . }}-inject-models
+ command:
+ - /bin/bash
+ - "-c"
+ - |
+ git clone -b {{ .Values.config.gerritBranch }} --single-branch {{ .Values.config.gerritProject }} /tmp/gerrit
+ cp -rp /tmp/gerrit/data-router/appconfig/model/* /model-dir
+ image: "{{ .Values.global.repository | default .Values.dockerHubRepository }}/{{ .Values.ubuntuInitImage }}"
+ imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
+ volumeMounts:
+ - name: modeldir
+ mountPath: "/model-dir"
containers:
- name: {{ include "common.name" . }}
image: "{{ .Values.global.repository | default .Values.repository }}/{{ .Values.image }}"
@@ -69,8 +82,6 @@ spec:
- mountPath: /opt/app/sparky/config/aai.properties
subPath: aai.properties
name: {{ include "common.fullname" . }}-config
- - mountPath: /opt/app/sparky/config/model/
- name: {{ include "common.fullname" . }}-model-config
- mountPath: /opt/app/sparky/config/portal/
name: {{ include "common.fullname" . }}-portal-config
- mountPath: /var/log/onap
@@ -78,6 +89,8 @@ spec:
- mountPath: /opt/app/sparky/bundleconfig/etc/logback.xml
name: {{ include "common.fullname" . }}-log-conf
subPath: logback.xml
+ - name: modeldir
+ mountPath: /opt/app/sparky/config/model
ports:
- containerPort: {{ .Values.service.internalPort }}
# disable liveness probe when breakpoints set in debugger
@@ -125,9 +138,6 @@ spec:
- name: {{ include "common.fullname" . }}-config
configMap:
name: {{ include "common.fullname" . }}
- - name: {{ include "common.fullname" . }}-model-config
- configMap:
- name: {{ include "common.fullname" . }}-model
- name: {{ include "common.fullname" . }}-portal-config
configMap:
name: {{ include "common.fullname" . }}-portal
@@ -144,6 +154,8 @@ spec:
- name: {{ include "common.fullname" . }}-log-conf
configMap:
name: {{ include "common.fullname" . }}-log
+ - name: modeldir
+ emptyDir: {}
restartPolicy: {{ .Values.global.restartPolicy | default .Values.restartPolicy }}
imagePullSecrets:
- name: "{{ include "common.namespace" . }}-docker-registry-key"