-
Notifications
You must be signed in to change notification settings - Fork 15
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
Lookup plugin #61
Comments
this doesnt work with the 1password connect I believe. |
according to https://developer.1password.com/docs/connect/connect-cli the |
Nevertheless, a native way without the need for any external dependency is very handy, especially when it comes to AWX or CI/CD-driven playbook execution |
While I gave it a try to implement a lookup plugin for this collection today, but unfortunately, the code is very tailored around module usage. I think the majority of the current API class implementation would need to be refactored with lookup plugin usage in mind as lookup plugins work differently. To the maintainers: Is this something you'd like to entertain? I am talking about a refactoring that adds the possibility to also work for a lookup plugin. If so, I might give it a shot. I am asking just because I don't want to make the effort and then ultimately the PR gets never touched or declined. |
Bonus points if this can use 1Password secret references! |
Very simple implementation vgijssel/setup@279608f |
I’ve developed an Ansible vars plugin in this commit that integrates seamlessly with 1Password. This plugin allows the use of 1Password secret references directly within a dedicated Ansible variables file for a specific host or group. For instance: my_secret_variable: op://my-vault/some-secret/password The variables file, such as If the 1Password team is interested, I’d be happy to submit a pull request to share this functionality! |
Summary
Collection does not have a lookup module, making it very hard to use it inside things like
group_vars
.Use cases
It's much more useful to be able to put things inside group vars using a lookup module than having a whole module call to make these, also, it allows you to retrieve the secret from the running host.
Proposed solution
An Ansible lookup module :)
Is there a workaround to accomplish this today?
Not really, working with a large number of secrets makes this very hard.
References & Prior Work
The text was updated successfully, but these errors were encountered: