FrontendTools and Node via NVM issue on Linux

The vaadin-maven-plugin support a big range of configuration parameters ( However we need to define one of those parameters when running from Intellij at java runtime (development only). There is a problem on my Linux running Node. Is it possible to have them as runtime configuration inside Intellij or from application.settings (spring boot)? The problem is that FrontendTools (NodeInstaller) looks for Node at the wrong place when it want’s to install.

I have installed NodeJS v18.16.0 and NPM v9.5.1. Both accessible from commandline. Therefor building with Maven works fine. However when starting the application from Intellij (Run Configurations) I get this error Node.js download failed. This may be due to loss of internet connection. Vaadin expects to find node from /usr/bin/node is what I have found since I can create a symlink and then it works.

We use nvmso we can specify which version of NodeJS we want to use. This is preferable since we are located on a offline LAN. NVM is exported a path /home/<username>/.nvm/ which Vaadin do not understand it seems.

Is there something I am doing wrong? Is there a easy way to fix this? Should Vaadin look for node when installed with NVM? Any thoughts?

FrontendTools and Node via NVM issue on Linux

NVM is not supported as far as I know, probably worth to create an enhancement issue for it tho

Created this enhancement request

This problem is solved. It was a problem related to env settings not being picked up when Intellij was started from desktop icon thus not reading my .zshrc. Starting Intellij ( from terminal is one way to solve this problem.

Vaadin run which node as a last option and that is very robust imo. When nothing is returned there is definitely a problem as I found out.