Store Community Support Documentation
Viewing Single Post

Hi i try to setup IM Chat in a new cloud server with Ubuntu. i follow the tutorial here all when good until i run the last command (node index.js) to start the Node.js server.

node index.js


/im/server/index.js:13         throw new Error('privateKey not found.')         ^

Error: privateKey not found.     at Object. (/im/server/index.js:13:15)     at Module._compile (module.js:652:30)     at Object.Module._extensions..js (module.js:663:10)     at Module.load (module.js:565:32)     at tryModuleLoad (module.js:505:12)     at Function.Module._load (module.js:497:3)     at Function.Module.runMain (module.js:693:10)     at startup (bootstrap_node.js:188:16)     at bootstrap_node.js:609:3

this is my settings in config.js

module.exports = {     port: 3000,     is_hosted: false,     chat_server_key: "stringkey_blabla",     secure: true, // use ssl ?     privateKey: "./opt/psa/var/modules/letsencrypt/etc/archive/", // path to private key ?     cert: "./opt/psa/var/modules/letsencrypt/etc/live/",  // path to cert key ?     firebase: {         serverKey: "",         senderId: ""     },     redis: {         host: '',         port: 6379,         password: 'my_host_password'     } };

i use plesk panel with Lets Encrypt for certificate, is that could be the problem that my certificate form is in *.pem and not in *.crt  ????

Instant Messaging Settings

Provide your Node JS server:
Provide your Node JS server key: stringkey_blabla

Last update on July 15, 7:21 pm by Hellas.
Be the first person to like this.