script modified

This commit is contained in:
Lucio Lelii 2020-04-09 11:20:01 +02:00
parent 12ac117046
commit 87ecf94971
5 changed files with 22 additions and 13 deletions

View File

@ -160,8 +160,8 @@ echo -e "\ninstalling components \c"
for f in $distrolibs/*.*;
do
if [ -z "$dryrun" ]; then
cp $f $shared/
basename $f >> $shared/$liblist
cp $f $shared/
basename $f | sed -r 's/[0-9]{1,2}.[0-9]{1,2}(.[0-9]{1,2})?(-SNAPSHOT)?(-[0-9]{1,2}.[0-9]{1,2}(.[0-9]{1,2})?-[0-9]{4,8})?/*/' >> $shared/$liblist
fi
echo -n "."
sleep .01

View File

@ -47,7 +47,7 @@ fi
echo -e "\nRemoving resource profiles from the Information System\n"
source ./load-env
source ./load-env $ghnhome
#java org.gcube.smartgears.utils.sweeper.AppSweeperClient $apps 1>/dev/null
#if [ "$?" != "0" ]; then

View File

@ -38,15 +38,15 @@ fi
echo -e "\nRemoving resource profiles from the Information System\n"
source "$ghnhome"/scripts/load-env
source "$ghnhome"/scripts/load-env "$ghnhome"
RETVAL=
if [ -z "$filename" ]; then
java org.gcube.smartgears.utils.sweeper.ContainerSweeperClient 1>/dev/null
java org.gcube.smartgears.utils.sweeper.ContainerSweeperClient -G"$ghnhome" 1>/home/gcube/SmartGears/containerState.log
RETVAL=$?
else
java org.gcube.smartgears.utils.sweeper.ContainerSweeperClient $filename 1>/dev/null
java org.gcube.smartgears.utils.sweeper.ContainerSweeperClient $filename -G"$ghnhome" 1>/home/gcube/SmartGears/containerState.log
RETVAL=$?
if [ $RETVAL -eq 0 ] ; then
echo -e "\nvolatile state saved in $ghnhome/$filename"
@ -63,4 +63,5 @@ else
rm -rf $ghnhome/state
fi
exit $RETVAL
exit $RETVAL

View File

@ -1,7 +1,15 @@
if [ -z "$GHN_HOME" ]; then
echo -e "\nERROR:please specify the GHN_HOME env var." >&2
echo -e "\naborting.\n"
exit 1
ghnhome=$1
if [ -z "$ghnhome" ]; then
if [ -z "$GHN_HOME" ]; then
echo -e "\nERROR:please specify the gHN directory (-g) or define the GHN_HOME env var." >&2
showhelp
echo -e "\naborting.\n"
exit 1
else
ghnhome=$GHN_HOME
fi
fi
export CLASSPATH=$CLASSPATH:"$GHN_HOME/lib/*"
export CLASSPATH=$CLASSPATH:"$ghnhome/lib/*"

View File

@ -9,7 +9,7 @@
<groupId>org.gcube.distribution</groupId>
<artifactId>smartgears-distribution</artifactId>
<version>2.5.0</version>
<version>2.5.2-SNAPSHOT</version>
<packaging>pom</packaging>
<name>A distribution for the SmartGears Framework</name>