You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I would like to be able to call docker run and use the output as a stream. For example: waiting for a specific log emitted by a server process.
Thank you for this wonderful library.
Hey, if I understand correctly this is the "echo" option. I meant getting a stream that is accessible for the user.
API Proposals
Async iterator:
construn=docker.command(`run exampleImage`,{stream: true});for(constawaitlineofrun){// use line here}
Old fashioned stream
construn=docker.command(`run exampleImage`,{stream: true});run.stdout.on("data",(buffer)=>{constline=buffer.toString();// use line here})
+1 this is a good idea @iddan . did you find a solution for this? I am trying to use this to execute some terraform scripts where it is expected to take a while for the docker command to run. however, i would like to receive the output somehow as the process is running so i can stream it back to the user via rabbitmq.
Activity
mattqs commentedon Jul 26, 2020
Does this help?
Added the ability to stream 'stdout' and 'stderr' from docker command.
2cd8af5
iddan commentedon Jul 26, 2020
Hey, if I understand correctly this is the "echo" option. I meant getting a stream that is accessible for the user.
API Proposals
Async iterator:
Old fashioned stream
kuboraam commentedon Jul 8, 2022
+1 this is a good idea @iddan . did you find a solution for this? I am trying to use this to execute some terraform scripts where it is expected to take a while for the docker command to run. however, i would like to receive the output somehow as the process is running so i can stream it back to the user via rabbitmq.
Ciao121 commentedon Oct 30, 2023
+1 for this