Skip to content
This repository was archived by the owner on Oct 13, 2023. It is now read-only.

Commit d43b66d

Browse files
committed
swagger: move NetworkingConfig to definitions
Signed-off-by: Sebastiaan van Stijn <github@gone.nl> (cherry picked from commit 89876e816585d814b31a2c5c9814eeda92b081bc) Signed-off-by: Sebastiaan van Stijn <github@gone.nl> Upstream-commit: d7423180e7896f48f833d625621ffae7bf2982ea Component: engine
1 parent c210a26 commit d43b66d

1 file changed

Lines changed: 37 additions & 10 deletions

File tree

components/engine/api/swagger.yaml

Lines changed: 37 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1202,6 +1202,42 @@ definitions:
12021202
items:
12031203
type: "string"
12041204

1205+
NetworkingConfig:
1206+
description: |
1207+
NetworkingConfig represents the container's networking configuration for
1208+
each of its interfaces.
1209+
It is used for the networking configs specified in the `docker create`
1210+
and `docker network connect` commands.
1211+
type: "object"
1212+
properties:
1213+
EndpointsConfig:
1214+
description: |
1215+
A mapping of network name to endpoint configuration for that network.
1216+
type: "object"
1217+
additionalProperties:
1218+
$ref: "#/definitions/EndpointSettings"
1219+
example:
1220+
# putting an example here, instead of using the example values from
1221+
# /definitions/EndpointSettings, because containers/create currently
1222+
# does not support attaching to multiple networks, so the example request
1223+
# would be confusing if it showed that multiple networks can be contained
1224+
# in the EndpointsConfig.
1225+
# TODO remove once we support multiple networks on container create (see https://github.com/moby/moby/blob/07e6b843594e061f82baa5fa23c2ff7d536c2a05/daemon/create.go#L323)
1226+
EndpointsConfig:
1227+
isolated_nw:
1228+
IPAMConfig:
1229+
IPv4Address: "172.20.30.33"
1230+
IPv6Address: "2001:db8:abcd::3033"
1231+
LinkLocalIPs:
1232+
- "169.254.34.68"
1233+
- "fe80::3468"
1234+
Links:
1235+
- "container_1"
1236+
- "container_2"
1237+
Aliases:
1238+
- "server_x"
1239+
- "server_y"
1240+
12051241
NetworkSettings:
12061242
description: "NetworkSettings exposes the network settings in the API"
12071243
type: "object"
@@ -5123,16 +5159,7 @@ paths:
51235159
HostConfig:
51245160
$ref: "#/definitions/HostConfig"
51255161
NetworkingConfig:
5126-
description: "This container's networking configuration."
5127-
type: "object"
5128-
properties:
5129-
EndpointsConfig:
5130-
description: |
5131-
A mapping of network name to endpoint configuration
5132-
for that network.
5133-
type: "object"
5134-
additionalProperties:
5135-
$ref: "#/definitions/EndpointSettings"
5162+
$ref: "#/definitions/NetworkingConfig"
51365163
example:
51375164
Hostname: ""
51385165
Domainname: ""

0 commit comments

Comments
 (0)