Level 3
Try remove node_modules
Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.
Hi,
I'm installing spark on a vanilla Ubuntu 16.04 instance. Node is v7.9.0, npm is v4.2.0, this is the only node on the system.
spark new foo works fine right up to the final asset compiling stage, I get cross-env: Permission denied every time.
npm run dev gives the same results.
The only thread I can find on this suggests a different version of node is being used; that's definitely not the case here.
Any ideas where to dig next?
Thanks, npm run dev output below.
ubuntu@hub:~/hub/codebase$ npm run dev
> @ dev /var/www/hub/releases/dev/codebase
> cross-env NODE_ENV=development node_modules/webpack/bin/webpack.js --progress --hide-modules --config=node_modules/laravel-mix/setup/webpack.config.js
sh: 1: cross-env: Permission denied
npm ERR! Linux 4.4.0-75-generic
npm ERR! argv "/usr/bin/nodejs" "/usr/bin/npm" "run" "dev"
npm ERR! node v7.9.0
npm ERR! npm v4.2.0
npm ERR! code ELIFECYCLE
npm ERR! errno 126
npm ERR! @ dev: `cross-env NODE_ENV=development node_modules/webpack/bin/webpack.js --progress --hide-modules --config=node_modules/laravel-mix/setup/webpack.config.js`
npm ERR! Exit status 126
npm ERR!
npm ERR! Failed at the @ dev script 'cross-env NODE_ENV=development node_modules/webpack/bin/webpack.js --progress --hide-modules --config=node_modules/laravel-mix/setup/webpack.config.js'.
Please or to participate in this conversation.