You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@jena.apache.org by an...@apache.org on 2015/12/17 10:43:25 UTC

jena git commit: JENA-1099: Export FUSEKI_HOME and FUSEKI_BASE

Repository: jena
Updated Branches:
  refs/heads/master fd0c7b31f -> 9ab858400


JENA-1099: Export FUSEKI_HOME and FUSEKI_BASE

Default FUSEKI_BASE to $FUSEKI_HOME/run
  It was not being exported. This is the compatible setting
  as it agrees with the java setup.
Remove FUSEKI_DATA_DIR
  Wrong value (was $FUSEKI_HOME/DB)
  Not used for anything
  Don't create $FUSEKI_DATA_DIR
Remove DATA_DIR (not used)


Project: http://git-wip-us.apache.org/repos/asf/jena/repo
Commit: http://git-wip-us.apache.org/repos/asf/jena/commit/9ab85840
Tree: http://git-wip-us.apache.org/repos/asf/jena/tree/9ab85840
Diff: http://git-wip-us.apache.org/repos/asf/jena/diff/9ab85840

Branch: refs/heads/master
Commit: 9ab8584002c59fcac6e917463f42ec96ade73ab5
Parents: fd0c7b3
Author: Andy Seaborne <an...@apache.org>
Authored: Thu Dec 17 09:05:36 2015 +0000
Committer: Andy Seaborne <an...@apache.org>
Committed: Thu Dec 17 09:15:47 2015 +0000

----------------------------------------------------------------------
 jena-fuseki2/apache-jena-fuseki/fuseki | 42 ++++++++++-------------------
 1 file changed, 14 insertions(+), 28 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/jena/blob/9ab85840/jena-fuseki2/apache-jena-fuseki/fuseki
----------------------------------------------------------------------
diff --git a/jena-fuseki2/apache-jena-fuseki/fuseki b/jena-fuseki2/apache-jena-fuseki/fuseki
index 4bee1b4..ee0f219 100755
--- a/jena-fuseki2/apache-jena-fuseki/fuseki
+++ b/jena-fuseki2/apache-jena-fuseki/fuseki
@@ -22,7 +22,12 @@
 #
 # Configuration
 # -------------
-# Default values are loaded from /etc/default/fuseki, if it exists.
+# Values are loaded from /etc/default/fuseki, if it exists.
+# The description below cover the default settings if /etc/default/fuseki
+# does not exist.
+#
+# Set DEBUG=1 (see below or set the environment variable) to print the
+# settings to be used.
 #
 # JAVA
 #   Command to invoke Java. If not set, java (from the PATH) will be used.
@@ -37,7 +42,7 @@
 # 
 # FUSEKI_BASE
 #   The root of the runtime area - logs files, system files, local configuration.
-#   Defaults to /etc/fuseki.
+#   Defaults to $FUSEKI_HOME/run.
 #
 # FUSEKI_RUN
 #   Where the fuseki.pid file should be stored.  It defaults
@@ -169,10 +174,8 @@ then
       *) SCRIPT=$( dirname "$0" )/$SCRIPT;; # fix
     esac
   fi
-
   # Work out root from script location
   FUSEKI_HOME="$( cd "$( dirname "$SCRIPT" )" && pwd )"
-
 fi
 
 # Deal with Cygwin path issues
@@ -187,9 +190,11 @@ then
   exit 1
 fi
 
+# Set FUSEKI_BASE
 if [ -z "$FUSEKI_BASE" ]
 then
-  FUSEKI_BASE="/etc/fuseki"
+  #FUSEKI_BASE="/etc/fuseki"
+  FUSEKI_BASE="$FUSEKI_HOME/run"  
 fi
 
 if [ "$cygwin" == "true" ]
@@ -197,7 +202,6 @@ then
   FUSEKI_BASE=`cygpath -w "$FUSEKI_BASE"`
 fi
 
-
 if [ ! -e "$FUSEKI_BASE" -o ! -d "$FUSEKI_BASE" ]
 then
   log_daemon_msg "FUSEKI_BASE '$FUSEKI_BASE' does not exist or is not a directory" 1>&2
@@ -210,14 +214,6 @@ then
   exit 1
 fi
 
-
-# Deal with Cygwin path issues
-if [ "$cygwin" == "true" ]
-then
-  FUSEKI_HOME=`cygpath -w "$FUSEKI_HOME"`
-  FUSEKI_BASE=`cygpath -w "$FUSEKI_BASE"`
- fi
-
 # Find a location for the pid file
 if [ -z "$FUSEKI_RUN" ]
 then
@@ -237,18 +233,12 @@ then
 fi
 FUSEKI_LOGS="$FUSEKI_BASE/logs"
 
-# Std Err and Out log
+# Stderr and stdout log
 if [ -z "$FUSEKI_LOGS_STDERROUT" ]
 then
   FUSEKI_LOGS_STDERROUT="$FUSEKI_LOGS/stderrout.log"
 fi
 
-# Data directory
-if [ -z "$FUSEKI_DATA_DIR" ]
-then
-  FUSEKI_DATA_DIR="$FUSEKI_HOME/DB"
-fi
-
 # Set up JAVA if not set
 if [ -z "$JAVA" ]
 then
@@ -275,10 +265,7 @@ FUSEKI_START=${FUSEKI_START:-$FUSEKI_HOME/fuseki-server.jar}
 # Deal with Cygwin path issues
 if [ "$cygwin" == "true" ]
 then
-  DATA_DIR=`cygpath -w "$FUSEKI_DATA_DIR"`
   FUSEKI_START=`cygpath -w "$FUSEKI_START"`
-else
-  DATA_DIR="$FUSEKI_DATA_DIR"
 fi
 
 # Some JVM settings
@@ -309,8 +296,8 @@ fi
 RUN_CMD=("$JAVA" "${RUN_ARGS[@]}")
 
 # Export the variables to be seen by the java server process.
-## export FUSEKI_HOME
-## export FUSEKI_BASE
+export FUSEKI_HOME
+export FUSEKI_BASE
 
 #####################################################
 # Comment these out after you're happy with what
@@ -343,11 +330,10 @@ start() {
   fi
 
   # Make sure the data and log directories exist
-  mkdir -p "$FUSEKI_DATA_DIR"
   mkdir -p "$FUSEKI_LOGS"
   if [ ! -z "$FUSEKI_USER" ]
   then
-    chown "$FUSEKI_USER" "$FUSEKI_DATA_DIR" "$FUSEKI_LOGS"
+    chown "$FUSEKI_USER" "$FUSEKI_LOGS"
   fi
 
   # Make sure the .jar file exists