-
Notifications
You must be signed in to change notification settings - Fork 24k
allow user to control vault decrypt is error #81918
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: devel
Are you sure you want to change the base?
Conversation
Not working for intended use case at https://github.com/AlanCoding/Ansible-inventory-file-examples/tree/master/vault/file_vars
the encrypted file at issue is https://github.com/AlanCoding/Ansible-inventory-file-examples/blob/master/vault/file_vars/group_vars/raleigh |
i did decryption errors, which require a secret ,missed the 'no secrets provided' one |
thinking if i should narrow it down to 'no secrets provided'? and keep decryption errors as hard error? is there a case to pass secrets, decrypt parts but not other parts? |
I re-tested and got this:
With the |
issues is that while im ignoring the error, im still returning the vaulted text (should be empty dict) .. no clue why no traceback |
Error:
Warning:
|
With current branch I get this
Just to show it here quickly, we have:
This is the issue that I'm interested in - ignoring an encrypted file that can't be decrypted. Since it's a vars file, it should contain a key-value mapping when decrypted. The request is to ignore the file, so that any group variables that would have been included if secrets were available are simply not included. |
@AlanCoding you might have not noticed, I changed the setting and config option names as we changed the scope of what it affects, use |
Thanks, that does seem to be working, and also manages to not interfere with other types of encrypted variables.
|
91492b3
to
d1e9d67
Compare
move vault error/warning handling just for dl fix test to new text
The test
|
new config item avoids requiring vault secret for all encrypted files, user is still responsible for play failing/doing the wrong thing if the data was actually required.
ISSUE TYPE