summaryrefslogtreecommitdiffstats
path: root/roles/openshift_ansible_inventory/templates/multi_ec2.yaml.j2
diff options
context:
space:
mode:
Diffstat (limited to 'roles/openshift_ansible_inventory/templates/multi_ec2.yaml.j2')
-rw-r--r--roles/openshift_ansible_inventory/templates/multi_ec2.yaml.j215
1 files changed, 15 insertions, 0 deletions
diff --git a/roles/openshift_ansible_inventory/templates/multi_ec2.yaml.j2 b/roles/openshift_ansible_inventory/templates/multi_ec2.yaml.j2
index 23dfe73b8..8228ab915 100644
--- a/roles/openshift_ansible_inventory/templates/multi_ec2.yaml.j2
+++ b/roles/openshift_ansible_inventory/templates/multi_ec2.yaml.j2
@@ -1,11 +1,26 @@
# multi ec2 inventory configs
cache_max_age: {{ oo_inventory_cache_max_age }}
+cache_location: {{ oo_inventory_cache_location | default('~/.ansible/tmp/multi_ec2_inventory.cache') }}
accounts:
{% for account in oo_inventory_accounts %}
- name: {{ account.name }}
provider: {{ account.provider }}
+ provider_config:
+{% for section, items in account.provider_config.items() %}
+ {{ section }}:
+{% for property, value in items.items() %}
+ {{ property }}: {{ value }}
+{% endfor %}
+{% endfor %}
env_vars:
AWS_ACCESS_KEY_ID: {{ account.env_vars.AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: {{ account.env_vars.AWS_SECRET_ACCESS_KEY }}
+{% if account.all_group is defined and account.hostvars is defined%}
+ all_group: {{ account.all_group }}
+ hostvars:
+{% for property, value in account.hostvars.items() %}
+ {{ property }}: {{ value }}
+{% endfor %}
+{% endif %}
{% endfor %}