moby/docs/reference/api
Ahmet Alp Balkan 755f8609f6 Add containers’ networks to /containers/json
After addition of multi-host networking in Docker 1.9, Docker Remote
API is still returning only the network specified during creation
of the container in the “List Containers” (`/containers/json`) endpoint:

    ...
    "HostConfig": {
      "NetworkMode": "default"
    },

The list of networks containers are attached to is only available at
Get Container (`/containers/<id>/json`) endpoint.
This does not allow applications utilizing multi-host networking to
be built on top of Docker Remote API.

Therefore I added a simple `"NetworkSettings"` section to the
`/containers/json` endpoint. This is not identical to the NetworkSettings
returned in Get Container (`/containers/<id>/json`) endpoint. It only
contains a single field `"Networks"`, which is essentially the same
value shown in inspect output of a container.

This change adds the following section to the `/containers/json`:

    "NetworkSettings": {
      "Networks": {
        "bridge": {
          "EndpointID": "2cdc4edb1ded3631c81f57966563e...",
          "Gateway": "172.17.0.1",
          "IPAddress": "172.17.0.2",
          "IPPrefixLen": 16,
          "IPv6Gateway": "",
          "GlobalIPv6Address": "",
          "GlobalIPv6PrefixLen": 0,
          "MacAddress": "02:42:ac:11:00:02"
        }
      }
    }

This is of type `SummaryNetworkSettings` type, a minimal version of
`api/types#NetworkSettings`.

Actually all I need is the network name and the IPAddress fields. If folks
find this addition too big, I can create a `SummaryEndpointSettings` field
as well, containing just the IPAddress field.

Signed-off-by: Ahmet Alp Balkan <ahmetalpbalkan@gmail.com>
2015-12-14 19:03:23 -08:00
..
_static retooling for hugo 2015-06-15 13:19:38 -07:00
images retooling for hugo 2015-06-15 13:19:38 -07:00
docker-io_api.md docs: fix broken link to 1.7 Hub API 2015-12-01 17:57:12 +01:00
docker_io_accounts_api.md retooling for hugo 2015-06-15 13:19:38 -07:00
docker_remote_api.md Add containers’ networks to /containers/json 2015-12-14 19:03:23 -08:00
docker_remote_api_v1.14.md update 'top' api endpoint documentation 2015-11-23 15:41:34 -08:00
docker_remote_api_v1.15.md update 'top' api endpoint documentation 2015-11-23 15:41:34 -08:00
docker_remote_api_v1.16.md update 'top' api endpoint documentation 2015-11-23 15:41:34 -08:00
docker_remote_api_v1.17.md update 'top' api endpoint documentation 2015-11-23 15:41:34 -08:00
docker_remote_api_v1.18.md update 'top' api endpoint documentation 2015-11-23 15:41:34 -08:00
docker_remote_api_v1.19.md update 'top' api endpoint documentation 2015-11-23 15:41:34 -08:00
docker_remote_api_v1.20.md update 'top' api endpoint documentation 2015-11-23 15:41:34 -08:00
docker_remote_api_v1.21.md docs: move API changes to the correct API version 2015-11-25 14:10:18 +01:00
docker_remote_api_v1.22.md Add containers’ networks to /containers/json 2015-12-14 19:03:23 -08:00
hub_registry_spec.md Enabled GitHub Flavored Markdown 2015-10-11 07:49:54 -07:00
README.md Fixes found by docs validation tool 2015-11-23 11:19:38 +10:00
registry_api.md Fixing seds, deleting old stuff 2015-06-17 21:05:37 -07:00
registry_api_client_libraries.md remove unused row-even and row-odd css classes 2015-07-19 21:27:12 +02:00
remote_api_client_libraries.md added albatros library 2015-12-06 20:40:42 +01:00

This directory holds the authoritative specifications of APIs defined and implemented by Docker. Currently this includes:

  • The remote API by which a docker node can be queried over HTTP
  • The registry API by which a docker node can download and upload images for storage and sharing
  • The index search API by which a docker node can search the public index for images to download
  • The docker.io OAuth and accounts API which 3rd party services can use to access account information