Home > front end >  Jenkins Fails to parse poms due to missing parent pom
Jenkins Fails to parse poms due to missing parent pom

Time:06-17

our jenkins job failes to parse poms, as it cannot find the parent pom. (Jenkins version 2.332.3)

Parsing POMs
Failed to transfer Could not find artifact <our parent pom> in central (https://repo.maven.apache.org/maven2)
ERROR: Failed to parse POMs
org.apache.maven.project.ProjectBuildingException: Some problems were encountered while processing the POMs:
[FATAL] Non-resolvable parent POM for <current project>: Could not find artifact <our parent pom> in central (https://repo.maven.apache.org/maven2) and 'parent.relativePath' points at wrong local POM @ line 10, column 13

The project is set up as a maven project and the no goal can be executed. If I configure the job as a pre-built step, the maven build is successfull.

Flags like -U and -X do not change the log message.

The parent pom is located in an artifact in our private nexus repository and should already be in the local .m2 repository, as the pre build step is successfull.

On the old jenkins (2.263.4) server, the build works just fine.

Any hint will be highly appreciated

CodePudding user response:

Specifying the path to the explicit settings.xml helped this time.

  • Yes, it is using the settings from root, which is most likely not recommended
  • The Jenkins instance is running in an docker container, which is based on an own image, that has the official jenkins image as its root.
  • Still it is weird, as another job works fine without specifying this path

enter image description here

  • Related