fix vault password file handling
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
Robert Kaussow 2020-10-10 10:25:53 +02:00
parent 520c697daf
commit 43be014317
No known key found for this signature in database
GPG Key ID: 65362AE74AF98B61

View File

@ -23,7 +23,8 @@ if [ -n "${MOLECULE_CUSTOM_FILTERS_REPO}" ]; then
fi
if [ -n "${MOLECULE_ANSIBLE_VAULT_PASSWORD}" ]; then
echo "${MOLECULE_ANSIBLE_VAULT_PASSWORD}" > /root/.vaultpasswd
MOLECULE_ANSIBLE_VAULT_PASSWORD_FILE=/root/.vaultpasswd
echo "${MOLECULE_ANSIBLE_VAULT_PASSWORD}" > $MOLECULE_ANSIBLE_VAULT_PASSWORD_FILE
fi
exec env ANSIBLE_VAULT_PASSWORD_FILE="${MOLECULE_ANSIBLE_VAULT_PASSWORD}" /usr/local/bin/molecule "$@"
exec env ANSIBLE_VAULT_PASSWORD_FILE=$MOLECULE_ANSIBLE_VAULT_PASSWORD_FILE /usr/local/bin/molecule "$@"