diff options
author | OpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com> | 2020-03-26 22:43:38 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-03-26 22:43:38 +0100 |
commit | 1710eca4e930f7ed3a2b060029c627c1a66a2349 (patch) | |
tree | f6a1161387751d8a413c0ebe66ba253f4a91a1af /libpod/networking_linux.go | |
parent | 6a46a87d08bd1e9ddda3dd3c9c30d21d2226a654 (diff) | |
parent | 2fa78938a94e90e41755b68dd1af36f5b817ed55 (diff) | |
download | podman-1710eca4e930f7ed3a2b060029c627c1a66a2349.tar.gz podman-1710eca4e930f7ed3a2b060029c627c1a66a2349.tar.bz2 podman-1710eca4e930f7ed3a2b060029c627c1a66a2349.zip |
Merge pull request #5629 from baude/v2containerinspect
podmanv2 container inspect
Diffstat (limited to 'libpod/networking_linux.go')
-rw-r--r-- | libpod/networking_linux.go | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/libpod/networking_linux.go b/libpod/networking_linux.go index a7f501bfe..ab6ec4439 100644 --- a/libpod/networking_linux.go +++ b/libpod/networking_linux.go @@ -573,8 +573,8 @@ func getContainerNetIO(ctr *Container) (*netlink.LinkStatistics, error) { // Produce an InspectNetworkSettings containing information on the container // network. -func (c *Container) getContainerNetworkInfo() (*InspectNetworkSettings, error) { - settings := new(InspectNetworkSettings) +func (c *Container) getContainerNetworkInfo() (*define.InspectNetworkSettings, error) { + settings := new(define.InspectNetworkSettings) settings.Ports = []ocicni.PortMapping{} if c.config.PortMappings != nil { // TODO: This may not be safe. @@ -600,13 +600,13 @@ func (c *Container) getContainerNetworkInfo() (*InspectNetworkSettings, error) { return nil, errors.Wrapf(define.ErrInternal, "network inspection mismatch: asked to join %d CNI networks but have information on %d networks", len(c.config.Networks), len(c.state.NetworkStatus)) } - settings.Networks = make(map[string]*InspectAdditionalNetwork) + settings.Networks = make(map[string]*define.InspectAdditionalNetwork) // CNI results should be in the same order as the list of // networks we pass into CNI. for index, name := range c.config.Networks { cniResult := c.state.NetworkStatus[index] - addedNet := new(InspectAdditionalNetwork) + addedNet := new(define.InspectAdditionalNetwork) addedNet.NetworkID = name basicConfig, err := resultToBasicNetworkConfig(cniResult) @@ -640,8 +640,8 @@ func (c *Container) getContainerNetworkInfo() (*InspectNetworkSettings, error) { // resultToBasicNetworkConfig produces an InspectBasicNetworkConfig from a CNI // result -func resultToBasicNetworkConfig(result *cnitypes.Result) (InspectBasicNetworkConfig, error) { - config := InspectBasicNetworkConfig{} +func resultToBasicNetworkConfig(result *cnitypes.Result) (define.InspectBasicNetworkConfig, error) { + config := define.InspectBasicNetworkConfig{} for _, ctrIP := range result.IPs { size, _ := ctrIP.Address.Mask.Size() |