If the file already exists we need to grant group read permissions explicitly.

This commit is contained in:
vinayak goyal
2020-11-16 22:59:30 +00:00
parent 147a120948
commit c2ea6842a7

View File

@@ -622,6 +622,7 @@ function write-pki-data {
if [[ -n "${KUBE_PKI_READERS_GROUP:-}" ]]; then
(umask 027; echo "${data}" | base64 --decode > "${path}")
chgrp "${KUBE_PKI_READERS_GROUP:-}" "${path}"
chmod g+r "${path}"
else
(umask 077; echo "${data}" | base64 --decode > "${path}")
fi