network-manager.yml 808 B

1234567891011121314151617181920212223242526
  1. ---
  2. - name: Install network manager dispatch script
  3. copy:
  4. src: networkmanager/99-origin-dns.sh
  5. dest: /etc/NetworkManager/dispatcher.d/
  6. mode: 0755
  7. notify: restart NetworkManager
  8. when: openshift_node_dnsmasq_install_network_manager_hook | default(true) | bool
  9. - name: Add network manager configuration
  10. ini_file:
  11. path: /etc/NetworkManager/conf.d/99-origin.conf
  12. section: main
  13. option: "{{ item.key }}"
  14. value: "{{ item.value }}"
  15. state: "{{ 'present' if item.present is not defined or item.present else 'absent' }}"
  16. no_extra_spaces: yes
  17. create: yes
  18. mode: 0600
  19. notify: restart NetworkManager
  20. with_items:
  21. - key: dns
  22. value: none
  23. present: "{{ openshift_node_dnsmasq_disable_network_manager_dns | default(false) | bool }}"
  24. - meta: flush_handlers