mirror of https://github.com/easzlab/kubeasz.git
14 lines
637 B
YAML
14 lines
637 B
YAML
# 设置 dns svc ip (这里选用 SERVICE_CIDR 中第2个IP)
|
|
CLUSTER_DNS_SVC_IP: "{{ SERVICE_CIDR | ipaddr('net') | ipaddr(2) | ipaddr('address') }}"
|
|
|
|
# 设置 APISERVER 地址
|
|
KUBE_APISERVER: "{%- if inventory_hostname in groups['kube-master'] -%} \
|
|
https://{{ inventory_hostname }}:6443 \
|
|
{%- else -%} \
|
|
{%- if groups['kube-master']|length > 1 -%} \
|
|
https://127.0.0.1:6443 \
|
|
{%- else -%} \
|
|
https://{{ groups['kube-master'][0] }}:6443 \
|
|
{%- endif -%} \
|
|
{%- endif -%}"
|