转载:https://blog.csdn.net/kq1983/article/details/83066102(感谢)
1. 点击 repositories
2. 点击 create repository
3. 选中maven(proxy)
4. 设置阿里云
阿里云nexus仓库URL: http://maven.aliyun.com/nexus/content/groups/public
5. maven-public
6. 把阿里云设置为第一位
设置maven的setting.xml文件
-
<!-- 不使用nexus,maven配置阿里云加速 -->
-
<mirror>
-
<id>nexus-aliyun
</id>
-
<mirrorOf>central
</mirrorOf>
-
<name>Nexus aliyun
</name>
-
<url>http://maven.aliyun.com/nexus/content/groups/public/
</url>
-
</mirror>
-
-
<!-- 使用nexus 配置镜像 -->
-
<mirror>
-
<id>nexus-central
</id>
-
<mirrorOf>*
</mirrorOf>
-
<name>Nexus Central
</name>
-
<url>http://192.168.3.200:8081/nexus/repository/maven-public/
</url>
-
</mirror>