summaryrefslogtreecommitdiff
path: root/roles/kubernetes/kubeadm/control-plane/templates/kubeadm-join.config.j2
blob: 9f79fbadd2b4eac919ec3311a63c52eca0bc9d3c (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
{# https://godoc.org/k8s.io/kubernetes/cmd/kubeadm/app/apis/kubeadm/v1beta3 #}
{#  #}
apiVersion: kubeadm.k8s.io/v1beta3
kind: JoinConfiguration
discovery:
  bootstrapToken:
    apiServerEndpoint: "127.0.0.1:6443"
    token: "{{ kube_bootstrap_token }}"
    caCertHashes:
    - "{{ kube_bootstrap_ca_cert_hash }}"
controlPlane:
  certificateKey: "{{ kubeadm_upload_certs_key }}"
  localAPIEndpoint:
    bindPort: 6442
{% if kubernetes_overlay_node_ip is defined %}
    advertiseAddress: "{{ kubernetes_overlay_node_ip }}"
{% endif %}
nodeRegistration:
  name: "{{ kubernetes_node_name }}"
  criSocket: "{{ kubernetes_cri_socket }}"
  kubeletExtraArgs:
    node-labels: "ansible.spreadsapce.org/inventory_hostname={{ inventory_hostname }}"
{% if kubernetes_overlay_node_ip is defined %}
    node-ip: "{{ kubernetes_overlay_node_ip }}"
{% endif %}