code for the remote node server