Skip to content

Commit 51fa294

Browse files
authored
Merge pull request #3 from Alexj9837/last-used-stamper
fix :updating the script
2 parents b4466c0 + 078caee commit 51fa294

1 file changed

Lines changed: 3 additions & 2 deletions

File tree

helm/blueapi/templates/cronjob.yaml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -61,8 +61,9 @@ spec:
6161
- -c
6262
- |
6363
# Get PVCs belonging to this blueapi release
64-
ALL_PVC=$(kubectl get pvc -l "argocd.argoproj.io/instance={{ .Release.Name }}" \
65-
-o jsonpath='{.items[*].metadata.name}' -n {{ .Release.Namespace }} | tr ' ' '\n')
64+
ALL_PVC=$(kubectl get pvc -n {{ .Release.Namespace }} \
65+
-o jsonpath='{.items[*].metadata.name}' | tr ' ' '\n' | \
66+
grep "^{{ .Release.Name }}-scratch-")
6667
# Get all PVCs currently mounted by running pods
6768
MOUNTED_PVCS=$(kubectl get pods -n {{ .Release.Namespace }} \
6869
-o=jsonpath='{.items[*].spec.volumes[*].persistentVolumeClaim.claimName}' | tr ' ' '\n' | sort -u)

0 commit comments

Comments
 (0)