There is a node.js service listening on port:8080
and my asp.net mvc application needs to communicate with node.js service using socket.io
This works fine in local host. But getting 502 and 522 error codes after publishing both mvc and node.js projects in my AWS EC2 instance.
var jsonfile = require('jsonfile');
var app = require('express')();
var http = require('http').Server(app);
var XMLHttpRequest = require("xmlhttprequest").XMLHttpRequest;
var xhr = new XMLHttpRequest();
var querystring = require('querystring');
var io = require('socket.io')(http);
var uniqid = require('uniqid');
io.set('origins', 'www.mydomain.com:80');