summaryrefslogtreecommitdiff
path: root/debian
diff options
context:
space:
mode:
authorErnie Hershey <ernie.hershey@10gen.com>2014-06-05 10:50:54 -0400
committerErnie Hershey <ernie.hershey@10gen.com>2014-06-05 11:28:50 -0400
commite5da7115afeee64fa24b467ab5ed22767bb040b8 (patch)
tree50c539b9091d58013deabb1780d433abc07ce842 /debian
parent849a83f3649a7c3e7f31c0858804dbb354cad298 (diff)
downloadmongo-e5da7115afeee64fa24b467ab5ed22767bb040b8.tar.gz
SERVER-9985 Adjust pre-script mkdir commands in upstart config
Diffstat (limited to 'debian')
-rw-r--r--debian/mongod.upstart15
1 files changed, 6 insertions, 9 deletions
diff --git a/debian/mongod.upstart b/debian/mongod.upstart
index a2647362357..b5004510cf3 100644
--- a/debian/mongod.upstart
+++ b/debian/mongod.upstart
@@ -13,15 +13,12 @@ limit nproc 32000 32000
kill timeout 300 # wait 300s between SIGTERM and SIGKILL.
pre-start script
- if ! [ -d /var/lib/mongodb/ ]; then
- mkdir -p /var/lib/mongodb/
- chown -R mongodb:mongodb /var/lib/mongodb/
- fi
-
- if ! [ -d /var/log/mongodb/ ]; then
- mkdir -p /var/log/mongodb/
- chown -R mongodb:mongodb /var/log/mongodb/
- fi
+ if [ ! -d /var/lib/mongod ]; then
+ mkdir -p /var/lib/mongodb && chown mongodb:mongodb /var/lib/mongodb
+ fi
+ if [ ! -d /var/log/mongod ]; then
+ mkdir -p /var/log/mongodb && chown mongodb:mongodb /var/log/mongodb
+ fi
end script
start on runlevel [2345]