|
@@ -220,7 +220,7 @@ Json Parameters:
|
|
(ie. the relative weight vs other containers).
|
|
(ie. the relative weight vs other containers).
|
|
- **CpuPeriod** - The length of a CPU period in microseconds.
|
|
- **CpuPeriod** - The length of a CPU period in microseconds.
|
|
- **CpuQuota** - Microseconds of CPU time that the container can get in a CPU period.
|
|
- **CpuQuota** - Microseconds of CPU time that the container can get in a CPU period.
|
|
-- **Cpuset** - Deprecated please don't use. Use `CpusetCpus` instead.
|
|
|
|
|
|
+- **Cpuset** - Deprecated please don't use. Use `CpusetCpus` instead.
|
|
- **CpusetCpus** - String value containing the `cgroups CpusetCpus` to use.
|
|
- **CpusetCpus** - String value containing the `cgroups CpusetCpus` to use.
|
|
- **CpusetMems** - Memory nodes (MEMs) in which to allow execution (0-3, 0,1). Only effective on NUMA systems.
|
|
- **CpusetMems** - Memory nodes (MEMs) in which to allow execution (0-3, 0,1). Only effective on NUMA systems.
|
|
- **BlkioWeight** - Block IO weight (relative weight) accepts a weight value between 10 and 1000.
|
|
- **BlkioWeight** - Block IO weight (relative weight) accepts a weight value between 10 and 1000.
|
|
@@ -310,7 +310,7 @@ Status Codes:
|
|
|
|
|
|
### Inspect a container
|
|
### Inspect a container
|
|
|
|
|
|
-`GET /containers/(id)/json`
|
|
|
|
|
|
+`GET /containers/(id or name)/json`
|
|
|
|
|
|
Return low-level information on the container `id`
|
|
Return low-level information on the container `id`
|
|
|
|
|
|
@@ -447,7 +447,7 @@ Status Codes:
|
|
|
|
|
|
### List processes running inside a container
|
|
### List processes running inside a container
|
|
|
|
|
|
-`GET /containers/(id)/top`
|
|
|
|
|
|
+`GET /containers/(id or name)/top`
|
|
|
|
|
|
List processes running inside the container `id`. On Unix systems this
|
|
List processes running inside the container `id`. On Unix systems this
|
|
is done by running the `ps` command. This endpoint is not
|
|
is done by running the `ps` command. This endpoint is not
|
|
@@ -511,7 +511,7 @@ Status Codes:
|
|
|
|
|
|
### Get container logs
|
|
### Get container logs
|
|
|
|
|
|
-`GET /containers/(id)/logs`
|
|
|
|
|
|
+`GET /containers/(id or name)/logs`
|
|
|
|
|
|
Get `stdout` and `stderr` logs from the container ``id``
|
|
Get `stdout` and `stderr` logs from the container ``id``
|
|
|
|
|
|
@@ -551,7 +551,7 @@ Status Codes:
|
|
|
|
|
|
### Inspect changes on a container's filesystem
|
|
### Inspect changes on a container's filesystem
|
|
|
|
|
|
-`GET /containers/(id)/changes`
|
|
|
|
|
|
+`GET /containers/(id or name)/changes`
|
|
|
|
|
|
Inspect changes on container `id`'s filesystem
|
|
Inspect changes on container `id`'s filesystem
|
|
|
|
|
|
@@ -593,7 +593,7 @@ Status Codes:
|
|
|
|
|
|
### Export a container
|
|
### Export a container
|
|
|
|
|
|
-`GET /containers/(id)/export`
|
|
|
|
|
|
+`GET /containers/(id or name)/export`
|
|
|
|
|
|
Export the contents of container `id`
|
|
Export the contents of container `id`
|
|
|
|
|
|
@@ -616,7 +616,7 @@ Status Codes:
|
|
|
|
|
|
### Get container stats based on resource usage
|
|
### Get container stats based on resource usage
|
|
|
|
|
|
-`GET /containers/(id)/stats`
|
|
|
|
|
|
+`GET /containers/(id or name)/stats`
|
|
|
|
|
|
This endpoint returns a live stream of a container's resource usage statistics.
|
|
This endpoint returns a live stream of a container's resource usage statistics.
|
|
|
|
|
|
@@ -708,7 +708,7 @@ Status Codes:
|
|
|
|
|
|
### Resize a container TTY
|
|
### Resize a container TTY
|
|
|
|
|
|
-`POST /containers/(id)/resize?h=<height>&w=<width>`
|
|
|
|
|
|
+`POST /containers/(id or name)/resize?h=<height>&w=<width>`
|
|
|
|
|
|
Resize the TTY for container with `id`. You must restart the container for the resize to take effect.
|
|
Resize the TTY for container with `id`. You must restart the container for the resize to take effect.
|
|
|
|
|
|
@@ -730,7 +730,7 @@ Status Codes:
|
|
|
|
|
|
### Start a container
|
|
### Start a container
|
|
|
|
|
|
-`POST /containers/(id)/start`
|
|
|
|
|
|
+`POST /containers/(id or name)/start`
|
|
|
|
|
|
Start the container `id`
|
|
Start the container `id`
|
|
|
|
|
|
@@ -740,7 +740,7 @@ Start the container `id`
|
|
|
|
|
|
**Example request**:
|
|
**Example request**:
|
|
|
|
|
|
- POST /containers/(id)/start HTTP/1.1
|
|
|
|
|
|
+ POST /containers/(id or name)/start HTTP/1.1
|
|
|
|
|
|
**Example response**:
|
|
**Example response**:
|
|
|
|
|
|
@@ -755,7 +755,7 @@ Status Codes:
|
|
|
|
|
|
### Stop a container
|
|
### Stop a container
|
|
|
|
|
|
-`POST /containers/(id)/stop`
|
|
|
|
|
|
+`POST /containers/(id or name)/stop`
|
|
|
|
|
|
Stop the container `id`
|
|
Stop the container `id`
|
|
|
|
|
|
@@ -780,7 +780,7 @@ Status Codes:
|
|
|
|
|
|
### Restart a container
|
|
### Restart a container
|
|
|
|
|
|
-`POST /containers/(id)/restart`
|
|
|
|
|
|
+`POST /containers/(id or name)/restart`
|
|
|
|
|
|
Restart the container `id`
|
|
Restart the container `id`
|
|
|
|
|
|
@@ -804,7 +804,7 @@ Status Codes:
|
|
|
|
|
|
### Kill a container
|
|
### Kill a container
|
|
|
|
|
|
-`POST /containers/(id)/kill`
|
|
|
|
|
|
+`POST /containers/(id or name)/kill`
|
|
|
|
|
|
Kill the container `id`
|
|
Kill the container `id`
|
|
|
|
|
|
@@ -829,7 +829,7 @@ Status Codes:
|
|
|
|
|
|
### Rename a container
|
|
### Rename a container
|
|
|
|
|
|
-`POST /containers/(id)/rename`
|
|
|
|
|
|
+`POST /containers/(id or name)/rename`
|
|
|
|
|
|
Rename the container `id` to a `new_name`
|
|
Rename the container `id` to a `new_name`
|
|
|
|
|
|
@@ -854,7 +854,7 @@ Status Codes:
|
|
|
|
|
|
### Pause a container
|
|
### Pause a container
|
|
|
|
|
|
-`POST /containers/(id)/pause`
|
|
|
|
|
|
+`POST /containers/(id or name)/pause`
|
|
|
|
|
|
Pause the container `id`
|
|
Pause the container `id`
|
|
|
|
|
|
@@ -874,7 +874,7 @@ Status Codes:
|
|
|
|
|
|
### Unpause a container
|
|
### Unpause a container
|
|
|
|
|
|
-`POST /containers/(id)/unpause`
|
|
|
|
|
|
+`POST /containers/(id or name)/unpause`
|
|
|
|
|
|
Unpause the container `id`
|
|
Unpause the container `id`
|
|
|
|
|
|
@@ -894,7 +894,7 @@ Status Codes:
|
|
|
|
|
|
### Attach to a container
|
|
### Attach to a container
|
|
|
|
|
|
-`POST /containers/(id)/attach`
|
|
|
|
|
|
+`POST /containers/(id or name)/attach`
|
|
|
|
|
|
Attach to the container `id`
|
|
Attach to the container `id`
|
|
|
|
|
|
@@ -977,7 +977,7 @@ Status Codes:
|
|
|
|
|
|
### Attach to a container (websocket)
|
|
### Attach to a container (websocket)
|
|
|
|
|
|
-`GET /containers/(id)/attach/ws`
|
|
|
|
|
|
+`GET /containers/(id or name)/attach/ws`
|
|
|
|
|
|
Attach to the container `id` via websocket
|
|
Attach to the container `id` via websocket
|
|
|
|
|
|
@@ -1012,7 +1012,7 @@ Status Codes:
|
|
|
|
|
|
### Wait a container
|
|
### Wait a container
|
|
|
|
|
|
-`POST /containers/(id)/wait`
|
|
|
|
|
|
+`POST /containers/(id or name)/wait`
|
|
|
|
|
|
Block until container `id` stops, then returns the exit code
|
|
Block until container `id` stops, then returns the exit code
|
|
|
|
|
|
@@ -1035,7 +1035,7 @@ Status Codes:
|
|
|
|
|
|
### Remove a container
|
|
### Remove a container
|
|
|
|
|
|
-`DELETE /containers/(id)`
|
|
|
|
|
|
+`DELETE /containers/(id or name)`
|
|
|
|
|
|
Remove the container `id` from the filesystem
|
|
Remove the container `id` from the filesystem
|
|
|
|
|
|
@@ -1063,7 +1063,7 @@ Status Codes:
|
|
|
|
|
|
### Copy files or folders from a container
|
|
### Copy files or folders from a container
|
|
|
|
|
|
-`POST /containers/(id)/copy`
|
|
|
|
|
|
+`POST /containers/(id or name)/copy`
|
|
|
|
|
|
Copy files or folders of container `id`
|
|
Copy files or folders of container `id`
|
|
|
|
|
|
@@ -1365,37 +1365,37 @@ Return the history of the image `name`
|
|
HTTP/1.1 200 OK
|
|
HTTP/1.1 200 OK
|
|
Content-Type: application/json
|
|
Content-Type: application/json
|
|
|
|
|
|
- [
|
|
|
|
- {
|
|
|
|
|
|
+ [
|
|
|
|
+ {
|
|
"Id": "3db9c44f45209632d6050b35958829c3a2aa256d81b9a7be45b362ff85c54710",
|
|
"Id": "3db9c44f45209632d6050b35958829c3a2aa256d81b9a7be45b362ff85c54710",
|
|
"Created": 1398108230,
|
|
"Created": 1398108230,
|
|
"CreatedBy": "/bin/sh -c #(nop) ADD file:eb15dbd63394e063b805a3c32ca7bf0266ef64676d5a6fab4801f2e81e2a5148 in /",
|
|
"CreatedBy": "/bin/sh -c #(nop) ADD file:eb15dbd63394e063b805a3c32ca7bf0266ef64676d5a6fab4801f2e81e2a5148 in /",
|
|
"Tags": [
|
|
"Tags": [
|
|
"ubuntu:lucid",
|
|
"ubuntu:lucid",
|
|
"ubuntu:10.04"
|
|
"ubuntu:10.04"
|
|
- ],
|
|
|
|
|
|
+ ],
|
|
"Size": 182964289,
|
|
"Size": 182964289,
|
|
"Comment": ""
|
|
"Comment": ""
|
|
- },
|
|
|
|
- {
|
|
|
|
|
|
+ },
|
|
|
|
+ {
|
|
"Id": "6cfa4d1f33fb861d4d114f43b25abd0ac737509268065cdfd69d544a59c85ab8",
|
|
"Id": "6cfa4d1f33fb861d4d114f43b25abd0ac737509268065cdfd69d544a59c85ab8",
|
|
"Created": 1398108222,
|
|
"Created": 1398108222,
|
|
"CreatedBy": "/bin/sh -c #(nop) MAINTAINER Tianon Gravi <admwiggin@gmail.com> - mkimage-debootstrap.sh -i iproute,iputils-ping,ubuntu-minimal -t lucid.tar.xz lucid http://archive.ubuntu.com/ubuntu/",
|
|
"CreatedBy": "/bin/sh -c #(nop) MAINTAINER Tianon Gravi <admwiggin@gmail.com> - mkimage-debootstrap.sh -i iproute,iputils-ping,ubuntu-minimal -t lucid.tar.xz lucid http://archive.ubuntu.com/ubuntu/",
|
|
"Tags": null,
|
|
"Tags": null,
|
|
"Size": 0,
|
|
"Size": 0,
|
|
"Comment": ""
|
|
"Comment": ""
|
|
- },
|
|
|
|
- {
|
|
|
|
|
|
+ },
|
|
|
|
+ {
|
|
"Id": "511136ea3c5a64f264b78b5433614aec563103b4d4702f3ba7d4d2698e22c158",
|
|
"Id": "511136ea3c5a64f264b78b5433614aec563103b4d4702f3ba7d4d2698e22c158",
|
|
"Created": 1371157430,
|
|
"Created": 1371157430,
|
|
"CreatedBy": "",
|
|
"CreatedBy": "",
|
|
"Tags": [
|
|
"Tags": [
|
|
"scratch12:latest",
|
|
"scratch12:latest",
|
|
"scratch:latest"
|
|
"scratch:latest"
|
|
- ],
|
|
|
|
|
|
+ ],
|
|
"Size": 0,
|
|
"Size": 0,
|
|
"Comment": "Imported from -"
|
|
"Comment": "Imported from -"
|
|
- }
|
|
|
|
|
|
+ }
|
|
]
|
|
]
|
|
|
|
|
|
Status Codes:
|
|
Status Codes:
|
|
@@ -1932,7 +1932,7 @@ the root that contains a list of repository and tag names mapped to layer IDs.
|
|
|
|
|
|
### Exec Create
|
|
### Exec Create
|
|
|
|
|
|
-`POST /containers/(id)/exec`
|
|
|
|
|
|
+`POST /containers/(id or name)/exec`
|
|
|
|
|
|
Sets up an exec instance in a running container `id`
|
|
Sets up an exec instance in a running container `id`
|
|
|
|
|
|
@@ -2182,7 +2182,7 @@ from **200 OK** to **101 UPGRADED** and resends the same headers.
|
|
|
|
|
|
## 3.3 CORS Requests
|
|
## 3.3 CORS Requests
|
|
|
|
|
|
-To set cross origin requests to the remote api please give values to
|
|
|
|
|
|
+To set cross origin requests to the remote api please give values to
|
|
`--api-cors-header` when running Docker in daemon mode. Set * (asterisk) allows all,
|
|
`--api-cors-header` when running Docker in daemon mode. Set * (asterisk) allows all,
|
|
default or blank means CORS disabled
|
|
default or blank means CORS disabled
|
|
|
|
|