Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var Cluster = template.Must(template.New("Cluster").Parse( dedent.Dedent(` apiVersion: kubekey.kubesphere.io/v1alpha2 kind: Cluster metadata: name: {{ .Options.Name }} spec: hosts: - {name: node1, address: 172.16.0.2, internalAddress: 172.16.0.2, user: ubuntu, password: "Qcloud@123"} - {name: node2, address: 172.16.0.3, internalAddress: 172.16.0.3, user: ubuntu, password: "Qcloud@123"} roleGroups: etcd: - node1 control-plane: - node1 worker: - node1 - node2 controlPlaneEndpoint: ## Internal loadbalancer for apiservers # internalLoadbalancer: haproxy domain: lb.kubesphere.local address: "" port: 6443 kubernetes: version: {{ .Options.KubeVersion }} clusterName: cluster.local autoRenewCerts: true containerManager: {{ .Options.ContainerManager }} etcd: type: kubekey network: plugin: calico kubePodsCIDR: 10.233.64.0/18 kubeServiceCIDR: 10.233.0.0/18 ## multus support. https://github.com/k8snetworkplumbingwg/multus-cni multusCNI: enabled: false registry: privateRegistry: "" namespaceOverride: "" registryMirrors: [] insecureRegistries: [] addons: [] {{ if .Options.KubeSphereEnabled }} {{ .Options.KubeSphereConfigMap }} {{ end }} `)))
Cluster defines the template of cluster configuration file default.
Functions ¶
func GenerateCluster ¶
GenerateCluster is used to generate cluster configuration content.
Types ¶
Click to show internal directories.
Click to hide internal directories.