Hi, Marko --
How about having three files in vars directory (eg. pvs_vars.yml,
> stage_vars.yml, prod_vars.yml) with the same variable in it (ldapserver)
> and using include_vars module this way:
> - include_vars: "{{ env }}_vars.yml"
>
That sounds like a considerably easier and more sane
Hi,
How about having three files in vars directory (eg. pvs_vars.yml,
stage_vars.yml, prod_vars.yml) with the same variable in it (ldapserver) and
using include_vars module this way:
- include_vars: "{{ env }}_vars.yml"
More info:
http://docs.ansible.com/ansible/include_vars_module.html
I have a playbook (ldapconfig.yml) with a variables file
(ldapconfig_vars.yml), and am hoping to use an inventory var to specify
which dictionary of the below to call.
So, if env=PVS, it calls the ldapserver_pvs dictionary, if env=PROD, it
calls the ldapserver_prod dict, and so on.