Skip to content

Commit

Permalink
plugin status should be skip, not error
Browse files Browse the repository at this point in the history
Signed-off-by: pacoxu <paco.xu@daocloud.io>
  • Loading branch information
pacoxu committed Mar 15, 2021
1 parent cb8253e commit a76cefd
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion cmd/ctr/commands/plugins/plugins.go
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ import (
"github.com/containerd/containerd/api/types"
"github.com/containerd/containerd/cmd/ctr/commands"
"github.com/containerd/containerd/platforms"
pluginutils "github.com/containerd/containerd/plugin"
v1 "github.com/opencontainers/image-spec/specs-go/v1"
"github.com/urfave/cli"
"google.golang.org/grpc/codes"
Expand Down Expand Up @@ -121,7 +122,11 @@ var listCommand = cli.Command{
status := "ok"

if plugin.InitErr != nil {
status = "error"
if strings.Contains(plugin.InitErr.Message, pluginutils.ErrSkipPlugin.Error()) {
status = "skip"
} else {
status = "error"
}
}

var platformColumn = "-"
Expand Down

0 comments on commit a76cefd

Please sign in to comment.