mirror of
https://github.com/itdoginfo/ansible-openwrt-hirkn.git
synced 2025-12-16 20:14:34 +05:00
fix noresolv
This commit is contained in:
@@ -352,21 +352,17 @@
|
|||||||
regexp: "# server_names ="
|
regexp: "# server_names ="
|
||||||
line: "server_names = ['google', 'cloudflare', 'scaleway-fr', 'yandex']"
|
line: "server_names = ['google', 'cloudflare', 'scaleway-fr', 'yandex']"
|
||||||
when: check_server_names.stdout
|
when: check_server_names.stdout
|
||||||
|
|
||||||
- name: edit dhcp config. resolvfile commented
|
|
||||||
lineinfile:
|
|
||||||
path: /etc/config/dhcp
|
|
||||||
regexp: "option resolvfile"
|
|
||||||
line: " #option resolvfile '/tmp/resolv.conf.auto'"
|
|
||||||
|
|
||||||
- name: edit dhcp config. add localhost server
|
- name: edit dhcp config. add localhost server
|
||||||
lineinfile:
|
lineinfile:
|
||||||
path: /etc/config/dhcp
|
path: /etc/config/dhcp
|
||||||
insertafter: "#option resolvfile"
|
firstmatch: "true"
|
||||||
|
insertafter: "option leasefile '/tmp/dhcp.leases'"
|
||||||
line: "{{ item }}"
|
line: "{{ item }}"
|
||||||
with_items:
|
with_items:
|
||||||
- " list server '127.0.0.53#53'"
|
- " list server '127.0.0.53#53'"
|
||||||
- " list server '/pool.ntp.org/208.67.222.222'"
|
- " list server '/pool.ntp.org/208.67.222.222'"
|
||||||
|
- " option noresolv '1'"
|
||||||
|
|
||||||
- name: enable and start dnscrypt-proxy
|
- name: enable and start dnscrypt-proxy
|
||||||
service:
|
service:
|
||||||
|
|||||||
Reference in New Issue
Block a user