Editing Setting up Kubernetes cluster
Warning: You are not logged in. Your IP address will be publicly visible if you make any edits. If you log in or create an account, your edits will be attributed to your username, along with other benefits.
The edit can be undone.
Please check the comparison below to verify that this is what you want to do, and then save the changes below to finish undoing the edit.
Latest revision | Your text | ||
Line 1: | Line 1: | ||
− | This article describes a way to deploy a Kubernetes cluster on a few CentOS 7 machines | + | This article describes a way to deploy a Kubernetes cluster on a few CentOS 7 machines. |
{{Stub}} | {{Stub}} | ||
Line 8: | Line 8: | ||
* CentOS 7 minimal installed | * CentOS 7 minimal installed | ||
* firewalld stopped | * firewalld stopped | ||
− | + | : <code>systemctl stop firewalld; systemctl disable firewalld</code> | |
− | + | * ntpd installed and running: | |
− | + | : <code>yum -y install ntpd && systemctl start ntpd && systemctl enable ntpd</code> | |
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
== Master installation == | == Master installation == | ||
Line 54: | Line 30: | ||
Make sure <code>/etc/kubernetes/apiserver</code> contains this: | Make sure <code>/etc/kubernetes/apiserver</code> contains this: | ||
− | + | 4. Start master node services: | |
for S in etcd kube-apiserver kube-controller-manager kube-scheduler; do | for S in etcd kube-apiserver kube-controller-manager kube-scheduler; do | ||
Line 63: | Line 39: | ||
== Set nodes (minions) == | == Set nodes (minions) == | ||
− | + | 1. Install vzkernel: | |
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
rpm -ihv https://download.openvz.org/virtuozzo/factory/x86_64/os/Packages/v/vzkernel-3.10.0-229.7.2.vz7.6.9.x86_64.rpm | rpm -ihv https://download.openvz.org/virtuozzo/factory/x86_64/os/Packages/v/vzkernel-3.10.0-229.7.2.vz7.6.9.x86_64.rpm | ||
− | + | 2. Enable docker-ploop repo: | |
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
cd /etc/yum.repos.d/ | cd /etc/yum.repos.d/ | ||
wget https://copr.fedoraproject.org/coprs/kir/docker-ploop/repo/epel-7/kir-docker-ploop-epel-7.repo | wget https://copr.fedoraproject.org/coprs/kir/docker-ploop/repo/epel-7/kir-docker-ploop-epel-7.repo | ||
Line 95: | Line 49: | ||
yum install ploop docker | yum install ploop docker | ||
− | + | 3. Set ploop driver to be default for docker. | |
+ | |||
+ | Make sure <code>/etc/sysconfig/docker-storage</code> contains: | ||
DOCKER_STORAGE_OPTIONS="-s ploop" | DOCKER_STORAGE_OPTIONS="-s ploop" | ||
− | + | 4. Install flannel and kubernetes-node: | |
yum -y install flannel kubernetes-node | yum -y install flannel kubernetes-node | ||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
== See also == | == See also == | ||
* [https://github.com/coreos/etcd/blob/master/Documentation/configuration.md etcd configuration] | * [https://github.com/coreos/etcd/blob/master/Documentation/configuration.md etcd configuration] |