Tag Archives: Archiva

Maven – Include system scope dependency in maven-assembly-plugin

If you don’t have Maven repository server like Archiva or Nexus, you may need to include those libs which are not public on the internet in your Maven project and specifiy the dependency scope as system in the pom.xml. The following example includes the eureka-0.0.1.jar which is located in the folder called external on project root.

...
<dependency>
  <groupId>ykyuen.info</groupId>
  <artifactId>eureka</artifactId>
  <version>0.0.1</version>
  <scope>system</scope>
  <systemPath>${project.basedir}/external/eureka-0.0.1.jar</systemPath>
</dependency>
...

 

A few months ago i wrote a blog post about how to package the project jar file with all dependencies.
Maven – Package the jar file with dependencies
Continue reading Maven – Include system scope dependency in maven-assembly-plugin

Maven – Add New Remote Maven Repository in Archiva

It is possible to add other Maven repositories which is specified explicitly in the pom.xml using the <repositories> node. But if you have a Maven Repository Manager like Archiva, you should configure those remote Maven repostories in Archiva instead of adding them in the pom.xml
Continue reading Maven – Add New Remote Maven Repository in Archiva