mirror of https://github.com/easzlab/kubeasz.git
53 lines
844 B
YAML
53 lines
844 B
YAML
# 在deploy节点生成CA相关证书,以供整个集群使用
|
||
# 以及初始化kubedns.yaml配置文件
|
||
- hosts: deploy
|
||
roles:
|
||
- deploy
|
||
|
||
# 集群节点的公共配置任务
|
||
- hosts:
|
||
- kube-cluster
|
||
- deploy
|
||
- etcd
|
||
- lb
|
||
roles:
|
||
- prepare
|
||
|
||
# [可选]多master部署时的负载均衡配置
|
||
- hosts: lb
|
||
roles:
|
||
- lb
|
||
|
||
# 创建etcd集群
|
||
- hosts: etcd
|
||
roles:
|
||
- etcd
|
||
|
||
# kubectl 客户端配置
|
||
- hosts:
|
||
- kube-cluster
|
||
- deploy
|
||
roles:
|
||
- kubectl
|
||
|
||
# docker服务安装
|
||
- hosts: kube-cluster
|
||
roles:
|
||
- docker
|
||
|
||
# master 节点部署
|
||
- hosts: kube-master
|
||
roles:
|
||
- kube-master
|
||
|
||
# node 节点部署
|
||
- hosts: kube-node
|
||
roles:
|
||
- kube-node
|
||
|
||
# 集群网络插件部署
|
||
- hosts: kube-cluster
|
||
roles:
|
||
- { role: calico, when: "CLUSTER_NETWORK == 'calico'" }
|
||
- { role: flannel, when: "CLUSTER_NETWORK == 'flannel'" }
|