Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Network inspect Id vs ID #22231

Closed
hamid-elaosta opened this issue Apr 21, 2016 · 7 comments · Fixed by #23226
Closed

Network inspect Id vs ID #22231

hamid-elaosta opened this issue Apr 21, 2016 · 7 comments · Fixed by #23226

Comments

@hamid-elaosta
Copy link

Output of docker version:

$ docker version
Client:
 Version:      1.11.0
 API version:  1.23
 Go version:   go1.5.4
 Git commit:   4dc5990
 Built:        Wed Apr 13 18:34:23 2016
 OS/Arch:      linux/amd64

Server:
 Version:      1.11.0
 API version:  1.23
 Go version:   go1.5.4
 Git commit:   4dc5990
 Built:        Wed Apr 13 18:34:23 2016
 OS/Arch:      linux/amd64

Output of docker info:

$ docker info
Containers: 0
 Running: 0
 Paused: 0
 Stopped: 0
Images: 1
Server Version: 1.11.0
Storage Driver: aufs
 Root Dir: /var/lib/docker/aufs
 Backing Filesystem: extfs
 Dirs: 1
 Dirperm1 Supported: true
Logging Driver: json-file
Cgroup Driver: cgroupfs
Plugins: 
 Volume: local
 Network: host bridge null
Kernel Version: 3.19.0-58-generic
Operating System: Ubuntu 14.04.4 LTS
OSType: linux
Architecture: x86_64
CPUs: 4
Total Memory: 15.56 GiB
Name: <removed>
ID: <removeD>
Docker Root Dir: /var/lib/docker
Debug mode (client): false
Debug mode (server): false
Registry: https://index.docker.io/v1/
WARNING: No swap limit support

Additional environment details (AWS, VirtualBox, physical, etc.):

Steps to reproduce the issue:

  1. create docker network
  2. docker network inspect network
  3. docker network inspect network -f {{.Id}}

Describe the results you received:

When running network inspect, the JSON output shows the "Id" field capitalised as such, however, running an inspect -f will fail if "{{.Id}}" is used, and instead is should be written "{{.ID}}

Describe the results you expected:

for inspect -f {{.Id}} to return the ID as the consistent name displayed in a bare network inspect.

Additional information you deem important (e.g. issue happens only occasionally):

TL;DR Network ID is named "Id" in network inspect, but network inspect -f expects "ID".

@HackToday
Copy link
Contributor

It seems a bug, I'd like to take a look at it

@HackToday
Copy link
Contributor

#dibs

@HackToday
Copy link
Contributor

@vdemeester and @calavera WDYT about the issue ? I have opened one in engine-api docker/engine-api#207 but not get any feedback.

@HackToday
Copy link
Contributor

hi @thaJeztah I tried change vendor/engine-api (https://github.com/docker/docker/blob/master/hack/vendor.sh#L63) with my engine-api commit docker/engine-api#207

But it seems can not just engine-api, as when I build, it also pops other issues # github.com/docker/docker/api/client
api/client/run.go:237: not enough arguments in call to cli.client.ContainerStart
api/client/start.go:116: not enough arguments in call to cli.client.ContainerStart
api/client/start.go:150: not enough arguments in call to cli.client.ContainerStart

So I think just vendor engine-api seems not good, maybe need vendor other?

@vdemeester
Copy link
Member

@HackToday it's because of the chekpoint/restore PR merged into engine-api that needs some update in docker/docker (it's simple and doesn't really matter right now). I'm "kinda" taking care of this in #22861

@HackToday
Copy link
Contributor

hi @vdemeester and @thaJeztah I am not sure who will do vendor for that, Not sure if #22861 handle that or not.

Will I do vendor for that ?

@HackToday
Copy link
Contributor

ping @thaJeztah and @vdemeester in case missed it 😄

@thaJeztah thaJeztah added this to the 1.12.0 milestone Jun 3, 2016
HackToday pushed a commit to HackToday/docker that referenced this issue Jun 6, 2016
This fixes moby#22231

Signed-off-by: Kai Qiang Wu(Kennan) <wkqwu@cn.ibm.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

6 participants