diff --git a/services/jenkins/helmrelease.yaml b/services/jenkins/helmrelease.yaml index 5bb9255..75fb8b6 100644 --- a/services/jenkins/helmrelease.yaml +++ b/services/jenkins/helmrelease.yaml @@ -79,6 +79,21 @@ spec: secretKeyRef: name: jenkins-oidc key: logoutUrl + customInitContainers: + - name: clean-jcasc-stale + image: alpine:3.20 + imagePullPolicy: IfNotPresent + command: + - sh + - -c + - | + set -euo pipefail + rm -f /var/jenkins_home/casc_configs/*.yaml || true + securityContext: + runAsUser: 0 + volumeMounts: + - name: jenkins-home + mountPath: /var/jenkins_home initScripts: oidc.groovy: | import hudson.util.Secret