I'm trying to use the pv command in my Dockerfile but nothing is displayed on screen when I call the building process.
I made a very simple version of my Dockerfile :
FROM debian:jessie RUN apt-get update && apt-get install -y pv RUN echo "Lorem ipsum dolor sit amet, consectetur adipiscing elit." | pv -L 5 -s56 > /dev/null If I run the command in a simple terminal i've got this output :
35 B 0:00:07 [5.35 B/s] [================================================================> ] 62% ETA 0:00:04` But when I run my docker build like this docker build -t foo . I only got this :
Sending build context to Docker daemon 2.048 kB Step 1 : FROM debian:jessie ---> 040bf8e08425 Step 2 : RUN apt-get update && apt-get install -y pv ---> Using cache ---> 155e9ebf615f Step 3 : RUN echo "Lorem ipsum dolor sit amet, consectetur adipiscing elit." | pv -L 5 -s56 > /dev/null ---> Running in 3afdb7b5822c ---> 6fcf83d0cd02 Removing intermediate container 3afdb7b5822c Successfully built 6fcf83d0cd02 Is there a way to have this pv command to work ?
Thank you !
docker buildand as you have no CMD nor ENTRYPOINT in your Dockerfile, nothing happens, this is normal> /dev/nullpart. So why not the output ofpv? And the CMD and ENTRYPOINT are for the run process not for the build right ? Actually I'm lauching thebuildcommand not therunone-L 5option. And the output of echo command works too. The only output that don't work is the one ofpv. What is the diffrence between the waypvoutput something and the wayechodoes ?pvoutput isn't visible whereas theechooutput is?