mirror of
https://github.com/kubernetes-sigs/kubespray.git
synced 2026-04-07 02:59:24 -02:30
Master and nodes will run the 'node' role, kube-proxy is run under a container, new script for ssl certs
This commit is contained in:
21
roles/kubernetes/node/templates/openssl.conf.j2
Normal file
21
roles/kubernetes/node/templates/openssl.conf.j2
Normal file
@@ -0,0 +1,21 @@
|
||||
[req]
|
||||
req_extensions = v3_req
|
||||
distinguished_name = req_distinguished_name
|
||||
[req_distinguished_name]
|
||||
[ v3_req ]
|
||||
basicConstraints = CA:FALSE
|
||||
keyUsage = nonRepudiation, digitalSignature, keyEncipherment
|
||||
subjectAltName = @alt_names
|
||||
[alt_names]
|
||||
DNS.1 = kubernetes
|
||||
DNS.2 = kubernetes.default
|
||||
DNS.3 = kubernetes.default.svc.{{ dns_domain }}
|
||||
{% for host in groups['kube-master'] %}
|
||||
IP.{{ loop.index }} = {{ hostvars[host]['ip'] | default(hostvars[host]['ansible_default_ipv4']['address']) }}
|
||||
{% endfor %}
|
||||
{% set idx = groups['kube-master'] | length | int + 1 %}
|
||||
IP.{{ idx | string }} = {{ kube_apiserver_ip }}
|
||||
{% if kube_loadbalancer_ip is defined | default('') %}
|
||||
{% set idx = idx | int + 1 %}
|
||||
IP.{{ idx | string }} = {{ kube_loadbalancer }}
|
||||
{% endif %}
|
||||
Reference in New Issue
Block a user