22 lines
436 B
YAML
22 lines
436 B
YAML
|
---
|
||
|
# tasks file for nut
|
||
|
- name: Install os-specific packages
|
||
|
include_tasks: "{{ ansible_os_family | lower }}.yml"
|
||
|
|
||
|
- name: Enable standalone mode for Nut
|
||
|
lineinfile:
|
||
|
path: /etc/nut/nut.conf
|
||
|
regexp: '^MODE='
|
||
|
line: MODE=standalone
|
||
|
notify: restart nut-server
|
||
|
|
||
|
- name: Copy ups.conf
|
||
|
template:
|
||
|
src: ups.conf.j2
|
||
|
dest: /etc/nut/ups.conf
|
||
|
owner: root
|
||
|
group: root
|
||
|
mode: 0644
|
||
|
notify: restart nut-server
|
||
|
|