通过Vagrant的配置文件问题安装node-inspector

时间:2017-06-10 11:17:49

标签: node.js ubuntu vagrant virtualbox node-inspector

我无法通过Vagrant up配置成功安装node-inspector。

我的配置文件包含以下命令:

  • npm install -g n --unsafe-perm
  • sudo n v8.0.0
  • sudo npm cache clean -f
  • sudo npm install -g node-inspector --unsafe-perm

但是,安装node-inspector的部分不断出错:

 6777 info lifecycle v8-profiler@5.7.0~install: v8-profiler@5.7.0
 6778 verbose lifecycle v8-profiler@5.7.0~install: unsafe-perm in lifecycle true
 6779 verbose lifecycle v8-profiler@5.7.0~install: PATH: /usr/local/lib/node_modules/npm/bin/node-gyp-bin:/usr/local/lib/node_modules/node-inspector/node_modules/v8-profiler/node_modules/.bin:/usr/local/lib/node_modules/node-inspector/node_modules/.bin:/usr/local/lib/node_modules/.bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
 6780 verbose lifecycle v8-profiler@5.7.0~install: CWD: /usr/local/lib/node_modules/node-inspector/node_modules/v8-profiler
 6781 silly lifecycle v8-profiler@5.7.0~install: Args: [ '-c', 'node-pre-gyp install --fallback-to-build' ]
 6782 silly lifecycle v8-profiler@5.7.0~install: Returned: code: 0  signal: null
 6783 silly install v8-debug@1.0.1
 6784 info lifecycle v8-debug@1.0.1~install: v8-debug@1.0.1
 6785 verbose lifecycle v8-debug@1.0.1~install: unsafe-perm in lifecycle true
 6786 verbose lifecycle v8-debug@1.0.1~install: PATH: /usr/local/lib/node_modules/npm/bin/node-gyp-bin:/usr/local/lib/node_modules/node-inspector/node_modules/v8-debug/node_modules/.bin:/usr/local/lib/node_modules/node-inspector/node_modules/.bin:/usr/local/lib/node_modules/.bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
 6787 verbose lifecycle v8-debug@1.0.1~install: CWD: /usr/local/lib/node_modules/node-inspector/node_modules/v8-debug
 6788 silly lifecycle v8-debug@1.0.1~install: Args: [ '-c', 'node-pre-gyp install --fallback-to-build' ]
 6789 silly lifecycle v8-debug@1.0.1~install: Returned: code: 1  signal: null
 6790 info lifecycle v8-debug@1.0.1~install: Failed to exec install script
 6791 verbose unlock done using /root/.npm/_locks/staging-3a08f0df5026584d.lock for /usr/local/lib/node_modules/.staging
 6792 verbose stack Error: v8-debug@1.0.1 install: `node-pre-gyp install --fallback-to-build`
 6792 verbose stack Exit status 1
 6792 verbose stack     at EventEmitter.<anonymous> (/usr/local/lib/node_modules/npm/lib/utils/lifecycle.js:283:16)
 6792 verbose stack     at emitTwo (events.js:125:13)
 6792 verbose stack     at EventEmitter.emit (events.js:213:7)
 6792 verbose stack     at ChildProcess.<anonymous> (/usr/local/lib/node_modules/npm/lib/utils/spawn.js:40:14)
 6792 verbose stack     at emitTwo (events.js:125:13)
 6792 verbose stack     at ChildProcess.emit (events.js:213:7)
 6792 verbose stack     at maybeClose (internal/child_process.js:887:16)
 6792 verbose stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:208:5)
 6793 verbose pkgid v8-debug@1.0.1
 6794 verbose cwd /home/vagrant
 6795 verbose Linux 3.13.0-24-generic
 6796 verbose argv "/usr/local/bin/node" "/usr/local/bin/npm" "install" "-g" "node-inspector" "--unsafe-perm"
 6797 verbose node v8.0.0
 6798 verbose npm  v5.0.0
 6799 error code ELIFECYCLE
 6800 error errno 1
 6801 error v8-debug@1.0.1 install: `node-pre-gyp install --fallback-to-build`
 6801 error Exit status 1
 6802 error Failed at the v8-debug@1.0.1 install script.
 6802 error This is probably not a problem with npm. There is likely additional logging output above.
 6803 verbose exit [ 1, true ]

我正在使用Vagrant的VM.box&#34; urban / trusty64-node&#34;。我的主机是Mac OS X(安装流浪者)。

0 个答案:

没有答案