ansible/lib/ansible/parsing
Adrian Likins 32971e8639 Fix 'vault rekey' with vault secret env var
if ANSIBLE_VAULT_PASSWORD_FILE is set, 'ansible-vault rekey myvault.yml'
will fail to prompt for the new vault password file, and will use
None.

Fix is to split out 'ask_vault_passwords' into 'ask_vault_passwords'
and 'ask_new_vault_passwords' to make the logic simpler. And then
make sure new_vault_pass is always set for 'rekey', and if not, then
call ask_new_vault_passwords() to set it.

ask_vault_passwords() would return values for vault_pass and new
vault_pass, and vault cli previously would not prompt for new_vault_pass
if there was a vault_pass set via a vault password file.

Fixes #18247

(cherry picked from commit 309f54b709)
2016-11-01 13:13:10 -04:00
..
utils Fixing up jsonify and adding unit tests 2016-02-29 14:51:23 -05:00
vault Fix 'vault rekey' with vault secret env var 2016-11-01 13:13:10 -04:00
yaml Move uses of to_bytes, to_text, to_native to use the module_utils version (#17423) 2016-09-06 22:54:17 -07:00
__init__.py Fix typo in lib/ansible/parsing/__init__.py (#16761) 2016-07-20 18:03:50 -04:00
dataloader.py Fix search path for relative paths in roles (fixes #17877) 2016-10-17 11:20:44 -04:00
mod_args.py During initial argument evaluation, cast args to string. (#17595) 2016-09-15 16:41:11 -04:00
quoting.py Break apart a looped dependency to show a warning when parsing playbooks 2015-10-27 12:39:42 -07:00
splitter.py Move uses of to_bytes, to_text, to_native to use the module_utils version (#17423) 2016-09-06 22:54:17 -07:00