What is the purpose of helm delete --purge
Asked Answered
F

3

49

Using helm is super cool, but what is the purpose of using helm delete --purge

I can see the doc says:remove the release from the store and make its name free for later use

So what is the purpose of saving the name and not releasing it with helm delete?

Fula answered 30/7, 2018 at 12:32 Comment(1)
As an aside, you can purge all deleted releases with helm delete --purge $(helm ls --deleted -q)Insistency
C
72

When you do helm delete $RELEASE_NAME it deletes all resources but keeps the record with $RELEASE_NAME in case you want to rollback. You can see removed releases via helm ls -a. Whereas helm delete --purge $RELEASE_NAME removes records and make that name free to be reused for another installation.

Cassis answered 1/8, 2018 at 3:3 Comment(3)
note: helm3 removed this flag and this answer is no longer valid in helm3+Benison
In Helm 3+, it looks like helm uninstall fully deletes and purges releases, unless you specify the --keep-history flag: helm.sh/docs/intro/using_helm/…Jelks
lol, I just realized another response already clarified this: https://mcmap.net/q/350147/-what-is-the-purpose-of-helm-delete-purgeJelks
V
40

Just to note as of helm v3 --purge is default behaviour. You no longer need the flag

If you want to keep any history (aka the behaviour of helm 2.x's helm delete without the --purge flag) you now need to use --keep-history eg helm delete nginx-ingress --keep-history

Vassili answered 6/12, 2019 at 10:5 Comment(0)
D
3

Recently they've finally managed necessity of --purge by replacing helm delete with helm uninstall. There appears it works fine now

Daglock answered 25/5, 2020 at 5:53 Comment(1)
Looks like delete and uninstall are aliased.Cook

© 2022 - 2024 — McMap. All rights reserved.