mirror of https://github.com/docker/cli.git
Hide command options that are related to Windows
Signed-off-by: Boaz Shuster <ripcurld.github@gmail.com>
This commit is contained in:
parent
eafb5565c9
commit
818c54a2ca
4
ping.go
4
ping.go
|
@ -7,7 +7,7 @@ import (
|
||||||
"golang.org/x/net/context"
|
"golang.org/x/net/context"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Ping pings the server and returns the value of the "Docker-Experimental" & "API-Version" headers
|
// Ping pings the server and returns the value of the "Docker-Experimental", "OS-Type" & "API-Version" headers
|
||||||
func (cli *Client) Ping(ctx context.Context) (types.Ping, error) {
|
func (cli *Client) Ping(ctx context.Context) (types.Ping, error) {
|
||||||
var ping types.Ping
|
var ping types.Ping
|
||||||
req, err := cli.buildRequest("GET", fmt.Sprintf("%s/_ping", cli.basePath), nil, nil)
|
req, err := cli.buildRequest("GET", fmt.Sprintf("%s/_ping", cli.basePath), nil, nil)
|
||||||
|
@ -26,5 +26,7 @@ func (cli *Client) Ping(ctx context.Context) (types.Ping, error) {
|
||||||
ping.Experimental = true
|
ping.Experimental = true
|
||||||
}
|
}
|
||||||
|
|
||||||
|
ping.OSType = serverResp.header.Get("OSType")
|
||||||
|
|
||||||
return ping, nil
|
return ping, nil
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue