forked from freifunk-franken/firmware
Add bootup notification and dissasociation notification
This commit is contained in:
parent
5ace9c2b82
commit
f0050578fe
|
@ -1,13 +1,18 @@
|
|||
#!/bin/sh
|
||||
|
||||
i=`/etc/clients.sh`
|
||||
wget -q -O - http://status.kreativitaet-trifft-technik.de/update/ff\?bootup=`date +%s`\&clients_count=$i
|
||||
|
||||
while read LINE
|
||||
do
|
||||
if [ "`echo $LINE | grep 'wlan0:'`" != "" ]; then
|
||||
wget -q -O - http://status.kreativitaet-trifft-technik.de/update/ff\?client_associated=`date +%s`\&clients_count=`/etc/clients.sh` & sleep 3; kill $!
|
||||
#echo http://status.kreativitaet-trifft-technik.de/update/ff\?client_associated=`date +%s`\&clients_count=`/etc/clients.sh` & sleep 3; kill $!
|
||||
|
||||
if [ "`echo $LINE | grep 'wlan0: new station'`" != "" ]; then
|
||||
i=`expr $i + 1`
|
||||
wget -q -O - http://status.kreativitaet-trifft-technik.de/update/ff\?client_associated=`date +%s`\&clients_count=$i
|
||||
fi
|
||||
if [ "`echo $LINE | grep 'wlan0: unknown event 20'`" != "" ]; then
|
||||
i=`expr $i - 1`
|
||||
wget -q -O - http://status.kreativitaet-trifft-technik.de/update/ff\?client_disassociated=`date +%s`\&clients_count=$i
|
||||
fi
|
||||
#echo `echo $LINE | grep 'wlan0:' | awk '{ print $4 }'` >> /var/log/clients_event.log
|
||||
done
|
||||
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user