mirror of
https://github.com/containers/podman.git
synced 2025-05-21 00:56:36 +08:00
Vendor containers/storage for better error reporting on dups
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com> Closes: #971 Approved by: mheon
This commit is contained in:

committed by
Atomic Bot

parent
f228cf73e0
commit
da29c52c15
@ -11,7 +11,7 @@ github.com/containerd/continuity master
|
||||
github.com/containernetworking/cni v0.6.0
|
||||
github.com/containernetworking/plugins 1fb94a4222eafc6f948eacdca9c9f2158b427e53
|
||||
github.com/containers/image ad33f7b73fbac0acf05b9e2cea021b61b4b0c3e0
|
||||
github.com/containers/storage 4993aae31ced3971f5b72f28c4e3fe38c34fa634
|
||||
github.com/containers/storage 51f1f85c2b7863b2fd361471f05b937fd8059124
|
||||
github.com/coreos/go-systemd v14
|
||||
github.com/cri-o/ocicni master
|
||||
github.com/cyphar/filepath-securejoin v0.2.1
|
||||
|
4
vendor/github.com/containers/storage/containers.go
generated
vendored
4
vendor/github.com/containers/storage/containers.go
generated
vendored
@ -2,6 +2,7 @@ package storage
|
||||
|
||||
import (
|
||||
"encoding/json"
|
||||
"fmt"
|
||||
"io/ioutil"
|
||||
"os"
|
||||
"path/filepath"
|
||||
@ -278,7 +279,8 @@ func (r *containerStore) Create(id string, names []string, image, layer, metadat
|
||||
names = dedupeNames(names)
|
||||
for _, name := range names {
|
||||
if _, nameInUse := r.byname[name]; nameInUse {
|
||||
return nil, ErrDuplicateName
|
||||
return nil, errors.Wrapf(ErrDuplicateName,
|
||||
fmt.Sprintf("the container name \"%s\" is already in use by \"%s\". You have to remove that container to be able to reuse that name.", name, r.byname[name].ID))
|
||||
}
|
||||
}
|
||||
if err == nil {
|
||||
|
1
vendor/github.com/containers/storage/containers_ffjson.go
generated
vendored
1
vendor/github.com/containers/storage/containers_ffjson.go
generated
vendored
@ -1,5 +1,6 @@
|
||||
// Code generated by ffjson <https://github.com/pquerna/ffjson>. DO NOT EDIT.
|
||||
// source: containers.go
|
||||
//
|
||||
|
||||
package storage
|
||||
|
||||
|
2
vendor/github.com/containers/storage/pkg/directory/directory_unix.go
generated
vendored
2
vendor/github.com/containers/storage/pkg/directory/directory_unix.go
generated
vendored
@ -1,4 +1,4 @@
|
||||
// +build linux freebsd solaris
|
||||
// +build linux darwin freebsd solaris
|
||||
|
||||
package directory
|
||||
|
||||
|
Reference in New Issue
Block a user