kubernetes - 从 Helm stable/cert-manager 升级到 jetstack/cert-manager
问题描述
我们有一个生产 AKS 集群,该集群stable/cert-manager
安装了 helm 图表以允许使用 Let's Encrypt 证书。当前安装的版本cert-manager-v0.6.0
位于kube-system
命名空间中。
Let's Encrypt 将从 2019 年 11 月 1 日起停止对来自 cert-manager pre 8.0 版本的流量的支持。
我想升级,但最新可用的stable
图表版本是v0.6.7
. 似乎要走的路是切换到jetstack/cert-manager
.
我如何最好地解决这个问题?我应该卸载当前stable/cert-manager
图表并使用jetstack/cert-manager
? 任何关于如何在不停机的情况下解决这个问题的资源将不胜感激。如果我可以提供更多详细信息,请告诉我。
解决方案
对于任何问同样问题的人,我都尝试在我的测试集群上执行全新安装,这似乎工作得相当顺利。我通过运行找到了我的掌舵版本的名称helm list
然后我执行了以下步骤:
1.备份:
kubectl get -o yaml \
--all-namespaces \
issuer,clusterissuer,certificates,orders,challenges > cert-manager-backup.yaml
2.删除:
# Uninstall the Helm chart
helm delete --purge <your release name here>
# Ensure the cert-manager CustomResourceDefinition resources do not exist:
kubectl delete crd \
certificates.certmanager.k8s.io \
issuers.certmanager.k8s.io \
clusterissuers.certmanager.k8s.io
在此处的第 2 步中描述
3.安装一个新的jetstack版本:
# Install the CustomResourceDefinition resources separately
kubectl apply -f https://raw.githubusercontent.com/jetstack/cert-manager/release-0.9/deploy/manifests/00-crds.yaml
# Create the namespace for cert-manager
kubectl create namespace cert-manager
# Label the cert-manager namespace to disable resource validation
kubectl label namespace cert-manager certmanager.k8s.io/disable-validation=true
# Add the Jetstack Helm repository
helm repo add jetstack https://charts.jetstack.io
# Update your local Helm chart repository cache
helm repo update
# Install the cert-manager Helm chart
helm install --name <your release name here> --namespace cert-manager --version v0.9.1 jetstack/cert-manager
这里描述
4.恢复:
我试过跑步
kubectl apply -f cert-manager-backup.yaml
如此处所述,但此步骤实际上并没有完全适合我。发行人已创建(自签名和 CA),但我无法重新创建Certificates
and ClusterIssuer
。这些是我收到的错误:
Error from server (InternalError): Internal error occurred: failed calling webhook "clusterissuers.admission.certmanager.k8s.io": the server is currently unable to handle the request
Error from server (InternalError): Internal error occurred: failed calling webhook "certificates.admission.certmanager.k8s.io": the server is currently unable to handle the request
我有我的原始yaml
文件,并且能够通过应用它们来创建ClusterIssuer
和Certificate
推荐阅读
- java - 网格 Java 中的 OOP 坐标不起作用。如何编程?
- react-native - 我无法在 Firebase 存储中查看图片
- assembly - .rodata 和 .rdata 有什么区别
- c# - Unity3D:如何在没有 spawner 单例的情况下进行对象池
- bash - 是什么导致 Elasticsearch 批量加载失败?
- python - Python 元类 - 验证初始化其他具有元的类的实例的类的名称
- java - java BindException:地址已在使用中:即使端口可用,也要绑定
- kubernetes - Kubernetes 集群获取凭据在 Windows 10 上返回错误
- r - 在列中填充缺失值,然后过滤
- java - Java while循环直到满足条件