mirror of
https://github.com/rancher/plugins.git
synced 2025-09-20 09:53:48 +00:00
vendor: bump to libcni v1.0
Signed-off-by: Casey Callendrello <cdc@redhat.com>
This commit is contained in:
10
vendor/github.com/containernetworking/cni/pkg/invoke/exec.go
generated
vendored
10
vendor/github.com/containernetworking/cni/pkg/invoke/exec.go
generated
vendored
@@ -20,6 +20,7 @@ import (
|
||||
"os"
|
||||
|
||||
"github.com/containernetworking/cni/pkg/types"
|
||||
"github.com/containernetworking/cni/pkg/types/create"
|
||||
"github.com/containernetworking/cni/pkg/version"
|
||||
)
|
||||
|
||||
@@ -83,14 +84,7 @@ func ExecPluginWithResult(ctx context.Context, pluginPath string, netconf []byte
|
||||
return nil, err
|
||||
}
|
||||
|
||||
// Plugin must return result in same version as specified in netconf
|
||||
versionDecoder := &version.ConfigDecoder{}
|
||||
confVersion, err := versionDecoder.Decode(netconf)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
return version.NewResult(confVersion, stdoutBytes)
|
||||
return create.CreateFromBytes(stdoutBytes)
|
||||
}
|
||||
|
||||
func ExecPluginWithoutResult(ctx context.Context, pluginPath string, netconf []byte, args CNIArgs, exec Exec) error {
|
||||
|
Reference in New Issue
Block a user