-
-
Save pfriedland/396d5a86024b5c724c6e8960fd7a4b91 to your computer and use it in GitHub Desktop.
Ansible playbook to get os distro and version for all hosts. Works on Fedora/CentOS/RedHat machines.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- name: Print linux distribution and version | |
hosts: all | |
tasks: | |
- name: capture output of id command | |
command: cat /etc/system-release | |
register: login | |
- debug: msg="{{ login.stdout }}" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment