Update ContainerStart calls to use options now

Signed-off-by: Vincent Demeester <vincent@sbr.pm>
This commit is contained in:
Vincent Demeester 2016-06-02 16:56:13 +02:00
parent 8ea051f012
commit 6b7f12650d
No known key found for this signature in database
GPG key ID: 083CC6FD6EB699A3
2 changed files with 3 additions and 3 deletions

View file

@ -234,7 +234,7 @@ func (cli *DockerCli) CmdRun(args ...string) error {
}
//start the container
if err := cli.client.ContainerStart(ctx, createResponse.ID, ""); err != nil {
if err := cli.client.ContainerStart(ctx, createResponse.ID, types.ContainerStartOptions{}); err != nil {
// If we have holdHijackedConnection, we should notify
// holdHijackedConnection we are going to exit and wait
// to avoid the terminal are not restored.

View file

@ -113,7 +113,7 @@ func (cli *DockerCli) CmdStart(args ...string) error {
})
// 3. Start the container.
if err := cli.client.ContainerStart(ctx, container, ""); err != nil {
if err := cli.client.ContainerStart(ctx, container, types.ContainerStartOptions{}); err != nil {
cancelFun()
<-cErr
return err
@ -147,7 +147,7 @@ func (cli *DockerCli) CmdStart(args ...string) error {
func (cli *DockerCli) startContainersWithoutAttachments(ctx context.Context, containers []string) error {
var failedContainers []string
for _, container := range containers {
if err := cli.client.ContainerStart(ctx, container, ""); err != nil {
if err := cli.client.ContainerStart(ctx, container, types.ContainerStartOptions{}); err != nil {
fmt.Fprintf(cli.err, "%s\n", err)
failedContainers = append(failedContainers, container)
} else {