diff options
-rwxr-xr-x | bin/lamp_test | 31 |
1 files changed, 0 insertions, 31 deletions
diff --git a/bin/lamp_test b/bin/lamp_test deleted file mode 100755 index f8a641b..0000000 --- a/bin/lamp_test +++ /dev/null @@ -1,31 +0,0 @@ -#!/bin/bash -# -# Test LAMP by checking Apache, MySQL, and PHP -# Requires: apache2, php5-mysql, libapache2-mod-php5, mysql-server -# - -# Check Apache is running; requires network connection so verify that -check=`ping -c 2 www.ubuntu.com |grep "2 received"` -if [ -n "$check" ]; then - run1=`w3m http://127.0.0.1/ | grep "404"` - if [ -n "$run1" ]; then - echo "FAIL: apache is not running." - exit 1 - fi -fi - -# Check if MySQL server is running -run2=`netstat -tap | grep mysql` -if [ -z "$run2" ]; then - echo "FAIL: mysql is not running." - exit 1 -fi - -# Check PHP -run3=`php -r 'phpinfo();' | grep 'PHP License'` -if [ -z "$run3" ]; then - echo "FAIL: php is not running." - exit 1 -fi - -exit 0 |