fixed #2101, maybe

This commit is contained in:
fgerlits 2007-02-01 17:45:57 +00:00
parent 5fe6ffbd15
commit 738ecfd77b
3 changed files with 17 additions and 9 deletions

View File

@ -21,6 +21,17 @@ installdir=/opt/campcaster
case "$1" in
configure)
if [ -f $installdir/storageServer.wasMounted ]; then
storagedir=$installdir/var/Campcaster/storageServer
if [ -d $storagedir.bak ]; then
rm -rf $storagedir.bak
fi
mv -f $storagedir $storagedir.bak
mkdir $storagedir
mount $storagedir
rm $installdir/storageServer.wasMounted
fi
# do post-installation configuration
$installdir/bin/postInstallStation.sh --directory=$installdir \
--apache-group=www-data \

View File

@ -70,11 +70,9 @@ case "$1" in
rm -rf $installdir/var/Campcaster/archiveServer/var/stor/*
storagedir=$installdir/var/Campcaster/storageServer
storage_is_local=yes
if [ "`mount | grep -o \"on $storagedir \"`" = "on $storagedir " ]; then
storage_is_local=no
fi
if [ "$storage_is_local" = "yes" ]; then
if [ -f $installdir/storageServer.wasMounted ]; then
rmdir $storagedir
else
rm -rf $storagedir/var/stor/*
fi
;;

View File

@ -80,11 +80,10 @@ case "$1" in
rm -rf $installdir/var/Campcaster/archiveServer/var/trans/*
storagedir=$installdir/var/Campcaster/storageServer
storage_is_local=yes
if [ "`mount | grep -o \"on $storagedir \"`" = "on $storagedir " ]; then
storage_is_local=no
fi
if [ "$storage_is_local" = "yes" ]; then
umount $storagedir
touch $installdir/storageServer.wasMounted
else
rm -rf $storagedir/var/access/*
rm -rf $storagedir/var/trans/*
fi