在Maven的conf目录下的setting.xml文件中添加
<mirrors>
<mirror>
<id>alimaven</id>
<name>aliyun maven</name>
<url>http://maven.aliyun.com/nexus/content/groups/public/</url>
<mirrorOf>central</mirrorOf>
</mirror>
</mirrors>
如图所示:
![](https://i-blog.csdnimg.cn/blog_migrate/88f661cefa1fcc4e2197ce86214fb7e1.png)