diff --git a/library/common-test/tests/persistence/pvc_data_test.yaml b/library/common-test/tests/persistence/pvc_data_test.yaml index 40db3907..800a8ade 100644 --- a/library/common-test/tests/persistence/pvc_data_test.yaml +++ b/library/common-test/tests/persistence/pvc_data_test.yaml @@ -8,6 +8,7 @@ tests: my-volume1: enabled: true type: pvc + size: 1Gi asserts: - documentIndex: &pvcDoc 0 isKind: diff --git a/library/common/Chart.yaml b/library/common/Chart.yaml index 4514af91..75ceccd0 100644 --- a/library/common/Chart.yaml +++ b/library/common/Chart.yaml @@ -15,4 +15,4 @@ maintainers: name: common sources: null type: library -version: 12.6.1 +version: 12.6.2 diff --git a/library/common/templates/lib/util/_manifest_manager.tpl b/library/common/templates/lib/util/_manifest_manager.tpl index 20c762fa..08df1ae9 100644 --- a/library/common/templates/lib/util/_manifest_manager.tpl +++ b/library/common/templates/lib/util/_manifest_manager.tpl @@ -75,13 +75,32 @@ spec: - | /bin/sh <<'EOF' touch /tmp/healthy - echo "installing manifests..." - kubectl apply --server-side --force-conflicts --grace-period 30 --v=4 -k https://github.com/truecharts/manifests/{{ if .Values.manifestManager.staging }}staging{{ else }}manifests{{ end }} || kubectl apply --server-side --force-conflicts --grace-period 30 -k https://github.com/truecharts/manifests/{{ if .Values.manifestManager.staging }}staging{{ else }}manifests || echo "job failed..."{{ end }} + echo "Installing manifests..." + {{- $branch := "manifests" -}} + {{- $handleErr := "|| echo 'Job succeeded...'" -}} + {{- if .Values.manifestManager.staging -}} + {{- $branch = "staging" -}} + {{- $handleErr = "&& echo 'Job failed...'" -}} + {{- end }} + + kubectl apply --server-side --force-conflicts --grace-period 30 --v=4 -k https://github.com/truecharts/manifests/{{ $branch }} || \ + kubectl apply --server-side --force-conflicts --grace-period 30 -k https://github.com/truecharts/manifests/{{ $branch }} {{ $handleErr }} + echo "Install finished..." + echo "Starting waits and checks..." + kubectl delete pod --field-selector=status.phase==Succeeded -n cnpg-system || echo "Delete of Completed Pods failed..." + kubectl delete pod --field-selector=status.phase==Failed -n cnpg-system || echo "Delete of Failed Pods failed..." kubectl wait --namespace cnpg-system --for=condition=ready pod --selector=app.kubernetes.io/name=cloudnative-pg --timeout=60s || echo "metallb-system wait failed..." + + kubectl delete pod --field-selector=status.phase==Succeeded -n metallb-system || echo "Delete of Completed Pods failed..." + kubectl delete pod --field-selector=status.phase==Failed -n metallb-system || echo "Delete of Failed Pods failed..." kubectl wait --namespace metallb-system --for=condition=ready pod --selector=app=metallb --timeout=60s || echo "metallb-system wait failed..." + + kubectl delete pod --field-selector=status.phase==Succeeded -n cert-manager || echo "Delete of Completed Pods failed..." + kubectl delete pod --field-selector=status.phase==Failed -n cert-manager || echo "Delete of Failed Pods failed..." kubectl wait --namespace cert-manager --for=condition=ready pod --selector=app.kubernetes.io/instance=cert-manager --timeout=60s || echo "cert-manager wait failed..." + cmctl check api --wait=1m || echo "cmctl wait failed..." EOF volumeMounts: diff --git a/library/common/values.yaml b/library/common/values.yaml index 0262f7fd..8a0424b4 100644 --- a/library/common/values.yaml +++ b/library/common/values.yaml @@ -26,7 +26,7 @@ fallbackDefaults: # -- Default Retain PVC pvcRetain: false # -- Default PVC Size - pvcSize: 1Gi + pvcSize: 100Gi # -- Default VCT Size vctSize: 100Gi # -- Default PVC/VCT Access Modes