From 02f3bdcbe70bc812ab08a1e967f79cf989bf2fef Mon Sep 17 00:00:00 2001 From: guoguangwu Date: Tue, 26 Sep 2023 18:46:14 +0800 Subject: [PATCH] chore: import packages only once Signed-off-by: guoguangwu --- src/cmd/linuxkit/pkglib/build_test.go | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/cmd/linuxkit/pkglib/build_test.go b/src/cmd/linuxkit/pkglib/build_test.go index 0c5447d8d4..0e37a587c4 100644 --- a/src/cmd/linuxkit/pkglib/build_test.go +++ b/src/cmd/linuxkit/pkglib/build_test.go @@ -17,7 +17,6 @@ import ( dockertypes "github.com/docker/docker/api/types" registry "github.com/google/go-containerregistry/pkg/v1" "github.com/google/go-containerregistry/pkg/v1/types" - "github.com/linuxkit/linuxkit/src/cmd/linuxkit/spec" lktspec "github.com/linuxkit/linuxkit/src/cmd/linuxkit/spec" buildkitClient "github.com/moby/buildkit/client" imagespec "github.com/opencontainers/image-spec/specs-go/v1" @@ -56,7 +55,7 @@ func (d *dockerMocker) contextSupportCheck() error { func (d *dockerMocker) builder(_ context.Context, _, _, _ string, _ bool) (*buildkitClient.Client, error) { return nil, fmt.Errorf("not implemented") } -func (d *dockerMocker) build(ctx context.Context, tag, pkg, dockerContext, builderImage, platform string, builderRestart bool, c spec.CacheProvider, r io.Reader, stdout io.Writer, imageBuildOpts dockertypes.ImageBuildOptions) error { +func (d *dockerMocker) build(ctx context.Context, tag, pkg, dockerContext, builderImage, platform string, builderRestart bool, c lktspec.CacheProvider, r io.Reader, stdout io.Writer, imageBuildOpts dockertypes.ImageBuildOptions) error { if !d.enableBuild { return errors.New("build disabled") }