Browse code

Update init scripts to use `docker daemon`.

Signed-off-by: David Calavera <david.calavera@gmail.com>

David Calavera authored on 2015/07/23 03:24:38
Showing 6 changed files
... ...
@@ -20,7 +20,7 @@ start() {
20 20
 		--pidfile "$DOCKER_PIDFILE" \
21 21
 		--stdout "$DOCKER_LOGFILE" \
22 22
 		--stderr "$DOCKER_LOGFILE" \
23
-		-- -d -p "$DOCKER_PIDFILE" \
23
+		-- daemon -p "$DOCKER_PIDFILE" \
24 24
 		$DOCKER_OPTS
25 25
 	eend $?
26 26
 }
... ...
@@ -5,7 +5,7 @@ After=network.target docker.socket
5 5
 Requires=docker.socket
6 6
 
7 7
 [Service]
8
-ExecStart=/usr/bin/docker -d -H fd://
8
+ExecStart=/usr/bin/docker daemon -H fd://
9 9
 MountFlags=slave
10 10
 LimitNOFILE=1048576
11 11
 LimitNPROC=1048576
... ...
@@ -107,7 +107,7 @@ case "$1" in
107 107
 			--pidfile "$DOCKER_SSD_PIDFILE" \
108 108
 			--make-pidfile \
109 109
 			-- \
110
-				-d -p "$DOCKER_PIDFILE" \
110
+				daemon -p "$DOCKER_PIDFILE" \
111 111
 				$DOCKER_OPTS \
112 112
 					>> "$DOCKER_LOGFILE" 2>&1
113 113
 		log_end_msg $?
... ...
@@ -49,7 +49,7 @@ start() {
49 49
         prestart
50 50
         printf "Starting $prog:\t"
51 51
         echo "\n$(date)\n" >> $logfile
52
-        "$unshare" -m -- $exec -d $other_args &>> $logfile &
52
+        "$unshare" -m -- $exec daemon $other_args &>> $logfile &
53 53
         pid=$!
54 54
         touch $lockfile
55 55
         # wait up to 10 seconds for the pidfile to exist.  see
... ...
@@ -2,6 +2,6 @@
2 2
 #
3 3
 # Other arguments to pass to the docker daemon process
4 4
 # These will be parsed by the sysv initscript and appended
5
-# to the arguments list passed to docker -d
5
+# to the arguments list passed to docker daemon
6 6
 
7 7
 other_args=""
... ...
@@ -39,7 +39,7 @@ script
39 39
 	if [ -f /etc/default/$UPSTART_JOB ]; then
40 40
 		. /etc/default/$UPSTART_JOB
41 41
 	fi
42
-	exec "$DOCKER" -d $DOCKER_OPTS
42
+	exec "$DOCKER" daemon $DOCKER_OPTS
43 43
 end script
44 44
 
45 45
 # Don't emit "started" event until docker.sock is ready.