mirror of
https://github.com/TrezOne/docker-mods-uptime-kuma-timeout-fix.git
synced 2026-07-19 09:53:02 -04:00
Merge pull request #728 from a-priestley/jellyfin-rffmpeg
Jellyfin rffmpeg NAT WoL
This commit is contained in:
@@ -86,3 +86,7 @@ WOL ENV:
|
|||||||
* WOL_API = IP of docker host
|
* WOL_API = IP of docker host
|
||||||
* WOL_API_PORT= port wol_api is running on
|
* WOL_API_PORT= port wol_api is running on
|
||||||
* WOL_WAIT= time in seconds to wait for host to wake
|
* WOL_WAIT= time in seconds to wait for host to wake
|
||||||
|
* WOL_NATIVE_HOST = IP of NAT gateway with forwarded port for WoL *
|
||||||
|
* WOL_NATIVE_PORT = External port on gateway for forwarding. Ensure that it is mapped to your target machine IP on port 9. *
|
||||||
|
|
||||||
|
*Optional. Only applicable when not using the WoL docker service API and when waking from outside NAT is required. Omit, or leave blank otherwise.
|
||||||
|
|||||||
@@ -14,8 +14,15 @@ if [ $RFFMPEG_WOL == "native" ] && [ ! -z $RFFMPEG_HOST ] && [ ! -z $RFFMPEG_HOS
|
|||||||
then
|
then
|
||||||
echo WOL enabled
|
echo WOL enabled
|
||||||
echo "$RFFMPEG_HOST" is down, sending wakeup to "$mac"
|
echo "$RFFMPEG_HOST" is down, sending wakeup to "$mac"
|
||||||
wakeonlan $mac
|
|
||||||
#wakeonlan -i $RFFMPEG_HOST $mac
|
WOL_OPTIONS=""
|
||||||
|
if [ ! -z $WOL_NATIVE_HOST ]; then
|
||||||
|
WOL_OPTIONS="$WOL_OPTIONS -i $WOL_NATIVE_HOST"
|
||||||
|
fi
|
||||||
|
if [ ! -z $WOL_NATIVE_PORT ]; then
|
||||||
|
WOL_OPTIONS="$WOL_OPTIONS -p $WOL_NATIVE_PORT"
|
||||||
|
fi
|
||||||
|
wakeonlan $WOL_OPTIONS $mac
|
||||||
echo "waiting $WOL_WAIT seconds for $RFFMPEG_HOST to wake"
|
echo "waiting $WOL_WAIT seconds for $RFFMPEG_HOST to wake"
|
||||||
sleep $WOL_WAIT
|
sleep $WOL_WAIT
|
||||||
fi
|
fi
|
||||||
|
|||||||
Reference in New Issue
Block a user