Force kubelet certificates to be generated as lowercase (#1886)

All nodes get converted to lowercase, so certs should set
CN with lowercase as well.
This commit is contained in:
Matthew Mosesohn 2017-10-27 15:58:25 +01:00 committed by GitHub
parent 84cf6fbe83
commit fe81bba08d

View file

@ -105,14 +105,13 @@ fi
if [ -n "$HOSTS" ]; then
for host in $HOSTS; do
cn="${host%%.*}"
gen_key_and_cert "node-${host}" "/CN=system:node:${cn}/O=system:nodes"
gen_key_and_cert "node-${host}" "/CN=system:node:${cn,,}/O=system:nodes"
done
fi
# system:node-proxier
if [ -n "$HOSTS" ]; then
for host in $HOSTS; do
cn="${host%%.*}"
# kube-proxy
gen_key_and_cert "kube-proxy-${host}" "/CN=system:kube-proxy/O=system:node-proxier"
done