kubernetes - 如何向 kubernetes ManagedCertificate 添加新的子域?
问题描述
我正在使用 K8s ManagedCertificate 在 GCE 上创建证书。我想在我的证书中添加一个新的子域,所以更新 yaml 文件并应用 kubectl。我试图描述我的证书以查看是否一切正常但发现错误
Warning BackendError 16m (x144 over 36h) managed-certificate-controller googleapi: Error 400: The ssl_certificate resource '< redated >' is already being used by '< redated >', resourceInUseByAnotherResource
同样在描述中,我没有看到我尝试添加为活动的新子域。
Spec:
Domains:
web.sub1.domain1.com
web.sub1.domain2.com
web.newsub.domain2.com
web.sub2.domain2.com
web.sub1.domain3.com
Status:
Certificate Name: < redated >
Certificate Status: Active
Domain Status:
Domain: web.sub1.domain1.com
Status: Active
Domain: web.sub1.domain2.com
Status: Active
Domain: web.sub2.domain2.com
Status: Active
Domain: web.sub1.domain3.com
Status: Active
Expire Time: 2021-07-30T00:54:02.000-07:00
解决方案
正如 John Hanley 提到的,您无法更新 SSL 证书。Google API for SSL 证书没有更新方法。所以删除了资源使用kubectl delete -f <cert>.yaml
并再次创建它kubectl apply -f <cert>.yaml
并且它工作
推荐阅读
- json - 有没有办法将传入的 JSON 数据与本地 JSON 数据进行比较?
- redis - 有没有办法使用 Redis 将属性与聊天消息相关联?
- java - 无法将 setOnClickListener 添加到导航抽屉中的按钮
- go - Go:将 gob 与 zmq4 一起使用
- powershell - 我如何从附加的 CSV 文件中的 DistinguishedName 列中过滤“OU = 服务帐户”:powershell
- docker - 在 docker-compose 中使用 command 关键字
- python - setuptools安装的python包无法卸载成功
- java - JAVA TelegramApiRequestException:获取更新时出错
- android - 如何在其他功能上完成WakefulIntent?
- c++ - 迭代创建三个数组的三个数组的组合