Install Kubernetes/K3s only, both Kubernetes/K3s and KubeSphere, and related cloud-native add-ons, it supports all-in-one, multi-node, and HA 🔥🐳
Go to file
pixiake e0df9df425 add docs 2020-04-27 23:44:53 +08:00
build add K2Cluster object 2020-04-26 10:40:50 +08:00
cmd add local volume 2020-04-27 17:39:42 +08:00
deploy add K2Cluster object 2020-04-26 10:40:50 +08:00
docs add docs 2020-04-27 23:44:53 +08:00
pkg add local volume 2020-04-27 17:39:42 +08:00
scripts add reset cmd 2020-04-26 15:14:43 +08:00
version add K2Cluster object 2020-04-26 10:40:50 +08:00
README.md add docs 2020-04-27 23:44:53 +08:00
go.mod add K2Cluster object 2020-04-26 10:40:50 +08:00
kubekey.go add K2Cluster object 2020-04-21 23:47:22 +08:00
tools.go add K2Cluster object 2020-04-26 10:40:50 +08:00

KubeKey

Deploy a Kubernetes Cluster flexibly and easily

Quick Start

Check List

Please follow the list to prepare environment.

ID Check Item
1 Require SSH can access to all nodes.
2 It's recommended that Your OS is clean (without any other software installed), otherwise there may be conflicts.
3 OS requirements (For Minimal Installation of KubeSphere only)at least 2 vCPUs and 4GB RAM.
4 Make sure the storage service is available if you want to deploy a cluster with KubeSphere.
The relevant client should be installed on all nodes in cluster, if you storage server is nfs / ceph / glusterfs.
5 Make sure the DNS address in /etc/resolv.conf is available. Otherwise, it may cause some issues of DNS in cluster.
6 If your network configuration uses Firewall or Security Groupyou must ensure infrastructure components can communicate with each other through specific ports.
It's recommended that you turn off the firewall or follow the link configuriation: NetworkAccess
7 A container image mirror (accelerator) is recommended to be prepared, if you have trouble downloading images from dockerhub.io.

Usage

  • Download binary
curl -O -k https://kubesphere-installer.pek3b.qingstor.com/kubeocean/ko
chmod +x ko
  • Deploy a Allinone cluster
./ko create cluster

# Kubesphere can be installed by "--add kubesphere"
./ko create cluster --add kubesphere
  • Deploy a MultiNodes cluster

Create a cluster config file by following command or example config file

./ko create config

Deploy cluster

./ko create cluster --cluster-info ./cluster-info.yaml

# Kubesphere can be installed by "--add kubesphere"
./ko create cluster --cluster-info ./cluster-info.yaml --add kubesphere
  • Add Nodes

Add new node's information to the cluster config file

./ko scale --cluster-info ./cluster-info.yaml
  • Reset Cluster
# allinone
./ko reset

# multinodes
./ko reset --cluster-info /home/ubuntu/cluster-info.yaml

Supported

  • Deploy allinone cluster
  • Deploy multinodes cluster
  • Add nodes (masters and nodes)

Build

git clone https://github.com/pixiake/kubeocean.git
cd kubeocean
./build.sh

Note: Docker needs to be installed before building.