Seeking some best-practice advice about where to store variables within the 
following structure:

* multiple inventory folders ./inventory/x, ./inventory/y, ./inventory/z
* inside each inventory folder, combinations of dynamic and static 
inventory sources
* inside each inventory folder, environment specific group vars

Currently I am copy-pasting variables common to all of the inventories 
(environments) between the all.yml group_vars files.


My question: is there a way to have a 'global' group variables file I can 
use for this type of variable?


I know I could source a file with include_vars: at the start of each of the 
multiple plays inside the playbooks, but hoped there might be something 
more elegant and/or automatic (like group_vars) available. Maybe even a 
simple restructure I can't think of.

.
├── inventory
│   ├── aws-dev
│   │   ├── aws-dev
│   │   ├── ec2.ini
│   │   ├── ec2.py
│   │   └── group_vars
│   │       ├── all
│   │       │   ├── all.yml
│   │       │   └── secrets.yml
│   │       ├── security_group_app.yml
│   │       └── security_group_util
│   │           ├── secrets.yml
│   │           └── security_group_util.yml
│   ├── aws-prod
│   │   ├── aws-prod
│   │   └── group_vars
│   │       └── all
│   │           ├── all.yml
│   │           └── secrets.yml
│   └── vmware-dev
│       ├── group_vars
│       │   ├── all
│       │   │   ├── all.yml
│       │   │   └── secrets.yml
│       │   └── tag_role_app.yml
│       ├── vmware-dev
│       ├── vmware.ini
│       └── vmware.py
├── roles
├── aws-configure.yml
├── aws-provision.yml
├── vmware-configure.yml
└── vmware-provision.yml


-- 
You received this message because you are subscribed to the Google Groups 
"Ansible Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/306e15e9-3a22-4c24-a346-791029131072%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to