Panagioths Parthenhs :
I am using the Apache Maven 3.5.2 and I face the same problem. I try to pull dependencies from two nexus-releases-repository, using the same account(username + password)
My .m2/setting.xml
contains:
<servers>
<server>
<id>nexus</id>
<username>username</username>
<password>password</password>
</server>
</servers>
My project's pom.xml
contains:
<repositories>
<repository>
<id>nexus</id>
<url>https://DOMAIN/repository/repoA-maven-public/</url>
</repository>
<repository>
<id>nexus</id>
<url>https://DOMAIN/repository/repoB-maven-public/</url>
</repository>
</repositories>
I am using the same account to login into both of repository, but I get maven error repositories.repository.id must be unique
. How that can be resolved
Gonzalo Matheu :
From Repositories section of pom.xml documentation:
id, name: The id is used to uniquely identify this repository amongst many, and the name is a human readable form.
So, the id should be unique.
In our case, in settings.xml we have multiple servers definitions with the same credentials but different id values.