I am a Kubernetes novice. I am trying to install a csi driver to a Kubernetes Namespace in a kubernetes cluster. I am using helm 2.16 version to do the install using below command :
.\helm install csi-secrets-store secrets-store-csi-driver/secrets-store-csi-driver -n csi
Error: This command needs 1 argument: chart name
Also tried running :
.\helm install csi-secrets-store secrets-store-csi-driver/secrets-store-csi-driver --namespace csi
and get below Error :
Error: This command needs 1 argument: chart name
Can some one help me with the correct command?
.\helm version
Client: &version.Version{SemVer:"v2.16.12", GitCommit:"47f0b88409e71fd9ca272abc7cd762a56a1c613e", GitTreeState:"clean"}
Server: &version.Version{SemVer:"v2.16.1", GitCommit:"bbdfe5e7803a12bbdf97e94cd847859890cf4050", GitTreeState:"clean"}
Thanks
According to the official docs:
This command installs a chart archive.
The install argument must be a chart reference, a path to a packaged chart, a path to an unpacked chart directory or a URL.
To override values in a chart, use either the
–values
flag and pass in a file or use the–set
flag and pass configuration from the command line. To force string values in–set
, use–set-string
instead. In case a value is large and therefore you want not to use neither–values
nor–set
, use–set-file
to read the single large value from file.CHART REFERENCES
A chart reference is a convenient way of reference a chart in a chart repository.
When you use a chart reference with a repo prefix (‘stable/mariadb’), Helm will look in the local configuration for a chart repository named ‘stable’, and will then look for a chart in that repository whose name is ‘mariadb’. It will install the latest version of that chart unless you also supply a version number with the ‘–version’ flag.
To see the list of chart repositories, use ‘helm repo list’. To search for charts in a repository, use ‘helm search’.
helm install [CHART] [flags]
Note the:
-n, --name string release name. If unspecified, it will autogenerate one for you
and:
--namespace string namespace to install the release into. Defaults to the current kube config namespace.
The error you see means that you did not reference the chart name properly. It looks like there are too many arguments for --name
(csi-secrets-store
and csi
). For example it should look more like this:
helm install --name <release name> --namespace <namespace>
which would be transleted into your use case as:
helm install --name csi-secrets-store secrets-store-csi-driver/secrets-store-csi-driver --namespace csi
*Note that I am not sure of the values you want to use so you have to check them yourself and adjust if needed. Here I assume that csi
is the namespace, csi-secrets-store
is the release name and secrets-store-csi-driver/secrets-store-csi-driver
is the repo/chart name.
Also make sure that the chart you want to install does not require Helm v3.0+. If so, than you will have to upgrade it before installing.