mirror of
https://gitea.com/gitea/helm-actions.git
synced 2026-04-09 19:20:40 +00:00
chore: add cache flushing init container
This commit is contained in:
@ -49,6 +49,23 @@ spec:
|
||||
{{- if .Values.preExtraInitContainers }}
|
||||
{{- toYaml .Values.preExtraInitContainers | nindent 8 }}
|
||||
{{- end }}
|
||||
{{- if .Values.statefulset.actRunner.flushCache }}
|
||||
- name: cache-flusher
|
||||
image: "{{ include "gitea.actions.init.image" . }}"
|
||||
command:
|
||||
- sh
|
||||
- -c
|
||||
- |
|
||||
if [[ -f /data/.runner ]]; then
|
||||
echo "Removing cache at /data/.runner"
|
||||
rm -v /data/.runner
|
||||
else
|
||||
echo "No .runner file to remove"
|
||||
fi
|
||||
volumeMounts:
|
||||
- mountPath: /data
|
||||
name: data-act-runner
|
||||
{{- end }}
|
||||
- name: init-gitea
|
||||
image: "{{ include "gitea.actions.init.image" . }}"
|
||||
command:
|
||||
|
||||
Reference in New Issue
Block a user