docs: unify no trailing dots in docstrings and help (#11301)

This commit is contained in:
Piotr Dąbrowski 2024-02-14 20:02:37 +01:00 коммит произвёл GitHub
Родитель aa56ab3e71
Коммит e330f5905b
Не найден ключ, соответствующий данной подписи
Идентификатор ключа GPG: B5690EEEBB952194
75 изменённых файлов: 359 добавлений и 362 удалений

Просмотреть файл

@ -43,7 +43,7 @@ func attachCommand(p *ProjectOptions, dockerCli command.Cli, backend api.Service
}
runCmd := &cobra.Command{
Use: "attach [OPTIONS] SERVICE",
Short: "Attach local standard input, output, and error streams to a service's running container.",
Short: "Attach local standard input, output, and error streams to a service's running container",
Args: cobra.MinimumNArgs(1),
PreRunE: Adapt(func(ctx context.Context, args []string) error {
opts.service = args[0]

Просмотреть файл

@ -111,13 +111,13 @@ func buildCommand(p *ProjectOptions, dockerCli command.Cli, backend api.Service)
ValidArgsFunction: completeServiceNames(dockerCli, p),
}
flags := cmd.Flags()
flags.BoolVar(&opts.push, "push", false, "Push service images.")
flags.BoolVar(&opts.push, "push", false, "Push service images")
flags.BoolVarP(&opts.quiet, "quiet", "q", false, "Don't print anything to STDOUT")
flags.BoolVar(&opts.pull, "pull", false, "Always attempt to pull a newer version of the image.")
flags.StringArrayVar(&opts.args, "build-arg", []string{}, "Set build-time variables for services.")
flags.BoolVar(&opts.pull, "pull", false, "Always attempt to pull a newer version of the image")
flags.StringArrayVar(&opts.args, "build-arg", []string{}, "Set build-time variables for services")
flags.StringVar(&opts.ssh, "ssh", "", "Set SSH authentications used when building service images. (use 'default' for using your default SSH Agent)")
flags.StringVar(&opts.builder, "builder", "", "Set builder to use.")
flags.BoolVar(&opts.deps, "with-dependencies", false, "Also build dependencies (transitively).")
flags.StringVar(&opts.builder, "builder", "", "Set builder to use")
flags.BoolVar(&opts.deps, "with-dependencies", false, "Also build dependencies (transitively)")
flags.Bool("parallel", true, "Build images in parallel. DEPRECATED")
flags.MarkHidden("parallel") //nolint:errcheck

Просмотреть файл

@ -157,7 +157,7 @@ func (o *ProjectOptions) addProjectFlags(f *pflag.FlagSet) {
f.StringArrayVar(&o.Profiles, "profile", []string{}, "Specify a profile to enable")
f.StringVarP(&o.ProjectName, "project-name", "p", "", "Project name")
f.StringArrayVarP(&o.ConfigPaths, "file", "f", []string{}, "Compose configuration files")
f.StringArrayVar(&o.EnvFiles, "env-file", nil, "Specify an alternate environment file.")
f.StringArrayVar(&o.EnvFiles, "env-file", nil, "Specify an alternate environment file")
f.StringVar(&o.ProjectDir, "project-directory", "", "Specify an alternate working directory\n(default: the path of the, first specified, Compose file)")
f.StringVar(&o.WorkDir, "workdir", "", "DEPRECATED! USE --project-directory INSTEAD.\nSpecify an alternate working directory\n(default: the path of the, first specified, Compose file)")
f.BoolVar(&o.Compatibility, "compatibility", false, "Run compose in backward compatibility mode")
@ -307,7 +307,7 @@ func RootCommand(dockerCli command.Cli, backend api.Service) *cobra.Command { //
)
c := &cobra.Command{
Short: "Docker Compose",
Long: "Define and run multi-container applications with Docker.",
Long: "Define and run multi-container applications with Docker",
Use: PluginName,
TraverseChildren: true,
// By default (no Run/RunE in parent c) for typos in subcommands, cobra displays the help of parent c but exit(0) !

Просмотреть файл

@ -106,18 +106,18 @@ func configCommand(p *ProjectOptions, dockerCli command.Cli, backend api.Service
}
flags := cmd.Flags()
flags.StringVar(&opts.Format, "format", "yaml", "Format the output. Values: [yaml | json]")
flags.BoolVar(&opts.resolveImageDigests, "resolve-image-digests", false, "Pin image tags to digests.")
flags.BoolVarP(&opts.quiet, "quiet", "q", false, "Only validate the configuration, don't print anything.")
flags.BoolVar(&opts.noInterpolate, "no-interpolate", false, "Don't interpolate environment variables.")
flags.BoolVar(&opts.noNormalize, "no-normalize", false, "Don't normalize compose model.")
flags.BoolVar(&opts.noResolvePath, "no-path-resolution", false, "Don't resolve file paths.")
flags.BoolVar(&opts.resolveImageDigests, "resolve-image-digests", false, "Pin image tags to digests")
flags.BoolVarP(&opts.quiet, "quiet", "q", false, "Only validate the configuration, don't print anything")
flags.BoolVar(&opts.noInterpolate, "no-interpolate", false, "Don't interpolate environment variables")
flags.BoolVar(&opts.noNormalize, "no-normalize", false, "Don't normalize compose model")
flags.BoolVar(&opts.noResolvePath, "no-path-resolution", false, "Don't resolve file paths")
flags.BoolVar(&opts.noConsistency, "no-consistency", false, "Don't check model consistency - warning: may produce invalid Compose output")
flags.BoolVar(&opts.services, "services", false, "Print the service names, one per line.")
flags.BoolVar(&opts.volumes, "volumes", false, "Print the volume names, one per line.")
flags.BoolVar(&opts.profiles, "profiles", false, "Print the profile names, one per line.")
flags.BoolVar(&opts.images, "images", false, "Print the image names, one per line.")
flags.StringVar(&opts.hash, "hash", "", "Print the service config hash, one per line.")
flags.BoolVar(&opts.services, "services", false, "Print the service names, one per line")
flags.BoolVar(&opts.volumes, "volumes", false, "Print the volume names, one per line")
flags.BoolVar(&opts.profiles, "profiles", false, "Print the profile names, one per line")
flags.BoolVar(&opts.images, "images", false, "Print the image names, one per line")
flags.StringVar(&opts.hash, "hash", "", "Print the service config hash, one per line")
flags.StringVarP(&opts.Output, "output", "o", "", "Save to file (default to stdout)")
return cmd

Просмотреть файл

@ -65,10 +65,10 @@ func copyCommand(p *ProjectOptions, dockerCli command.Cli, backend api.Service)
}
flags := copyCmd.Flags()
flags.IntVar(&opts.index, "index", 0, "index of the container if service has multiple replicas")
flags.BoolVar(&opts.all, "all", false, "copy to all the containers of the service.")
flags.MarkHidden("all") //nolint:errcheck
flags.MarkDeprecated("all", "by default all the containers of the service will get the source file/directory to be copied.") //nolint:errcheck
flags.IntVar(&opts.index, "index", 0, "Index of the container if service has multiple replicas")
flags.BoolVar(&opts.all, "all", false, "Copy to all the containers of the service")
flags.MarkHidden("all") //nolint:errcheck
flags.MarkDeprecated("all", "By default all the containers of the service will get the source file/directory to be copied") //nolint:errcheck
flags.BoolVarP(&opts.followLink, "follow-link", "L", false, "Always follow symbol link in SRC_PATH")
flags.BoolVarP(&opts.copyUIDGID, "archive", "a", false, "Archive mode (copy all uid/gid information)")

Просмотреть файл

@ -55,7 +55,7 @@ func createCommand(p *ProjectOptions, dockerCli command.Cli, backend api.Service
}
cmd := &cobra.Command{
Use: "create [OPTIONS] [SERVICE...]",
Short: "Creates containers for a service.",
Short: "Creates containers for a service",
PreRunE: AdaptCmd(func(ctx context.Context, cmd *cobra.Command, args []string) error {
opts.pullChanged = cmd.Flags().Changed("pull")
if opts.Build && opts.noBuild {
@ -72,12 +72,12 @@ func createCommand(p *ProjectOptions, dockerCli command.Cli, backend api.Service
ValidArgsFunction: completeServiceNames(dockerCli, p),
}
flags := cmd.Flags()
flags.BoolVar(&opts.Build, "build", false, "Build images before starting containers.")
flags.BoolVar(&opts.noBuild, "no-build", false, "Don't build an image, even if it's policy.")
flags.BoolVar(&opts.Build, "build", false, "Build images before starting containers")
flags.BoolVar(&opts.noBuild, "no-build", false, "Don't build an image, even if it's policy")
flags.StringVar(&opts.Pull, "pull", "policy", `Pull image before running ("always"|"missing"|"never"|"build")`)
flags.BoolVar(&opts.forceRecreate, "force-recreate", false, "Recreate containers even if their configuration and image haven't changed.")
flags.BoolVar(&opts.forceRecreate, "force-recreate", false, "Recreate containers even if their configuration and image haven't changed")
flags.BoolVar(&opts.noRecreate, "no-recreate", false, "If containers already exist, don't recreate them. Incompatible with --force-recreate.")
flags.BoolVar(&opts.removeOrphans, "remove-orphans", false, "Remove containers for services not defined in the Compose file.")
flags.BoolVar(&opts.removeOrphans, "remove-orphans", false, "Remove containers for services not defined in the Compose file")
flags.StringArrayVar(&opts.scale, "scale", []string{}, "Scale SERVICE to NUM instances. Overrides the `scale` setting in the Compose file if present.")
return cmd
}

Просмотреть файл

@ -63,9 +63,9 @@ func downCommand(p *ProjectOptions, dockerCli command.Cli, backend api.Service)
}
flags := downCmd.Flags()
removeOrphans := utils.StringToBool(os.Getenv(ComposeRemoveOrphans))
flags.BoolVar(&opts.removeOrphans, "remove-orphans", removeOrphans, "Remove containers for services not defined in the Compose file.")
flags.BoolVar(&opts.removeOrphans, "remove-orphans", removeOrphans, "Remove containers for services not defined in the Compose file")
flags.IntVarP(&opts.timeout, "timeout", "t", 0, "Specify a shutdown timeout in seconds")
flags.BoolVarP(&opts.volumes, "volumes", "v", false, `Remove named volumes declared in the "volumes" section of the Compose file and anonymous volumes attached to containers.`)
flags.BoolVarP(&opts.volumes, "volumes", "v", false, `Remove named volumes declared in the "volumes" section of the Compose file and anonymous volumes attached to containers`)
flags.StringVar(&opts.images, "rmi", "", `Remove images used by services. "local" remove only images that don't have a custom tag ("local"|"all")`)
flags.SetNormalizeFunc(func(f *pflag.FlagSet, name string) pflag.NormalizedName {
if name == "volume" {

Просмотреть файл

@ -40,7 +40,7 @@ func eventsCommand(p *ProjectOptions, dockerCli command.Cli, backend api.Service
}
cmd := &cobra.Command{
Use: "events [OPTIONS] [SERVICE...]",
Short: "Receive real time events from containers.",
Short: "Receive real time events from containers",
RunE: Adapt(func(ctx context.Context, args []string) error {
return runEvents(ctx, dockerCli, backend, opts, args)
}),

Просмотреть файл

@ -51,7 +51,7 @@ func execCommand(p *ProjectOptions, dockerCli command.Cli, backend api.Service)
}
runCmd := &cobra.Command{
Use: "exec [OPTIONS] SERVICE COMMAND [ARGS...]",
Short: "Execute a command in a running container.",
Short: "Execute a command in a running container",
Args: cobra.MinimumNArgs(2),
PreRunE: Adapt(func(ctx context.Context, args []string) error {
opts.service = args[0]
@ -64,17 +64,17 @@ func execCommand(p *ProjectOptions, dockerCli command.Cli, backend api.Service)
ValidArgsFunction: completeServiceNames(dockerCli, p),
}
runCmd.Flags().BoolVarP(&opts.detach, "detach", "d", false, "Detached mode: Run command in the background.")
runCmd.Flags().BoolVarP(&opts.detach, "detach", "d", false, "Detached mode: Run command in the background")
runCmd.Flags().StringArrayVarP(&opts.environment, "env", "e", []string{}, "Set environment variables")
runCmd.Flags().IntVar(&opts.index, "index", 0, "index of the container if service has multiple replicas")
runCmd.Flags().BoolVarP(&opts.privileged, "privileged", "", false, "Give extended privileges to the process.")
runCmd.Flags().StringVarP(&opts.user, "user", "u", "", "Run the command as this user.")
runCmd.Flags().IntVar(&opts.index, "index", 0, "Index of the container if service has multiple replicas")
runCmd.Flags().BoolVarP(&opts.privileged, "privileged", "", false, "Give extended privileges to the process")
runCmd.Flags().StringVarP(&opts.user, "user", "u", "", "Run the command as this user")
runCmd.Flags().BoolVarP(&opts.noTty, "no-TTY", "T", !dockerCli.Out().IsTerminal(), "Disable pseudo-TTY allocation. By default `docker compose exec` allocates a TTY.")
runCmd.Flags().StringVarP(&opts.workingDir, "workdir", "w", "", "Path to workdir directory for this command.")
runCmd.Flags().StringVarP(&opts.workingDir, "workdir", "w", "", "Path to workdir directory for this command")
runCmd.Flags().BoolVarP(&opts.interactive, "interactive", "i", true, "Keep STDIN open even if not attached.")
runCmd.Flags().BoolVarP(&opts.interactive, "interactive", "i", true, "Keep STDIN open even if not attached")
runCmd.Flags().MarkHidden("interactive") //nolint:errcheck
runCmd.Flags().BoolP("tty", "t", true, "Allocate a pseudo-TTY.")
runCmd.Flags().BoolP("tty", "t", true, "Allocate a pseudo-TTY")
runCmd.Flags().MarkHidden("tty") //nolint:errcheck
runCmd.Flags().SetInterspersed(false)

Просмотреть файл

@ -51,7 +51,7 @@ func imagesCommand(p *ProjectOptions, dockerCli command.Cli, backend api.Service
}),
ValidArgsFunction: completeServiceNames(dockerCli, p),
}
imgCmd.Flags().StringVar(&opts.Format, "format", "table", "Format the output. Values: [table | json].")
imgCmd.Flags().StringVar(&opts.Format, "format", "table", "Format the output. Values: [table | json]")
imgCmd.Flags().BoolVarP(&opts.Quiet, "quiet", "q", false, "Only display IDs")
return imgCmd
}

Просмотреть файл

@ -39,7 +39,7 @@ func killCommand(p *ProjectOptions, dockerCli command.Cli, backend api.Service)
}
cmd := &cobra.Command{
Use: "kill [OPTIONS] [SERVICE...]",
Short: "Force stop service containers.",
Short: "Force stop service containers",
RunE: Adapt(func(ctx context.Context, args []string) error {
return runKill(ctx, dockerCli, backend, opts, args)
}),
@ -48,8 +48,8 @@ func killCommand(p *ProjectOptions, dockerCli command.Cli, backend api.Service)
flags := cmd.Flags()
removeOrphans := utils.StringToBool(os.Getenv(ComposeRemoveOrphans))
flags.BoolVar(&opts.removeOrphans, "remove-orphans", removeOrphans, "Remove containers for services not defined in the Compose file.")
flags.StringVarP(&opts.signal, "signal", "s", "SIGKILL", "SIGNAL to send to the container.")
flags.BoolVar(&opts.removeOrphans, "remove-orphans", removeOrphans, "Remove containers for services not defined in the Compose file")
flags.StringVarP(&opts.signal, "signal", "s", "SIGKILL", "SIGNAL to send to the container")
return cmd
}

Просмотреть файл

@ -49,9 +49,9 @@ func listCommand(dockerCli command.Cli, backend api.Service) *cobra.Command {
Args: cobra.NoArgs,
ValidArgsFunction: noCompletion(),
}
lsCmd.Flags().StringVar(&lsOpts.Format, "format", "table", "Format the output. Values: [table | json].")
lsCmd.Flags().BoolVarP(&lsOpts.Quiet, "quiet", "q", false, "Only display IDs.")
lsCmd.Flags().Var(&lsOpts.Filter, "filter", "Filter output based on conditions provided.")
lsCmd.Flags().StringVar(&lsOpts.Format, "format", "table", "Format the output. Values: [table | json]")
lsCmd.Flags().BoolVarP(&lsOpts.Quiet, "quiet", "q", false, "Only display IDs")
lsCmd.Flags().Var(&lsOpts.Filter, "filter", "Filter output based on conditions provided")
lsCmd.Flags().BoolVarP(&lsOpts.All, "all", "a", false, "Show all stopped Compose projects")
return lsCmd

Просмотреть файл

@ -59,14 +59,14 @@ func logsCommand(p *ProjectOptions, dockerCli command.Cli, backend api.Service)
ValidArgsFunction: completeServiceNames(dockerCli, p),
}
flags := logsCmd.Flags()
flags.BoolVarP(&opts.follow, "follow", "f", false, "Follow log output.")
flags.BoolVarP(&opts.follow, "follow", "f", false, "Follow log output")
flags.IntVar(&opts.index, "index", 0, "index of the container if service has multiple replicas")
flags.StringVar(&opts.since, "since", "", "Show logs since timestamp (e.g. 2013-01-02T13:23:37Z) or relative (e.g. 42m for 42 minutes)")
flags.StringVar(&opts.until, "until", "", "Show logs before a timestamp (e.g. 2013-01-02T13:23:37Z) or relative (e.g. 42m for 42 minutes)")
flags.BoolVar(&opts.noColor, "no-color", false, "Produce monochrome output.")
flags.BoolVar(&opts.noPrefix, "no-log-prefix", false, "Don't print prefix in logs.")
flags.BoolVarP(&opts.timestamps, "timestamps", "t", false, "Show timestamps.")
flags.StringVarP(&opts.tail, "tail", "n", "all", "Number of lines to show from the end of the logs for each container.")
flags.BoolVar(&opts.noColor, "no-color", false, "Produce monochrome output")
flags.BoolVar(&opts.noPrefix, "no-log-prefix", false, "Don't print prefix in logs")
flags.BoolVarP(&opts.timestamps, "timestamps", "t", false, "Show timestamps")
flags.StringVarP(&opts.tail, "tail", "n", "all", "Number of lines to show from the end of the logs for each container")
return logsCmd
}

Просмотреть файл

@ -41,7 +41,7 @@ func portCommand(p *ProjectOptions, dockerCli command.Cli, backend api.Service)
}
cmd := &cobra.Command{
Use: "port [OPTIONS] SERVICE PRIVATE_PORT",
Short: "Print the public port for a port binding.",
Short: "Print the public port for a port binding",
Args: cobra.MinimumNArgs(2),
PreRunE: Adapt(func(ctx context.Context, args []string) error {
port, err := strconv.ParseUint(args[1], 10, 16)
@ -58,7 +58,7 @@ func portCommand(p *ProjectOptions, dockerCli command.Cli, backend api.Service)
ValidArgsFunction: completeServiceNames(dockerCli, p),
}
cmd.Flags().StringVar(&opts.protocol, "protocol", "tcp", "tcp or udp")
cmd.Flags().IntVar(&opts.index, "index", 0, "index of the container if service has multiple replicas")
cmd.Flags().IntVar(&opts.index, "index", 0, "Index of the container if service has multiple replicas")
return cmd
}

Просмотреть файл

@ -81,7 +81,7 @@ func psCommand(p *ProjectOptions, dockerCli command.Cli, backend api.Service) *c
}
flags := psCmd.Flags()
flags.StringVar(&opts.Format, "format", "table", cliflags.FormatHelp)
flags.StringVar(&opts.Filter, "filter", "", "Filter services by a property (supported filters: status).")
flags.StringVar(&opts.Filter, "filter", "", "Filter services by a property (supported filters: status)")
flags.StringArrayVar(&opts.Status, "status", []string{}, "Filter services by status. Values: [paused | restarting | removing | running | dead | created | exited]")
flags.BoolVarP(&opts.Quiet, "quiet", "q", false, "Only display IDs")
flags.BoolVar(&opts.Services, "services", false, "Display services")

Просмотреть файл

@ -44,7 +44,7 @@ func publishCommand(p *ProjectOptions, dockerCli command.Cli, backend api.Servic
Args: cobra.ExactArgs(1),
}
flags := cmd.Flags()
flags.BoolVar(&opts.resolveImageDigests, "resolve-image-digests", false, "Pin image tags to digests.")
flags.BoolVar(&opts.resolveImageDigests, "resolve-image-digests", false, "Pin image tags to digests")
flags.StringVar(&opts.ociVersion, "oci-version", "", "OCI Image/Artifact specification version (automatically determined by default)")
return cmd
}

Просмотреть файл

@ -60,15 +60,15 @@ func pullCommand(p *ProjectOptions, dockerCli command.Cli, backend api.Service)
ValidArgsFunction: completeServiceNames(dockerCli, p),
}
flags := cmd.Flags()
flags.BoolVarP(&opts.quiet, "quiet", "q", false, "Pull without printing progress information.")
cmd.Flags().BoolVar(&opts.includeDeps, "include-deps", false, "Also pull services declared as dependencies.")
cmd.Flags().BoolVar(&opts.parallel, "parallel", true, "DEPRECATED pull multiple images in parallel.")
flags.BoolVarP(&opts.quiet, "quiet", "q", false, "Pull without printing progress information")
cmd.Flags().BoolVar(&opts.includeDeps, "include-deps", false, "Also pull services declared as dependencies")
cmd.Flags().BoolVar(&opts.parallel, "parallel", true, "DEPRECATED pull multiple images in parallel")
flags.MarkHidden("parallel") //nolint:errcheck
cmd.Flags().BoolVar(&opts.parallel, "no-parallel", true, "DEPRECATED disable parallel pulling.")
cmd.Flags().BoolVar(&opts.parallel, "no-parallel", true, "DEPRECATED disable parallel pulling")
flags.MarkHidden("no-parallel") //nolint:errcheck
cmd.Flags().BoolVar(&opts.ignorePullFailures, "ignore-pull-failures", false, "Pull what it can and ignores images with pull failures.")
cmd.Flags().BoolVar(&opts.noBuildable, "ignore-buildable", false, "Ignore images that can be built.")
cmd.Flags().StringVar(&opts.policy, "policy", "", `Apply pull policy ("missing"|"always").`)
cmd.Flags().BoolVar(&opts.ignorePullFailures, "ignore-pull-failures", false, "Pull what it can and ignores images with pull failures")
cmd.Flags().BoolVar(&opts.noBuildable, "ignore-buildable", false, "Ignore images that can be built")
cmd.Flags().StringVar(&opts.policy, "policy", "", `Apply pull policy ("missing"|"always")`)
return cmd
}

Просмотреть файл

@ -50,7 +50,7 @@ func restartCommand(p *ProjectOptions, dockerCli command.Cli, backend api.Servic
}
flags := restartCmd.Flags()
flags.IntVarP(&opts.timeout, "timeout", "t", 0, "Specify a shutdown timeout in seconds")
flags.BoolVar(&opts.noDeps, "no-deps", false, "Don't restart dependent services.")
flags.BoolVar(&opts.noDeps, "no-deps", false, "Don't restart dependent services")
return restartCmd
}

