mirror of
https://github.com/moby/moby.git
synced 2022-11-09 12:21:53 -05:00
Modify Network structure json tags
- So that they comply with docker inspect convention Which is allowing camel case for json field names Signed-off-by: Alessandro Boch <aboch@docker.com>
This commit is contained in:
parent
0aa3bff482
commit
b2d0b75018
1 changed files with 20 additions and 20 deletions
|
@ -335,44 +335,44 @@ type VolumeCreateRequest struct {
|
||||||
|
|
||||||
// NetworkResource is the body of the "get network" http response message
|
// NetworkResource is the body of the "get network" http response message
|
||||||
type NetworkResource struct {
|
type NetworkResource struct {
|
||||||
Name string `json:"name"`
|
Name string
|
||||||
ID string `json:"id"`
|
ID string `json:"Id"`
|
||||||
Scope string `json:"scope"`
|
Scope string
|
||||||
Driver string `json:"driver"`
|
Driver string
|
||||||
IPAM network.IPAM `json:"ipam"`
|
IPAM network.IPAM
|
||||||
Containers map[string]EndpointResource `json:"containers"`
|
Containers map[string]EndpointResource
|
||||||
Options map[string]string `json:"options"`
|
Options map[string]string
|
||||||
}
|
}
|
||||||
|
|
||||||
//EndpointResource contains network resources allocated and usd for a container in a network
|
//EndpointResource contains network resources allocated and usd for a container in a network
|
||||||
type EndpointResource struct {
|
type EndpointResource struct {
|
||||||
EndpointID string `json:"endpoint"`
|
EndpointID string
|
||||||
MacAddress string `json:"mac_address"`
|
MacAddress string
|
||||||
IPv4Address string `json:"ipv4_address"`
|
IPv4Address string
|
||||||
IPv6Address string `json:"ipv6_address"`
|
IPv6Address string
|
||||||
}
|
}
|
||||||
|
|
||||||
// NetworkCreate is the expected body of the "create network" http request message
|
// NetworkCreate is the expected body of the "create network" http request message
|
||||||
type NetworkCreate struct {
|
type NetworkCreate struct {
|
||||||
Name string `json:"name"`
|
Name string
|
||||||
CheckDuplicate bool `json:"check_duplicate"`
|
CheckDuplicate bool
|
||||||
Driver string `json:"driver"`
|
Driver string
|
||||||
IPAM network.IPAM `json:"ipam"`
|
IPAM network.IPAM
|
||||||
Options map[string]string `json:"options"`
|
Options map[string]string
|
||||||
}
|
}
|
||||||
|
|
||||||
// NetworkCreateResponse is the response message sent by the server for network create call
|
// NetworkCreateResponse is the response message sent by the server for network create call
|
||||||
type NetworkCreateResponse struct {
|
type NetworkCreateResponse struct {
|
||||||
ID string `json:"id"`
|
ID string `json:"Id"`
|
||||||
Warning string `json:"warning"`
|
Warning string
|
||||||
}
|
}
|
||||||
|
|
||||||
// NetworkConnect represents the data to be used to connect a container to the network
|
// NetworkConnect represents the data to be used to connect a container to the network
|
||||||
type NetworkConnect struct {
|
type NetworkConnect struct {
|
||||||
Container string `json:"container"`
|
Container string
|
||||||
}
|
}
|
||||||
|
|
||||||
// NetworkDisconnect represents the data to be used to disconnect a container from the network
|
// NetworkDisconnect represents the data to be used to disconnect a container from the network
|
||||||
type NetworkDisconnect struct {
|
type NetworkDisconnect struct {
|
||||||
Container string `json:"container"`
|
Container string
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue