Skip to content

Commit

Permalink
Wire logger through to config
Browse files Browse the repository at this point in the history
Currently we are only wiring the logger into run_linux.go
Not into the Config section.

This PR is needed in order to update vendor in Podman.
containers/podman#12375

[NO NEW TESTS NEEDED] Tests will be done in Podman.

Signed-off-by: Daniel J Walsh <[email protected]>
  • Loading branch information
rhatdan committed Dec 3, 2021
1 parent 6d01253 commit 5b1b0d2
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 0 deletions.
2 changes: 2 additions & 0 deletions buildah.go
Original file line number Diff line number Diff line change
Expand Up @@ -271,6 +271,8 @@ type BuilderOptions struct {
// to store copies of layer blobs that we pull down, if any. It should
// already exist.
BlobDirectory string
// Logger is the logrus logger to write log messages with
Logger *logrus.Logger `json:"-"`
// Mount signals to NewBuilder() that the container should be mounted
// immediately.
Mount bool
Expand Down
1 change: 1 addition & 0 deletions imagebuildah/stage_executor.go
Original file line number Diff line number Diff line change
Expand Up @@ -558,6 +558,7 @@ func (s *StageExecutor) prepare(ctx context.Context, from string, initializeIBCo
MaxPullRetries: s.executor.maxPullPushRetries,
PullRetryDelay: s.executor.retryPullPushDelay,
OciDecryptConfig: s.executor.ociDecryptConfig,
Logger: s.executor.logger,
}

builder, err = buildah.NewBuilder(ctx, s.executor.store, builderOptions)
Expand Down
1 change: 1 addition & 0 deletions new.go
Original file line number Diff line number Diff line change
Expand Up @@ -290,6 +290,7 @@ func newBuilder(ctx context.Context, store storage.Store, options BuilderOptions
Format: options.Format,
TempVolumes: map[string]bool{},
Devices: options.Devices,
Logger: options.Logger,
}

if options.Mount {
Expand Down

0 comments on commit 5b1b0d2

Please sign in to comment.