kubernetes-helm - Helm 未显示版本/无法删除旧版本
问题描述
我在 Kubernetes v1.15.3 上使用 helm v3.0.0-alpha.2。
[root@somebox log]# helm version
version.BuildInfo{Version:"v3.0.0-alpha.2", GitCommit:"97e7461e41455e58d89b4d7d192fed5352001d44", GitTreeState:"clean", GoVersion:"go1.12.7"}
helm list
显示没有发布。
[root@somebox log]# helm list
NAME NAMESPACE REVISION UPDATED STATUS CHART
但是我无法安装新版本并为其命名,因为它“仍在使用”。它在某个时候是一个版本,但应该不再存在。
[root@somebox log]# helm install --namespace rook-ceph rook-ceph-acme rook-release/rook-ceph
Error: cannot re-use a name that is still in use
如何清除未显示的旧版本helm list
?
谢谢。
解决方案
首先,您必须列出分配给它的命名空间的版本。其次,您必须清除helm2
; 它会自动清除helm3
掌舵2
helm del <release-name> --namespace <namespace>
helm del $(helm ls --all | grep 'DELETED' | awk '{print $1}') --purge
掌舵3
helm3 del <release-name> --namespace <namespace>
# list and delete the release
helm3 del -n rook-ceph $(helm3 ls -n rook-ceph | grep 'rook-ceph' | awk '{print $1}')
更多详情:https ://devopsqa.wordpress.com/2020/01/29/helm-cli-cheatsheet/
推荐阅读
- mysql - 如何制作 node.js api 并将其部署到 heroku(postgresql 或 mySQL 数据库)
- javascript - CryptoJS 在后端解密,但不是前端
- java - 如何修复此错误消息:xhr.js:178 GET http://localhost:8080/jpa/users/undefined/accounts/undefined?
- php - 我不断收到此错误:第 8 行的语法错误,意外 ':',期待 ')'
- python - 使用“子进程调用”调用未知目录中的程序
- laravel - 基于 Laravel API 的验证/身份验证
- python - 奇怪的 GUDHI + rpy2 交互
- c - 我想在 C 中创建一个链表并对其执行某些功能。但在我的代码中找不到错误
- css - bootstrap row-cols-sm-1 不适用于卡片。应该为 1 的单元格屏幕上出现两张卡片
- visual-studio-code - SUMX 为所有行提供相同的值