mirror of
https://github.com/docker/compose.git
synced 2026-08-31 23:03:55 +00:00
Merge pull request #1163 from docker/stop-on-ctrlc
Stop project on Ctrl+C
This commit is contained in:
commit
3f474143ad
10 changed files with 102 additions and 12 deletions
|
|
@ -117,7 +117,7 @@ func runCreateStart(ctx context.Context, opts upOptions, services []string) erro
|
|||
fmt.Println("Gracefully stopping...")
|
||||
ctx = context.Background()
|
||||
_, err = progress.Run(ctx, func(ctx context.Context) (string, error) {
|
||||
return "", c.ComposeService().Down(ctx, project.Name, compose.DownOptions{})
|
||||
return "", c.ComposeService().Stop(ctx, project, consumer)
|
||||
})
|
||||
}
|
||||
return err
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue