(ctx context.Context, dockerCli command.Cli, backendOptions *BackendOptions, options commitOptions)
| 76 | } |
| 77 | |
| 78 | func runCommit(ctx context.Context, dockerCli command.Cli, backendOptions *BackendOptions, options commitOptions) error { |
| 79 | projectName, err := options.toProjectName(ctx, dockerCli) |
| 80 | if err != nil { |
| 81 | return err |
| 82 | } |
| 83 | |
| 84 | backend, err := compose.NewComposeService(dockerCli, backendOptions.Options...) |
| 85 | if err != nil { |
| 86 | return err |
| 87 | } |
| 88 | return backend.Commit(ctx, projectName, api.CommitOptions{ |
| 89 | Service: options.service, |
| 90 | Reference: options.reference, |
| 91 | Pause: options.pause, |
| 92 | Comment: options.comment, |
| 93 | Author: options.author, |
| 94 | Changes: options.changes, |
| 95 | Index: options.index, |
| 96 | }) |
| 97 | } |
no test coverage detected