Skip to content

Commit

Permalink
Debugging...
Browse files Browse the repository at this point in the history
Signed-off-by: Arnaud Quette <[email protected]>
  • Loading branch information
aquette committed Dec 16, 2023
1 parent 419d9a1 commit 2a75660
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion smartnut/rootfs/etc/cont-init.d/smartnut.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@
# Home Assistant Community Add-on: SmartNUT - Network UPS Tools
# Configures SmartNUT - Network UPS Tools
# ==============================================================================
set -x

readonly UPS_CONF=/etc/nut/ups.conf

# FIXME: check if root is really needed? simple 'nut' should do
Expand All @@ -13,10 +15,11 @@ chown -R root:root /etc/nut
find /etc/nut -not -perm 0660 -type f -exec chmod 0660 {} \;
find /etc/nut -not -perm 0660 -type d -exec chmod 0660 {} \;

# Clear configuration
echo "" > "${UPS_CONF}"
nut-scanner -A

# NUT discovery through Avahi
nut-scanner -A

# Check for USB devices first
if bashio::config.true 'autoconf_usb_devices' ;then
Expand Down

0 comments on commit 2a75660

Please sign in to comment.