diff options
author | Pramod <pramod.kumarsharma@amdocs.com> | 2018-01-17 12:05:14 +0000 |
---|---|---|
committer | BorislavG <Borislav.Glozman@amdocs.com> | 2018-02-07 14:56:42 +0000 |
commit | ba635b3dc4d520e4be28dc82c40b049567ff2c88 (patch) | |
tree | fa61825a68b5c577d207e8090d9a1c81d5b3a38d /kubernetes/sdc/templates | |
parent | 18c2dbcdf7904d6a4030efa141fe232009362800 (diff) |
Config seg sdc deployment
Issue-ID: OOM-550
Signed-off-by: Pramod <pramod.kumarsharma@amdocs.com>
Change-Id: Ibad8a16fb289ddd4260be5cce0c787e4de212a97
Diffstat (limited to 'kubernetes/sdc/templates')
-rw-r--r-- | kubernetes/sdc/templates/sdc-be.yaml | 14 | ||||
-rw-r--r-- | kubernetes/sdc/templates/sdc-cs.yaml | 5 | ||||
-rw-r--r-- | kubernetes/sdc/templates/sdc-environments-configmap.yaml | 9 | ||||
-rw-r--r-- | kubernetes/sdc/templates/sdc-es.yaml | 21 | ||||
-rw-r--r-- | kubernetes/sdc/templates/sdc-fe-configmap.yaml | 9 | ||||
-rw-r--r-- | kubernetes/sdc/templates/sdc-fe.yaml | 20 | ||||
-rw-r--r-- | kubernetes/sdc/templates/sdc-kb.yaml | 5 | ||||
-rw-r--r-- | kubernetes/sdc/templates/sdc-log-configmap.yaml | 27 |
8 files changed, 90 insertions, 20 deletions
diff --git a/kubernetes/sdc/templates/sdc-be.yaml b/kubernetes/sdc/templates/sdc-be.yaml index 41560525e1..6485aa1983 100644 --- a/kubernetes/sdc/templates/sdc-be.yaml +++ b/kubernetes/sdc/templates/sdc-be.yaml @@ -89,27 +89,29 @@ spec: volumeMounts: - mountPath: /usr/share/filebeat/filebeat.yml name: filebeat-conf + subPath: filebeat.yml - mountPath: /var/log/onap name: sdc-logs-2 - mountPath: /usr/share/filebeat/data name: sdc-data-filebeat volumes: - name: filebeat-conf - hostPath: - path: /dockerdata-nfs/{{ .Values.nsPrefix }}/log/filebeat/logback/filebeat.yml + configMap: + name: sdc-filebeat-configmap - name: sdc-logs-2 emptyDir: {} - name: sdc-data-filebeat emptyDir: {} - name: sdc-logback - hostPath: - path: /dockerdata-nfs/{{ .Values.nsPrefix }}/log/sdc/be/logback.xml + configMap: + name : sdc-log-be-configmap - name: sdc-sdc-es-es hostPath: path: /dockerdata-nfs/{{ .Values.nsPrefix }}/sdc/sdc-es/ES - name: sdc-environments - hostPath: - path: /dockerdata-nfs/{{ .Values.nsPrefix }}/sdc/environments + configMap: + name: sdc-environments-configmap + defaultMode: 0755 - name: sdc-localtime hostPath: path: /etc/localtime diff --git a/kubernetes/sdc/templates/sdc-cs.yaml b/kubernetes/sdc/templates/sdc-cs.yaml index a81d4ae826..d70ead4407 100644 --- a/kubernetes/sdc/templates/sdc-cs.yaml +++ b/kubernetes/sdc/templates/sdc-cs.yaml @@ -67,8 +67,9 @@ spec: persistentVolumeClaim: claimName: sdc-cs-db - name: sdc-environments - hostPath: - path: /dockerdata-nfs/{{ .Values.nsPrefix }}/sdc/environments + configMap: + name : sdc-environments-configmap + defaultMode: 0755 - name: sdc-localtime hostPath: path: /etc/localtime diff --git a/kubernetes/sdc/templates/sdc-environments-configmap.yaml b/kubernetes/sdc/templates/sdc-environments-configmap.yaml new file mode 100644 index 0000000000..f8456b0efe --- /dev/null +++ b/kubernetes/sdc/templates/sdc-environments-configmap.yaml @@ -0,0 +1,9 @@ +#{{ if not .Values.disableSdcSdcBe }} +apiVersion: v1 +kind: ConfigMap +metadata: + name: sdc-environments-configmap + namespace: {{ .Values.nsPrefix }}-sdc +data: +{{ tpl (.Files.Glob "resources/config/environments/*").AsConfig . | indent 2 }} +#{{ end }} diff --git a/kubernetes/sdc/templates/sdc-es.yaml b/kubernetes/sdc/templates/sdc-es.yaml index 1d2ba4805b..3f2ef332b1 100644 --- a/kubernetes/sdc/templates/sdc-es.yaml +++ b/kubernetes/sdc/templates/sdc-es.yaml @@ -16,6 +16,20 @@ spec: app: sdc-es name: sdc-es spec: + initContainers: + - name: sdc-logs-init + image: {{ .Values.image.ubuntuInit }} + imagePullPolicy: {{ .Values.pullPolicy }} + command: + - /bin/bash + - "-c" + - | + mkdir -p /ubuntu-init/ASDC/ASDC-ES/ + mkdir -p /ubuntu-init/ASDC/ASDC-CS/ + mkdir -p /ubuntu-init/ASDC/ASDC-KB/ + mkdir -p /ubuntu-init/ASDC/ASDC-BE/ + mkdir -p /ubuntu-init/ASDC/ASDC-FE/ + chmod -R 777 /ubuntu-init/ containers: - image: {{ .Values.image.sdcElasticsearch }} imagePullPolicy: {{ .Values.pullPolicy }} @@ -30,6 +44,8 @@ spec: - name: ES_HEAP_SIZE value: "1024M" volumeMounts: + - name: sdc-logs + mountPath: /ubuntu-init/ - mountPath: /root/chef-solo/environments/ name: sdc-environments - mountPath: /etc/localtime @@ -47,8 +63,9 @@ spec: periodSeconds: 10 volumes: - name: sdc-environments - hostPath: - path: /dockerdata-nfs/{{ .Values.nsPrefix }}/sdc/environments + configMap : + name : sdc-environments-configmap + defaultMode: 0755 - name: sdc-localtime hostPath: path: /etc/localtime diff --git a/kubernetes/sdc/templates/sdc-fe-configmap.yaml b/kubernetes/sdc/templates/sdc-fe-configmap.yaml new file mode 100644 index 0000000000..2f60ef88e3 --- /dev/null +++ b/kubernetes/sdc/templates/sdc-fe-configmap.yaml @@ -0,0 +1,9 @@ +#{{ if not .Values.disableSdcSdcFe }} +apiVersion: v1 +kind: ConfigMap +metadata: + name: sdc-fe-configmap + namespace: {{ .Values.nsPrefix }}-sdc +data: +{{ tpl (.Files.Glob "resources/config/sdc-fe/*").AsConfig . | indent 2 }} +#{{ end }} diff --git a/kubernetes/sdc/templates/sdc-fe.yaml b/kubernetes/sdc/templates/sdc-fe.yaml index bc1777f3ab..b4205ed653 100644 --- a/kubernetes/sdc/templates/sdc-fe.yaml +++ b/kubernetes/sdc/templates/sdc-fe.yaml @@ -62,6 +62,7 @@ spec: name: sdc-logs-2 - mountPath: /root/chef-solo/cookbooks/sdc-catalog-fe/recipes/FE_2_setup_configuration.rb name: sdc-fe-config + subPath: FE_2_setup_configuration.rb - mountPath: /tmp/logback.xml name: sdc-logback lifecycle: @@ -82,27 +83,29 @@ spec: volumeMounts: - mountPath: /usr/share/filebeat/filebeat.yml name: filebeat-conf + subPath: filebeat.yml - mountPath: /var/log/onap name: sdc-logs-2 - mountPath: /usr/share/filebeat/data name: sdc-data-filebeat volumes: - name: filebeat-conf - hostPath: - path: /dockerdata-nfs/{{ .Values.nsPrefix }}/log/filebeat/logback/filebeat.yml + configMap: + name : sdc-filebeat-configmap - name: sdc-logs-2 emptyDir: {} - name: sdc-data-filebeat emptyDir: {} - name: sdc-logback - hostPath: - path: /dockerdata-nfs/{{ .Values.nsPrefix }}/log/sdc/fe/logback.xml + configMap: + name : sdc-log-fe-configmap - name: sdc-sdc-es-es hostPath: path: /dockerdata-nfs/{{ .Values.nsPrefix }}/sdc/sdc-es/ES - name: sdc-environments - hostPath: - path: /dockerdata-nfs/{{ .Values.nsPrefix }}/sdc/environments + configMap: + name: sdc-environments-configmap + defaultMode: 0755 - name: sdc-localtime hostPath: path: /etc/localtime @@ -110,8 +113,9 @@ spec: hostPath: path: /dockerdata-nfs/{{ .Values.nsPrefix }}/sdc/logs - name: sdc-fe-config - hostPath: - path: /dockerdata-nfs/{{ .Values.nsPrefix }}/sdc/sdc-fe/FE_2_setup_configuration.rb + configMap: + name: sdc-fe-configmap + defaultMode: 0755 imagePullSecrets: - name: "{{ .Values.nsPrefix }}-docker-registry-key" #{{ end }} diff --git a/kubernetes/sdc/templates/sdc-kb.yaml b/kubernetes/sdc/templates/sdc-kb.yaml index a7334d4d08..658f6c1a03 100644 --- a/kubernetes/sdc/templates/sdc-kb.yaml +++ b/kubernetes/sdc/templates/sdc-kb.yaml @@ -59,8 +59,9 @@ spec: periodSeconds: 10 volumes: - name: sdc-environments - hostPath: - path: /dockerdata-nfs/{{ .Values.nsPrefix }}/sdc/environments + configMap: + name: sdc-environments-configmap + defaultMode: 0755 - name: sdc-localtime hostPath: path: /etc/localtime diff --git a/kubernetes/sdc/templates/sdc-log-configmap.yaml b/kubernetes/sdc/templates/sdc-log-configmap.yaml new file mode 100644 index 0000000000..c79f9e064c --- /dev/null +++ b/kubernetes/sdc/templates/sdc-log-configmap.yaml @@ -0,0 +1,27 @@ +#{{ if not .Values.disableSdcSdcBe }} +apiVersion: v1 +kind: ConfigMap +metadata: + name: sdc-log-be-configmap + namespace: {{ .Values.nsPrefix }}-sdc +data: +{{ tpl (.Files.Glob "resources/config/log/be/*").AsConfig . | indent 2 }} +--- +apiVersion: v1 +kind: ConfigMap +metadata: + name: sdc-filebeat-configmap + namespace: {{ .Values.nsPrefix }}-sdc +data: +{{ tpl (.Files.Glob "resources/config/log/filebeat/*").AsConfig . | indent 2 }} +#{{ end }} +--- +#{{ if not .Values.disableSdcSdcFe }} +apiVersion: v1 +kind: ConfigMap +metadata: + name: sdc-log-fe-configmap + namespace: {{ .Values.nsPrefix }}-sdc +data: +{{ tpl (.Files.Glob "resources/config/log/fe/*").AsConfig . | indent 2 }} +#{{ end }} |