#!/bin/bash
# author: Teddy
CheckURL="http://fueux.com"
STATUS_CODE=`curl -o /dev/null -m 10 --connect-timeout 10 -s -w %{http_code} $CheckURL`
#echo "$CheckURL Status Code:\t$STATUS_CODE"
if [ "$STATUS_CODE" = "502" ]; then
/etc/init.d/php-fpm restart
fi
Created
August 23, 2014 08:16
-
-
Save sgsheg/c4b318c2fc726b44753c to your computer and use it in GitHub Desktop.
listen php-fpm stop
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment