summaryrefslogtreecommitdiff
path: root/debian/mongod.upstart
diff options
context:
space:
mode:
authorErnie Hershey <ernie.hershey@10gen.com>2013-09-26 18:06:20 -0400
committerErnie Hershey <ernie.hershey@10gen.com>2013-10-04 13:25:27 -0400
commit09ffdcc9274e20b879710cdb5d1271a65e6c6470 (patch)
treea32fb276bca972847b541998e37a9a6ca2d4b9d6 /debian/mongod.upstart
parent060a5527947a4facdacfb15cbbfa18d75dbfdb19 (diff)
downloadmongo-09ffdcc9274e20b879710cdb5d1271a65e6c6470.tar.gz
SERVER-10871 Change 'mongodb' to 'mongo' to mean the mongod process and service
Diffstat (limited to 'debian/mongod.upstart')
-rw-r--r--debian/mongod.upstart19
1 files changed, 19 insertions, 0 deletions
diff --git a/debian/mongod.upstart b/debian/mongod.upstart
new file mode 100644
index 00000000000..48180ba8a4e
--- /dev/null
+++ b/debian/mongod.upstart
@@ -0,0 +1,19 @@
+# Ubuntu upstart file at /etc/init/mongod.conf
+
+limit nofile 20000 20000
+
+kill timeout 300 # wait 300s between SIGTERM and SIGKILL.
+
+pre-start script
+ mkdir -p /var/lib/mongodb/
+ mkdir -p /var/log/mongodb/
+end script
+
+start on runlevel [2345]
+stop on runlevel [06]
+
+script
+ ENABLE_MONGOD="yes"
+ if [ -f /etc/default/mongod ]; then . /etc/default/mongod; fi
+ if [ "x$ENABLE_MONGOD" = "xyes" ]; then exec start-stop-daemon --start --quiet --chuid mongodb --exec /usr/bin/mongod -- --config /etc/mongod.conf; fi
+end script