lan direction
This commit is contained in:
5
main.sh
5
main.sh
@@ -7,10 +7,11 @@ getcode(){
|
|||||||
curl --fail-early -s -o /dev/null -w "%{http_code}" "$url"
|
curl --fail-early -s -o /dev/null -w "%{http_code}" "$url"
|
||||||
}
|
}
|
||||||
|
|
||||||
site="https://seafile.clonbg.es/accounts/login/?next=/"
|
site="http://192.168.1.97:38082/accounts/login/?next=/"
|
||||||
|
|
||||||
code=$(getcode "$site")
|
code=$(getcode "$site")
|
||||||
|
|
||||||
|
echo $code
|
||||||
|
|
||||||
if [[ "$code" != 2?? ]];then
|
if [[ "$code" != 2?? ]];then
|
||||||
DATE=$(date +"%F_%H:%M:%S")
|
DATE=$(date +"%F_%H:%M:%S")
|
||||||
echo "$DATE docker restart seafile-mysql seafile-memcached seafile" >> "/home/ubunturpi/logs/docker_status.txt"
|
echo "$DATE docker restart seafile-mysql seafile-memcached seafile" >> "/home/ubunturpi/logs/docker_status.txt"
|
||||||
|
|||||||
Reference in New Issue
Block a user