add_hosts_entry.yaml 346 B

123456789101112
  1. ---
  2. - name: "Add line in hosts file to point ***CONTENTS REDACTED*** to ***CONTENTS REDACTED***"
  3. hosts: all
  4. gather_facts: True
  5. become: true
  6. tasks:
  7. - name: "line entry into /etc/hosts"
  8. lineinfile:
  9. path: "/etc/hosts"
  10. line: "***CONTENTS REDACTED***"
  11. state: present
  12. backup: yes