Explorar el Código

Added format of Volumes and Binds parameters to create and start

* Added sample Volumes parameter to container create API.
* Added PortBindings and PublishAllPorts parameter to container start API
* Added note to container start about Binds needed to be declared as Volumes during container create.
Ben Sargent hace 11 años
padre
commit
b9ad0c9f74
Se han modificado 1 ficheros con 8 adiciones y 2 borrados
  1. 8 2
      docs/sources/api/docker_remote_api_v1.7.rst

+ 8 - 2
docs/sources/api/docker_remote_api_v1.7.rst

@@ -132,7 +132,9 @@ Create a container
 		],
 		"Dns":null,
 		"Image":"base",
-		"Volumes":{},
+		"Volumes":{
+			"/tmp": {}
+		},
 		"VolumesFrom":"",
 		"WorkingDir":""
 
@@ -361,8 +363,12 @@ Start a container
 
            {
                 "Binds":["/tmp:/tmp"],
-                "LxcConf":{"lxc.utsname":"docker"}
+                "LxcConf":{"lxc.utsname":"docker"},
+                "PortBindings":null
+                "PublishAllPorts":false
            }
+           
+        Binds need to reference Volumes that were defined during container creation.
 
         **Example response**: