Add support for env var for IRIS_CONFIG_LOCATION

This commit is contained in:
Daniel Evans
2023-06-01 19:22:31 -07:00
parent 5ef872a5d3
commit 4a3a77419f

View File

@ -28,7 +28,10 @@ elif [[ $1 = "restart" ]]; then
elif [[ $1 = "local_scan" ]]; then
START=$(date +%s)
if $IS_CONTAINER; then
SCAN=$(mopidy --config /config/mopidy.conf local scan)
if [ -n "$IRIS_CONFIG_LOCATION" ]; then
SCAN=$(mopidy --config $IRIS_CONFIG_LOCATION local scan)
else
SCAN=$(mopidy --config /config/mopidy.conf local scan)
else
SCAN=$(sudo mopidyctl local scan)
fi