idok-commit AT lists.psi.ch
Subject: Commit emails of the iDok project
List archive
- From: "AFS account Florian Huebner" <huebner AT savannah.psi.ch>
- To: idok-commit AT lists.psi.ch
- Subject: [idok-commit] idok commit r374 - in trunk/sites/psi: oodaemon scripts/admin
- Date: Wed, 29 Jul 2009 08:30:19 +0200
- List-archive: <https://lists.web.psi.ch/pipermail/idok-commit/>
- List-id: Commit emails of the iDok project <idok-commit.lists.psi.ch>
Author: huebner
Date: Wed Jul 29 08:30:18 2009
New Revision: 374
Log:
script updates
Added:
trunk/sites/psi/scripts/admin/dmsdIndexMover.sh
trunk/sites/psi/scripts/admin/init_local_server.sh (contents, props
changed)
Modified:
trunk/sites/psi/oodaemon/convertOO.sh
trunk/sites/psi/scripts/admin/deploy_prod.sh
trunk/sites/psi/scripts/admin/deploy_qa.sh
Modified: trunk/sites/psi/oodaemon/convertOO.sh
==============================================================================
--- trunk/sites/psi/oodaemon/convertOO.sh (original)
+++ trunk/sites/psi/oodaemon/convertOO.sh Wed Jul 29 08:30:18 2009
@@ -31,7 +31,7 @@
- /opt/jdk1.6.0_01/bin/java \
+ /opt/java/bin/java \
-Xbootclasspath/p:/opt/dms/commons-io.jar:/opt/dms/juh.jar:/opt/dms/jurt.jar:/opt/dms/ridl.jar:/opt/dms/slf4j-api.jar:/opt/dms/slf4j-jdk14.jar:/opt/dms/unoil.jar:/opt/dms/commons-cli.jar:/opt/dms/jodconverter.jar
\
-cp /opt/dms/jodconverter-cli.jar \
com.artofsolving.jodconverter.cli.ConvertDocument
$INTMPFILE.$DOCTYPESOURCE $OUTTMPFILE.$DOCTYPEDEST
Modified: trunk/sites/psi/scripts/admin/deploy_prod.sh
==============================================================================
--- trunk/sites/psi/scripts/admin/deploy_prod.sh (original)
+++ trunk/sites/psi/scripts/admin/deploy_prod.sh Wed Jul 29 08:30:18
2009
@@ -54,13 +54,13 @@
COPY_SOURCES=
if [ $DO_IDOK ]; then
- COPY_SOURCES="$COPY_SOURCES opt/dms etc/init.d/dmssd"
+ COPY_SOURCES="$COPY_SOURCES opt/dms/ etc/init.d/dmssd"
fi
if [ $DO_DMSD ]; then
- COPY_SOURCES="$COPY_SOURCES opt/dmsd"
+ COPY_SOURCES="$COPY_SOURCES opt/dmsd/"
fi
if [ $DO_OOD ]; then
- COPY_SOURCES="$COPY_SOURCES opt/dms/ood"
+ COPY_SOURCES="$COPY_SOURCES opt/dms/ood/"
fi
REPLACE_PATTERNS=
@@ -81,12 +81,14 @@
#echo "Copying $src to $dst"
#cp -pR $src $dst
echo "synchronising $src to $dst"
- rsync -avE --delete
--exclude=ch.psi.idok.gwt.twiki.IdokSearchTwikiInclude/
--exclude=ch.psi.idok.gwt.twiki.IdokSearchTwikiMashup/ $src/ $dst/
+ /usr/bin/rsync -avE --delete
--exclude=ch.psi.idok.gwt.twiki.IdokSearchTwikiInclude/ \
+
--exclude=ch.psi.idok.gwt.twiki.IdokSearchTwikiMashup/ $src $dst
else
#echo "Copying $src to $dst"
#cp -p $src $dst
echo "synchronising $src to $dst"
- rsync -avE
--exclude=ch.psi.idok.gwt.twiki.IdokSearchTwikiInclude/
--exclude=ch.psi.idok.gwt.twiki.IdokSearchTwikiMashup/ $src/ $dst/
+ /usr/bin/rsync -avE
--exclude=ch.psi.idok.gwt.twiki.IdokSearchTwikiInclude/ \
+
--exclude=ch.psi.idok.gwt.twiki.IdokSearchTwikiMashup/ $src $dst
fi
done
@@ -95,7 +97,6 @@
for f in $REPLACE_PATTERNS ; do
absolute_patterns="$absolute_patterns $DST_ROOT/$f"
done
-
for f in $absolute_patterns; do
echo "Replacing patterns in $f"
cp -p $f $f.devel
Modified: trunk/sites/psi/scripts/admin/deploy_qa.sh
==============================================================================
--- trunk/sites/psi/scripts/admin/deploy_qa.sh (original)
+++ trunk/sites/psi/scripts/admin/deploy_qa.sh Wed Jul 29 08:30:18 2009
@@ -55,13 +55,13 @@
COPY_SOURCES=
if [ $DO_IDOK ]; then
- COPY_SOURCES="$COPY_SOURCES opt/dms etc/init.d/dmssd"
+ COPY_SOURCES="$COPY_SOURCES opt/dms/ etc/init.d/dmssd"
fi
if [ $DO_DMSD ]; then
- COPY_SOURCES="$COPY_SOURCES opt/dmsd"
+ COPY_SOURCES="$COPY_SOURCES opt/dmsd/"
fi
if [ $DO_OOD ]; then
- COPY_SOURCES="$COPY_SOURCES opt/dms/ood"
+ COPY_SOURCES="$COPY_SOURCES opt/dms/ood/"
fi
REPLACE_PATTERNS=
@@ -82,12 +82,14 @@
#echo "Copying $src to $dst"
#cp -pR $src $dst
echo "synchronising $src to $dst"
- rsync -avE --delete
--exclude=ch.psi.idok.gwt.twiki.IdokSearchTwikiInclude/
--exclude=ch.psi.idok.gwt.twiki.IdokSearchTwikiMashup/ $src/ $dst/
+ rsync -avE --delete
--exclude=ch.psi.idok.gwt.twiki.IdokSearchTwikiInclude/ \
+ --exclude=ch.psi.idok.gwt.twiki.IdokSearchTwikiMashup/
$src $dst
else
#echo "Copying $src to $dst"
#cp -p $src $dst
echo "synchronising $src to $dst"
- rsync -avE
--exclude=ch.psi.idok.gwt.twiki.IdokSearchTwikiInclude/
--exclude=ch.psi.idok.gwt.twiki.IdokSearchTwikiMashup/ $src/ $dst/
+ rsync -avE
--exclude=ch.psi.idok.gwt.twiki.IdokSearchTwikiInclude/ \
+ --exclude=ch.psi.idok.gwt.twiki.IdokSearchTwikiMashup/
$src $dst
fi
done
Added: trunk/sites/psi/scripts/admin/dmsdIndexMover.sh
==============================================================================
--- (empty file)
+++ trunk/sites/psi/scripts/admin/dmsdIndexMover.sh Wed Jul 29 08:30:18
2009
@@ -0,0 +1,72 @@
+#/bin/bash
+
+function usage() {
+ echo "Usage: $0 (backup|restore <file>)"
+ echo " $PWD must be /data"
+ exit 1
+}
+
+if [ $(pwd) != /data ]; then
+ echo "Error: PWD is not /data!"
+ exit 1
+fi
+
+H=$(hostname)
+echo "Hostname: $H"
+
+case $H in
+dms01)
+ S=prod;;
+dms02)
+ S=devel;;
+dms03)
+ S=qa;;
+*)
+ echo "Unknown host $H"
+ exit 1
+esac
+echo "System: $S"
+
+case "x$1" in
+xbackup)
+ if (($# != 1)); then
+ usage
+ fi
+ tar jcvf /afs/psi.ch/project/dms/index_backup/${S}-index-$(date
+"%Y%m%d").tar.bz2 /data/dmsd
+ ;;
+xrestore)
+ if (($# != 2)); then
+ usage
+ fi
+ if [ -d dmsd ]; then
+ echo "Error: dmsd directory already exists!"
+ exit 1
+ fi
+ F=${2##*/}
+ F=${F:=$2}
+ F=${F%%-*}
+ case "x$F" in
+ xprod) ;;
+ xqa) ;;
+ xdevel) ;;
+ *)
+ echo "Error: unknown backup file format!"
+ exit 1
+ ;;
+ esac
+ echo "File: $F"
+ tar xvjf $2
+ if [ $F != $S ]; then
+ for f in $(find dmsd -mindepth 3 -maxdepth 3); do
+ D=${f%/*}
+ N=${f##*/}
+ N=${N/$F/$S}
+ mv $f $D/$N
+ done
+ fi
+ ;;
+*)
+ usage
+ ;;
+esac
+
\ No newline at end of file
Added: trunk/sites/psi/scripts/admin/init_local_server.sh
==============================================================================
--- (empty file)
+++ trunk/sites/psi/scripts/admin/init_local_server.sh Wed Jul 29 08:30:18
2009
@@ -0,0 +1,14 @@
+#! /bin/bash
+#
+# Start local iDok debug server
+ant -f local-server.xml init-server-dirs
+ant -f local-server.xml create-test-project-svn
+mkdir /tmp/idok_server/projects/foo/bar/conf/schema
+cp java/ch/idok/service/server/admin/schema/DublinCore.schema
/tmp/idok_server/projects/foo/bar/conf/schema/DublinCore
+ant -f local-server.xml generate-logging-config
+xterm -e ant -f local-server.xml start-orbd &
+xterm -e ant -f local-server.xml start-indexer &
+
+echo "Start server in Eclipse"
+echo "Then initialize the admin db:"
+echo " curl -v --negotiate -u : -X PUT
http://mpc1127.psi.ch:8183/v1/admin/"
\ No newline at end of file
- [idok-commit] idok commit r374 - in trunk/sites/psi: oodaemon scripts/admin, AFS account Florian Huebner, 07/29/2009
Archive powered by MHonArc 2.6.19.