forked from TrueCloudLab/certificates
Add newline to password file for readabiliy
This commit is contained in:
parent
bc63829111
commit
4e8e4c638e
1 changed files with 2 additions and 1 deletions
|
@ -32,6 +32,7 @@ function init_if_possible () {
|
||||||
function generate_password () {
|
function generate_password () {
|
||||||
set +o pipefail
|
set +o pipefail
|
||||||
< /dev/urandom tr -dc A-Za-z0-9 | head -c40
|
< /dev/urandom tr -dc A-Za-z0-9 | head -c40
|
||||||
|
echo
|
||||||
set -o pipefail
|
set -o pipefail
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -45,7 +46,7 @@ function step_ca_init () {
|
||||||
--address ":9000"
|
--address ":9000"
|
||||||
)
|
)
|
||||||
if [ -n "${DOCKER_STEPCA_INIT_PASSWORD}" ]; then
|
if [ -n "${DOCKER_STEPCA_INIT_PASSWORD}" ]; then
|
||||||
echo -n "${DOCKER_STEPCA_INIT_PASSWORD}" > "${STEPPATH}/password"
|
echo "${DOCKER_STEPCA_INIT_PASSWORD}" > "${STEPPATH}/password"
|
||||||
else
|
else
|
||||||
generate_password > "${STEPPATH}/password"
|
generate_password > "${STEPPATH}/password"
|
||||||
fi
|
fi
|
||||||
|
|
Loading…
Reference in a new issue