From 711fc5fb580e8b814bc469bbf04c7fefbf025d34 Mon Sep 17 00:00:00 2001 From: Armel Soro Date: Mon, 3 Feb 2025 15:26:12 +0100 Subject: [PATCH] fix(release-1.3): Make the audit log PVC configurable [RHIDP-5839] --- charts/backstage/Chart.yaml | 2 +- charts/backstage/README.md | 3 ++- .../ci/with-custom-dynamic-pvc-claim-spec-values.yaml | 8 ++++++++ charts/backstage/templates/pvcs.yaml | 6 +----- charts/backstage/values.yaml | 11 +++++++++++ 5 files changed, 23 insertions(+), 7 deletions(-) diff --git a/charts/backstage/Chart.yaml b/charts/backstage/Chart.yaml index f1abda4c..834e7689 100644 --- a/charts/backstage/Chart.yaml +++ b/charts/backstage/Chart.yaml @@ -45,4 +45,4 @@ sources: # This is the chart version. This version number should be incremented each time you make changes # to the chart and its templates, including the app version. # Versions are expected to follow Semantic Versioning (https://semver.org/) -version: 2.19.3 +version: 2.19.4 diff --git a/charts/backstage/README.md b/charts/backstage/README.md index d717a8b6..2fb5cf44 100644 --- a/charts/backstage/README.md +++ b/charts/backstage/README.md @@ -2,7 +2,7 @@ # RHDH Backstage Helm Chart for OpenShift (Community Version) [![Artifact Hub](https://img.shields.io/endpoint?url=https://artifacthub.io/badge/repository/rhdh-chart&style=flat-square)](https://artifacthub.io/packages/search?repo=rhdh-chart) -![Version: 2.19.3](https://img.shields.io/badge/Version-2.19.3-informational?style=flat-square) +![Version: 2.19.4](https://img.shields.io/badge/Version-2.19.4-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) A Helm chart for deploying Red Hat Developer Hub. @@ -181,6 +181,7 @@ Kubernetes: `>= 1.25.0-0` | Key | Description | Type | Default | |-----|-------------|------|---------| +| auditLog.volumeClaimSpec | Spec of the audit log volume claim.
Note that, by default, this is set to use the default storage class, if available in the cluster. | object | `{"accessModes":["ReadWriteOnce"],"resources":{"requests":{"storage":"1Gi"}},"storageClassName":null}` | | dynamicPlugins.cache.volumeClaimSpec | Spec of the dynamic plugins root volume claim.
Note that, by default, this is set to use the default storage class, if available in the cluster. | object | `{"accessModes":["ReadWriteOnce"],"resources":{"requests":{"storage":"5Gi"}},"storageClassName":null}` | | global.auth | Enable service authentication within Backstage instance | object | `{"backend":{"enabled":true,"existingSecret":"","value":""}}` | | global.auth.backend | Backend service to service authentication
Ref: https://backstage.io/docs/auth/service-to-service-auth/ | object | `{"enabled":true,"existingSecret":"","value":""}` | diff --git a/charts/backstage/ci/with-custom-dynamic-pvc-claim-spec-values.yaml b/charts/backstage/ci/with-custom-dynamic-pvc-claim-spec-values.yaml index e98f0bde..0a266395 100644 --- a/charts/backstage/ci/with-custom-dynamic-pvc-claim-spec-values.yaml +++ b/charts/backstage/ci/with-custom-dynamic-pvc-claim-spec-values.yaml @@ -8,6 +8,14 @@ upstream: # This custom-sc storage class is created in the test GH Workflow storageClass: custom-sc +auditLog: + volumeClaimSpec: + resources: + requests: + storage: 2Gi + # This custom-sc storage class is created in the test GH Workflow + storageClassName: custom-sc + dynamicPlugins: cache: volumeClaimSpec: diff --git a/charts/backstage/templates/pvcs.yaml b/charts/backstage/templates/pvcs.yaml index 9548b5b1..cfaeb42c 100644 --- a/charts/backstage/templates/pvcs.yaml +++ b/charts/backstage/templates/pvcs.yaml @@ -3,11 +3,7 @@ apiVersion: v1 metadata: name: {{ printf "%s-audit-log" .Release.Name }} spec: - accessModes: - - ReadWriteOnce - resources: - requests: - storage: 1Gi + {{- toYaml .Values.auditLog.volumeClaimSpec | nindent 2 }} --- kind: PersistentVolumeClaim apiVersion: v1 diff --git a/charts/backstage/values.yaml b/charts/backstage/values.yaml index d019dd2e..09deb8e6 100644 --- a/charts/backstage/values.yaml +++ b/charts/backstage/values.yaml @@ -285,6 +285,17 @@ route: #
While each router may make its own decisions on which ports to expose, this is normally port 80. The only valid values are None, Redirect, or empty for disabled. insecureEdgeTerminationPolicy: "Redirect" +auditLog: + # -- Spec of the audit log volume claim. + #
Note that, by default, this is set to use the default storage class, if available in the cluster. + volumeClaimSpec: + accessModes: + - ReadWriteOnce + resources: + requests: + storage: 1Gi + storageClassName: null + dynamicPlugins: cache: # -- Spec of the dynamic plugins root volume claim.