-
-
Save amsterdatech/72be66e70221cdb3af41655ba999b7c4 to your computer and use it in GitHub Desktop.
HTTP Ping
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function http-ping { | |
SLEEP=${2:-5} | |
while true; do echo "$(date +'%Y-%m-%d %H:%M:%S') - GET $1 - $(curl -sL -w "%{http_code}" -o /dev/null $1)"; sleep $SLEEP; done | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment