tteckster 3 роки тому
батько
коміт
28b0fcdce7
1 змінених файлів з 7 додано та 0 видалено
  1. 7 0
      misc/internet-check.sh

+ 7 - 0
misc/internet-check.sh

@@ -0,0 +1,7 @@
+#!/usr/bin/env bash -ex
+wget -q --tries=10 --timeout=5 --spider http://google.com
+if [[ $? -eq 0 ]]; then
+        echo -e "Internet Online"
+else
+        echo -e "Internet Offline"
+fi