From 67d4f89b0cddb3de05c20e08c20f1bea714c2a9e Mon Sep 17 00:00:00 2001
From: James Moger <james.moger@gitblit.com>
Date: Mon, 18 Jun 2012 16:09:44 -0400
Subject: [PATCH] Added setting to control Groovy Grape folder (issue 91)

---
 distrib/gitblit-centos |    8 ++++++--
 1 files changed, 6 insertions(+), 2 deletions(-)

diff --git a/distrib/gitblit-centos b/distrib/gitblit-centos
index db2fdef..c608097 100644
--- a/distrib/gitblit-centos
+++ b/distrib/gitblit-centos
@@ -1,5 +1,6 @@
 #!/bin/bash
 # chkconfig: 3 21 91
+# description: Starts and Stops gitblit
 # Source function library.
 . /etc/init.d/functions
 
@@ -7,7 +8,8 @@
 GITBLIT_PATH=/opt/gitblit
 GITBLIT_HTTP_PORT=0
 GITBLIT_HTTPS_PORT=8443
-JAVA="java -server -Xmx1024M -jar"
+source ${GITBLIT_PATH}/java-proxy-config.sh
+JAVA="java -server -Xmx1024M ${JAVA_PROXY_CONFIG} -Djava.awt.headless=true -jar"
 
 RETVAL=0
 
@@ -16,6 +18,7 @@
     if [ -f $GITBLIT_PATH/gitblit.jar ];
       then
       echo $"Starting gitblit server"
+      cd $GITBLIT_PATH
       $JAVA $GITBLIT_PATH/gitblit.jar --httpsPort $GITBLIT_HTTPS_PORT --httpPort $GITBLIT_HTTP_PORT > /dev/null &
       echo "."
       exit $RETVAL
@@ -25,7 +28,8 @@
   stop)
     if [ -f $GITBLIT_PATH/gitblit.jar ];
       then
-      echo $"Starting gitblit server"
+      echo $"Stopping gitblit server"
+      cd $GITBLIT_PATH
       $JAVA $GITBLIT_PATH/gitblit.jar --stop > /dev/null &
       echo "."
       exit $RETVAL

--
Gitblit v1.9.1