4 |
HOST="" |
HOST="" |
5 |
DBNAME="" |
DBNAME="" |
6 |
FORCE="no" |
FORCE="no" |
7 |
COUNT=0;for word in `echo ${PAM_DBHOST} | tr [\/] [" "] |sed 's/mysql://g' `; do if [ $COUNT -eq 0 ]; then HOST=`echo $word`; fi; if [ $COUNT -eq 1 ]; then DBNAME=`echo $word`; fi; let COUNT=$COUNT+1; done |
COUNT=0;for word in `echo ${PAM_DBHOST} | tr [\/] [" "] |tr [?] [" "] |sed 's/mysql://g' `; do if [ $COUNT -eq 0 ]; then HOST=`echo $word`; fi; if [ $COUNT -eq 1 ]; then DBNAME=`echo $word`; fi; let COUNT=$COUNT+1; done |
8 |
PASSWORD=${PAM_DBPSW} |
PASSWORD=${PAM_DBPSW} |
9 |
if [ $# -gt 0 ]; then |
if [ $# -gt 0 ]; then |
10 |
for INPUT in $*; do |
for INPUT in $*; do |
31 |
fi |
fi |
32 |
TEST=`echo $INPUT | sed 's/--host=//g'` |
TEST=`echo $INPUT | sed 's/--host=//g'` |
33 |
if [ $TEST != $INPUT ]; then |
if [ $TEST != $INPUT ]; then |
34 |
COUNT=0;for word in `echo $TEST | tr [\/] [" "] |sed 's/mysql://g' `; do if [ $COUNT -eq 0 ]; then HOST=`echo $word`; fi; if [ $COUNT -eq 1 ]; then DBNAME=`echo $word`; fi; let COUNT=$COUNT+1; done |
COUNT=0;for word in `echo $TEST | tr [\/] [" "] | tr [?] [" "] | sed 's/mysql://g' `; do if [ $COUNT -eq 0 ]; then HOST=`echo $word`; fi; if [ $COUNT -eq 1 ]; then DBNAME=`echo $word`; fi; let COUNT=$COUNT+1; done |
35 |
export DBNAME; |
export DBNAME; |
36 |
export HOST; |
export HOST; |
37 |
fi |
fi |
48 |
else |
else |
49 |
if [ "$USERNAME" == "" ] || [ "$HOST" == "" ] || [ "$DBNAME" == "" ]; then |
if [ "$USERNAME" == "" ] || [ "$HOST" == "" ] || [ "$DBNAME" == "" ]; then |
50 |
echo "" |
echo "" |
51 |
echo " Usage: ./install_GL_PARAM.sh [options] " |
echo " Usage: ./install_DB.sh [options] " |
52 |
echo "" |
echo "" |
53 |
echo " Options: " |
echo " Options: " |
54 |
echo "" |
echo "" |