0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 1 year has passed since last update.

【Laravel×Homestead】npm installをしたらエラーが出た話

Posted at

laravel/uiをインストールし、php artisan ui bootstrap --authにて、ui機能を使ってbootstrapの認証機能のひな形ファイルを作成。
その後、必要なパッケージ管理機能を使えるようにnpm installを実行すると、symlinkエラーが発生しました。

環境

  • OS : windows11 pro
  • VirtualBox (5.2.44)
  • vagrant (2.2.5)
  • Laravel8×Homestead

symlinkエラー

npm WARN deprecated stable@0.1.8: Modern JS already guarantees Array#sort() is a stable sort, so this library is deprecated. See the compatibility table on MDN: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/sort#browser_compatibility
npm WARN deprecated querystring@0.2.0: The querystring API is considered Legacy. new code should use the URLSearchParams API instead.
npm ERR! code EPROTO
npm ERR! syscall symlink
npm ERR! path ../@babel/parser/bin/babel-parser.js
npm ERR! dest /home/vagrant/code/physical_health_record/node_modules/.bin/parser
npm ERR! errno -71
npm ERR! EPROTO: protocol error, symlink '../@babel/parser/bin/babel-parser.js' -> '/home/vagrant/code/physical_health_record/node_modules/.bin/parser'

npm ERR! A complete log of this run can be found in:
npm ERR!     /home/vagrant/.npm/_logs/2022-09-30T00_44_03_829Z-debug-0.log

解決方法

原因は分かりませんが、VirtualBoxを管理者で先に起動させ、npm installを実行するとうまくいきました。

つまり、vagrant upは管理者権限で起動したCMDで実行しないとダメらしい・・・
ややこしいが、成功して良かったです。

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?