-
Bug
-
Resolution: Fixed
-
Major
-
None
-
windows
-
-
pipeline-maven-3.11.0
in a clean jenkins (no maven plugin installed)
In an agent without maven on the path add MAVEN_HOME to the environment variables for the node.
run the follwoing pipeline
node { bat "set" withMaven { git changelog: false, poll: false, url: 'https://github.com/jtnord/maven-test-project.git' bat "mvn package" } }
This should work as MAVEN_HOME is in the environment as confimerd by the set command.
However it fails with the following message
[withMaven] use JDK installation provided by the build agent
$ where mvn.cmd
$ where mvn.bat
[withMaven] use Maven installation provided by the build agent with executable null
[Pipeline] // withMaven
[Pipeline] }
[Pipeline] // node
[Pipeline] End of Pipeline
ERROR: Could not find maven executable, please set up a Maven Installation or configure MAVEN_HOME or M2_HOME environment variable
But MAVEN_HOME is defined - so this is just plain wrong...
- is duplicated by
-
JENKINS-61612 withMaven does not detect maven
- Closed
- is related to
-
JENKINS-61612 withMaven does not detect maven
- Closed
- links to