I have an Ansible playbook with vault, and I want to ask for vault password through the prompt box in my web interface and then pass the posted password when running ansible playbook. I tried to use:
echo $password | ansible-playbook test.yml --ask-vault-pass
to pass the password to the playbook, but it doesn't work, the error message is:
"msg": "Attempting to decrypt but no vault secrets found"
I don't want to store password in file for some resons and now I just want to try to automatically pass password to the playbook while running it. Is there any advice to me? The ansible version is 2.4.