24 lines
427 B
YAML
24 lines
427 B
YAML
- name: Install acpupsd
|
|
apt:
|
|
name: apcupsd
|
|
|
|
- name: Apcupsd configuration
|
|
copy:
|
|
src: ./filesystem/yggdrasil/etc/apcupsd/apcupsd.conf
|
|
dest: /etc/apcupsd/apcupsd.conf
|
|
mode: 0644
|
|
register: apcupsd_conf
|
|
|
|
- name: Enable/start apcupsd
|
|
systemd:
|
|
name: apcupsd
|
|
enabled: yes
|
|
state: started
|
|
|
|
- name: Restart apcupsd
|
|
systemd:
|
|
name: apcupsd
|
|
state: restarted
|
|
when:
|
|
apcupsd_conf is changed
|