Skip to content

Commit b90ccb6

Browse files
author
Richard Kreuter
committed
Backport of Debianoid packaging commit 09f3ed3, fixes SERVER-709.
1 parent c0a6852 commit b90ccb6

File tree

2 files changed

+9
-2
lines changed

2 files changed

+9
-2
lines changed

debian/init.d

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -68,6 +68,10 @@ if test ! -x $DAEMON; then
6868
exit 0
6969
fi
7070

71+
if test "x$ENABLE_MONGODB" != "xyes"; then
72+
exit 0
73+
fi
74+
7175
if test ! -x $DATA; then
7276
mkdir $DATA || exit 0
7377
fi

debian/mongodb.upstart

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,5 +8,8 @@ end script
88
start on runlevel [2345]
99
stop on runlevel [06]
1010

11-
exec start-stop-daemon --start --quiet --chuid mongodb --exec /usr/bin/mongod -- --config /etc/mongodb.conf
12-
11+
script
12+
ENABLE_MONGODB="yes"
13+
if [ -f /etc/default/mongodb ]; then . /etc/default/mongodb; fi
14+
if [ "x$ENABLE_MONGODB" = "xyes" ]; then start-stop-daemon --start --quiet --chuid mongodb --exec /usr/bin/mongod -- --config /etc/mongodb.conf; fi
15+
end script

0 commit comments

Comments
 (0)