mirror of https://github.com/docker/docs.git
fix typos
Signed-off-by: allencloud <allen.sun@daocloud.io>
This commit is contained in:
parent
6f9872180c
commit
6983f05b42
|
@ -106,13 +106,13 @@ func (fi *HashedFileInfo) SetHash(h string) {
|
||||||
type Backend interface {
|
type Backend interface {
|
||||||
// TODO: use digest reference instead of name
|
// TODO: use digest reference instead of name
|
||||||
|
|
||||||
// GetImage looks up a Docker image referenced by `name`.
|
// GetImageOnBuild looks up a Docker image referenced by `name`.
|
||||||
GetImageOnBuild(name string) (Image, error)
|
GetImageOnBuild(name string) (Image, error)
|
||||||
// Tag an image with newTag
|
// TagImage tags an image with newTag
|
||||||
TagImage(newTag reference.Named, imageName string) error
|
TagImage(newTag reference.Named, imageName string) error
|
||||||
// Pull tells Docker to pull image referenced by `name`.
|
// PullOnBuild tells Docker to pull image referenced by `name`.
|
||||||
PullOnBuild(ctx context.Context, name string, authConfigs map[string]types.AuthConfig, output io.Writer) (Image, error)
|
PullOnBuild(ctx context.Context, name string, authConfigs map[string]types.AuthConfig, output io.Writer) (Image, error)
|
||||||
// ContainerAttach attaches to container.
|
// ContainerAttachRaw attaches to container.
|
||||||
ContainerAttachRaw(cID string, stdin io.ReadCloser, stdout, stderr io.Writer, stream bool) error
|
ContainerAttachRaw(cID string, stdin io.ReadCloser, stdout, stderr io.Writer, stream bool) error
|
||||||
// ContainerCreate creates a new Docker container and returns potential warnings
|
// ContainerCreate creates a new Docker container and returns potential warnings
|
||||||
ContainerCreate(types.ContainerCreateConfig) (types.ContainerCreateResponse, error)
|
ContainerCreate(types.ContainerCreateConfig) (types.ContainerCreateResponse, error)
|
||||||
|
@ -120,13 +120,13 @@ type Backend interface {
|
||||||
ContainerRm(name string, config *types.ContainerRmConfig) error
|
ContainerRm(name string, config *types.ContainerRmConfig) error
|
||||||
// Commit creates a new Docker image from an existing Docker container.
|
// Commit creates a new Docker image from an existing Docker container.
|
||||||
Commit(string, *backend.ContainerCommitConfig) (string, error)
|
Commit(string, *backend.ContainerCommitConfig) (string, error)
|
||||||
// Kill stops the container execution abruptly.
|
// ContainerKill stops the container execution abruptly.
|
||||||
ContainerKill(containerID string, sig uint64) error
|
ContainerKill(containerID string, sig uint64) error
|
||||||
// Start starts a new container
|
// ContainerStart starts a new container
|
||||||
ContainerStart(containerID string, hostConfig *container.HostConfig) error
|
ContainerStart(containerID string, hostConfig *container.HostConfig) error
|
||||||
// ContainerWait stops processing until the given container is stopped.
|
// ContainerWait stops processing until the given container is stopped.
|
||||||
ContainerWait(containerID string, timeout time.Duration) (int, error)
|
ContainerWait(containerID string, timeout time.Duration) (int, error)
|
||||||
// ContainerUpdateCmd updates container.Path and container.Args
|
// ContainerUpdateCmdOnBuild updates container.Path and container.Args
|
||||||
ContainerUpdateCmdOnBuild(containerID string, cmd []string) error
|
ContainerUpdateCmdOnBuild(containerID string, cmd []string) error
|
||||||
|
|
||||||
// ContainerCopy copies/extracts a source FileInfo to a destination path inside a container
|
// ContainerCopy copies/extracts a source FileInfo to a destination path inside a container
|
||||||
|
|
|
@ -189,7 +189,7 @@ func Subcmd(name string, synopses []string, description string, exitOnError bool
|
||||||
return flags
|
return flags
|
||||||
}
|
}
|
||||||
|
|
||||||
// An StatusError reports an unsuccessful exit by a command.
|
// StatusError reports an unsuccessful exit by a command.
|
||||||
type StatusError struct {
|
type StatusError struct {
|
||||||
Status string
|
Status string
|
||||||
StatusCode int
|
StatusCode int
|
||||||
|
|
|
@ -151,7 +151,7 @@ func LoadFromReader(configData io.Reader) (*ConfigFile, error) {
|
||||||
}
|
}
|
||||||
|
|
||||||
// Load reads the configuration files in the given directory, and sets up
|
// Load reads the configuration files in the given directory, and sets up
|
||||||
// the auth config information and return values.
|
// the auth config information and returns values.
|
||||||
// FIXME: use the internal golang config parser
|
// FIXME: use the internal golang config parser
|
||||||
func Load(configDir string) (*ConfigFile, error) {
|
func Load(configDir string) (*ConfigFile, error) {
|
||||||
if configDir == "" {
|
if configDir == "" {
|
||||||
|
|
|
@ -11,7 +11,7 @@ import (
|
||||||
// ResolvePath resolves the given path in the container to a resource on the
|
// ResolvePath resolves the given path in the container to a resource on the
|
||||||
// host. Returns a resolved path (absolute path to the resource on the host),
|
// host. Returns a resolved path (absolute path to the resource on the host),
|
||||||
// the absolute path to the resource relative to the container's rootfs, and
|
// the absolute path to the resource relative to the container's rootfs, and
|
||||||
// a error if the path points to outside the container's rootfs.
|
// an error if the path points to outside the container's rootfs.
|
||||||
func (container *Container) ResolvePath(path string) (resolvedPath, absPath string, err error) {
|
func (container *Container) ResolvePath(path string) (resolvedPath, absPath string, err error) {
|
||||||
// Consider the given path as an absolute path in the container.
|
// Consider the given path as an absolute path in the container.
|
||||||
absPath = archive.PreserveTrailingDotOrSeparator(filepath.Join(string(filepath.Separator), path), path)
|
absPath = archive.PreserveTrailingDotOrSeparator(filepath.Join(string(filepath.Separator), path), path)
|
||||||
|
|
Loading…
Reference in New Issue