This is inventory_hostname.
This commit is contained in:
parent
2b467bc572
commit
401ac631b2
1 changed files with 1 additions and 1 deletions
|
@ -13,7 +13,7 @@
|
|||
- base
|
||||
|
||||
- name: make sure hostname is set right on rhel7 hosts
|
||||
command: hostnamectl set-hostname {{ ansible_fqdn }}
|
||||
command: hostnamectl set-hostname {{ inventory_hostname }}
|
||||
when: ( ansible_fqdn != inventory_hostname ) and ansible_distribution_major_version == '7'
|
||||
|
||||
- name: sshd_config
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue