У меня настроено локальное репо, но проблема, с которой я сталкиваюсь, заключается в том, что я не могу подключиться к главному репо maven, когда его локальное репо включено.
это файл settings.xml
в моем .m2
каталог:
<settings xmlns="http://maven.apache.org/SETTINGS/1.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/SETTINGS/1.0.0
http://maven.apache.org/xsd/settings-1.0.0.xsd">
<localRepository/>
<interactiveMode/>
<usePluginRegistry/>
<offline/>
<pluginGroups/>
<servers>
<server>
<id>nexus</id>
<username>epic</username>
<password>artifactory$$$</password>
</server>
<server>
<id>releases</id>
<username>epic</username>
<password>artifactory$$$</password>
<filePermissions>664</filePermissions>
<directoryPermissions>775</directoryPermissions>
</server>
<server>
<id>snapshots</id>
<username>epic</username>
<password>artifactory$$$</password>
<filePermissions>664</filePermissions>
<directoryPermissions>775</directoryPermissions>
</server>
</servers>
<mirrors>
<mirror>
<!--This sends everything else to /public -->
<id>nexus</id>
<mirrorOf>*</mirrorOf>
<url>http://192.168.0.120/nexus/content/groups/public</url>
</mirror>
</mirrors>
<proxies/>
<profiles>
<profile>
<id>nexus</id>
<repositories>
<repository>
<id>central</id>
<url>http://central</url>
<releases><enabled>true</enabled></releases>
<snapshots><enabled>true</enabled></snapshots>
</repository>
</repositories>
<pluginRepositories>
<pluginRepository>
<id>central</id>
<url>http://central</url>
<releases><enabled>true</enabled></releases>
<snapshots><enabled>true</enabled></snapshots>
</pluginRepository>
</pluginRepositories>
</profile>
</profiles>
<activeProfiles>
<activeProfile>nexus</activeProfile>
</activeProfiles>
</settings>
когда этот файл существует, я получаю следующую ошибку:
Failure to find io.swagger:swagger-annotations:pom:1.5.17 in http://192.168.0.120/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
теперь, если я удаляю этот файл конфигурации, получаю следующую ошибку:
Failure to find antlr:antlr-runtime-repackaged:pom:3.2 in https://repo.maven.apache.org/maven2 was cached in the local repository, resolution will not be reattempted until the update interval of central has elapsed or updates are forced
в чем проблема?
Я думаю, что речь идет о файле настроек локального репозитория или самом сервере.