一、环境配置
网络规划:
阿里云vpc:10.34.0.0/16
cluser-ip:10.35.0.0/16
pod-ip:10.36.0.0/16
修改内核:
vi /etc/sysctl.conf
# docker
net.bridge.bridge-nf-call-iptables = 1
net.bridge.bridge-nf-call-ip6tables = 1
# swap off
vm.swappiness = 0
安装基础软件:
# 安装 git
yum -y install git
# 安装 centos 额外的yum源
yum install -y epel-release
# make 缓存
yum clean all && yum makecache
# 安装 软件
yum install -y python-pip python34 python-netaddr python34-pip ansible
# 升级 Jinja2
pip install --upgrade Jinja2
二、kubespray安装配置
下载源码:
git clone https://github.com/kubernetes-incubator/kubespray
# Install dep