Просмотреть файл

@ -129,7 +129,7 @@ func runCommand(p *ProjectOptions, dockerCli command.Cli, backend api.Service) *
}
cmd := &cobra.Command{
Use: "run [OPTIONS] SERVICE [COMMAND] [ARGS...]",
Short: "Run a one-off command on a service.",
Short: "Run a one-off command on a service",
Args: cobra.MinimumNArgs(1),
PreRunE: AdaptCmd(func(ctx context.Context, cmd *cobra.Command, args []string) error {
options.Service = args[0]
@ -175,24 +175,24 @@ func runCommand(p *ProjectOptions, dockerCli command.Cli, backend api.Service) *
flags.StringArrayVarP(&options.environment, "env", "e", []string{}, "Set environment variables")
flags.StringArrayVarP(&options.labels, "label", "l", []string{}, "Add or override a label")
flags.BoolVar(&options.Remove, "rm", false, "Automatically remove the container when it exits")
flags.BoolVarP(&options.noTty, "no-TTY", "T", !dockerCli.Out().IsTerminal(), "Disable pseudo-TTY allocation (default: auto-detected).")
flags.BoolVarP(&options.noTty, "no-TTY", "T", !dockerCli.Out().IsTerminal(), "Disable pseudo-TTY allocation (default: auto-detected)")
flags.StringVar(&options.name, "name", "", "Assign a name to the container")
flags.StringVarP(&options.user, "user", "u", "", "Run as specified username or uid")
flags.StringVarP(&options.workdir, "workdir", "w", "", "Working directory inside the container")
flags.StringVar(&options.entrypoint, "entrypoint", "", "Override the entrypoint of the image")
flags.Var(&options.capAdd, "cap-add", "Add Linux capabilities")
flags.Var(&options.capDrop, "cap-drop", "Drop Linux capabilities")
flags.BoolVar(&options.noDeps, "no-deps", false, "Don't start linked services.")
flags.StringArrayVarP(&options.volumes, "volume", "v", []string{}, "Bind mount a volume.")
flags.StringArrayVarP(&options.publish, "publish", "p", []string{}, "Publish a container's port(s) to the host.")
flags.BoolVar(&options.useAliases, "use-aliases", false, "Use the service's network useAliases in the network(s) the container connects to.")
flags.BoolVarP(&options.servicePorts, "service-ports", "P", false, "Run command with all service's ports enabled and mapped to the host.")
flags.BoolVar(&options.quietPull, "quiet-pull", false, "Pull without printing progress information.")
flags.BoolVar(&createOpts.Build, "build", false, "Build image before starting container.")
flags.BoolVar(&createOpts.removeOrphans, "remove-orphans", false, "Remove containers for services not defined in the Compose file.")
flags.BoolVar(&options.noDeps, "no-deps", false, "Don't start linked services")
flags.StringArrayVarP(&options.volumes, "volume", "v", []string{}, "Bind mount a volume")
flags.StringArrayVarP(&options.publish, "publish", "p", []string{}, "Publish a container's port(s) to the host")
flags.BoolVar(&options.useAliases, "use-aliases", false, "Use the service's network useAliases in the network(s) the container connects to")
flags.BoolVarP(&options.servicePorts, "service-ports", "P", false, "Run command with all service's ports enabled and mapped to the host")
flags.BoolVar(&options.quietPull, "quiet-pull", false, "Pull without printing progress information")
flags.BoolVar(&createOpts.Build, "build", false, "Build image before starting container")
flags.BoolVar(&createOpts.removeOrphans, "remove-orphans", false, "Remove containers for services not defined in the Compose file")
cmd.Flags().BoolVarP(&options.interactive, "interactive", "i", true, "Keep STDIN open even if not attached.")
cmd.Flags().BoolVarP(&options.tty, "tty", "t", true, "Allocate a pseudo-TTY.")
cmd.Flags().BoolVarP(&options.interactive, "interactive", "i", true, "Keep STDIN open even if not attached")
cmd.Flags().BoolVarP(&options.tty, "tty", "t", true, "Allocate a pseudo-TTY")
cmd.Flags().MarkHidden("tty") //nolint:errcheck
flags.SetNormalizeFunc(normalizeRunFlags)

Просмотреть файл

@ -54,7 +54,7 @@ func scaleCommand(p *ProjectOptions, dockerCli command.Cli, backend api.Service)
ValidArgsFunction: completeServiceNames(dockerCli, p),
}
flags := scaleCmd.Flags()
flags.BoolVar(&opts.noDeps, "no-deps", false, "Don't start linked services.")
flags.BoolVar(&opts.noDeps, "no-deps", false, "Don't start linked services")
return scaleCmd
}

Просмотреть файл

@ -101,29 +101,29 @@ func upCommand(p *ProjectOptions, dockerCli command.Cli, backend api.Service) *c
}
flags := upCmd.Flags()
flags.BoolVarP(&up.Detach, "detach", "d", false, "Detached mode: Run containers in the background")
flags.BoolVar(&create.Build, "build", false, "Build images before starting containers.")
flags.BoolVar(&create.noBuild, "no-build", false, "Don't build an image, even if it's policy.")
flags.BoolVar(&create.Build, "build", false, "Build images before starting containers")
flags.BoolVar(&create.noBuild, "no-build", false, "Don't build an image, even if it's policy")
flags.StringVar(&create.Pull, "pull", "policy", `Pull image before running ("always"|"missing"|"never")`)
flags.BoolVar(&create.removeOrphans, "remove-orphans", false, "Remove containers for services not defined in the Compose file.")
flags.BoolVar(&create.removeOrphans, "remove-orphans", false, "Remove containers for services not defined in the Compose file")
flags.StringArrayVar(&create.scale, "scale", []string{}, "Scale SERVICE to NUM instances. Overrides the `scale` setting in the Compose file if present.")
flags.BoolVar(&up.noColor, "no-color", false, "Produce monochrome output.")
flags.BoolVar(&up.noPrefix, "no-log-prefix", false, "Don't print prefix in logs.")
flags.BoolVar(&create.forceRecreate, "force-recreate", false, "Recreate containers even if their configuration and image haven't changed.")
flags.BoolVar(&up.noColor, "no-color", false, "Produce monochrome output")
flags.BoolVar(&up.noPrefix, "no-log-prefix", false, "Don't print prefix in logs")
flags.BoolVar(&create.forceRecreate, "force-recreate", false, "Recreate containers even if their configuration and image haven't changed")
flags.BoolVar(&create.noRecreate, "no-recreate", false, "If containers already exist, don't recreate them. Incompatible with --force-recreate.")
flags.BoolVar(&up.noStart, "no-start", false, "Don't start the services after creating them.")
flags.BoolVar(&up.noStart, "no-start", false, "Don't start the services after creating them")
flags.BoolVar(&up.cascadeStop, "abort-on-container-exit", false, "Stops all containers if any container was stopped. Incompatible with -d")
flags.StringVar(&up.exitCodeFrom, "exit-code-from", "", "Return the exit code of the selected service container. Implies --abort-on-container-exit")
flags.IntVarP(&create.timeout, "timeout", "t", 0, "Use this timeout in seconds for container shutdown when attached or when containers are already running.")
flags.BoolVar(&up.timestamp, "timestamps", false, "Show timestamps.")
flags.BoolVar(&up.noDeps, "no-deps", false, "Don't start linked services.")
flags.IntVarP(&create.timeout, "timeout", "t", 0, "Use this timeout in seconds for container shutdown when attached or when containers are already running")
flags.BoolVar(&up.timestamp, "timestamps", false, "Show timestamps")
flags.BoolVar(&up.noDeps, "no-deps", false, "Don't start linked services")
flags.BoolVar(&create.recreateDeps, "always-recreate-deps", false, "Recreate dependent containers. Incompatible with --no-recreate.")
flags.BoolVarP(&create.noInherit, "renew-anon-volumes", "V", false, "Recreate anonymous volumes instead of retrieving data from the previous containers.")
flags.BoolVar(&create.quietPull, "quiet-pull", false, "Pull without printing progress information.")
flags.BoolVarP(&create.noInherit, "renew-anon-volumes", "V", false, "Recreate anonymous volumes instead of retrieving data from the previous containers")
flags.BoolVar(&create.quietPull, "quiet-pull", false, "Pull without printing progress information")
flags.StringArrayVar(&up.attach, "attach", []string{}, "Restrict attaching to the specified services. Incompatible with --attach-dependencies.")
flags.StringArrayVar(&up.noAttach, "no-attach", []string{}, "Do not attach (stream logs) to the specified services.")
flags.BoolVar(&up.attachDependencies, "attach-dependencies", false, "Automatically attach to log output of dependent services.")
flags.StringArrayVar(&up.noAttach, "no-attach", []string{}, "Do not attach (stream logs) to the specified services")
flags.BoolVar(&up.attachDependencies, "attach-dependencies", false, "Automatically attach to log output of dependent services")
flags.BoolVar(&up.wait, "wait", false, "Wait for services to be running|healthy. Implies detached mode.")
flags.IntVar(&up.waitTimeout, "wait-timeout", 0, "Maximum duration to wait for the project to be running|healthy.")
flags.IntVar(&up.waitTimeout, "wait-timeout", 0, "Maximum duration to wait for the project to be running|healthy")
return upCmd
}

Просмотреть файл

@ -52,7 +52,7 @@ func versionCommand(dockerCli command.Cli) *cobra.Command {
// define flags for backward compatibility with com.docker.cli
flags := cmd.Flags()
flags.StringVarP(&opts.format, "format", "f", "", "Format the output. Values: [pretty | json]. (Default: pretty)")
flags.BoolVar(&opts.short, "short", false, "Shows only Compose's version number.")
flags.BoolVar(&opts.short, "short", false, "Shows only Compose's version number")
return cmd
}

Просмотреть файл

@ -1,42 +1,42 @@
# docker compose
<!---MARKER_GEN_START-->
Define and run multi-container applications with Docker.
Define and run multi-container applications with Docker
### Subcommands
| Name | Description |
|:--------------------------------|:-----------------------------------------------------------------------------------------|
| [`attach`](compose_attach.md) | Attach local standard input, output, and error streams to a service's running container. |
| [`build`](compose_build.md) | Build or rebuild services |
| [`config`](compose_config.md) | Parse, resolve and render compose file in canonical format |
| [`cp`](compose_cp.md) | Copy files/folders between a service container and the local filesystem |
| [`create`](compose_create.md) | Creates containers for a service. |
| [`down`](compose_down.md) | Stop and remove containers, networks |
| [`events`](compose_events.md) | Receive real time events from containers. |
| [`exec`](compose_exec.md) | Execute a command in a running container. |
| [`images`](compose_images.md) | List images used by the created containers |
| [`kill`](compose_kill.md) | Force stop service containers. |
| [`logs`](compose_logs.md) | View output from containers |
| [`ls`](compose_ls.md) | List running compose projects |
| [`pause`](compose_pause.md) | Pause services |
| [`port`](compose_port.md) | Print the public port for a port binding. |
| [`ps`](compose_ps.md) | List containers |
| [`pull`](compose_pull.md) | Pull service images |
| [`push`](compose_push.md) | Push service images |
| [`restart`](compose_restart.md) | Restart service containers |
| [`rm`](compose_rm.md) | Removes stopped service containers |
| [`run`](compose_run.md) | Run a one-off command on a service. |
| [`scale`](compose_scale.md) | Scale services |
| [`start`](compose_start.md) | Start services |
| [`stats`](compose_stats.md) | Display a live stream of container(s) resource usage statistics |
| [`stop`](compose_stop.md) | Stop services |
| [`top`](compose_top.md) | Display the running processes |
| [`unpause`](compose_unpause.md) | Unpause services |
| [`up`](compose_up.md) | Create and start containers |
| [`version`](compose_version.md) | Show the Docker Compose version information |
| [`wait`](compose_wait.md) | Block until the first service container stops |
| [`watch`](compose_watch.md) | Watch build context for service and rebuild/refresh containers when files are updated |
| Name | Description |
|:--------------------------------|:----------------------------------------------------------------------------------------|
| [`attach`](compose_attach.md) | Attach local standard input, output, and error streams to a service's running container |
| [`build`](compose_build.md) | Build or rebuild services |
| [`config`](compose_config.md) | Parse, resolve and render compose file in canonical format |
| [`cp`](compose_cp.md) | Copy files/folders between a service container and the local filesystem |
| [`create`](compose_create.md) | Creates containers for a service |
| [`down`](compose_down.md) | Stop and remove containers, networks |
| [`events`](compose_events.md) | Receive real time events from containers |
| [`exec`](compose_exec.md) | Execute a command in a running container |
| [`images`](compose_images.md) | List images used by the created containers |
| [`kill`](compose_kill.md) | Force stop service containers |
| [`logs`](compose_logs.md) | View output from containers |
| [`ls`](compose_ls.md) | List running compose projects |
| [`pause`](compose_pause.md) | Pause services |
| [`port`](compose_port.md) | Print the public port for a port binding |
| [`ps`](compose_ps.md) | List containers |
| [`pull`](compose_pull.md) | Pull service images |
| [`push`](compose_push.md) | Push service images |
| [`restart`](compose_restart.md) | Restart service containers |
| [`rm`](compose_rm.md) | Removes stopped service containers |
| [`run`](compose_run.md) | Run a one-off command on a service |
| [`scale`](compose_scale.md) | Scale services |
| [`start`](compose_start.md) | Start services |
| [`stats`](compose_stats.md) | Display a live stream of container(s) resource usage statistics |
| [`stop`](compose_stop.md) | Stop services |
| [`top`](compose_top.md) | Display the running processes |
| [`unpause`](compose_unpause.md) | Unpause services |
| [`up`](compose_up.md) | Create and start containers |
| [`version`](compose_version.md) | Show the Docker Compose version information |
| [`wait`](compose_wait.md) | Block until the first service container stops |
| [`watch`](compose_watch.md) | Watch build context for service and rebuild/refresh containers when files are updated |
### Options
@ -46,7 +46,7 @@ Define and run multi-container applications with Docker.
| `--ansi` | `string` | `auto` | Control when to print ANSI control characters ("never"\|"always"\|"auto") |
| `--compatibility` | | | Run compose in backward compatibility mode |
| `--dry-run` | | | Execute command in dry run mode |
| `--env-file` | `stringArray` | | Specify an alternate environment file. |
| `--env-file` | `stringArray` | | Specify an alternate environment file |
| `-f`, `--file` | `stringArray` | | Compose configuration files |
| `--parallel` | `int` | `-1` | Control max parallelism, -1 for unlimited |
| `--profile` | `stringArray` | | Specify a profile to enable |

