开发者

Teamcity: Update local maven repository on build server from Nexus

开发者 https://www.devze.com 2023-03-18 03:37 出处:网络
I am using Teamcity to build by Maven based Java Project. I have recently added a third party artifact into my Nexus Repository Man开发者_运维百科ager. Now when I am building the project, I am getti

I am using Teamcity to build by Maven based Java Project.

I have recently added a third party artifact into my Nexus Repository Man开发者_运维百科ager. Now when I am building the project, I am getting the following error:

[core:project1] Failed to execute goal on project project1: Could not resolve dependencies for project core:project1:jar:1.0.0: Failure to find com.oracle:ojdbc:jar:11.2.0.2.0 in http://localhost:8081/nexus/content/groups/public was cached in the local repository, resolution will not be reattempted until the update interval of nexus has elapsed or updates are forced

Can anyone tell me how can i FORCE updates in the local repository cache on my build server? Is this something to do with Maven settings.xml ?


Try running maven with with the -U option.

http://www.sonatype.com/books/mvnref-book/reference/running.html#running-sect-deps-option


I think, that your real trouble was that the public group (nexus) wasn't aggregating artifacts from third party.

The solution was to add a repository for third party artifacts to settings.xml or to make a different group that will also provide yours third party artifacts.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号