blob: e16b593304f1fa82cf9c70ca6ebf939cc50c51e0 [file] [log] [blame]
---
# hostvars-defaults/tasks/main.yml
# Sets default variables in multiple hosts to allow them to accessed on other
# hosts via the hostvars['otherhost']['defaultvar']
- name: List host group specific values of default variables
debug:
msg: "{{ item.key }}:{{ item.val }}"
with_items: "{{ hostvars_defaults_dict }}"
- name: Set hostvars as facts to persist them
set_fact: {"{{ item.key }}":"{{ item.val }}"}
with_items: "{{ hostvars_defaults_dict }}"