CentOS7 单机版使用kubeadm安装K8S
准备一台干干净净的服务器准备环境
-----------------------------------------------------------------------------------------
为了安全,先把SSH端口默认的22端口修改了
vi /etc/ssh/sshd_config修改Port,在服务器的安全策略组中把修改后的端口加进去
重启SSHD服务
service sshd restart----------------------------------------------------------------------------------------
修改主机名,并在hosts文件中加一行主机名的解析,重启服务器使配置生效
hostnamectl set-hostname master
hostnamectl status<br>vi /etc/hosts<br>reboot-----------------------------------------------------------------------------------------
关闭防火墙、selinux、swap
systemctl stop firewalld
systemctl disable firewalld
sed -i 's/enforcing/disabled/' /etc/selinux/config
setenforce 0
swapoff -a------------------------------------------------------------------------------------------
将桥接的IPv4流量传递到iptables的链:
cat > /etc/sysctl.d/k8s.conf/etc/yum.repos.d/kubernetes.repo
页:
[1]