Is it possible to make failing RUN command's output visible with docker build?

In Dockerfile there is :

RUN [cmd]

When [cmd] fails it normally prints output to stderr and to log but since the Dockerfile is processed by

docker build command the output is suppressed and the log is lost with the container’s context.

Is it possible to make failing command’s output visible with docker build?

I’d try changing the RUN line to:

RUN [cmd]; cat [logfile]

1 Like

That helps. Thanks!

Regards

Vilho