-
Notifications
You must be signed in to change notification settings - Fork 0
/
facts.yml
37 lines (33 loc) · 1019 Bytes
/
facts.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
# playbook to gather facts about the system
- name: Gather facts
hosts: all
gather_facts: yes
tasks:
- name: Print the facts
debug:
var: ansible_facts
# playbook to gather facts about the system
- name: Gather facts
hosts: all
gather_facts: yes
tasks:
- name: Print the facts
debug:
var: ansible_facts # ansible_facts is a dictionary
# playbook to gather facts about the system
- name: Gather facts
hosts: all
gather_facts: yes
tasks:
- name: Print the facts
debug:
var: ansible_facts['ansible_distribution'] # ansible_facts is a dictionary
- name: Print the facts
debug:
var: ansible_facts['ansible_distribution_version'] # ansible_facts is a dictionary
- name: Print the facts
debug:
var: ansible_facts['ansible_distribution_major_version'] # ansible_facts is a dictionary
- name: Print the facts
debug:
var: ansible_facts['ansible_distribution_release'] # ansible_facts is a dictionary