Просмотреть файл

@ -1,7 +1,7 @@
# docker compose alpha dry-run
<!---MARKER_GEN_START-->
Dry run command allows you to test a command without applying changes.
Dry run command allows you to test a command without applying changes
<!---MARKER_GEN_END-->

Просмотреть файл

@ -9,7 +9,7 @@ Publish compose application
|:--------------------------|:---------|:--------|:-------------------------------------------------------------------------------|
| `--dry-run` | | | Execute command in dry run mode |
| `--oci-version` | `string` | | OCI Image/Artifact specification version (automatically determined by default) |
| `--resolve-image-digests` | | | Pin image tags to digests. |
| `--resolve-image-digests` | | | Pin image tags to digests |
<!---MARKER_GEN_END-->

Просмотреть файл

@ -1,14 +1,14 @@
# docker compose alpha scale
<!---MARKER_GEN_START-->
Scale services.
Scale services
### Options
| Name | Type | Default | Description |
|:------------|:-----|:--------|:--------------------------------|
| `--dry-run` | | | Execute command in dry run mode |
| `--no-deps` | | | Don't start linked services |
| `--no-deps` | | | Don't start linked services |
<!---MARKER_GEN_END-->

Просмотреть файл

@ -1,7 +1,7 @@
# docker compose attach
<!---MARKER_GEN_START-->
Attach local standard input, output, and error streams to a service's running container.
Attach local standard input, output, and error streams to a service's running container
### Options
@ -15,4 +15,3 @@ Attach local standard input, output, and error streams to a service's running co
<!---MARKER_GEN_END-->

Просмотреть файл

@ -7,16 +7,16 @@ Build or rebuild services
| Name | Type | Default | Description |
|:----------------------|:--------------|:--------|:------------------------------------------------------------------------------------------------------------|
| `--build-arg` | `stringArray` | | Set build-time variables for services. |
| `--builder` | `string` | | Set builder to use. |
| `--build-arg` | `stringArray` | | Set build-time variables for services |
| `--builder` | `string` | | Set builder to use |
| `--dry-run` | | | Execute command in dry run mode |
| `-m`, `--memory` | `bytes` | `0` | Set memory limit for the build container. Not supported by BuildKit. |
| `--no-cache` | | | Do not use cache when building the image |
| `--pull` | | | Always attempt to pull a newer version of the image. |
| `--push` | | | Push service images. |
| `--pull` | | | Always attempt to pull a newer version of the image |
| `--push` | | | Push service images |
| `-q`, `--quiet` | | | Don't print anything to STDOUT |
| `--ssh` | `string` | | Set SSH authentications used when building service images. (use 'default' for using your default SSH Agent) |
| `--with-dependencies` | | | Also build dependencies (transitively). |
| `--with-dependencies` | | | Also build dependencies (transitively) |
<!---MARKER_GEN_END-->

Просмотреть файл

@ -13,18 +13,18 @@ Parse, resolve and render compose file in canonical format
|:--------------------------|:---------|:--------|:----------------------------------------------------------------------------|
| `--dry-run` | | | Execute command in dry run mode |
| `--format` | `string` | `yaml` | Format the output. Values: [yaml \| json] |
| `--hash` | `string` | | Print the service config hash, one per line. |
| `--images` | | | Print the image names, one per line. |
| `--hash` | `string` | | Print the service config hash, one per line |
| `--images` | | | Print the image names, one per line |
| `--no-consistency` | | | Don't check model consistency - warning: may produce invalid Compose output |
| `--no-interpolate` | | | Don't interpolate environment variables. |
| `--no-normalize` | | | Don't normalize compose model. |
| `--no-path-resolution` | | | Don't resolve file paths. |
| `--no-interpolate` | | | Don't interpolate environment variables |
| `--no-normalize` | | | Don't normalize compose model |
| `--no-path-resolution` | | | Don't resolve file paths |
| `-o`, `--output` | `string` | | Save to file (default to stdout) |
| `--profiles` | | | Print the profile names, one per line. |
| `-q`, `--quiet` | | | Only validate the configuration, don't print anything. |
| `--resolve-image-digests` | | | Pin image tags to digests. |
| `--services` | | | Print the service names, one per line. |
| `--volumes` | | | Print the volume names, one per line. |
| `--profiles` | | | Print the profile names, one per line |
| `-q`, `--quiet` | | | Only validate the configuration, don't print anything |
| `--resolve-image-digests` | | | Pin image tags to digests |
| `--services` | | | Print the service names, one per line |
| `--volumes` | | | Print the volume names, one per line |
<!---MARKER_GEN_END-->

Просмотреть файл

@ -10,7 +10,7 @@ Copy files/folders between a service container and the local filesystem
| `-a`, `--archive` | | | Archive mode (copy all uid/gid information) |
| `--dry-run` | | | Execute command in dry run mode |
| `-L`, `--follow-link` | | | Always follow symbol link in SRC_PATH |
| `--index` | `int` | `0` | index of the container if service has multiple replicas |
| `--index` | `int` | `0` | Index of the container if service has multiple replicas |
<!---MARKER_GEN_END-->

