Kubernetes 无法进行头盔初始化:未找到舵柄
我正在尝试使用Helm在集群上的Ubuntu18.10主机上安装Traefik 我可以使用snap-snap-install-Helm-classic安装头盔,但是当我想使用Helm-init命令安装舵柄时,我有以下输出:Kubernetes 无法进行头盔初始化:未找到舵柄,kubernetes,kubernetes-helm,Kubernetes,Kubernetes Helm,我正在尝试使用Helm在集群上的Ubuntu18.10主机上安装Traefik 我可以使用snap-snap-install-Helm-classic安装头盔,但是当我想使用Helm-init命令安装舵柄时,我有以下输出: helm init Creating /home/user/.helm
helm init
Creating /home/user/.helm
Creating /home/user/.helm/repository
Creating /home/user/.helm/repository/cache
Creating /home/user/.helm/repository/local
Creating /home/user/.helm/plugins
Creating /home/user/.helm/starters
Creating /home/user/.helm/cache/archive
Creating /home/user/.helm/repository/repositories.yaml
Adding stable repo with URL: https://kubernetes-charts.storage.googleapis.com
Adding local repo with URL: http://127.0.0.1:8879/charts
$HELM_HOME has been configured at /home/user/.helm.
Error: error installing: the server could not find the requested resource
我试图通过官方GitHub的二进制文件安装helm,但最终还是出现了相同的错误
我还尝试通过运行以下命令手动安装Tiller:
helm init-干运行-调试>>tiller.yml
但是当我使用kubectl apply-f tiller.yml时,它说它找不到扩展/v1beta1
我的解决方案快用完了,所以如果你有任何想法,我请求你的帮助
---
apiVersion: extensions/v1beta1
kind: Deployment
metadata:
creationTimestamp: null
labels:
app: helm
name: tiller
name: tiller-deploy
namespace: kube-system
spec:
replicas: 1
strategy: {}
template:
metadata:
creationTimestamp: null
labels:
app: helm
name: tiller
spec:
automountServiceAccountToken: true
containers:
- env:
- name: TILLER_NAMESPACE
value: kube-system
- name: TILLER_HISTORY_MAX
value: "0"
image: gcr.io/kubernetes-helm/tiller:v2.14.3
imagePullPolicy: IfNotPresent
livenessProbe:
httpGet:
httpGet:
path: /liveness
port: 44135
initialDelaySeconds: 1
timeoutSeconds: 1
name: tiller
ports:
- containerPort: 44134
name: tiller
- containerPort: 44135
name: http
readinessProbe:
httpGet:
path: /readiness
port: 44135
initialDelaySeconds: 1
timeoutSeconds: 1
resources: {}
status: {}
---
apiVersion: v1
kind: Service
metadata:
creationTimestamp: null
labels:
app: helm
name: tiller
name: tiller-deploy
namespace: kube-system
spec:
ports:
- name: tiller
port: 44134
targetPort: tiller
selector:
app: helm
name: tiller
type: ClusterIP
status:
loadBalancer: {}
...
解决方法,使用命令: 舵手初始-服务帐户舵柄-输出yaml | sed's@apiVersion: 扩展/v1beta1@apiVersion:apps/v1@'| sed's@副本:1@ 副本:1\n选择器:{matchLabels:{app:helm,name: tiller}}@'kubectl应用-f- 如果k8s版本为:1.16,则应降级至1.14 如果是k8s版本1.16,是否在其他版本中链接到我的答案 有相同错误的问题jt97
jt97的评论是一个完美的解决方法,谢谢 您的k8s版本1.16是什么?如果是k8s版本1.16,则链接到我在另一个问题中的答案时出现了相同的错误。我的k8s版本是1.16,我不知道此版本存在问题,感谢您的帮助,我将尝试降级!我不必降级,你的变通方法非常有效!谢谢你的帮助!Helm发布了,Helm init现在安装了一个具有apiVersion apps/v1的Tiller部署,使其与Kubernetes的较新版本兼容。Tiller的RBAC如何?我的k8s版本是1.16,我不知道这个版本有问题,感谢帮助,我将尝试降级!