summaryrefslogtreecommitdiff
path: root/etc
diff options
context:
space:
mode:
authorNoah Slater <nslater@apache.org>2008-09-11 19:29:37 +0000
committerNoah Slater <nslater@apache.org>2008-09-11 19:29:37 +0000
commit088bb03823efcd22cc24da8ed33e2799205f46c0 (patch)
tree4d2b7b8992ee21e073419a1d4918da21003c5d2a /etc
parent634b1b193acc24b95326c74e615d723043516f16 (diff)
remove PID and INI options from the etc/default file and added COUCHDB_OPTIONS variable
git-svn-id: https://svn.apache.org/repos/asf/incubator/couchdb/trunk@694432 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'etc')
-rw-r--r--etc/default/couchdb.tpl.in3
-rw-r--r--etc/init/couchdb.tpl.in17
2 files changed, 6 insertions, 14 deletions
diff --git a/etc/default/couchdb.tpl.in b/etc/default/couchdb.tpl.in
index 40498d56..c2a3f2ae 100644
--- a/etc/default/couchdb.tpl.in
+++ b/etc/default/couchdb.tpl.in
@@ -1,8 +1,7 @@
# Sourced by init script for configuration.
COUCHDB_USER=couchdb
-COUCHDB_INI_FILE=%localconfdir%/couch.ini
-COUCHDB_PID_FILE=%localstatedir%/run/couchdb.pid
COUCHDB_STDOUT_FILE=/dev/null
COUCHDB_STDERR_FILE=/dev/null
COUCHDB_RESPAWN_TIMEOUT=5
+COUCHDB_OPTIONS=
diff --git a/etc/init/couchdb.tpl.in b/etc/init/couchdb.tpl.in
index df91167f..b25c8685 100644
--- a/etc/init/couchdb.tpl.in
+++ b/etc/init/couchdb.tpl.in
@@ -63,12 +63,6 @@ start_couchdb () {
# Start Apache CouchDB as a background process.
command="$COUCHDB -b"
- if test -n "$COUCHDB_INI_FILE"; then
- command="$command -c $COUCHDB_INI_FILE"
- fi
- if test -n "$COUCHDB_PID_FILE"; then
- command="$command -p $COUCHDB_PID_FILE"
- fi
if test -n "$COUCHDB_STDOUT_FILE"; then
command="$command -o $COUCHDB_STDOUT_FILE"
fi
@@ -78,11 +72,10 @@ start_couchdb () {
if test -n "$COUCHDB_RESPAWN_TIMEOUT"; then
command="$command -r $COUCHDB_RESPAWN_TIMEOUT"
fi
+ if test -n "$COUCHDB_OPTIONS"; then
+ command="$command $COUCHDB_OPTIONS"
+ fi
if test -n "$COUCHDB_USER"; then
- if test -n "$COUCHDB_PID_FILE"; then
- touch $COUCHDB_PID_FILE
- chown $COUCHDB_USER $COUCHDB_PID_FILE
- fi
if su $COUCHDB_USER -c "$command" > /dev/null; then
return $SCRIPT_OK
else
@@ -101,8 +94,8 @@ stop_couchdb () {
# Stop the running Apache CouchDB process.
command="$COUCHDB -d"
- if test -n "$COUCHDB_PID_FILE"; then
- command="$command -p $COUCHDB_PID_FILE"
+ if test -n "$COUCHDB_OPTIONS"; then
+ command="$command $COUCHDB_OPTIONS"
fi
if test -n "$COUCHDB_USER"; then
if su $COUCHDB_USER -c "$command" > /dev/null; then