Receive commands over a socket and execute them in a terminal