I'm trying to connect to my Socket.IO server, but the connection couldn't be made. It works without HTTPS. I created the pem and crt file with openssl
command, I also have opened port 3300
through Firewall.
var https = require('https');
var options = {
key: fs.readFileSync('file.pem'),
cert: fs.readFileSync('file.crt')
};
var app = https.createServer(options);
io.listen(app);
app.listen('3300');
Calling the server/url.
io('https://example.com:3300');
NodeJS is just as a backend, I'm not using express or anything on there.
via Jordn
No comments:
Post a Comment