diff options
Diffstat (limited to 'wlanWDprowl.sh')
| -rwxr-xr-x | wlanWDprowl.sh | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/wlanWDprowl.sh b/wlanWDprowl.sh new file mode 100755 index 0000000..3955346 --- /dev/null +++ b/wlanWDprowl.sh @@ -0,0 +1,21 @@ +#!/bin/bash +# wlanWDprowl.sh +# SJP 19 Nov 2017 +# +# Designed to stop a headless wireless raspi from disappearing from the LAN. +# IS called from a systemd timer +# +cd /usr/local/bin +# The following block enables private configuration +logdir="/path/to/my/log" # overwritten by sourcing from .logdir.config +if [ -e logdir.config ]; then + . logdir.config # source directory name from local config file +else echo "logdir.config does not exist"; exit 1 +fi +# end of privacy config + +# Detect the state of the wireless network adaptor +wirelessLink='wlan0' # ymmv +networkctl status ${wirlesessLink} | grep 'State:' + + |
