Overview
- to know magic variables
- hosts: all
gather_facts: no
tasks:
- name: show Magic | group_names
debug: var=group_names
- name: show Magic | groups
debug: var=groups
- name: show Magic | inventory_hostname
debug: var=inventory_hostname
- name: show Magic | inventory_hostname_short
debug: var=inventory_hostname_short
- name: show Magic | play_hosts
debug: var=play_hosts
- name: show Magic | inventory_dir
debug: var=inventory_dir
- name: show Magic | inventory_file
debug: var=inventory_file
# Reserved magic variable
- name: show Reserved magic | environment
debug: var=environment