Skip to content

Instantly share code, notes, and snippets.

@mkuklis
Created March 2, 2014 00:39
Show Gist options
  • Save mkuklis/9300012 to your computer and use it in GitHub Desktop.
Save mkuklis/9300012 to your computer and use it in GitHub Desktop.
description "mongodb container"
author "ququplay"
start on filesystem and started docker
stop on runlevel [!2345]
respawn
script
# Wait for docker to finish starting up first.
FILE=/var/run/docker.sock
while [ ! -e $FILE ] ; do
inotifywait -t 2 -e create $(dirname $FILE)
done
/usr/bin/docker start -a mongodb
end script
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment