Implement docker unpause with standalone client lib.

Signed-off-by: David Calavera <david.calavera@gmail.com>
Upstream-commit: b8be62e28eee322b791251f29595648f795efcb3
Component: engine
This commit is contained in:
David Calavera
2015-12-09 12:04:57 -05:00
parent 5787f4e76e
commit 73385f6639
2 changed files with 9 additions and 1 deletions
@@ -0,0 +1,8 @@
package lib
// ContainerUnpause resumes the process execution within a container
func (cli *Client) ContainerUnpause(containerID string) error {
resp, err := cli.POST("/containers/"+containerID+"/unpause", nil, nil, nil)
ensureReaderClosed(resp)
return err
}
+1 -1
View File
@@ -18,7 +18,7 @@ func (cli *DockerCli) CmdUnpause(args ...string) error {
var errNames []string
for _, name := range cmd.Args() {
if _, _, err := readBody(cli.call("POST", fmt.Sprintf("/containers/%s/unpause", name), nil, nil)); err != nil {
if err := cli.client.ContainerUnpause(name); err != nil {
fmt.Fprintf(cli.err, "%s\n", err)
errNames = append(errNames, name)
} else {