Answers for "ansible sety hostname"

-1

ansible set hostname from facts

- name: Set proper hostname
  hostname:
    #name: hostvars[inventory_hostname].ansible_host
    name: "{{ hostvars[inventory_hostname].ansible_host }}"
  become: yes
  when:
    - ansible_facts['os_family'] == 'Suse'
Posted by: Guest on June-08-2020

Code answers related to "Shell/Bash"

Browse Popular Code Answers by Language