You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@couchdb.apache.org by ja...@apache.org on 2012/05/06 14:13:22 UTC
[2/2] git commit: init.d: Only chown when COUCHDB_USER is not empty.
init.d: Only chown when COUCHDB_USER is not empty.
Project: http://git-wip-us.apache.org/repos/asf/couchdb/repo
Commit: http://git-wip-us.apache.org/repos/asf/couchdb/commit/7d540c6e
Tree: http://git-wip-us.apache.org/repos/asf/couchdb/tree/7d540c6e
Diff: http://git-wip-us.apache.org/repos/asf/couchdb/diff/7d540c6e
Branch: refs/heads/master
Commit: 7d540c6e61a6aa3c44580041a25edf4ea4574b40
Parents: a1d46ac
Author: Jan Lehnardt <ja...@apache.org>
Authored: Sun May 6 14:09:13 2012 +0200
Committer: Jan Lehnardt <ja...@apache.org>
Committed: Sun May 6 14:09:36 2012 +0200
----------------------------------------------------------------------
etc/init/couchdb.tpl.in | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/couchdb/blob/7d540c6e/etc/init/couchdb.tpl.in
----------------------------------------------------------------------
diff --git a/etc/init/couchdb.tpl.in b/etc/init/couchdb.tpl.in
index 173efa3..39b6250 100644
--- a/etc/init/couchdb.tpl.in
+++ b/etc/init/couchdb.tpl.in
@@ -84,7 +84,9 @@ start_couchdb () {
# Start Apache CouchDB as a background process.
mkdir -p "$RUN_DIR"
- chown $COUCHDB_USER "$RUN_DIR"
+ if test -n "$COUCHDB_USER"; then
+ chown $COUCHDB_USER "$RUN_DIR"
+ fi
command="$COUCHDB -b"
if test -n "$COUCHDB_STDOUT_FILE"; then
command="$command -o $COUCHDB_STDOUT_FILE"