root@lnmymachine # helm ls
Error: Unauthorized
root@lnmymachine # helm install --name initial stable/jenkins
Error: the server has asked for the client to provide credentials
Browsed similar issues and few of them were due to multiple clusters. I have only one cluster. kubectl gives all information correctly.
Running the script only installs the client, in your output it shows a running server component (tiller), guessing it wasn’t installed with RBAC properly before. And the install steps from Rancher Helm Init will just say it’s already installed. Both errors indicate issues with auth, can you supply exact steps and outputs or retry using https://rancher.com/docs/rancher/v2.x/en/installation/ha/helm-init/troubleshooting/#helm-commands-show-forbidden
# bash helm.sh
Downloading https://kubernetes-helm.storage.googleapis.com/helm-v2.12.3-linux-amd64.tar.gz
Preparing to install helm and tiller into /usr/local/bin
helm installed into /usr/local/bin/helm
tiller installed into /usr/local/bin/tiller
Run 'helm init' to configure helm.
# helm version
Client: &version.Version{SemVer:"v2.12.3", GitCommit:"eecf22f77df5f65c823aacd2dbd30ae6c65f186e", GitTreeState:"clean"}
Error: Get http://localhost:8080/api/v1/namespaces/kube-system/pods?labelSelector=app%3Dhelm%2Cname%3Dtiller: dial tcp 127.0.0.1:8080: connect: connection refused
The issue was missing = in –clusterrole cluster-admin. I have copied the command from Rancher docs and executed as it is. Now I submitted a pull request for the correction.
That equals shouldn’t be significant… are you sure it’s not because of the dashes? Your post has “smart dashes” instead of two hyphens for the flag, – != --.
@vincent I was using two dashes and even my post had dashes, When formatting I think it got converted to smartdashes. Good find.
To get it working all I did was to add that single “=” nothing else.