reg/vendor/github.com/docker/docker-ce/components/engine/volume/validate.go
Jess Frazelle 8e5eba8735
switch to dep
Signed-off-by: Jess Frazelle <acidburn@microsoft.com>
2017-12-11 14:50:55 -05:00

26 lines
579 B
Go

package volume
import (
"fmt"
"github.com/docker/docker/api/types/mount"
"github.com/pkg/errors"
)
var errBindNotExist = errors.New("bind source path does not exist")
type errMountConfig struct {
mount *mount.Mount
err error
}
func (e *errMountConfig) Error() string {
return fmt.Sprintf("invalid mount config for type %q: %v", e.mount.Type, e.err.Error())
}
func errExtraField(name string) error {
return errors.Errorf("field %s must not be specified", name)
}
func errMissingField(name string) error {
return errors.Errorf("field %s must not be empty", name)
}