|
@@ -1359,6 +1359,8 @@ If `name` is a specific name and tag (e.g. ubuntu:latest), then only that image
|
|
image (and its parents) are returned, but with the exclusion of the
|
|
image (and its parents) are returned, but with the exclusion of the
|
|
'repositories' file in the tarball, as there were no image names referenced.
|
|
'repositories' file in the tarball, as there were no image names referenced.
|
|
|
|
|
|
|
|
+See the [image tarball format](#image-tarball-format) for more details.
|
|
|
|
+
|
|
**Example request**
|
|
**Example request**
|
|
|
|
|
|
GET /images/ubuntu/get
|
|
GET /images/ubuntu/get
|
|
@@ -1386,6 +1388,7 @@ ubuntu:latest), then only that image (and its parents) are returned; if it is
|
|
an image ID, similarly only that image (and its parents) are returned and there
|
|
an image ID, similarly only that image (and its parents) are returned and there
|
|
would be no names referenced in the 'repositories' file for this image ID.
|
|
would be no names referenced in the 'repositories' file for this image ID.
|
|
|
|
|
|
|
|
+See the [image tarball format](#image-tarball-format) for more details.
|
|
|
|
|
|
**Example request**
|
|
**Example request**
|
|
|
|
|
|
@@ -1408,6 +1411,7 @@ Status Codes:
|
|
`POST /images/load`
|
|
`POST /images/load`
|
|
|
|
|
|
Load a set of images and tags into the docker repository.
|
|
Load a set of images and tags into the docker repository.
|
|
|
|
+See the [image tarball format](#image-tarball-format) for more details.
|
|
|
|
|
|
**Example request**
|
|
**Example request**
|
|
|
|
|
|
@@ -1424,6 +1428,27 @@ Status Codes:
|
|
- **200** – no error
|
|
- **200** – no error
|
|
- **500** – server error
|
|
- **500** – server error
|
|
|
|
|
|
|
|
+### Image tarball format
|
|
|
|
+
|
|
|
|
+An image tarball contains one directory per image layer (named using its long ID),
|
|
|
|
+each containing three files:
|
|
|
|
+
|
|
|
|
+1. `VERSION`: currently `1.0` - the file format version
|
|
|
|
+2. `json`: detailed layer information, similar to `docker inspect layer_id`
|
|
|
|
+3. `layer.tar`: A tarfile containing the filesystem changes in this layer
|
|
|
|
+
|
|
|
|
+The `layer.tar` file will contain `aufs` style `.wh..wh.aufs` files and directories
|
|
|
|
+for storing attribute changes and deletions.
|
|
|
|
+
|
|
|
|
+If the tarball defines a repository, there will also be a `repositories` file at
|
|
|
|
+the root that contains a list of repository and tag names mapped to layer IDs.
|
|
|
|
+
|
|
|
|
+```
|
|
|
|
+{"hello-world":
|
|
|
|
+ {"latest":"565a9d68a73f6706862bfe8409a7f659776d4d60a8d096eb4a3cbce6999cc2a1"}
|
|
|
|
+}
|
|
|
|
+```
|
|
|
|
+
|
|
# 3. Going further
|
|
# 3. Going further
|
|
|
|
|
|
## 3.1 Inside `docker run`
|
|
## 3.1 Inside `docker run`
|