Ran*_*ggs 3 artifactory playframework
我正在尝试添加一个本地maven存储库,我使用artifactory设置它,用于缓存maven存储库.根据依赖指令,我发现如何使用包含属性的存储库来设置存储库具有的范围.我想要做的是将此存储库用于所有内容,有没有办法配置它?
repositories:
- artifactory:
type: iBiblio
artifact: "http://myartifactoryhost.com/artifactory/libs-release"
contains:
- foo-bars -> *
Run Code Online (Sandbox Code Playgroud)
您可以将以下内容放入$ HOME/.ivy2/ivysettings.xml
这将使常春藤(因此播放依赖性解析)首先在本地maven repo中查看,然后使用您的repo管理器(类似于.m2/settings.xml中的mirrorOf*).
<ivy-settings>
<!-- path to local maven repo and default maven layout -->
<property name="local-maven2-pattern" value="${user.home}/.m2/repository/[organisation]/[module]/[revision]/[module]-[revision]" override="false" />
<!-- set resolver chain as default -->
<settings defaultResolver="main" />
<!-- configure caches -->
<caches repositoryCacheDir="${user.home}/.ivy2/cache">
<!-- do not cache from local .m2-->
<cache name="nocache" useOrigin="true" />
<cache name="default" />
</caches>
<resolvers>
<chain name="main">
<!-- as this is not cached, even changing SNAPSHOT dependencies are resolved correctly -->
<filesystem name="local-maven-2" m2compatible="true" local="true" cache="nocache">
<ivy pattern="${local-maven2-pattern}.pom" />
<artifact pattern="${local-maven2-pattern}(-[classifier]).[ext]" />
</filesystem>
<!-- use repository manager as proxy to maven-central (and alle other repositories)-->
<ibiblio name="repomanager" m2compatible="true"root="http://your.repomanager.intra/path/to/repo" cache="default"/>
</chain>
</resolvers>
</ivy-settings>
Run Code Online (Sandbox Code Playgroud)
| 归档时间: |
|
| 查看次数: |
4793 次 |
| 最近记录: |