Prechádzať zdrojové kódy

if -c is not specified, do not set cpu.shares (instead of using the default value of 1024)

Jérôme Petazzoni 12 rokov pred
rodič
commit
e36752e033
2 zmenil súbory, kde vykonal 2 pridanie a 2 odobranie
  1. 1 1
      container.go
  2. 1 1
      docs/sources/commandline/command/run.rst

+ 1 - 1
container.go

@@ -92,7 +92,7 @@ func ParseRun(args []string, stdout io.Writer, capabilities *Capabilities) (*Con
 		*flMemory = 0
 	}
 
-	flCpuShares := cmd.Int64("c", 1024, "CPU shares (relative weight)")
+	flCpuShares := cmd.Int64("c", 0, "CPU shares (relative weight)")
 
 	var flPorts ListOpts
 	cmd.Var(&flPorts, "p", "Expose a container's port to the host (use 'docker port' to see the actual mapping)")

+ 1 - 1
docs/sources/commandline/command/run.rst

@@ -9,7 +9,7 @@
     Run a command in a new container
 
       -a=map[]: Attach to stdin, stdout or stderr.
-      -c=1024: CPU shares (relative weight)
+      -c=0: CPU shares (relative weight)
       -d=false: Detached mode: leave the container running in the background
       -e=[]: Set environment variables
       -h="": Container host name