When running app/console assetic:dump, I am getting:
Path to node executable could not be resolved
What does it mean and how to fix this?
When trying to browse project via app_dev.php, I am getting an HTTP 500 errors when browser tries to download css and js files.
Node. js provides a CLI which is an executable file called node . This executable file is located in folder /usr/local/bin .
If you downloaded and run, the installer package from the nodejs.org website, the Node. js main executables files -- node and npm -- are located on the /usr/local/bin folder.
First make sure you have node installed and find the path to node. You can usually find this by using which node
which will return something like /usr/local/bin/node
. If it returns something like /usr/bin/which: no node in ...
you need to install node.
Next configure symfony. Open your config.yml (./app/config/config.yml) and the path to node to you assetic config, i.e.:
# app/config/config.yml
assetic:
node: /usr/local/bin/node
This worked for me
sudo apt-get remove nodejs
sudo apt-get remove npm
sudo curl -sL https://deb.nodesource.com/setup | sudo bash -
sudo apt-get install nodejs
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With