Merge pull request #1588 from ndeloof/prefer_cli_plugin

On default context, "compose" is implemented by CLI Plugin
This commit is contained in:
Guillaume Tardif 2021-04-23 12:28:00 +02:00 committed by GitHub
commit 1607370b81
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -218,10 +218,14 @@ func main() {
root.AddCommand(
run.Command(ctype),
compose.RootCommand(ctype, service.ComposeService()),
volume.Command(ctype),
)
if ctype != store.DefaultContextType {
// On default context, "compose" is implemented by CLI Plugin
root.AddCommand(compose.RootCommand(ctype, service.ComposeService()))
}
if err = root.ExecuteContext(ctx); err != nil {
handleError(ctx, err, ctype, currentContext, cc, root)
}