From cfb7ff9315a0863c699acb018bfa947add0a1f25 Mon Sep 17 00:00:00 2001 From: Sylvain Desbureaux Date: Wed, 6 May 2020 17:40:20 +0200 Subject: [DCAEGEN2] Remove Lost+Found in PVC When using dynamic storage, "Lost+Found" may be present. Cloudify init script doesn't work when it's the case, so we need to remove it. Issue-ID: OOM-1227 Signed-off-by: Sylvain Desbureaux Change-Id: Ie298c55aa997a441dde0bd45c452f41eb77ad495 --- .../dcae-cloudify-manager/templates/deployment.yaml | 13 +++++++++++++ kubernetes/dcaegen2/values.yaml | 2 ++ 2 files changed, 15 insertions(+) diff --git a/kubernetes/dcaegen2/components/dcae-cloudify-manager/templates/deployment.yaml b/kubernetes/dcaegen2/components/dcae-cloudify-manager/templates/deployment.yaml index 9bee0510cd..8a03e90333 100644 --- a/kubernetes/dcaegen2/components/dcae-cloudify-manager/templates/deployment.yaml +++ b/kubernetes/dcaegen2/components/dcae-cloudify-manager/templates/deployment.yaml @@ -65,6 +65,19 @@ spec: volumeMounts: - mountPath: /opt/app/osaaf name: tls-info + {{- if .Values.persistence.enabled }} + - name: remove-lost-found + image: "{{ .Values.global.busyboxRepository }}/{{ .Values.global.busyboxImage }}" + imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }} + volumeMounts: + - mountPath: /cfy-persist + name: cm-persistent + command: + - /bin/sh + args: + - -c + - "rm -rf '/cfy-persist/lost+found';" + {{- end }} containers: - name: {{ include "common.name" . }} image: "{{ include "common.repository" . }}/{{ .Values.image }}" diff --git a/kubernetes/dcaegen2/values.yaml b/kubernetes/dcaegen2/values.yaml index 25ddfc7558..aff40d4a6a 100644 --- a/kubernetes/dcaegen2/values.yaml +++ b/kubernetes/dcaegen2/values.yaml @@ -22,5 +22,7 @@ global: tlsImage: onap/org.onap.dcaegen2.deployments.tls-init-container:2.1.0 consulLoaderRepository: nexus3.onap.org:10001 consulLoaderImage: onap/org.onap.dcaegen2.deployments.consul-loader-container:1.0.0 + busyboxRepository: docker.io + busyboxImage: library/busybox:1.30 redis: replicaCount: 6 -- cgit 1.2.3-korg