老师你好,我租了一台阿里云轻量级云服务器,然后用client-go去连接访问,但是报错
kind: Cluster
apiVersion: kind.x-k8s.io/v1alpha4
networking:
# WARNING: It is _strongly_ recommended that you keep this the default
# (127.0.0.1) for security reasons. However it is possible to change this.
apiServerAddress: "172.24.61.141"
# By default the API server listens on a random open port.
# You may choose a specific port but probably don't need to in most cases.
# Using a random port makes it easier to spin up multiple clusters.
apiServerPort: 6443
containerdConfigPatches:
- |-
[plugins."io.containerd.grpc.v1.cri".registry.mirrors."docker.io"]
endpoint = ["https://njzb6yez.mirror.aliyuncs.com"]
nodes:
- role: control-plane
- role: worker
- role: worker
Get "https://172.24.61.141:6443/api/v1/pods": dial tcp 172.24.61.141:6443: connectex: A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond.
172.24.61.141是我的私人ip,我在防火墙也开启了6443端口
但是我用我自己创建的Ubuntu就可以,这是为什么