echo -n to avoid new lines at the end

`echo blah | base64` will actually result in the base64 of `blah\n`, which will usually not be intended by the user.
This commit is contained in:
Carlos Alexandro Becker 2017-04-18 14:41:43 -03:00 committed by GitHub
parent 4e17230345
commit 4b5a3d2e5a

View File

@ -50,8 +50,8 @@ metadata:
name: mysecret
type: Opaque
data:
password: $(echo "s33msi4" | base64)
username: $(echo "jane" | base64)
password: $(echo -n "s33msi4" | base64)
username: $(echo -n "jane" | base64)
EOF
# TODO: kubectl-explain example