Closed Bug 1164175 Opened 9 years ago Closed 9 years ago

docker-worker: Don't include 'docker pull' progress output in logs

Categories

(Taskcluster :: Workers, defect)

defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: dustin, Assigned: eggylv999)

References

(Blocks 1 open bug)

Details

Attachments

(1 file)

53 bytes, text/x-github-pull-request
garndt
: review+
Details | Review
> 706766fe1019 - Downloading [>                                                  ] 527.2 kB/65.76 MB 21s
> 706766fe1019 - Downloading [>                                                  ] 1.054 MB/65.76 MB 14s
> 706766fe1019 - Downloading [=>                                                 ] 1.593 MB/65.76 MB 11s

etc. etc. etc.

it'd be nice to silence this, without silencing the actual *useful* output from docker pull.
This should be done: https://github.com/taskcluster/dockerode-process
We can do whatever we want, it's mostly just a matter of decide what is useful and what isn't useful.

If when viewing logs we respect backspace characters we could print this in a way where we delete previous status pages... Or something, I'm not sure what works best.
Summary: Don't include 'docker pull' progress output in logs → docker-worker: Don't include 'docker pull' progress output in logs
Do you mean that you've already done something to address this?  Because I don't see a commit to that repo since 2014..

I had been hoping docker pull had a --no-progress option, but that does not appear to be the case.  The --log-level seems not to affect it, either.

A generic \r -> delete-to-last-newline translation would do the trick, and likely be useful for other purposes, so I'll see if that would work.
No, we've done anything... But it is our code the makes the ugly things :)
We used to have a bug for cleaning it up, but it might have drowned or nobody cared to solve it.

The code that prints this ugly stuff is right here:
https://github.com/taskcluster/dockerode-process/blob/300bbc93ed56e1046b63a7fb9911ec91b7b89967/utils.js#L14-L43

We maintain this repository, if anyone feels like refactoring to print something nicer it straightforward.
Silencing it is just making _transform: function() {return done();}
We would should probably print something useful, like errors, layers, speed and time used downloading.
(But maybe we don't need the progress updates, or maybe we should delete them with backspace).

Note, docker-worker doesn't wrap the docker cli tool, we interface the docker unix domain socket and communicate with the docker daemon using the remote HTTP interface. So anything we print to log from pulling is purely our fault.
Assignee: dustin → nobody
Blocks: logspam
https://github.com/taskcluster/dockerode-process/pull/7
Assignee: nobody → eggylv999
Status: NEW → ASSIGNED
Component: TaskCluster → Docker-Worker
Product: Testing → Taskcluster
Attached file PR to fix the bug
Attachment #8634364 - Flags: review?(garndt)
Comment on attachment 8634364 [details] [review]
PR to fix the bug

Looks good. Individual layer progress is now a thing of the past and I see we just log the time each layer took. Still some noise in the logs but should be much less now.
Attachment #8634364 - Flags: review?(garndt) → review+
Status: ASSIGNED → RESOLVED
Closed: 9 years ago
Resolution: --- → FIXED
Component: Docker-Worker → Workers
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: