This is what I did

  1. As a first step, I have configured the Apache Archiva and the service runs perfectly as a standalone service though it created some trouble for me while trying to run in tomcat.

  2. Edited the setting.xml in the MAVEN_HOME pointing to the Apache Archiva repository by adding mirror.

With the project's pom.xml, I see the following

<repositories>
  <repository>
    <snapshots>
      <enabled>false</enabled>
    </snapshots>
    <id>central</id>
    <name>Central Repository</name>
    <url>http://repo.maven.apache.org/maven2</url>
  </repository>
</repositories>

Should I remove this to make my Archiva repository effective? I am afraid that this code makes a direct call from the Central repository without making use of the Archiva. Is this correct? Please advise

有帮助吗?

解决方案

yes you can. This repository is the default one (and no need to declare it in your pom). Just a mirror with <mirrorOf>central</mirrorOf> in your settings

许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top