bundlewrap/bundles/sshmon/files/check_http_url_for_string

14 lines
195 B
Text
Raw Normal View History

#!/bin/bash
url=$1
string=$2
if curl -m 30 -sLk "$url" | grep -F "$string" > /dev/null
then
echo OK
exit 0
else
echo "CRITICAL - String '$string' not found in '$url'"
exit 2
fi