I need to communicate with a background process via a named pipe. This background process is a node.js process.
So I do this in a shell script:
mkfifo MYPIPE node script.js < MYPIPE
what happens is that the node.js script does not start - it appears to be waiting for the first stdin message to be written to
What I want to do, is send the data from MYPIPE to the stdin of the node process, but I want to start the node.js process instead of it waiting for the first message from MYPIPE. How do I do that?