Merge pull request #148 from dbcode/development

allow custom ulimit -n for Docker
This commit is contained in:
Anders Ingemann 2014-09-18 23:01:03 +02:00
commit 4feac3fe83
2 changed files with 7 additions and 0 deletions

View file

@ -6,6 +6,9 @@
# Use DOCKER_OPTS to modify the daemon startup options.
#DOCKER_OPTS="--dns 8.8.8.8 --dns 8.8.4.4"
# Use DOCKER_NOFILE to set ulimit -n before starting Docker.
#DOCKER_NOFILE=65536
# If you need Docker to use an HTTP proxy, it can also be specified here.
#export http_proxy="http://127.0.0.1:3128/"

View file

@ -83,6 +83,10 @@ case "$1" in
touch "$DOCKER_LOGFILE"
chgrp docker "$DOCKER_LOGFILE"
if [ -n $DOCKER_NOFILE ]; then
ulimit -n $DOCKER_NOFILE
fi
log_begin_msg "Starting $DOCKER_DESC: $BASE"
start-stop-daemon --start --background \
--no-close \