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

No longer maintained, here's the workaround #19

Open
RobinDaugherty opened this issue Jun 10, 2024 · 0 comments
Open

No longer maintained, here's the workaround #19

RobinDaugherty opened this issue Jun 10, 2024 · 0 comments

Comments

@RobinDaugherty
Copy link

This project seems to be unmaintained. Pull requests have languished for years.

But fortunately, this project is no longer necessary! You can configure git to use ansible-vault directly.

First, add a git driver for "ansible-vault" designated files, instructing it to use ansible-vault to convert them to text in order to diff:

git config --global diff.ansible-vault.textconv "ansible-vault view"

Instruct git not to cache the plaintext, since that might present a security problem:

git config diff.ansible-vault.cachetextconv false

In your project, add .gitattributes to identify the files that should be treated as "ansible-vault" files by git:

# add to .gitattributes
group_vars/all.yml diff=ansible-vault merge=binary

This is based on https://stackoverflow.com/a/39511274

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

No branches or pull requests

1 participant