You can do this multiple ways:
- Start the process via a startup task
- Start the process from the role entry point.
For #1, if you were seeing the role hanging/cycling then it is because of a bug in your startup task, not because Azure prevents you from running a socket.io script. See http://blogs.msdn.com/b/kwill/archive/2013/08/09/windows-azure-paas-compute-diagnostics-data.aspx for how to troubleshoot this issue, in particular the Troubleshooting Scenario 2 (http://blogs.msdn.com/b/kwill/archive/2013/08/26/troubleshooting-scenario-2-role-recycling-after-running-fine-for-2-weeks.aspx). Also, make sure you set the startup task as background so that the host bootstrapper is not waiting for the process to exit before continuing with the role startup process.
For #2, you would have to either modify node.cmd to spawn two processes, or switch to use a different role entry point and have that role entry point start the node.cmd along with your other script.