PHP项目流浪设置错误[安装的NodeJS步]
问题描述:
我正在使用VirtualBox上的流浪汉在WINDOWS 10我的PHP项目的设置,在命令行中当我打PHP项目流浪设置错误[安装的NodeJS步]
vagrant up
安装开始,在安装过程中在这一步
==> default: TASK [app : Angular - Install dependencies]
我得到这个错误
==> default: TASK [app : Angular - Install dependencies] ************************************
==> default: fatal: [10.91.0.102]: FAILED! => {"changed": true, "cmd": "npm install", "delta": "0:06:23.111672", "end": "2017-10-05 05:46:47.136976",
"failed": true, "msg": "non-zero return code", "rc": 185, "start": "2017-10-05 05:40:24.025304", "stderr": "npm WARN deprecated [email protected]:
Typings is deprecated in favor of NPM @types -- see README for more information\nnpm WARN deprecated [email protected]: Please update to minimatch 3.0.2 or higher to avoid a RegExp DoS issue\nnpm WARN optional
SKIPPING OPTIONAL DEPENDENCY: [email protected]^1.0.0 (node_modules/chokidar/node_modules/fsevents):\nnpm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for [email protected]: wanted {\"os\":\"darwin\",\"arch\":\"any\"}
(current: {\"os\":\"linux\",\"arch\":\"x64\"})\nnpm WARN [email protected] requires a peer of @angular/[email protected]>=4.3.0
but none was installed.\nnpm WARN [email protected] requires a peer of @angular/[email protected]>=4.3.0 but none was installed.\nnpm WARN [email protected] requires a peer of @angular/[email protected]>=4.3.0
but none was installed.\nnpm WARN [email protected] requires a peer of @angular/[email protected]>=4.3.0 but none was installed.\nnpm WARN [email protected] requires a peer of [email protected]>=5.4.3
but none was installed.\nnpm WARN [email protected] requires a peer of [email protected]>=2.4.2 but none was installed.\nnpm ERR! Linux 3.13.0-132-generic\nnpm ERR! argv \"/usr/local/bin/node\" \"/usr/local/bin/npm\"
\"install\"\nnpm ERR! node v7.0.0\nnpm ERR! npm v3.10.8\nnpm ERR! path ../typescript/bin/tsserver\nnpm ERR! code EPROTO\nnpm ERR! errno -71\nnpm ERR! syscall symlink\n\nnpm
ERR! EPROTO: protocol error, symlink '../typescript/bin/tsserver' -> '/vagrant/angular_admin/node_modules/@angular-devkit/build-optimizer/node_modules/.bin/tsserver'\nnpm ERR! \nnpm ERR! If you need help,
you may report this error at:\nnpm ERR! <https://github.com/npm/npm/issues>\n\nnpm ERR! Please include the following file with any support request:\nnpm ERR!
/vagrant/angular_admin/npm-debug.log", "stderr_lines": ["npm WARN deprecated [email protected]: Typings is deprecated in favor of NPM @types -- see README for more information", "npm WARN deprecated [email protected]:
Please update to minimatch 3.0.2 or higher to avoid a RegExp DoS issue", "npm WARN optional SKIPPING OPTIONAL DEPENDENCY: [email protected]^1.0.0 (node_modules/chokidar/node_modules/fsevents):",
"npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for [email protected]: wanted {\"os\":\"darwin\",\"arch\":\"any\"} (current: {\"os\":\"linux\",\"arch\":\"x64\"})", "npm WARN [email protected]
requires a peer of @angular/[email protected]>=4.3.0 but none was installed.", "npm WARN [email protected] requires a peer of @angular/[email protected]>=4.3.0 but none was installed.", "npm WARN [email protected]
requires a peer of @angular/[email protected]>=4.3.0 but none was installed.", "npm WARN [email protected] requires a peer of @angular/[email protected]>=4.3.0 but none was installed.", "npm WARN [email protected]
requires a peer of [email protected]>=5.4.3 but none was installed.", "npm WARN [email protected] requires a peer of [email protected]>=2.4.2 but none was installed.", "npm ERR! Linux 3.13.0-132-generic",
"npm ERR! argv \"/usr/local/bin/node\" \"/usr/local/bin/npm\" \"install\"", "npm ERR! node v7.0.0", "npm ERR! npm v3.10.8", "npm ERR! path ../typescript/bin/tsserver", "npm ERR! code EPROTO", "npm ERR! errno -71",
"npm ERR! syscall symlink", "", "npm ERR! EPROTO: protocol error, symlink '../typescript/bin/tsserver' -> '/vagrant/angular_admin/node_modules/@angular-devkit/build-optimizer/node_modules/.bin/tsserver'", "npm ERR! ",
"npm ERR! If you need help, you may report this error at:", "npm ERR! <https://github.com/npm/npm/issues>", "", "npm ERR! Please include the following file with any support request:", "npm ERR!
/vagrant/angular_admin/npm-debug.log"], "stdout": "[email protected] /vagrant/angular_admin\n├── @angular/[email protected] \n├── UNMET PEER DEPENDENCY @angular/[email protected]\n├── UNMET PEER DEPENDE
错误太长了,所以我只是复制了它的开始部分。
现在,它显示这个错误http://mysticpaste.com/3OP1NJG73p
任何帮助深表感谢。
答
看起来像你不能使用符号链接。
您有几种选择:
- 尝试
--no-bin-links
标志添加到npm install
命令或在全局配置为默认值(npm config set bin-links false
)设置 英寸 - 如果您在Windows上运行Vagrant,请尝试运行
vagrant up
作为addministrator。
如果你不希望运行的VirtualBox作为管理员,您可以允许所有用户创建符号链接:
- 打开本地组策略编辑器(
gpedit.msc
) - 编辑在
Create symbolic links
政策:计算机配置→Windows设置→安全设置→本地 策略→用户权利指派→创建符号链接
错误消息是关于NodeJS包的问题,不是PHP( - ; – Neodan
@Neodan是的,它是NodeJS包问题,我该如何解决它? – Aamir
如果没有提供正确答案,请不要忘记标记答案或添加答案。换句话说,这个问题在未来将毫无用处。 – Neodan