mirror of
https://github.com/kubesphere/kubekey.git
synced 2025-12-26 01:22:51 +00:00
|
|
||
|---|---|---|
| build | ||
| cmd | ||
| deploy | ||
| docs | ||
| pkg | ||
| scripts | ||
| version | ||
| README.md | ||
| build.sh | ||
| go.mod | ||
| kubekey.go | ||
| tools.go | ||
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 Group,you 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://kubernetes.pek3b.qingstor.com/tools/kubekey/kk
chmod +x kk
- Deploy a Allinone cluster
./kk create cluster
- Deploy a MultiNodes cluster
Create a example configuration file by following command or example configuration file
./kk create config # Only kubernetes
./kk create config --add localVolume # Add plugins (eg: localVolume / nfsClient / localVolume,nfsClient)
# Please fill in the configuration file under the current path (k2cluster-example.yaml) according to the environmental information
Deploy cluster
./kk create cluster -f ./k2cluster-example.yaml
- Add Nodes
Add new node's information to the cluster config file
./kk scale -f ./k2cluster-example.yaml
- Reset Cluster
# allinone
./kk reset
# multinodes
./kk reset -f ./k2cluster-example.yaml
Supported
- Deploy allinone cluster
- Deploy multinodes cluster
- Add nodes (masters and nodes)
Build
git clone https://github.com/pixiake/kubekey.git
cd kubekey
./build.sh
Note: Docker needs to be installed before building.
Quick Start
- CaaO (Cluster as a Object)
- Support more container runtimes: cri-o containerd