nut LISTEN ip
parent
f01821b3a9
commit
cc1a43322e
|
@ -223,8 +223,6 @@ all:
|
||||||
|
|
||||||
nut_host: localhost
|
nut_host: localhost
|
||||||
|
|
||||||
nut_listen: "10.0.0.0/24"
|
|
||||||
|
|
||||||
caladan:
|
caladan:
|
||||||
ansible_host: caladan
|
ansible_host: caladan
|
||||||
ansible_user: ansible
|
ansible_user: ansible
|
||||||
|
|
|
@ -27,11 +27,13 @@
|
||||||
password = "{{ nut_upsmon_password }}"
|
password = "{{ nut_upsmon_password }}"
|
||||||
upsmon {{ nut_types[nut_mode] }}
|
upsmon {{ nut_types[nut_mode] }}
|
||||||
|
|
||||||
- name: add LISTEN line to /etc/nut/upsd.conf
|
- name: allow NUT to listen to all IPs
|
||||||
lineinfile:
|
blockinfile:
|
||||||
path: /etc/nut/upsd.conf
|
path: /etc/nut/upsd.conf
|
||||||
regexp: '^LISTEN'
|
block: |
|
||||||
line: "LISTEN {{ nut_listen }}"
|
LISTEN 0.0.0.0
|
||||||
|
LISTEN ::1
|
||||||
|
when: nut_mode == "netserver"
|
||||||
|
|
||||||
- name: start and enable nut-upsd
|
- name: start and enable nut-upsd
|
||||||
service:
|
service:
|
||||||
|
|
Loading…
Reference in New Issue