mirror of https://github.com/k3s-io/k3s
Merge pull request #9543 from ddysher/base64-w0
Document why we use 'tr -d' instead of 'base64 w0'pull/6/head
commit
62911dc2fb
|
@ -550,6 +550,8 @@ function create-certs {
|
|||
exit 2
|
||||
}
|
||||
CERT_DIR="${KUBE_TEMP}/easy-rsa-master/easyrsa3"
|
||||
# By default, linux wraps base64 output every 76 cols, so we use 'tr -d' to remove whitespaces.
|
||||
# Note 'base64 -w0' doesn't work on Mac OS X, which has different flags.
|
||||
CA_CERT_BASE64=$(cat "${CERT_DIR}/pki/ca.crt" | base64 | tr -d '\r\n')
|
||||
MASTER_CERT_BASE64=$(cat "${CERT_DIR}/pki/issued/${MASTER_NAME}.crt" | base64 | tr -d '\r\n')
|
||||
MASTER_KEY_BASE64=$(cat "${CERT_DIR}/pki/private/${MASTER_NAME}.key" | base64 | tr -d '\r\n')
|
||||
|
|
Loading…
Reference in New Issue