Browse Source

Merge pull request #11945 from lmars/fix-upstart-post-start

Prevent Upstart post-start stanza from hanging
Jessie Frazelle 10 years ago
parent
commit
485071f92e
1 changed files with 1 additions and 1 deletions
  1. 1 1
      contrib/init/upstart/docker.conf

+ 1 - 1
contrib/init/upstart/docker.conf

@@ -49,7 +49,7 @@ post-start script
 	fi
 	fi
 	if ! printf "%s" "$DOCKER_OPTS" | grep -qE -e '-H|--host'; then
 	if ! printf "%s" "$DOCKER_OPTS" | grep -qE -e '-H|--host'; then
 		while ! [ -e /var/run/docker.sock ]; do
 		while ! [ -e /var/run/docker.sock ]; do
-			initctl status $UPSTART_JOB | grep -q "stop/" && exit 1
+			initctl status $UPSTART_JOB | grep -qE "(stop|respawn)/" && exit 1
 			echo "Waiting for /var/run/docker.sock"
 			echo "Waiting for /var/run/docker.sock"
 			sleep 0.1
 			sleep 0.1
 		done
 		done