Skip to content

Commit

Permalink
fix: restore job logger for clean-up tasks after cancellation
Browse files Browse the repository at this point in the history
Co-authored-by: Markus Wolf <markus.wolf@new-work.se>
  • Loading branch information
2 people authored and github-actions committed Jul 21, 2022
1 parent a255cf8 commit 65bb9bb
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pkg/runner/job_executor.go
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ func newJobExecutor(info jobInfo, sf stepFactory, rc *RunContext) common.Executo
if ctx.Err() == context.Canceled {
// in case of an aborted run, we still should execute the
// post steps to allow cleanup.
ctx, cancel = context.WithTimeout(context.Background(), 5*time.Minute)
ctx, cancel = context.WithTimeout(WithJobLogger(context.Background(), rc.Run.JobID, rc.String(), rc.Config, &rc.Masks), 5*time.Minute)
defer cancel()
}
return postExecutor(ctx)
Expand Down

0 comments on commit 65bb9bb

Please sign in to comment.