MCPcopy
hub / github.com/docker/compose / runVolumes

Function runVolumes

cmd/compose/config.go:384–398  ·  view source on GitHub ↗
(ctx context.Context, dockerCli command.Cli, opts configOptions)

Source from the content-addressed store, hash-verified

382}
383
384func runVolumes(ctx context.Context, dockerCli command.Cli, opts configOptions) error {
385 backend, err := compose.NewComposeService(dockerCli)
386 if err != nil {
387 return err
388 }
389
390 project, _, err := opts.ProjectOptions.ToProject(ctx, dockerCli, backend, nil, cli.WithoutEnvironmentResolution)
391 if err != nil {
392 return err
393 }
394 for n := range project.Volumes {
395 _, _ = fmt.Fprintln(dockerCli.Out(), n)
396 }
397 return nil
398}
399
400func runNetworks(ctx context.Context, dockerCli command.Cli, opts configOptions) error {
401 backend, err := compose.NewComposeService(dockerCli)

Callers 1

configCommandFunction · 0.85

Calls 3

NewComposeServiceFunction · 0.92
ToProjectMethod · 0.45
OutMethod · 0.45

Tested by

no test coverage detected