I am trying to understand how authentication is working within blockstack and so I am trying to follow Hello-World tutorials and I got an error as below and I appreciate your support to solve:
yo blockstack
/usr/lib/node_modules/yo/node_modules/write-file-atomic/index.js:197
throw err
^
Error: EACCES: permission denied, open '/root/.config/insight-nodejs/insight-yo.json.412770396'
at Error (native)
at Object.fs.openSync (fs.js:642:18)
at Function.writeFileSync [as sync] (/usr/lib/node_modules/yo/node_modules/write-file-atomic/index.js:180:17)
at Conf.set store [as store] (/usr/lib/node_modules/yo/node_modules/conf/index.js:142:19)
at Conf.set (/usr/lib/node_modules/yo/node_modules/conf/index.js:64:14)
at Insight.set optOut [as optOut] (/usr/lib/node_modules/yo/node_modules/insight/lib/index.js:56:15)
at Object.<anonymous> (/usr/lib/node_modules/yo/lib/cli.js:198:18)
at Module._compile (module.js:577:32)
at Object.Module._extensions..js (module.js:586:10)
at Module.load (module.js:494:32)
I am not sure this is the case, but I think you may need to use βsudoβ (or whatever the equivalent would be for your operating system) with your commands, if npm is not installed globally.
It is possible if you installed npm just for this project, it was installed locally.
Can you try
$ npm list -g
to see if the associated modules are installed globally or locally?
-g indicates a global install.
You may be able to troubleshoot further based on this knowledge.
For who faced the same issue of permissions, It is solved by using normal user. The OS is Centos . @retired_user I faced another issue if you can support. After Installation and run npm start I got the below error: npm start
> [email protected] start /home/blockstack/hello-world-tutorial
> npm run browserify && node server.js
> [email protected] browserify /home/blockstack/hello-world-tutorial
> browserify requires.js -o public/bundle.js
server is listening on 5000
(node:7028) UnhandledPromiseRejectionWarning: Unhandled promise rejection (rejection id: 1): Error: Exited with code 3