mirror of
https://github.com/truenas/charts.git
synced 2026-04-09 21:59:10 +08:00
Add upgrade hook where we nuke nextcloud/postgres deployments
This commit is contained in:
19
test/nextcloud/1.0.0/templates/nuke-deployments-hook.yaml
Normal file
19
test/nextcloud/1.0.0/templates/nuke-deployments-hook.yaml
Normal file
@@ -0,0 +1,19 @@
|
||||
apiVersion: batch/v1
|
||||
kind: Job
|
||||
metadata:
|
||||
name: "pre-upgrade-hook1"
|
||||
annotations:
|
||||
"helm.sh/hook": pre-upgrade
|
||||
"helm.sh/hook-weight": "-1"
|
||||
"helm.sh/hook-delete-policy": hook-succeeded
|
||||
spec:
|
||||
template:
|
||||
metadata:
|
||||
name: "pre-upgrade-hook1"
|
||||
spec:
|
||||
restartPolicy: Never
|
||||
serviceAccountName: {{ template "nextcloud.serviceAccountName" }}
|
||||
containers:
|
||||
- name: kubectl
|
||||
image: "bitnami/kubectl:1.19"
|
||||
command: ["delete" , "deployment", "{{ template "nextcloud.fullname" . }}", "{{ template "nextcloud.fullname" . }}-postgres"]
|
||||
Reference in New Issue
Block a user