summaryrefslogtreecommitdiffstats
path: root/kubernetes/aai/charts/aai-data-router/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-data-router/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-data-router/templates')
-rw-r--r--kubernetes/aai/charts/aai-data-router/templates/configmap.yaml32
-rw-r--r--kubernetes/aai/charts/aai-data-router/templates/deployment.yaml40
2 files changed, 16 insertions, 56 deletions
diff --git a/kubernetes/aai/charts/aai-data-router/templates/configmap.yaml b/kubernetes/aai/charts/aai-data-router/templates/configmap.yaml
index a8793acd9f..9652712aa6 100644
--- a/kubernetes/aai/charts/aai-data-router/templates/configmap.yaml
+++ b/kubernetes/aai/charts/aai-data-router/templates/configmap.yaml
@@ -9,38 +9,6 @@ data:
apiVersion: v1
kind: ConfigMap
metadata:
- name: {{ include "common.fullname" . }}-model-v8
- namespace: {{ include "common.namespace" . }}
-data:
-{{ tpl (.Files.Glob "resources/config/model/aai_oxm_v8.xml").AsConfig . | indent 2 }}
----
-apiVersion: v1
-kind: ConfigMap
-metadata:
- name: {{ include "common.fullname" . }}-model-v9
- namespace: {{ include "common.namespace" . }}
-data:
-{{ tpl (.Files.Glob "resources/config/model/aai_oxm_v9.xml").AsConfig . | indent 2 }}
----
-apiVersion: v1
-kind: ConfigMap
-metadata:
- name: {{ include "common.fullname" . }}-model-v10
- namespace: {{ include "common.namespace" . }}
-data:
-{{ tpl (.Files.Glob "resources/config/model/aai_oxm_v10.xml").AsConfig . | indent 2 }}
----
-apiVersion: v1
-kind: ConfigMap
-metadata:
- name: {{ include "common.fullname" . }}-model-v11
- namespace: {{ include "common.namespace" . }}
-data:
-{{ tpl (.Files.Glob "resources/config/model/aai_oxm_v11.xml").AsConfig . | indent 2 }}
----
-apiVersion: v1
-kind: ConfigMap
-metadata:
name: {{ include "common.fullname" . }}-dynamic
namespace: {{ include "common.namespace" . }}
data:
diff --git a/kubernetes/aai/charts/aai-data-router/templates/deployment.yaml b/kubernetes/aai/charts/aai-data-router/templates/deployment.yaml
index 79bcff33eb..cf81948160 100644
--- a/kubernetes/aai/charts/aai-data-router/templates/deployment.yaml
+++ b/kubernetes/aai/charts/aai-data-router/templates/deployment.yaml
@@ -56,6 +56,18 @@ spec:
volumeMounts:
- name: {{ include "common.fullname" . }}-logs
mountPath: /logroot/
+ - 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 }}"
@@ -79,18 +91,6 @@ spec:
- mountPath: /etc/localtime
name: localtime
readOnly: true
- - mountPath: /opt/app/data-router/config/model/aai_oxm_v8.xml
- subPath: aai_oxm_v8.xml
- name: {{ include "common.fullname" . }}-model-v8
- - mountPath: /opt/app/data-router/config/model/aai_oxm_v9.xml
- subPath: aai_oxm_v9.xml
- name: {{ include "common.fullname" . }}-model-v9
- - mountPath: /opt/app/data-router/config/model/aai_oxm_v10.xml
- subPath: aai_oxm_v10.xml
- name: {{ include "common.fullname" . }}-model-v10
- - mountPath: /opt/app/data-router/config/model/aai_oxm_v11.xml
- subPath: aai_oxm_v11.xml
- name: {{ include "common.fullname" . }}-model-v11
- mountPath: /opt/app/data-router/config/auth
name: {{ include "common.fullname" . }}-auth
- mountPath: /opt/app/data-router/config/data-router.properties
@@ -104,6 +104,8 @@ spec:
name: {{ include "common.fullname" . }}-dynamic-policy
- mountPath: /logs/
name: {{ include "common.fullname" . }}-logs
+ - name: modeldir
+ mountPath: /opt/app/data-router/config/model
ports:
- containerPort: {{ .Values.service.internalPort }}
{{- if eq .Values.liveness.enabled true }}
@@ -122,18 +124,6 @@ spec:
- name: localtime
hostPath:
path: /etc/localtime
- - name: {{ include "common.fullname" . }}-model-v8
- configMap:
- name: {{ include "common.fullname" . }}-model-v8
- - name: {{ include "common.fullname" . }}-model-v9
- configMap:
- name: {{ include "common.fullname" . }}-model-v9
- - name: {{ include "common.fullname" . }}-model-v10
- configMap:
- name: {{ include "common.fullname" . }}-model-v10
- - name: {{ include "common.fullname" . }}-model-v11
- configMap:
- name: {{ include "common.fullname" . }}-model-v11
- name: {{ include "common.fullname" . }}-auth
secret:
secretName: {{ include "common.fullname" . }}
@@ -149,6 +139,8 @@ spec:
- name: {{ include "common.fullname" . }}-logs
hostPath:
path: {{ .Values.persistence.mountPath }}/{{ include "common.namespace" . }}/{{ .Values.persistence.mountSubPath }}
+ - name: modeldir
+ emptyDir: {}
restartPolicy: {{ .Values.global.restartPolicy | default .Values.restartPolicy }}
imagePullSecrets:
- name: "{{ include "common.namespace" . }}-docker-registry-key"