在Kubernetes v1.16集群上安装csi驱动错误



我是一个Kubernetes新手。我试图在Kubernetes集群版本1.16.15中安装一个csi驱动程序到Kubernetes命名空间。

我使用的是helm 2.16版本,使用下面的命令来安装:

.helm install --name csi-secrets-store secrets-store-csi-driver/secrets-store-csi-driver --namespace csi --debug

[debug] Created tunnel using local port: '63250'
[debug] SERVER: "127.0.0.1:63250"
[debug] Original chart version: ""
[debug] Fetched secrets-store-csi-driver/secrets-store-csi-driver to C:UsersXXX.helmcachearchivesecrets-store-csi-driver-0.0.19.tgz
[debug] CHART PATH: C:UsersXXX.helmcachearchivesecrets-store-csi-driver-0.0.19.tgz
**Error: render error in "secrets-store-csi-driver/templates/csidriver.yaml": template: secrets-store-csi-driver/templates/_helpers.tpl:40:45: executing "csidriver.apiVersion" at <.Capabilities.KubeVersion.Version>: can't evaluate field Version in type *version.Info**

csidriver。yaml:

apiVersion: {{ template "csidriver.apiVersion" . }}
kind: CSIDriver
metadata:
name: secrets-store.csi.k8s.io
spec:
podInfoOnMount: true
attachRequired: false
{{- if semverCompare ">=1.16-0" .Capabilities.KubeVersion.Version }}
# Added in Kubernetes 1.16 with default mode of Persistent. Secrets store csi driver needs Ephermeral to be set.
volumeLifecycleModes: 
- Ephemeral
{{ end }}

任何帮助都非常感谢

Helm版本较旧。升级到新的Helm v3后问题已解决。

有关于如何将Helm v2迁移到v3的有用指南。

相关内容

  • 没有找到相关文章

最新更新