Files
Ansible_/roles/Configure_Hostname/tasks/main.yml
2020-08-18 07:42:39 +02:00

16 lines
344 B
YAML
Executable File

---
# tasks file for Configure_Hostname
- name: Configure Hostname
shell: hostnamectl set-hostname "{{hostname_suffix}}"."{{suffix}}"
- name: Insert Hosts
blockinfile:
path: /etc/hosts
block: |
172.17.22.174 gsmc5.gsmc.com
- name: Insert resolv
replace:
path: /etc/resolv.conf
regexp: '^gmv.es'
replace: 'gsmc.com'