gri*_*edj 46
要使用单个命令删除所有Helm版本,您可以使用一些好的旧版bash.只需输出helm ls --shortto 的输出xargs,然后helm delete为每个版本运行.
helm ls --all --short | xargs -L1 helm delete
--purge根据@Yeasin Ar Rahman的评论,添加也会删除图表.
helm ls --all --short | xargs -L1 helm delete --purge
jhn*_*lvr 16
对于 helm 3,您必须提供命名空间,因此awk之前有一个步骤xargs:
helm ls -a --all-namespaces | awk 'NR > 1 { print "-n "$2, $1}' | xargs -L1 helm delete
这会导致如下命令:
helm delete -n my-namespace my-release
imo*_*mos 12
helm delete $(helm ls --short)
描述:
helm ls --short 给出发布 ID 的列表。
helm delete id1 id2 id3删除带有 ids: id1, id2, 的版本id3。
所以将它们结合起来,我们得到:
helm delete $(helm ls --short)
小智 12
这在PowerShell cmd窗口中对我有用:
helm del $(helm ls --all --short) --purge
Run Code Online (Sandbox Code Playgroud)
| 归档时间: |
|
| 查看次数: |
37814 次 |
| 最近记录: |