mirror of
https://github.com/netbirdio/plugins.git
synced 2026-05-22 18:44:07 -07:00
sysutils/nut - Add port field to netclient (#2052)
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
PLUGIN_NAME= nut
|
||||
PLUGIN_VERSION= 1.8
|
||||
PLUGIN_VERSION= 1.8.1
|
||||
PLUGIN_COMMENT= Network UPS Tools
|
||||
PLUGIN_DEPENDS= nut
|
||||
PLUGIN_MAINTAINER= m.muenz@gmail.com
|
||||
|
||||
@@ -157,6 +157,12 @@
|
||||
<type>text</type>
|
||||
<help>Set the IP address of the remote NUT server.</help>
|
||||
</field>
|
||||
<field>
|
||||
<id>nut.netclient.port</id>
|
||||
<label>Port</label>
|
||||
<type>text</type>
|
||||
<help>Set the TCP port of the remote NUT server.</help>
|
||||
</field>
|
||||
<field>
|
||||
<id>nut.netclient.user</id>
|
||||
<label>Username</label>
|
||||
|
||||
@@ -111,6 +111,10 @@
|
||||
<default></default>
|
||||
<Required>N</Required>
|
||||
</address>
|
||||
<port type="PortField">
|
||||
<default>3493</default>
|
||||
<Required>N</Required>
|
||||
</port>
|
||||
<user type="TextField">
|
||||
<Required>N</Required>
|
||||
</user>
|
||||
|
||||
@@ -7,7 +7,7 @@ SHUTDOWNCMD "/usr/local/etc/rc.halt"
|
||||
POWERDOWNFLAG /etc/killpower
|
||||
{% endif %}
|
||||
{% if helpers.exists('OPNsense.Nut.netclient.enable') and OPNsense.Nut.netclient.enable == '1' %}
|
||||
MONITOR {{ OPNsense.Nut.general.name }}@{{ OPNsense.Nut.netclient.address }} 1 {{ OPNsense.Nut.netclient.user }} {{ OPNsense.Nut.netclient.password }} slave
|
||||
MONITOR {{ OPNsense.Nut.general.name }}@{{ OPNsense.Nut.netclient.address }}{% if helpers.exists('OPNsense.Nut.netclient.port') %}:{{ OPNsense.Nut.netclient.port }}{% endif %} 1 {{ OPNsense.Nut.netclient.user }} {{ OPNsense.Nut.netclient.password }} slave
|
||||
SHUTDOWNCMD "/usr/local/etc/rc.halt"
|
||||
POWERDOWNFLAG /etc/killpower
|
||||
{% endif %}
|
||||
|
||||
Reference in New Issue
Block a user