Hi
In my SSL enabled server, socket.io is unable to communicate back to Drupal site. Both node.js and drupal are in the same server.
and all the components of npm are of latest version.
I gone through all the existing issue list and tried with different possible values for nodejs.config.js file. Nothing worked out. Please help

I see this error in chrome:
GET https://localhost:8080/socket.io/socket.io.js net::ERR_CONNECTION_REFUSED

Contents from nodejs config file:
backendSettings = {
scheme: 'https',
host: 'localhost',
resource: '/socket.io',
serviceKey: '',
backend: {
port: 443,
scheme: 'https',
host: 'domainname.com',
messagePath: '/nodejs/message'
},
debug: true,
sslKeyPath: ‘/path/to/keyfile’,
sslCertPath: ‘/path/to/certfile’,
sslCAPath: '',
baseAuthPath: '/nodejs/',
publishUrl: 'publish',
kickUserUrl: 'user/kick/:uid',
logoutUserUrl: 'user/logout/:authtoken',
addUserToChannelUrl: 'user/channel/add/:channel/:uid',
removeUserFromChannelUrl: 'user/channel/remove/:channel/:uid',
addChannelUrl: 'channel/add/:channel',
removeChannelUrl: 'channel/remove/:channel',
setUserPresenceListUrl: 'user/presence-list/:uid/:uidList',
addAuthTokenToChannelUrl: 'authtoken/channel/add/:channel/:uid',
removeAuthTokenFromChannelUrl: 'authtoken/channel/remove/:channel/:uid',
toggleDebugUrl: 'debug/toggle',
contentTokenUrl: 'content/token',
publishMessageToContentChannelUrl: 'content/token/message',
extensions: [],
clientsCanWriteToChannels: false,
clientsCanWriteToClients: false,
transports: ['websocket', 'polling'],
jsMinification: true,
jsEtag: true,
logLevel: 1
};

Comments

saptha created an issue. See original summary.

saptha’s picture

Issue summary: View changes
saptha’s picture

Status: Active » Closed (works as designed)

It turned out to be issue with port. I opened the port, restarted the iptables,
Then changed the host to domainname.com as follows.

backendSettings = {
scheme: 'https',
host: 'domainname.com',
resource: '/socket.io',
serviceKey: '',
backend: {
port: 443,
scheme: 'https',
host: 'domainname.com',
messagePath: '/nodejs/message'
},
debug: true,
......
...

Probably this update might help someone.
Regards
Saptha