X-Git-Url: https://code.wpia.club/?p=gigi.git;a=blobdiff_plain;f=doc%2Fscripts%2Fgigi;h=e0e6dc03a18c9db70ff53ba068d0787ee41d2988;hp=f96d19309b57319ed670e86fe91f183f30b2dfa2;hb=5b63545e9b35c41f8130ecce5d3e787fad74478a;hpb=753aae17442cbcdfcbce2d720b7b5dfd13918294 diff --git a/doc/scripts/gigi b/doc/scripts/gigi index f96d1930..e0e6dc03 100755 --- a/doc/scripts/gigi +++ b/doc/scripts/gigi @@ -1,60 +1,67 @@ -#!/bin/bash -if [ "$JDBC_DRIVER" == "" ] -then -JDBC_DRIVER=/usr/share/java/postgresql-jdbc4.jar -#echo "JDBC_DRIVER environment variable not set. Assumed path: $JDBC_DRIVER" -fi -if [ "$GIGI_EXEC" == "" ] -then -GIGI_EXEC=/usr/share/java/gigi.jar -#echo "GIGI_EXEC environment variable not set. Assumed path: $GIGI_EXEC" -fi - -cd /var/lib/cacert-gigi - -if [ "$1" == "start" ] -then - java -cp $JDBC_DRIVER:$GIGI_EXEC org.cacert.gigi.Launcher -elif [ "$1" == "debug" ] -then - java -cp $JDBC_DRIVER:$GIGI_EXEC -Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=n,address=8000 org.cacert.gigi.Launcher -elif [ "$1" == "start-daemon" ] -then - if [ ! -e /etc/cacert/gigi/conf.tar ]; then - echo "Config missing." - exit 1; - fi - java -cp $JDBC_DRIVER:$GIGI_EXEC org.cacert.gigi.Launcher < /etc/cacert/gigi/conf.tar >> /var/log/cacert-gigi.log 2>&1 & - echo $! > /var/run/cacert-gigi.pid -elif [ "$1" == "signer" ] -then - java -cp $JDBC_DRIVER:$GIGI_EXEC org.cacert.gigi.util.SimpleSigner -elif [ "$1" == "reset-database" ] -then - java -cp $JDBC_DRIVER:$GIGI_EXEC org.cacert.gigi.util.DatabaseManager -elif [ "$1" == "fetch-alexa" ] -then - java -cp $JDBC_DRIVER:$GIGI_EXEC org.cacert.gigi.util.HighFinancialValueFetcher $2 $3 -elif [ "$1" == "fetch-locales" ] -then - if [ "$2" == "" ]; then - java -cp $JDBC_DRIVER:$GIGI_EXEC org.cacert.gigi.util.FetchLocales - else - java -cp $JDBC_DRIVER:$GIGI_EXEC org.cacert.gigi.util.FetchLocales "$2" - fi -elif [ "$1" == "signer-conf" ] -then - mkdir /var/lib/cacert-gigi/config - cd /var/lib/cacert-gigi/config - tar x gigi.properties -else - echo "Usage: gigi