Thanks Ann. I fixed the issues from my original post but now am encountering a different problem, which is that SoanrQube expects nodejs to be installed on every Jenkins build agent even if we are not scanning for javascript.
ERROR: Error when running: ‘node -v’. Is Node.js available during analysis?
08:14:27 org.sonarsource.nodejs.NodeCommandException: Error when running: ‘node -v’. Is Node.js available during analysis?
We are using the following plug ins:
sonar-csharp-plugin-6.5.0.3766.jar
sonar-flex-plugin-2.3.jar
sonar-java-plugin-4.15.0.12310.jar
sonar-javascript-plugin-5.1.0.7456.jar
sonar-ldap-plugin-2.2.0.608.jar
sonar-php-plugin-2.11.0.2485.jar
sonar-python-plugin-1.8.0.1496.jar
sonar-scm-git-plugin-1.3.0.869.jar
sonar-scm-svn-plugin-1.6.0.860.jar
sonar-typescript-plugin-1.9.0.3766.jar
sonar-xml-plugin-1.4.3.1027.jar
It’s very strange. We have installed nodejs on each of our build agents. However, the same jobs might run find on one server but still give us this error:
14:31:51 ERROR: Error when running: ‘node -v’. Is Node.js available during analysis? 14:31:51 org.sonarsource.nodejs.NodeCommandException: Error when running: ‘node -v’. Is Node.js available during analysis?
node is installed, as I can validate by:
javab427@servername:/opt/javab427 > node -v
v8.9.3
javab427@servername:/opt/javab427 > which node
/opt/devops/nodejs/node-v8.9.3-linux-x64/bin/node
Also, though we might have the TypeScript and CSS plugins installed, these jobs are not scanning for those so I don’t know why they’d be looking for nodejs.