gpt4 book ai didi

node.js - npm 安装 Fabric-ca-client 失败

转载 作者:太空宇宙 更新时间:2023-11-03 23:25:15 24 4
gpt4 key购买 nike

我们在 CentOS 7.3 和 RHEL 7.3 上尝试安装最新的 NodeJs Fabric-ca-client 时遇到问题

以下是完整列表:

sudo npm install -g fabric-ca-client@1.0.0

> x509@0.3.2 install /usr/lib/node_modules/fabric-ca-client/node_modules/x509
> node-gyp rebuild

gyp ERR! clean error
gyp ERR! stack Error: EACCES: permission denied, rmdir 'build'
gyp ERR! stack at Error (native)
gyp ERR! System Linux 3.10.0-514.el7.x86_64
gyp ERR! command "/usr/bin/node" "/usr/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /usr/lib/node_modules/fabric-ca-client/node_modules/x509
gyp ERR! node -v v6.11.0
gyp ERR! node-gyp -v v3.6.2
gyp ERR! not ok
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! x509@0.3.2 install: `node-gyp rebuild`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the x509@0.3.2 install script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR! /root/.npm/_logs/2017-07-19T14_02_06_503Z-debug.log

2017-07-19T14_02_06_503Z-debug.log 中的列表包含以下内容:

1666 silly install x509@0.3.2
1667 info lifecycle x509@0.3.2~install: x509@0.3.2
1668 verbose lifecycle x509@0.3.2~install: unsafe-perm in lifecycle false
1669 verbose lifecycle x509@0.3.2~install: PATH: /usr/lib/node_modules/npm/bin/node-gyp-bin:/usr/lib/node_modules/fabric-ca-client/node_modules/x509/node_modules/.bin:/usr/lib/node_modules/fabric-ca-client/node_modules/.bin:/usr/lib/node_modules/.bin:/sbin:/bin:/usr/sbin:/usr/bin
1670 verbose lifecycle x509@0.3.2~install: CWD: /usr/lib/node_modules/fabric-ca-client/node_modules/x509
1671 silly lifecycle x509@0.3.2~install: Args: [ '-c', 'node-gyp rebuild' ]
1672 silly lifecycle x509@0.3.2~install: Returned: code: 1 signal: null
1673 info lifecycle x509@0.3.2~install: Failed to exec install script
1674 verbose unlock done using /root/.npm/_locks/staging-a072192f34a17023.lock for /usr/lib/node_modules/.staging
1675 verbose stack Error: x509@0.3.2 install: `node-gyp rebuild`
1675 verbose stack Exit status 1
1675 verbose stack at EventEmitter.<anonymous> (/usr/lib/node_modules/npm/lib/utils/lifecycle.js:289:16)
1675 verbose stack at emitTwo (events.js:106:13)
1675 verbose stack at EventEmitter.emit (events.js:191:7)
1675 verbose stack at ChildProcess.<anonymous> (/usr/lib/node_modules/npm/lib/utils/spawn.js:40:14)
1675 verbose stack at emitTwo (events.js:106:13)
1675 verbose stack at ChildProcess.emit (events.js:191:7)
1675 verbose stack at maybeClose (internal/child_process.js:891:16)
1675 verbose stack at Process.ChildProcess._handle.onexit (internal/child_process.js:226:5)
1676 verbose pkgid x509@0.3.2
1677 verbose cwd /home/ibmuser
1678 verbose Linux 3.10.0-514.el7.x86_64
1679 verbose argv "/usr/bin/node" "/bin/npm" "install" "-g" "fabric-ca-client@1.0.0"
1680 verbose node v6.11.0
1681 verbose npm v5.3.0
1682 error code ELIFECYCLE
1683 error errno 1
1684 error x509@0.3.2 install: `node-gyp rebuild`
1684 error Exit status 1
1685 error Failed at the x509@0.3.2 install script.
1685 error This is probably not a problem with npm. There is likely additional logging output above.

非常感谢任何帮助。提前致谢!

最佳答案

由于依赖包 x509 https://github.com/Southern/node-x509/issues/49 中存在已知问题,NodeJs 包 Fabric-ca-client 版本 1.0.0 似乎无法通过 root 全局安装。但它可以使用有效的 package.json 本地安装在 NodeJs 源文件夹中。

关于node.js - npm 安装 Fabric-ca-client 失败,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/45193218/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com