Skip to content
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

Decrypt vaulted variables in yaml files #6

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

davetapley
Copy link

  • Appends decrypted value after the !vault tag.
  • Deletes encrypted string from the DOM.

Try to replicate existing semantics,
but no 'Decrypt' button (because I didn't need it).

See:
https://docs.ansible.com/ansible/latest/user_guide/vault.html#creating-encrypted-variables

* Appends decrypted value after the !vault tag.
* Deletes encrypted string from the DOM.

Try to replicate existing semantics,
but no 'Decrypt' button (because I didn't need it).

See:
https://docs.ansible.com/ansible/latest/user_guide/vault.html#creating-encrypted-variables
@gwatts
Copy link
Owner

gwatts commented Sep 21, 2021

@davetapley This doesn't seem to work for me atm; testing with this file (vault password is "test") https://github.com/gwatts/ansible-test/blob/main/keys.yaml

@gwatts
Copy link
Owner

gwatts commented Sep 21, 2021

also I think we'd want to maintain the "decrypt" button semantics so it matches the rest of the extension behavior

@davetapley
Copy link
Author

@davetapley This doesn't seem to work for me atm; testing with this file (vault password is "test")
https://github.com/gwatts/ansible-test/blob/main/keys.yaml

@gwatts well that is peculiar, I see the same, I'm glad you tested it, I'll 👀


also I think we'd want to maintain the "decrypt" button semantics so it matches the rest of the extension behavior

That's fair. I'll see if I can figure something out.
It's a little awkward because I collapse multiple encrypted lines down to a single one, which is easy enough just deleting DOM nodes and inserting a new one, but going the other way might require some more cleverness.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants