home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
OS/2 Shareware BBS: 10 Tools
/
10-Tools.zip
/
wsgatsam.zip
/
install
/
WSGWinstallJDBC.sh
< prev
Wrap
Linux/UNIX/POSIX Shell Script
|
2003-02-24
|
2KB
|
70 lines
#!/bin/sh
# JDBC Setup - IBM WebServices Gateway
# The arguments are:
# "1: WebServices Gateway dir"
# "2: WebSphere nodename"
# "3: WebSphere AppServer dir"
# "4: DB2 dir"
echo
if [ $# -eq 4 ]; then # test there are 4 arguments
if [ -d $1 ]; then # test 1st argument is a directory
if [ -d $3 ]; then # test 3d argument is a directory
DB2JAVAZIP=$4/java12/db2java.zip
if [ -f $DB2JAVAZIP ]; then # test db2java.zip exists
./installJDBC.sh $1 $2 $3 $DB2JAVAZIP > $3/logs/WSGWinstallJDBC.log 2>&1
if [ $? -eq 0 ]; then # installJDBC.sh worked.
echo "The WebServices Gateway JDBC has been installed."
else
echo "The WebServices Gateway JDBC has NOT been created."
echo "Try looking at the WSGWinstallJDBC.log file in the /logs subdirectory"
echo "of the WebSphere AppServer dir to diagnose the problem."
fi
else # couldn't find db2java.zip
echo "The file $DB2JAVAZIP couldn't be found."
echo "The WebServices Gateway JDBC has NOT been installed."
fi
else # 3d argument isn't a dir
echo "The directory ($3) specified for WebSphere AppServer doesn't exist."
echo "The WebServices Gateway JDBC has NOT been installed."
fi
else # 1st argument isn't a dir
echo "The directory ($1) specified for WebServices Gateway doesn't exist."
echo "The WebServices Gateway JDBC has NOT been installed."
fi
else # user didn't pass 4 arguments
echo "WSGWinstallJDBC.sh requires 4 arguments:"
echo "1: WebServices Gateway Directory (no trailing /)"
echo "2: WebSphere nodename"
echo "3: WebSphere AppServer Directory (no trailing /)"
echo "4: DB2 Directory (no trailing /)"
echo "Example: ./WSGWinstallJDBC.sh /opt/WebSphere/AppServer/WSGW bportier /opt/WebSphere/AppServer /usr/IBMdb2/V7.1"
fi
echo