Question

Normally CouchDB communicates with a view server over STDIO via a simple line-based protocol.

What I want to do is, instead of a view server, have it read and write to some sort of pipe or pseudo terminal, to which I then connect, and play the view server.

I think one way to do it is with a lot of complicated use of cat and FIFO's.

But I found out that on my Mac echo "hi" > /dev/ttys000 comes back to my terminal, so I was thinking it should be possible to establish a connection this way, but I can't tell from manpages how to do it for real.

[update] I found write, which sends message from couch to my terminal, but couch is not attached, so I can't send messages in return.

Was it helpful?

Solution

nc -l 12345

And then a regular netcat to connect to it.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top