I want to implement Gitlab CI on my repository. I have already set up the runner on Windows and configure the .yml to work with a Maven project. The problem is that I have the folders Domain and Front-end in the root of the repository. Is there a way to change the root so the .yml could be able to find the pom.XML file which is in the domain folder?
When I run it, it says that it couldn't find the pom files.
[ERROR] The goal you specified requires a project to execute but there is no POM in this directory (/builds/motomine/web). Please verify you invoked Maven from the correct directory.
So I think changing the root folder might solve the problem.
You don't necessarily need to change the directory. You can point maven to the directory which contains the pom. In your .yml file:
...
- mvn -f Domain
From the maven documentation:
-f,--file : Force the use of an alternate POM file (or directory with pom.xml)
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