# internalhost == the internal name of the target machine.
# externalhost == the external name of the target machine (if different from internal name).
#
# Set ASTROGRID_HOME environment variable.
export ASTROGRID_HOME=/usr/local/astrogrid
#
# Create the top level directory.
#
mkdir $ASTROGRID_HOME
#
# Create downloads directory
mkdir $ASTROGRID_HOME/downloads
#
# -------- -------- -------- --------
# Install Sun JDK.
# *Need to be root to run rpm.
# *Ignore this section if JDK already installed
#
#
# Get the target java JDK.
pushd $ASTROGRID_HOME/downloads
wget http://www.astrogrid.org/maven/java--downloads/j2sdk-1_4_2_11-linux-i586.rpm
popd
#
# Install the JDK (need to be root).
rpm -i $ASTROGRID_HOME/downloads/2sdk-1_4_2_11-linux-i586.rpm
#
# Set JAVA_HOME environment variable.
export JAVA_HOME=/usr/java/j2sdk1.4.2_11
#
# -------- -------- -------- --------
# Install Tomcat.
# *Ignore this section if Tomcat already installed
#
# Get the latest Tomcat distro.
# http://www.astrogrid.org/maven/tomcat/zips/
pushd $ASTROGRID_HOME/downloads
wget http://www.astrogrid.org/maven/tomcat/zips/jakarta-tomcat-5.0.28.zip
popd
#
# Unpack the Tomcat distro.
pushd $ASTROGRID_HOME
unzip $ASTROGRID_HOME/downloads/jakarta-tomcat-5.0.28.zip
popd
#
# Set CATALINA_HOME environment variable.
export CATALINA_HOME=$ASTROGRID_HOME/jakarta-tomcat-5.0.28
#
# Tweak the Tomcat control scripts.
chmod a+x $CATALINA_HOME/bin/*.sh
#
# Tweak the Tomcat user accounts.
vi $CATALINA_HOME/conf/tomcat-users.xml
+
+
+
#
# Start Tomcat.
$CATALINA_HOME/bin/startup.sh
#
# Check Tomcat running.
# http://internalhost:8080/
#
# Check Tomcat admin login (workshop, qwerty)
# http://internalhost:8080/admin
#
# Check Tomcat manager login (workshop, qwerty)
# http://internalhost:8080/manager/html
#
# -------- -------- -------- --------
# ** EXTRA STEP required to add DSA admin users to Tomcat **
# Install DSA admin users.
#
#
# Stop Tomcat ...
$CATALINA_HOME/bin/shutdown.sh
#
# Tweak the user accounts.
vi $CATALINA_HOME/conf/tomcat-users.xml
+
+
+
#
# Start Tomcat ...
$CATALINA_HOME/bin/startup.sh
#
# Check Tomcat running.
# http://internalhost:8080/
#
# -------- -------- -------- --------
# Install DSA webapp.
#
#
# Create DSA webapp directory.
mkdir $ASTROGRID_HOME/database
mkdir $ASTROGRID_HOME/database/webapp
#
# Get the latest DSA webapp.
pushd database/webapp
wget http://www.astrogrid.org/maven/org.astrogrid/wars/astrogrid-dsa-catalog-2006.3.01pl.war
popd
#
# Create the config directory
mkdir $ASTROGRID_HOME/database/config
#
# Extract the default properties
unzip
-j \
-d $ASTROGRID_HOME/database/config \
$ASTROGRID_HOME/database/webapp/astrogrid-dsa-catalog-2006.3.01pl.war \
WEB-INF/classes/default.properties
#
# Rename example dataset properties file.
mv $ASTROGRID_HOME/database/config/default.properties \
$ASTROGRID_HOME/database/config/example.properties
#
# Edit example dataset properties file.
vi $ASTROGRID_HOME/database/config/example.properties
....
datacenter.url=http://externalhost:8080/saao-database/
....
datacenter.name=SAAO DSA
datacenter.description=SAAO DSA with test dataset
....
datacenter.authorityId=za.ac.saao
datacenter.resourceKey=test-dataset
....
datacenter.publisher=SAAO
datacenter.contact.name=xxxx
datacenter.contact.email=astrogrid.admin@saao.ac.za
....
org.astrogrid.registry.admin.endpoint=http://internalhost:8080/saao-registry/services/RegistryUpdate
....
org.astrogrid.registry.query.endpoint=http://galahad.star.le.ac.uk:8080/astrogrid-registry/services/RegistryQuery
....
org.astrogrid.registry.query.altendpoint=http://galahad.star.le.ac.uk:8080/astrogrid-registry/services/RegistryQuery
#
# Create DSA context file.
vi $CATALINA_HOME/conf/Catalina/localhost/saao-database.xml
** Replace ASTROGRID_HOME with the full path (two places) **
#
# Check the DSA home page.
# http://internalhost:8080/saao-database/
#
# Check external access.
# http://externalhost:8080/saao-database/
#
# Self register page.
# http://internalhost:8080/saao-database/admin/register.jsp
ContactName xxxx
ContactEmail astrogrid.admin@saao.ac.za
#
# No need to fix URLs to use external address.
# They should already be set correctly using datacenter.url from properties file.
#
#
# Check that SAAO DSA services are visible in SAAO registry.
# http://internalhost:8080/saao-registry/browse.jsp?IvornPart=za.ac.saao
#
# Ask the AstroGrid registry to harvest SAAO public registry.
# ** This needs to be done by a member of the AstroGrid team at Leicester **
#
# Check that SAAO DSA services are visible in the main AstroGrid registry.
# http://galahad.star.le.ac.uk:8080/astrogrid-registry/browse.jspIvornPart=za.ac.saao