Skip to content

Commit 5da16ce

Browse files
committed
Reverse changes on wait.go
Signed-off-by: Mark Jagyo <mark.jagyo@gmail.com>
1 parent b199368 commit 5da16ce

File tree

2 files changed

+2
-11
lines changed

2 files changed

+2
-11
lines changed

cmd/compose/wait.go

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,6 @@ import (
2424
"github.com/docker/cli/cli/command"
2525
"github.com/spf13/cobra"
2626

27-
"github.com/docker/compose/v5/cmd/formatter"
2827
"github.com/docker/compose/v5/pkg/api"
2928
"github.com/docker/compose/v5/pkg/compose"
3029
)
@@ -35,7 +34,6 @@ type waitOptions struct {
3534
services []string
3635

3736
downProject bool
38-
log bool
3937
}
4038

4139
func waitCommand(p *ProjectOptions, dockerCli command.Cli, backendOptions *BackendOptions) *cobra.Command {
@@ -65,21 +63,17 @@ func waitCommand(p *ProjectOptions, dockerCli command.Cli, backendOptions *Backe
6563
}
6664

6765
func runWait(ctx context.Context, dockerCli command.Cli, backendOptions *BackendOptions, opts *waitOptions) (int64, error) {
68-
project, name, err := opts.projectOrName(ctx, dockerCli)
66+
_, name, err := opts.projectOrName(ctx, dockerCli)
6967
if err != nil {
7068
return 0, err
7169
}
7270

73-
consumer := formatter.NewLogConsumer(ctx, dockerCli.Out(), dockerCli.Err(), false, false, false)
7471
backend, err := compose.NewComposeService(dockerCli, backendOptions.Options...)
7572
if err != nil {
7673
return 0, err
7774
}
78-
7975
return backend.Wait(ctx, name, api.WaitOptions{
8076
Services: opts.services,
8177
DownProjectOnContainerExit: opts.downProject,
82-
Consumer: consumer,
83-
Project: project,
8478
})
8579
}

pkg/e2e/fixtures/wait/compose.yaml

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,4 @@ services:
77
command: sleep 5
88
infinity:
99
image: alpine
10-
command: sleep infinity
11-
hello:
12-
image: alpine
13-
command: sh -c "echo hello"
10+
command: sleep infinity

0 commit comments

Comments
 (0)