fix make vet failures, and enable make vet on CI
Signed-off-by: Akihiro Suda <suda.akihiro@lab.ntt.co.jp>
This commit is contained in:
5
cmd/dist/ingest.go
vendored
5
cmd/dist/ingest.go
vendored
@@ -1,7 +1,6 @@
|
||||
package main
|
||||
|
||||
import (
|
||||
contextpkg "context"
|
||||
"os"
|
||||
|
||||
contentapi "github.com/containerd/containerd/api/services/content"
|
||||
@@ -29,14 +28,12 @@ var ingestCommand = cli.Command{
|
||||
},
|
||||
Action: func(context *cli.Context) error {
|
||||
var (
|
||||
ctx = background
|
||||
cancel func()
|
||||
ref = context.Args().First()
|
||||
expectedSize = context.Int64("expected-size")
|
||||
expectedDigest = digest.Digest(context.String("expected-digest"))
|
||||
)
|
||||
|
||||
ctx, cancel = contextpkg.WithCancel(ctx)
|
||||
ctx, cancel := appContext()
|
||||
defer cancel()
|
||||
|
||||
if err := expectedDigest.Validate(); expectedDigest != "" && err != nil {
|
||||
|
||||
Reference in New Issue
Block a user