Fixed local server and grunt build with require.js and established socket connection between client and server