Use fifo pipe and STDIN.gets listener in ci-client to keep open and close the netcat connection