CurrentVersion returns the API version currently negotiated, or the default version otherwise.
()
| 86 | // CurrentVersion returns the API version currently negotiated, or the default |
| 87 | // version otherwise. |
| 88 | func (cli *DockerCli) CurrentVersion() string { |
| 89 | _ = cli.initialize() |
| 90 | if cli.client == nil { |
| 91 | return client.MaxAPIVersion |
| 92 | } |
| 93 | return cli.client.ClientVersion() |
| 94 | } |
| 95 | |
| 96 | // Client returns the APIClient |
| 97 | func (cli *DockerCli) Client() client.APIClient { |