Closed Bug 1567073 Opened 5 years ago Closed 5 years ago

generic-worker: consistently log executed commands and output / exit code from failed commands

Categories

(Taskcluster :: Workers, enhancement)

enhancement
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: pmoore, Assigned: pmoore, Mentored)

References

Details

(Keywords: good-first-bug)

Attachments

(1 file)

Throughout generic-worker code there are several places we execute native commands on the host, on all supported platforms. Sometimes we log the command we run, sometimes we don't, sometimes we collect output from stdout and stderr and log it if command fails, sometimes we don't.

We should have an exported function in a package somewhere that takes a command, logs it, executes it, writing the output from stdout and stderr to a temporary file, defers the deletion of that file, and if the command fails, logs the contents of the temporary file to the worker log, together with exit code. Then we should make sure that we use it everywhere where we currently execute commands on the local host.

Blocks: 1559777
Assignee: nobody → pmoore
Status: NEW → ASSIGNED

Released in generic-worker 15.1.3.

Status: ASSIGNED → RESOLVED
Closed: 5 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: