Hey there! I am trying to accelerate my python pro...
# general
c
Hey there! I am trying to accelerate my python projects (we already using pants to package everything with Docker) I would like to see what is happening in the Docker build phase, even if I run
pants -ldebug package ...
I get the
[DEBUG] spawned local process as Some(2605) for Process { argv: ["/usr/bin/docker", "build" ...
message and then
ā “ 79.65s Building docker image
during the build Process, is there a way to expose the logs to see the steps and the layers of the build to see what is taking time and how I can optimize it ? Thanks in advance.
c
the stdout/stderr from a process invoked by Pants is buffered and not returned until the process exits, so you should see the build log, but it will be all at once at the end, and only when running with
-ldebug
.
c
Thanks, I will check in the logs after the building process is done, is there any way to force the
--cache-from
argument in the docker build command ?
c
b
I think
docker_image
might support logging the output somehow. I’m on my phone so cannot check the docs, but hopefully you can find it!
c
@broad-processor-92400 I get the logs after the process is done, so no need to investigate further. Thanks šŸ™‚
šŸ‘ 1