nut and acme working

This commit is contained in:
2024-01-11 18:15:16 +13:00
parent ba7cda511e
commit c6755e8d97
19 changed files with 287 additions and 70 deletions

View File

@ -1,5 +1,12 @@
{% for ups in ups_devices %}
[ups{{ loop.index }}]
# File configured via Ansible playbook
# Reference documentation:
# https://networkupstools.org/docs/man/ups.conf.html
maxretry = 5
{% for ups in nut_server_ups_devices %}
[{{ ups.name }}]
driver = {{ ups.driver }}
port = {{ ups.port }}
{% endfor %}
{% endfor %}

View File

@ -0,0 +1,18 @@
# File configured via Ansible playbook
# Reference documentation:
# https://networkupstools.org/docs/man/upsd.conf.html
# MAXAGE 15
# TRACKINGDELAY 3600
# ALLOW_NO_DEVICE false
# STATEPATH /var/run/nut
LISTEN {{ nut_server_listen_address }} {{ nut_server_listen_port }}
LISTEN localhost {{ nut_server_listen_port }}
# MAXCONN 1024
CERTFILE {{ nut_server_certificate_file }}
# CERTPATH /usr/local/ups/etc/cert/upsd
# CERTIDENT "my nut server" "MyPasSw0rD"
# CERTREQUEST REQUIRE
DISABLE_WEAK_SSL true
# DEBUG_MIN 2

View File

@ -1,11 +1,17 @@
# File configured via Ansible playbook
# Reference documentation:
# https://networkupstools.org/docs/man/upsd.users.html
[{{ nut_client_admin_username }}]
password = {{ nut_client_admin_password }}
actions = set
actions = fsd
instcmds = all
[{{ nut_client_primary_username }}]
password = {{ nut_client_primary_password }}
upsmon primary
actions = SET
instcmds = ALL
[{{ nut_client_secondary_username }}]
password = {{ nut_client_secondary_password }}
upsmon secondary
actions = SET
instcmds = ALL
upsmon secondary