Просмотреть файл

@ -1,19 +1,19 @@
# docker compose create
<!---MARKER_GEN_START-->
Creates containers for a service.
Creates containers for a service
### Options
| Name | Type | Default | Description |
|:-------------------|:--------------|:---------|:----------------------------------------------------------------------------------------------|
| `--build` | | | Build images before starting containers. |
| `--build` | | | Build images before starting containers |
| `--dry-run` | | | Execute command in dry run mode |
| `--force-recreate` | | | Recreate containers even if their configuration and image haven't changed. |
| `--no-build` | | | Don't build an image, even if it's policy. |
| `--force-recreate` | | | Recreate containers even if their configuration and image haven't changed |
| `--no-build` | | | Don't build an image, even if it's policy |
| `--no-recreate` | | | If containers already exist, don't recreate them. Incompatible with --force-recreate. |
| `--pull` | `string` | `policy` | Pull image before running ("always"\|"missing"\|"never"\|"build") |
| `--remove-orphans` | | | Remove containers for services not defined in the Compose file. |
| `--remove-orphans` | | | Remove containers for services not defined in the Compose file |
| `--scale` | `stringArray` | | Scale SERVICE to NUM instances. Overrides the `scale` setting in the Compose file if present. |

Просмотреть файл

@ -5,13 +5,13 @@ Stop and remove containers, networks
### Options
| Name | Type | Default | Description |
|:-------------------|:---------|:--------|:-------------------------------------------------------------------------------------------------------------------------|
| `--dry-run` | | | Execute command in dry run mode |
| `--remove-orphans` | | | Remove containers for services not defined in the Compose file. |
| `--rmi` | `string` | | Remove images used by services. "local" remove only images that don't have a custom tag ("local"\|"all") |
| `-t`, `--timeout` | `int` | `0` | Specify a shutdown timeout in seconds |
| `-v`, `--volumes` | | | Remove named volumes declared in the "volumes" section of the Compose file and anonymous volumes attached to containers. |
| Name | Type | Default | Description |
|:-------------------|:---------|:--------|:------------------------------------------------------------------------------------------------------------------------|
| `--dry-run` | | | Execute command in dry run mode |
| `--remove-orphans` | | | Remove containers for services not defined in the Compose file |
| `--rmi` | `string` | | Remove images used by services. "local" remove only images that don't have a custom tag ("local"\|"all") |
| `-t`, `--timeout` | `int` | `0` | Specify a shutdown timeout in seconds |
| `-v`, `--volumes` | | | Remove named volumes declared in the "volumes" section of the Compose file and anonymous volumes attached to containers |
<!---MARKER_GEN_END-->

Просмотреть файл

@ -1,7 +1,7 @@
# docker compose events
<!---MARKER_GEN_START-->
Receive real time events from containers.
Receive real time events from containers
### Options

Просмотреть файл

@ -1,20 +1,20 @@
# docker compose exec
<!---MARKER_GEN_START-->
Execute a command in a running container.
Execute a command in a running container
### Options
| Name | Type | Default | Description |
|:------------------|:--------------|:--------|:---------------------------------------------------------------------------------|
| `-d`, `--detach` | | | Detached mode: Run command in the background. |
| `-d`, `--detach` | | | Detached mode: Run command in the background |
| `--dry-run` | | | Execute command in dry run mode |
| `-e`, `--env` | `stringArray` | | Set environment variables |
| `--index` | `int` | `0` | index of the container if service has multiple replicas |
| `--index` | `int` | `0` | Index of the container if service has multiple replicas |
| `-T`, `--no-TTY` | | | Disable pseudo-TTY allocation. By default `docker compose exec` allocates a TTY. |
| `--privileged` | | | Give extended privileges to the process. |
| `-u`, `--user` | `string` | | Run the command as this user. |
| `-w`, `--workdir` | `string` | | Path to workdir directory for this command. |
| `--privileged` | | | Give extended privileges to the process |
| `-u`, `--user` | `string` | | Run the command as this user |
| `-w`, `--workdir` | `string` | | Path to workdir directory for this command |
<!---MARKER_GEN_END-->

Просмотреть файл

@ -5,11 +5,11 @@ List images used by the created containers
### Options
| Name | Type | Default | Description |
|:----------------|:---------|:--------|:--------------------------------------------|
| `--dry-run` | | | Execute command in dry run mode |
| `--format` | `string` | `table` | Format the output. Values: [table \| json]. |
| `-q`, `--quiet` | | | Only display IDs |
| Name | Type | Default | Description |
|:----------------|:---------|:--------|:-------------------------------------------|
| `--dry-run` | | | Execute command in dry run mode |
| `--format` | `string` | `table` | Format the output. Values: [table \| json] |
| `-q`, `--quiet` | | | Only display IDs |
<!---MARKER_GEN_END-->

Просмотреть файл

@ -1,15 +1,15 @@
# docker compose kill
<!---MARKER_GEN_START-->
Force stop service containers.
Force stop service containers
### Options
| Name | Type | Default | Description |
|:-------------------|:---------|:----------|:----------------------------------------------------------------|
| `--dry-run` | | | Execute command in dry run mode |
| `--remove-orphans` | | | Remove containers for services not defined in the Compose file. |
| `-s`, `--signal` | `string` | `SIGKILL` | SIGNAL to send to the container. |
| Name | Type | Default | Description |
|:-------------------|:---------|:----------|:---------------------------------------------------------------|
| `--dry-run` | | | Execute command in dry run mode |
| `--remove-orphans` | | | Remove containers for services not defined in the Compose file |
| `-s`, `--signal` | `string` | `SIGKILL` | SIGNAL to send to the container |
<!---MARKER_GEN_END-->

Просмотреть файл

@ -8,13 +8,13 @@ View output from containers
| Name | Type | Default | Description |
|:---------------------|:---------|:--------|:-----------------------------------------------------------------------------------------------|
| `--dry-run` | | | Execute command in dry run mode |
| `-f`, `--follow` | | | Follow log output. |
| `-f`, `--follow` | | | Follow log output |
| `--index` | `int` | `0` | index of the container if service has multiple replicas |
| `--no-color` | | | Produce monochrome output. |
| `--no-log-prefix` | | | Don't print prefix in logs. |
| `--no-color` | | | Produce monochrome output |
| `--no-log-prefix` | | | Don't print prefix in logs |
| `--since` | `string` | | Show logs since timestamp (e.g. 2013-01-02T13:23:37Z) or relative (e.g. 42m for 42 minutes) |
| `-n`, `--tail` | `string` | `all` | Number of lines to show from the end of the logs for each container. |
| `-t`, `--timestamps` | | | Show timestamps. |
| `-n`, `--tail` | `string` | `all` | Number of lines to show from the end of the logs for each container |
| `-t`, `--timestamps` | | | Show timestamps |
| `--until` | `string` | | Show logs before a timestamp (e.g. 2013-01-02T13:23:37Z) or relative (e.g. 42m for 42 minutes) |
@ -22,4 +22,4 @@ View output from containers
## Description
Displays log output from services.
Displays log output from services

Просмотреть файл

@ -5,17 +5,17 @@ List running compose projects
### Options
| Name | Type | Default | Description |
|:----------------|:---------|:--------|:--------------------------------------------|
| `-a`, `--all` | | | Show all stopped Compose projects |
| `--dry-run` | | | Execute command in dry run mode |
| `--filter` | `filter` | | Filter output based on conditions provided. |
| `--format` | `string` | `table` | Format the output. Values: [table \| json]. |
| `-q`, `--quiet` | | | Only display IDs. |
| Name | Type | Default | Description |
|:----------------|:---------|:--------|:-------------------------------------------|
| `-a`, `--all` | | | Show all stopped Compose projects |
| `--dry-run` | | | Execute command in dry run mode |
| `--filter` | `filter` | | Filter output based on conditions provided |
| `--format` | `string` | `table` | Format the output. Values: [table \| json] |
| `-q`, `--quiet` | | | Only display IDs |
<!---MARKER_GEN_END-->
## Description
Lists running Compose projects.
Lists running Compose projects

Просмотреть файл

@ -1,14 +1,14 @@
# docker compose port
<!---MARKER_GEN_START-->
Print the public port for a port binding.
Print the public port for a port binding
### Options
| Name | Type | Default | Description |
|:-------------|:---------|:--------|:--------------------------------------------------------|
| `--dry-run` | | | Execute command in dry run mode |
| `--index` | `int` | `0` | index of the container if service has multiple replicas |
| `--index` | `int` | `0` | Index of the container if service has multiple replicas |
| `--protocol` | `string` | `tcp` | tcp or udp |
@ -16,4 +16,4 @@ Print the public port for a port binding.
## Description
Prints the public port for a port binding.
Prints the public port for a port binding

Просмотреть файл

