标签: rancher-rke

错误:Kubernetes 集群无法访问:获取“http://localhost:8080/version?timeout=32s”:dial tcp 127.0.0.1:8080:connect:连接被拒绝

我正在尝试将我的应用程序部署到 Rancher 管理的 kubernetes 集群 RKE 中。我已经使用 auto devops 在 gitlab 中创建了管道。但是当掌舵图尝试部署时,我收到此错误。 错误:Kubernetes 集群无法访问:获取“http://localhost:8080/version?timeout=32s”:dial tcp 127.0.0.1:8080:connect:连接被拒绝

下面是我的部署脚本:

deploy:
  stage: deploy
  image: cdrx/rancher-gitlab-deploy
  only:
    - master
  script:
    - apk --no-cache add curl
    - curl -L https://get.helm.sh/helm-v3.3.0-rc.1-linux-amd64.tar.gz > helm.tar.gz
    - tar -zxvf helm.tar.gz
    - mv linux-amd64/helm /usr/local/bin/helm
    - helm install mychart ./mychart
Run Code Online (Sandbox Code Playgroud)

有人可以帮我解决这个问题吗

kubernetes kubernetes-helm rancher-rke

14
推荐指数
4
解决办法
2万
查看次数

Kubernetes 证书支持哪些椭圆曲线?

问题

我使用 secp256k1 生成了密钥和证书,运行rke版本 v1.2.8,并收到以下错误:

FATA[0000] Failed to read certificates from dir [/home/max/cluster_certs]: failed to read certificate [kube-apiserver-requestheader-ca.pem]: x509: unsupported elliptic curve
Run Code Online (Sandbox Code Playgroud)

kubectl version

Client Version: version.Info{Major:"1", Minor:"21", GitVersion:"v1.21.1", GitCommit:"5e58841cce77d4bc13713ad2b91fa0d961e69192", GitTreeState:"clean", BuildDate:"2021-05-12T14:18:45Z", GoVersion:"go1.16.4", Compiler:"gc", Platform:"linux/amd64"}
Run Code Online (Sandbox Code Playgroud)

我已经通过以下方式生成了根 CA 密钥和证书:

openssl ecparam -name secp256k1 -genkey -noout -out ca-pvt.pem -rand random.bin -writerand random.bin
openssl req -config .\openssl.cnf -x509 -sha256 -new -nodes -key ca-pvt.pem -days 10227 -out ca-cert.cer -rand random.bin -writerand random.bin
Run Code Online (Sandbox Code Playgroud)

然后我用它来签署由rke cert generate-csr我的 Kubernetes Rancher生成的 CSR cluster.yml …

elliptic-curve kubernetes rancher rancher-rke

9
推荐指数
1
解决办法
4043
查看次数

如何避免 Rancher RKE Reconcile 警告?

每当我使用 RKE 设置 Rancher Kubernetes 集群时,该集群就会完美设置。但是,我收到以下警告消息:

WARN[0011] [reconcile] host [host.example.com] is a control plane node without reachable Kubernetes API endpoint in the cluster
WARN[0011] [reconcile] no control plane node with reachable Kubernetes API endpoint in the cluster found
Run Code Online (Sandbox Code Playgroud)

(在上面的消息中,host.example.com是我实际主机名的占位符,此消息是针对 cluster.yml 中指定的每个控制平面主机给出的)

如何修改 RKEcluster.yml文件或任何其他设置以避免此警告?

kubernetes rancher reconcile rancher-rke

5
推荐指数
1
解决办法
4755
查看次数