Я сделал API-интерфейс nodejs, и он работает нормально, когда я запускаю его локально.Однако, когда я пытаюсь запустить его на облачном сервере Google, он выдает некоторые ошибки в запросе на вход в систему.
Error: secretOrPrivateKey must have a value
at Object.module.exports [as sign] (/home/labssimplifii/kiran/ProductCatalogue/productapi/node_modules/jsonwebtoken/sign.js:107:20)
at bcrypt.compare (/home/labssimplifii/kiran/ProductCatalogue/productapi/api/routes/user.js:57:23)
npm ERR! Linux 4.15.0-1028-gcp
npm ERR! argv "/usr/bin/node" "/usr/bin/npm" "start"
npm ERR! node v6.17.1
npm ERR! npm v3.10.10
npm ERR! code ELIFECYCLE
npm ERR! productapi@1.0.0 start: `node server.js`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the productapi@1.0.0 start script 'node server.js'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the productapi package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! node server.js
npm ERR! You can get information on how to open an issue for this project with:
npm ERR! npm bugs productapi
npm ERR! Or if that isn't available, you can get their info via:
npm ERR! npm owner ls productapi
npm ERR! There is likely additional logging output above.
npm ERR! Please include the following file with any support request:
npm ERR! /home/labssimplifii/kiran/ProductCatalogue/productapi/npm-debug.log
Это ошибка, и запрос на вход в систему работает нормальноместный