@ -9,7 +9,7 @@ List containers
|:----------------------|:--------------|:--------|:-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| `-a`, `--all` | | | Show all stopped containers (including those created by the run command) |
| `--dry-run` | | | Execute command in dry run mode |
| [`--filter`](#filter) | `string` | | Filter services by a property (supported filters: status). |
| [`--filter`](#filter) | `string` | | Filter services by a property (supported filters: status) |
| [`--format`](#format) | `string` | `table` | Format output using a custom template:<br>'table': Print output in table format with column headers (default)<br>'table TEMPLATE': Print output in table format using the given Go template<br>'json': Print in JSON format<br>'TEMPLATE': Print output using the given Go template.<br>Refer to https://docs.docker.com/go/formatting/ for more information about formatting output with templates |
| `--no-trunc` | | | Don't truncate output |
| `--orphans` | | | Include orphaned services (not declared by project) |

Просмотреть файл

@ -5,22 +5,21 @@ Pull service images
### Options
| Name | Type | Default | Description |
|:-------------------------|:---------|:--------|:--------------------------------------------------------|
| `--dry-run` | | | Execute command in dry run mode |
| `--ignore-buildable` | | | Ignore images that can be built. |
| `--ignore-pull-failures` | | | Pull what it can and ignores images with pull failures. |
| `--include-deps` | | | Also pull services declared as dependencies. |
| `--policy` | `string` | | Apply pull policy ("missing"\|"always"). |
| `-q`, `--quiet` | | | Pull without printing progress information. |
| Name | Type | Default | Description |
|:-------------------------|:---------|:--------|:-------------------------------------------------------|
| `--dry-run` | | | Execute command in dry run mode |
| `--ignore-buildable` | | | Ignore images that can be built |
| `--ignore-pull-failures` | | | Pull what it can and ignores images with pull failures |
| `--include-deps` | | | Also pull services declared as dependencies |
| `--policy` | `string` | | Apply pull policy ("missing"\|"always") |
| `-q`, `--quiet` | | | Pull without printing progress information |
<!---MARKER_GEN_END-->
## Description
Pulls an image associated with a service defined in a `compose.yaml` file, but does not start containers based on
those images.
Pulls an image associated with a service defined in a `compose.yaml` file, but does not start containers based on those images
## Examples

Просмотреть файл

@ -8,7 +8,7 @@ Restart service containers
| Name | Type | Default | Description |
|:------------------|:------|:--------|:--------------------------------------|
| `--dry-run` | | | Execute command in dry run mode |
| `--no-deps` | | | Don't restart dependent services. |
| `--no-deps` | | | Don't restart dependent services |
| `-t`, `--timeout` | `int` | `0` | Specify a shutdown timeout in seconds |

Просмотреть файл

@ -1,33 +1,33 @@
# docker compose run
<!---MARKER_GEN_START-->
Run a one-off command on a service.
Run a one-off command on a service
### Options
| Name | Type | Default | Description |
|:------------------------|:--------------|:--------|:----------------------------------------------------------------------------------|
| `--build` | | | Build image before starting container. |
| `--cap-add` | `list` | | Add Linux capabilities |
| `--cap-drop` | `list` | | Drop Linux capabilities |
| `-d`, `--detach` | | | Run container in background and print container ID |
| `--dry-run` | | | Execute command in dry run mode |
| `--entrypoint` | `string` | | Override the entrypoint of the image |
| `-e`, `--env` | `stringArray` | | Set environment variables |
| `-i`, `--interactive` | | | Keep STDIN open even if not attached. |
| `-l`, `--label` | `stringArray` | | Add or override a label |
| `--name` | `string` | | Assign a name to the container |
| `-T`, `--no-TTY` | | | Disable pseudo-TTY allocation (default: auto-detected). |
| `--no-deps` | | | Don't start linked services. |
| `-p`, `--publish` | `stringArray` | | Publish a container's port(s) to the host. |
| `--quiet-pull` | | | Pull without printing progress information. |
| `--remove-orphans` | | | Remove containers for services not defined in the Compose file. |
| `--rm` | | | Automatically remove the container when it exits |
| `-P`, `--service-ports` | | | Run command with all service's ports enabled and mapped to the host. |
| `--use-aliases` | | | Use the service's network useAliases in the network(s) the container connects to. |
| `-u`, `--user` | `string` | | Run as specified username or uid |
| `-v`, `--volume` | `stringArray` | | Bind mount a volume. |
| `-w`, `--workdir` | `string` | | Working directory inside the container |
| Name | Type | Default | Description |
|:------------------------|:--------------|:--------|:---------------------------------------------------------------------------------|
| `--build` | | | Build image before starting container |
| `--cap-add` | `list` | | Add Linux capabilities |
| `--cap-drop` | `list` | | Drop Linux capabilities |
| `-d`, `--detach` | | | Run container in background and print container ID |
| `--dry-run` | | | Execute command in dry run mode |
| `--entrypoint` | `string` | | Override the entrypoint of the image |
| `-e`, `--env` | `stringArray` | | Set environment variables |
| `-i`, `--interactive` | | | Keep STDIN open even if not attached |
| `-l`, `--label` | `stringArray` | | Add or override a label |
| `--name` | `string` | | Assign a name to the container |
| `-T`, `--no-TTY` | | | Disable pseudo-TTY allocation (default: auto-detected) |
| `--no-deps` | | | Don't start linked services |
| `-p`, `--publish` | `stringArray` | | Publish a container's port(s) to the host |
| `--quiet-pull` | | | Pull without printing progress information |
| `--remove-orphans` | | | Remove containers for services not defined in the Compose file |
| `--rm` | | | Automatically remove the container when it exits |
| `-P`, `--service-ports` | | | Run command with all service's ports enabled and mapped to the host |
| `--use-aliases` | | | Use the service's network useAliases in the network(s) the container connects to |
| `-u`, `--user` | `string` | | Run as specified username or uid |
| `-v`, `--volume` | `stringArray` | | Bind mount a volume |
| `-w`, `--workdir` | `string` | | Working directory inside the container |
<!---MARKER_GEN_END-->

Просмотреть файл

@ -8,7 +8,7 @@ Scale services
| Name | Type | Default | Description |
|:------------|:-----|:--------|:--------------------------------|
| `--dry-run` | | | Execute command in dry run mode |
| `--no-deps` | | | Don't start linked services. |
| `--no-deps` | | | Don't start linked services |
<!---MARKER_GEN_END-->

Просмотреть файл

@ -14,4 +14,4 @@ Start services
## Description
Starts existing containers for a service.
Starts existing containers for a service

Просмотреть файл

@ -14,7 +14,7 @@ Display the running processes
## Description
Displays the running processes.
Displays the running processes
## Examples

Просмотреть файл

@ -14,4 +14,4 @@ Unpause services
## Description
Unpauses paused containers of a service.
Unpauses paused containers of a service

Просмотреть файл

@ -5,33 +5,33 @@ Create and start containers
### Options
| Name | Type | Default | Description |
|:-----------------------------|:--------------|:---------|:---------------------------------------------------------------------------------------------------------|
| `--abort-on-container-exit` | | | Stops all containers if any container was stopped. Incompatible with -d |
| `--always-recreate-deps` | | | Recreate dependent containers. Incompatible with --no-recreate. |
| `--attach` | `stringArray` | | Restrict attaching to the specified services. Incompatible with --attach-dependencies. |
| `--attach-dependencies` | | | Automatically attach to log output of dependent services. |
| `--build` | | | Build images before starting containers. |
| `-d`, `--detach` | | | Detached mode: Run containers in the background |
| `--dry-run` | | | Execute command in dry run mode |
| `--exit-code-from` | `string` | | Return the exit code of the selected service container. Implies --abort-on-container-exit |
| `--force-recreate` | | | Recreate containers even if their configuration and image haven't changed. |
| `--no-attach` | `stringArray` | | Do not attach (stream logs) to the specified services. |
| `--no-build` | | | Don't build an image, even if it's policy. |
| `--no-color` | | | Produce monochrome output. |
| `--no-deps` | | | Don't start linked services. |
| `--no-log-prefix` | | | Don't print prefix in logs. |
| `--no-recreate` | | | If containers already exist, don't recreate them. Incompatible with --force-recreate. |
| `--no-start` | | | Don't start the services after creating them. |
| `--pull` | `string` | `policy` | Pull image before running ("always"\|"missing"\|"never") |
| `--quiet-pull` | | | Pull without printing progress information. |
| `--remove-orphans` | | | Remove containers for services not defined in the Compose file. |
| `-V`, `--renew-anon-volumes` | | | Recreate anonymous volumes instead of retrieving data from the previous containers. |
| `--scale` | `stringArray` | | Scale SERVICE to NUM instances. Overrides the `scale` setting in the Compose file if present. |
| `-t`, `--timeout` | `int` | `0` | Use this timeout in seconds for container shutdown when attached or when containers are already running. |
| `--timestamps` | | | Show timestamps. |
| `--wait` | | | Wait for services to be running\|healthy. Implies detached mode. |
| `--wait-timeout` | `int` | `0` | Maximum duration to wait for the project to be running\|healthy. |
| Name | Type | Default | Description |
|:-----------------------------|:--------------|:---------|:--------------------------------------------------------------------------------------------------------|
| `--abort-on-container-exit` | | | Stops all containers if any container was stopped. Incompatible with -d |
| `--always-recreate-deps` | | | Recreate dependent containers. Incompatible with --no-recreate. |
| `--attach` | `stringArray` | | Restrict attaching to the specified services. Incompatible with --attach-dependencies. |
| `--attach-dependencies` | | | Automatically attach to log output of dependent services |
| `--build` | | | Build images before starting containers |
| `-d`, `--detach` | | | Detached mode: Run containers in the background |
| `--dry-run` | | | Execute command in dry run mode |
| `--exit-code-from` | `string` | | Return the exit code of the selected service container. Implies --abort-on-container-exit |
| `--force-recreate` | | | Recreate containers even if their configuration and image haven't changed |
| `--no-attach` | `stringArray` | | Do not attach (stream logs) to the specified services |
| `--no-build` | | | Don't build an image, even if it's policy |
| `--no-color` | | | Produce monochrome output |
| `--no-deps` | | | Don't start linked services |
| `--no-log-prefix` | | | Don't print prefix in logs |
| `--no-recreate` | | | If containers already exist, don't recreate them. Incompatible with --force-recreate. |
| `--no-start` | | | Don't start the services after creating them |
| `--pull` | `string` | `policy` | Pull image before running ("always"\|"missing"\|"never") |
| `--quiet-pull` | | | Pull without printing progress information |
| `--remove-orphans` | | | Remove containers for services not defined in the Compose file |
| `-V`, `--renew-anon-volumes` | | | Recreate anonymous volumes instead of retrieving data from the previous containers |
| `--scale` | `stringArray` | | Scale SERVICE to NUM instances. Overrides the `scale` setting in the Compose file if present. |
| `-t`, `--timeout` | `int` | `0` | Use this timeout in seconds for container shutdown when attached or when containers are already running |
| `--timestamps` | | | Show timestamps |
| `--wait` | | | Wait for services to be running\|healthy. Implies detached mode. |
| `--wait-timeout` | `int` | `0` | Maximum duration to wait for the project to be running\|healthy |
<!---MARKER_GEN_END-->

Просмотреть файл

@ -9,7 +9,7 @@ Show the Docker Compose version information
|:-----------------|:---------|:--------|:---------------------------------------------------------------|
| `--dry-run` | | | Execute command in dry run mode |
| `-f`, `--format` | `string` | | Format the output. Values: [pretty \| json]. (Default: pretty) |
| `--short` | | | Shows only Compose's version number. |
| `--short` | | | Shows only Compose's version number |
<!---MARKER_GEN_END-->

Просмотреть файл

@ -242,7 +242,7 @@ options:
- option: env-file
value_type: stringArray
default_value: '[]'
description: Specify an alternate environment file.
description: Specify an alternate environment file
deprecated: false
hidden: false
experimental: false

Просмотреть файл

@ -18,7 +18,7 @@ options:
- option: resolve-image-digests
value_type: bool
default_value: "false"
description: Pin image tags to digests.
description: Pin image tags to digests
deprecated: false
hidden: false
experimental: false

Просмотреть файл

@ -1,8 +1,8 @@
command: docker compose attach
short: |
Attach local standard input, output, and error streams to a service's running container.
Attach local standard input, output, and error streams to a service's running container
long: |
Attach local standard input, output, and error streams to a service's running container.
Attach local standard input, output, and error streams to a service's running container
usage: docker compose attach [OPTIONS] SERVICE
pname: docker compose
plink: docker_compose.yaml

Просмотреть файл

@ -17,7 +17,7 @@ options:
- option: build-arg
value_type: stringArray
default_value: '[]'
description: Set build-time variables for services.
description: Set build-time variables for services
deprecated: false
hidden: false
experimental: false
@ -26,7 +26,7 @@ options:
swarm: false
- option: builder
value_type: string
description: Set builder to use.
description: Set builder to use
deprecated: false
hidden: false
experimental: false
@ -109,7 +109,7 @@ options:
- option: pull
value_type: bool
default_value: "false"
description: Always attempt to pull a newer version of the image.
description: Always attempt to pull a newer version of the image
deprecated: false
hidden: false
experimental: false
@ -119,7 +119,7 @@ options:
- option: push
value_type: bool
default_value: "false"
description: Push service images.
description: Push service images
deprecated: false
hidden: false
experimental: false
@ -150,7 +150,7 @@ options:
- option: with-dependencies
value_type: bool
default_value: "false"
description: Also build dependencies (transitively).
description: Also build dependencies (transitively)
deprecated: false
hidden: false
experimental: false

Просмотреть файл

@ -21,7 +21,7 @@ options:
swarm: false
- option: hash
value_type: string
description: Print the service config hash, one per line.
description: Print the service config hash, one per line
deprecated: false
hidden: false
experimental: false
@ -31,7 +31,7 @@ options:
- option: images
value_type: bool
default_value: "false"
description: Print the image names, one per line.
description: Print the image names, one per line
deprecated: false
hidden: false
experimental: false
@ -52,7 +52,7 @@ options:
- option: no-interpolate
value_type: bool
default_value: "false"
description: Don't interpolate environment variables.
description: Don't interpolate environment variables
deprecated: false
hidden: false
experimental: false
@ -62,7 +62,7 @@ options:
- option: no-normalize
value_type: bool
default_value: "false"
description: Don't normalize compose model.
description: Don't normalize compose model
deprecated: false
hidden: false
experimental: false
@ -72,7 +72,7 @@ options:
- option: no-path-resolution
value_type: bool
default_value: "false"
description: Don't resolve file paths.
description: Don't resolve file paths
deprecated: false
hidden: false
experimental: false
@ -92,7 +92,7 @@ options:
- option: profiles
value_type: bool
default_value: "false"
description: Print the profile names, one per line.
description: Print the profile names, one per line
deprecated: false
hidden: false
experimental: false
@ -103,7 +103,7 @@ options:
shorthand: q
value_type: bool
default_value: "false"
description: Only validate the configuration, don't print anything.
description: Only validate the configuration, don't print anything
deprecated: false
hidden: false
experimental: false
@ -113,7 +113,7 @@ options:
- option: resolve-image-digests
value_type: bool
default_value: "false"
description: Pin image tags to digests.
description: Pin image tags to digests
deprecated: false
hidden: false
experimental: false
@ -123,7 +123,7 @@ options:
- option: services
value_type: bool
default_value: "false"
description: Print the service names, one per line.
description: Print the service names, one per line
deprecated: false
hidden: false
experimental: false
@ -133,7 +133,7 @@ options:
- option: volumes
value_type: bool
default_value: "false"
description: Print the volume names, one per line.
description: Print the volume names, one per line
deprecated: false
hidden: false
experimental: false

Просмотреть файл

@ -10,7 +10,7 @@ options:
- option: all
value_type: bool
default_value: "false"
description: copy to all the containers of the service.
description: Copy to all the containers of the service
deprecated: true
hidden: true
experimental: false
@ -42,7 +42,7 @@ options:
- option: index
value_type: int
default_value: "0"
description: index of the container if service has multiple replicas
description: Index of the container if service has multiple replicas
deprecated: false
hidden: false
experimental: false

Просмотреть файл

@ -1,6 +1,6 @@
command: docker compose create
short: Creates containers for a service.
long: Creates containers for a service.
short: Creates containers for a service
long: Creates containers for a service
usage: docker compose create [OPTIONS] [SERVICE...]
pname: docker compose
plink: docker_compose.yaml
@ -8,7 +8,7 @@ options:
- option: build
value_type: bool
default_value: "false"
description: Build images before starting containers.
description: Build images before starting containers
deprecated: false
hidden: false
experimental: false
@ -19,7 +19,7 @@ options:
value_type: bool
default_value: "false"
description: |
Recreate containers even if their configuration and image haven't changed.
Recreate containers even if their configuration and image haven't changed
deprecated: false
hidden: false
experimental: false
@ -29,7 +29,7 @@ options:
- option: no-build
value_type: bool
default_value: "false"
description: Don't build an image, even if it's policy.
description: Don't build an image, even if it's policy
deprecated: false
hidden: false
experimental: false
@ -60,7 +60,7 @@ options:
- option: remove-orphans
value_type: bool
default_value: "false"
description: Remove containers for services not defined in the Compose file.
description: Remove containers for services not defined in the Compose file
deprecated: false
hidden: false
experimental: false

Просмотреть файл

@ -21,7 +21,7 @@ options:
- option: remove-orphans
value_type: bool
default_value: "false"
description: Remove containers for services not defined in the Compose file.
description: Remove containers for services not defined in the Compose file
deprecated: false
hidden: false
experimental: false
@ -54,7 +54,7 @@ options:
value_type: bool
default_value: "false"
description: |
Remove named volumes declared in the "volumes" section of the Compose file and anonymous volumes attached to containers.
Remove named volumes declared in the "volumes" section of the Compose file and anonymous volumes attached to containers
deprecated: false
hidden: false
experimental: false

Просмотреть файл

@ -1,5 +1,5 @@
command: docker compose events
short: Receive real time events from containers.
short: Receive real time events from containers
long: |-
Stream container events for every container in the project.

Просмотреть файл

@ -1,5 +1,5 @@
command: docker compose exec
short: Execute a command in a running container.
short: Execute a command in a running container
long: |-
This is the equivalent of `docker exec` targeting a Compose service.
@ -13,7 +13,7 @@ options:
shorthand: d
value_type: bool
default_value: "false"
description: 'Detached mode: Run command in the background.'
description: 'Detached mode: Run command in the background'
deprecated: false
hidden: false
experimental: false
@ -34,7 +34,7 @@ options:
- option: index
value_type: int
default_value: "0"
description: index of the container if service has multiple replicas
description: Index of the container if service has multiple replicas
deprecated: false
hidden: false
experimental: false
@ -45,7 +45,7 @@ options:
shorthand: i
value_type: bool
default_value: "true"
description: Keep STDIN open even if not attached.
description: Keep STDIN open even if not attached
deprecated: false
hidden: true
experimental: false
@ -67,7 +67,7 @@ options:
- option: privileged
value_type: bool
default_value: "false"
description: Give extended privileges to the process.
description: Give extended privileges to the process
deprecated: false
hidden: false
experimental: false
@ -78,7 +78,7 @@ options:
shorthand: t
value_type: bool
default_value: "true"
description: Allocate a pseudo-TTY.
description: Allocate a pseudo-TTY
deprecated: false
hidden: true
experimental: false
@ -88,7 +88,7 @@ options:
- option: user
shorthand: u
value_type: string
description: Run the command as this user.
description: Run the command as this user
deprecated: false
hidden: false
experimental: false
@ -98,7 +98,7 @@ options:
- option: workdir
shorthand: w
value_type: string
description: Path to workdir directory for this command.
description: Path to workdir directory for this command
deprecated: false
hidden: false
experimental: false

Просмотреть файл

@ -8,7 +8,7 @@ options:
- option: format
value_type: string
default_value: table
description: 'Format the output. Values: [table | json].'
description: 'Format the output. Values: [table | json]'
deprecated: false
hidden: false
experimental: false

Просмотреть файл

@ -1,5 +1,5 @@
command: docker compose kill
short: Force stop service containers.
short: Force stop service containers
long: |-
Forces running containers to stop by sending a `SIGKILL` signal. Optionally the signal can be passed, for example:
@ -13,7 +13,7 @@ options:
- option: remove-orphans
value_type: bool
default_value: "false"
description: Remove containers for services not defined in the Compose file.
description: Remove containers for services not defined in the Compose file
deprecated: false
hidden: false
experimental: false
@ -24,7 +24,7 @@ options:
shorthand: s
value_type: string
default_value: SIGKILL
description: SIGNAL to send to the container.
description: SIGNAL to send to the container
deprecated: false
hidden: false
experimental: false

Просмотреть файл

@ -1,6 +1,6 @@
command: docker compose logs
short: View output from containers
long: Displays log output from services.
long: Displays log output from services
usage: docker compose logs [OPTIONS] [SERVICE...]
pname: docker compose
plink: docker_compose.yaml
@ -9,7 +9,7 @@ options:
shorthand: f
value_type: bool
default_value: "false"
description: Follow log output.
description: Follow log output
deprecated: false
hidden: false
experimental: false
@ -29,7 +29,7 @@ options:
- option: no-color
value_type: bool
default_value: "false"
description: Produce monochrome output.
description: Produce monochrome output
deprecated: false
hidden: false
experimental: false
@ -39,7 +39,7 @@ options:
- option: no-log-prefix
value_type: bool
default_value: "false"
description: Don't print prefix in logs.
description: Don't print prefix in logs
deprecated: false
hidden: false
experimental: false
@ -61,7 +61,7 @@ options:
value_type: string
default_value: all
description: |
Number of lines to show from the end of the logs for each container.
Number of lines to show from the end of the logs for each container
deprecated: false
hidden: false
experimental: false
@ -72,7 +72,7 @@ options:
shorthand: t
value_type: bool
default_value: "false"
description: Show timestamps.
description: Show timestamps
deprecated: false
hidden: false
experimental: false

Просмотреть файл

@ -1,6 +1,6 @@
command: docker compose ls
short: List running compose projects
long: Lists running Compose projects.
long: Lists running Compose projects
usage: docker compose ls [OPTIONS]
pname: docker compose
plink: docker_compose.yaml
@ -18,7 +18,7 @@ options:
swarm: false
- option: filter
value_type: filter
description: Filter output based on conditions provided.
description: Filter output based on conditions provided
deprecated: false
hidden: false
experimental: false
@ -28,7 +28,7 @@ options:
- option: format
value_type: string
default_value: table
description: 'Format the output. Values: [table | json].'
description: 'Format the output. Values: [table | json]'
deprecated: false
hidden: false
experimental: false
@ -39,7 +39,7 @@ options:
shorthand: q
value_type: bool
default_value: "false"
description: Only display IDs.
description: Only display IDs
deprecated: false
hidden: false
experimental: false

Просмотреть файл

@ -1,6 +1,6 @@
command: docker compose port
short: Print the public port for a port binding.
long: Prints the public port for a port binding.
short: Print the public port for a port binding
long: Prints the public port for a port binding
usage: docker compose port [OPTIONS] SERVICE PRIVATE_PORT
pname: docker compose
plink: docker_compose.yaml
@ -8,7 +8,7 @@ options:
- option: index
value_type: int
default_value: "0"
description: index of the container if service has multiple replicas
description: Index of the container if service has multiple replicas
deprecated: false
hidden: false
experimental: false

Просмотреть файл

@ -35,7 +35,7 @@ options:
swarm: false
- option: filter
value_type: string
description: 'Filter services by a property (supported filters: status).'
description: 'Filter services by a property (supported filters: status)'
details_url: '#filter'
deprecated: false
hidden: false

Просмотреть файл

@ -1,8 +1,7 @@
command: docker compose pull
short: Pull service images
long: |-
Pulls an image associated with a service defined in a `compose.yaml` file, but does not start containers based on
those images.
long: |
Pulls an image associated with a service defined in a `compose.yaml` file, but does not start containers based on those images
usage: docker compose pull [OPTIONS] [SERVICE...]
pname: docker compose
plink: docker_compose.yaml
@ -10,7 +9,7 @@ options:
- option: ignore-buildable
value_type: bool
default_value: "false"
description: Ignore images that can be built.
description: Ignore images that can be built
deprecated: false
hidden: false
experimental: false
@ -20,7 +19,7 @@ options:
- option: ignore-pull-failures
value_type: bool
default_value: "false"
description: Pull what it can and ignores images with pull failures.
description: Pull what it can and ignores images with pull failures
deprecated: false
hidden: false
experimental: false
@ -30,7 +29,7 @@ options:
- option: include-deps
value_type: bool
default_value: "false"
description: Also pull services declared as dependencies.
description: Also pull services declared as dependencies
deprecated: false
hidden: false
experimental: false
@ -40,7 +39,7 @@ options:
- option: no-parallel
value_type: bool
default_value: "true"
description: DEPRECATED disable parallel pulling.
description: DEPRECATED disable parallel pulling
deprecated: false
hidden: true
experimental: false
@ -50,7 +49,7 @@ options:
- option: parallel
value_type: bool
default_value: "true"
description: DEPRECATED pull multiple images in parallel.
description: DEPRECATED pull multiple images in parallel
deprecated: false
hidden: true
experimental: false
@ -59,7 +58,7 @@ options:
swarm: false
- option: policy
value_type: string
description: Apply pull policy ("missing"|"always").
description: Apply pull policy ("missing"|"always")
deprecated: false
hidden: false
experimental: false
@ -70,7 +69,7 @@ options:
shorthand: q
value_type: bool
default_value: "false"
description: Pull without printing progress information.
description: Pull without printing progress information
deprecated: false
hidden: false
experimental: false

Просмотреть файл

@ -18,7 +18,7 @@ options:
- option: no-deps
value_type: bool
default_value: "false"
description: Don't restart dependent services.
description: Don't restart dependent services
deprecated: false
hidden: false
experimental: false

Просмотреть файл

@ -1,5 +1,5 @@
command: docker compose run
short: Run a one-off command on a service.
short: Run a one-off command on a service
long: |-
Runs a one-time command against a service.
@ -61,7 +61,7 @@ options:
- option: build
value_type: bool
default_value: "false"
description: Build image before starting container.
description: Build image before starting container
deprecated: false
hidden: false
experimental: false
@ -121,7 +121,7 @@ options:
shorthand: i
value_type: bool
default_value: "true"
description: Keep STDIN open even if not attached.
description: Keep STDIN open even if not attached
deprecated: false
hidden: false
experimental: false
@ -152,7 +152,7 @@ options:
shorthand: T
value_type: bool
default_value: "true"
description: 'Disable pseudo-TTY allocation (default: auto-detected).'
description: 'Disable pseudo-TTY allocation (default: auto-detected)'
deprecated: false
hidden: false
experimental: false
@ -162,7 +162,7 @@ options:
- option: no-deps
value_type: bool
default_value: "false"
description: Don't start linked services.
description: Don't start linked services
deprecated: false
hidden: false
experimental: false
@ -173,7 +173,7 @@ options:
shorthand: p
value_type: stringArray
default_value: '[]'
description: Publish a container's port(s) to the host.
description: Publish a container's port(s) to the host
deprecated: false
hidden: false
experimental: false
@ -183,7 +183,7 @@ options:
- option: quiet-pull
value_type: bool
default_value: "false"
description: Pull without printing progress information.
description: Pull without printing progress information
deprecated: false
hidden: false
experimental: false
@ -193,7 +193,7 @@ options:
- option: remove-orphans
value_type: bool
default_value: "false"
description: Remove containers for services not defined in the Compose file.
description: Remove containers for services not defined in the Compose file
deprecated: false
hidden: false
experimental: false
@ -215,7 +215,7 @@ options:
value_type: bool
default_value: "false"
description: |
Run command with all service's ports enabled and mapped to the host.
Run command with all service's ports enabled and mapped to the host
deprecated: false
hidden: false
experimental: false
@ -226,7 +226,7 @@ options:
shorthand: t
value_type: bool
default_value: "true"
description: Allocate a pseudo-TTY.
description: Allocate a pseudo-TTY
deprecated: false
hidden: true
experimental: false
@ -237,7 +237,7 @@ options:
value_type: bool
default_value: "false"
description: |
Use the service's network useAliases in the network(s) the container connects to.
Use the service's network useAliases in the network(s) the container connects to
deprecated: false
hidden: false
experimental: false
@ -258,7 +258,7 @@ options:
shorthand: v
value_type: stringArray
default_value: '[]'
description: Bind mount a volume.
description: Bind mount a volume
deprecated: false
hidden: false
experimental: false

Просмотреть файл

@ -8,7 +8,7 @@ options:
- option: no-deps
value_type: bool
default_value: "false"
description: Don't start linked services.
description: Don't start linked services
deprecated: false
hidden: false
experimental: false

Просмотреть файл

@ -1,6 +1,6 @@
command: docker compose start
short: Start services
long: Starts existing containers for a service.
long: Starts existing containers for a service
usage: docker compose start [SERVICE...]
pname: docker compose
plink: docker_compose.yaml

Просмотреть файл

@ -1,6 +1,6 @@
command: docker compose top
short: Display the running processes
long: Displays the running processes.
long: Displays the running processes
usage: docker compose top [SERVICES...]
pname: docker compose
plink: docker_compose.yaml

Просмотреть файл

@ -1,6 +1,6 @@
command: docker compose unpause
short: Unpause services
long: Unpauses paused containers of a service.
long: Unpauses paused containers of a service
usage: docker compose unpause [SERVICE...]
pname: docker compose
plink: docker_compose.yaml

Просмотреть файл

@ -59,7 +59,7 @@ options:
- option: attach-dependencies
value_type: bool
default_value: "false"
description: Automatically attach to log output of dependent services.
description: Automatically attach to log output of dependent services
deprecated: false
hidden: false
experimental: false
@ -69,7 +69,7 @@ options:
- option: build
value_type: bool
default_value: "false"
description: Build images before starting containers.
description: Build images before starting containers
deprecated: false
hidden: false
experimental: false
@ -101,7 +101,7 @@ options:
value_type: bool
default_value: "false"
description: |
Recreate containers even if their configuration and image haven't changed.
Recreate containers even if their configuration and image haven't changed
deprecated: false
hidden: false
experimental: false
@ -111,7 +111,7 @@ options:
- option: no-attach
value_type: stringArray
default_value: '[]'
description: Do not attach (stream logs) to the specified services.
description: Do not attach (stream logs) to the specified services
deprecated: false
hidden: false
experimental: false
@ -121,7 +121,7 @@ options:
- option: no-build
value_type: bool
default_value: "false"
description: Don't build an image, even if it's policy.
description: Don't build an image, even if it's policy
deprecated: false
hidden: false
experimental: false
@ -131,7 +131,7 @@ options:
- option: no-color
value_type: bool
default_value: "false"
description: Produce monochrome output.
description: Produce monochrome output
deprecated: false
hidden: false
experimental: false
@ -141,7 +141,7 @@ options:
- option: no-deps
value_type: bool
default_value: "false"
description: Don't start linked services.
description: Don't start linked services
deprecated: false
hidden: false
experimental: false
@ -151,7 +151,7 @@ options:
- option: no-log-prefix
value_type: bool
default_value: "false"
description: Don't print prefix in logs.
description: Don't print prefix in logs
deprecated: false
hidden: false
experimental: false
@ -172,7 +172,7 @@ options:
- option: no-start
value_type: bool
default_value: "false"
description: Don't start the services after creating them.
description: Don't start the services after creating them
deprecated: false
hidden: false
experimental: false
@ -192,7 +192,7 @@ options:
- option: quiet-pull
value_type: bool
default_value: "false"
description: Pull without printing progress information.
description: Pull without printing progress information
deprecated: false
hidden: false
experimental: false
@ -202,7 +202,7 @@ options:
- option: remove-orphans
value_type: bool
default_value: "false"
description: Remove containers for services not defined in the Compose file.
description: Remove containers for services not defined in the Compose file
deprecated: false
hidden: false
experimental: false
@ -214,7 +214,7 @@ options:
value_type: bool
default_value: "false"
description: |
Recreate anonymous volumes instead of retrieving data from the previous containers.
Recreate anonymous volumes instead of retrieving data from the previous containers
deprecated: false
hidden: false
experimental: false
@ -237,7 +237,7 @@ options:
value_type: int
default_value: "0"
description: |
Use this timeout in seconds for container shutdown when attached or when containers are already running.
Use this timeout in seconds for container shutdown when attached or when containers are already running
deprecated: false
hidden: false
experimental: false
@ -247,7 +247,7 @@ options:
- option: timestamps
value_type: bool
default_value: "false"
description: Show timestamps.
description: Show timestamps
deprecated: false
hidden: false
experimental: false
@ -267,7 +267,7 @@ options:
- option: wait-timeout
value_type: int
default_value: "0"
description: Maximum duration to wait for the project to be running|healthy.
description: Maximum duration to wait for the project to be running|healthy
deprecated: false
hidden: false
experimental: false

Просмотреть файл

@ -18,7 +18,7 @@ options:
- option: short
value_type: bool
default_value: "false"
description: Shows only Compose's version number.
description: Shows only Compose's version number
deprecated: false
hidden: false
experimental: false

Просмотреть файл

@ -170,7 +170,7 @@ func (s *composeService) build(ctx context.Context, project *types.Project, opti
}
if options.Memory != 0 {
fmt.Fprintln(s.stderr(), "WARNING: --memory is not supported by BuildKit and will be ignored.")
fmt.Fprintln(s.stderr(), "WARNING: --memory is not supported by BuildKit and will be ignored")
}
buildOptions, err := s.toBuildOptions(project, service, options)