下午好,我是Kubernetes新手,我正在安装开发环境Kubernetes,我有一个red hat服务器(Redhat)作为node/master,同时,我按照以下步骤安装:
按照页面上的教程进行操作:
https://www.linuxtechi.com/install-kubernetes-k8s-minikube-centos-8/
sudo dnf update -y
sudo setenforce 0
sudo sed -i --follow-symlinks 's/SELINUX=enforcing/SELINUX=disabled/g' /etc/sysconfig/selinux
sudo systemctl start docker
sudo systemctl enable docker
sudo dnf install conntrack -y
#Installing Kubectl
sudo cat <<EOF > /etc/yum.repos.d/kubernetes.repo (root)
yum install -y kubectl (root)
#Installing Minikube
curl -Lo minikube https://storage.googleapis.com/minikube/releases/latest/minikube-linux-amd64
chmod +x minikube
mkdir -p /usr/local/bin/
install minikube /usr/local/bin/然而,当我配置minikube时,它并不指向我的服务器的IP,而是指向IP 172.17.0.2:

minikube ip
172.17.0.2
kubectl cluster-infoTo further debug and diagnose cluster problems, use 'kubectl cluster-info dump'.
The connection to the server 172.17.0.2:8443 was refused - did you specify the right host or port?我的IP是10.154.7.209
我能做错什么吗?如果我不能使用minikube将服务器提升为主/节点,我可以使用什么?
发布于 2020-08-05 12:24:00
你没有做错任何事,?。minikube基本上使用docker驱动程序,因此172.17.0.2是运行集群的容器的IP地址。
但看起来您使用的是proxy somewhere in your system。因此,您需要在NO_PROXY环境变量中包含172.17.0.0/24范围。
如下所示:
export HTTP_PROXY=http://<proxy hostname:port>
export HTTPS_PROXY=https://<proxy hostname:port>
export NO_PROXY=localhost,127.0.0.1,10.96.0.0/12,192.168.99.0/24,192.168.39.0/24,172.17.0.0/24 ?
minikube start
# get pods
minukube kubectl -- get pods --all-namespaces✌️
https://stackoverflow.com/questions/63251413
复制相似问题