goethite / hashivault_vars Goto Github PK
View Code? Open in Web Editor NEWAnsible Vars Plugin for Hashicorp Vault
License: MIT License
Ansible Vars Plugin for Hashicorp Vault
License: MIT License
I have ansible_connection
set in group_vars/all.yml
. At least in my setup hashivault_vars
is executed before host_group_vars
. Therefore, ansible_connection
is not set yet when hashivault_vars
is run, which leads to the wrong protocol being used.
I, personally, do not need to be able to have different secrets depending on the protocol. I would be happy with /secret/ansible/hosts/hosta.example.com
. Anyway, any ideas on how to solve this? I do not want to set ansible_connection
in Vault. I only would like to keep secrets there.
Hi.. @easybe and @gbevan ..
we found this repository with good project and we are trying to implement on our virtual environment
we are using right now ansible-5.2
installed hashivault_vars 0.2.0 without any errors using pip
ansible 5.2 in this case use python 3.8
we recreate this path on vault for test
/secret/ansible/groups/all
inside a simple var for example:
testvar = '123abc'
vault kv get secret/ansible/groups/all
======= Metadata =======
Key Value
--- -----
created_time 2022-02-15T14:55:53.343017959Z
custom_metadata <nil>
deletion_time n/a
destroyed false
version 1
===== Data =====
Key Value
--- -----
testvar 123abc
and on playbook test can't found this var
- name: Lookup hashicorp vault secrets
hosts: localhost
gather_facts: false
connection: local
vars:
tasks:
- name: Debug
ansible.builtin.debug:
msg: "{{ testvar }}"
output:
TASK [Debug test 3] *****************************************************************************************************************************************************************************
fatal: [localhost]: FAILED! =>
msg: |-
The task includes an option with an undefined variable. The error was: 'testvar' is undefined
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.