Let Maven fly: replace the Maven image with the domestic Alibaba Cloud warehouse, and modify the local warehouse

Crazy maker circle: spring boot, spring cloud architecture exchange. Please join the QQ group to join the circle to learn and communicate, so that everyone can learn, communicate and grow together .

To enter the QQ group to communicate, please click the link: Crazy Maker Circle QQ Group


foreword


1. Domestic access to maven's default remote central mirror is particularly slow

2. Replace the remote central mirror with Ali's mirror

3. Most of the jar packages can be found in the Ali mirror, some jar packages are not in the Ali mirror, you need to configure the mirror separately

Change it to a domestic mirror, let you feel the feeling of flying.

replace

Find the maven installation directory



Modify the maven configuration file settings.xml and add the following mirrors


 <!-- 阿里云仓库 -->
        <mirror>
        <id>nexus-aliyun</id>
        <mirrorOf>central</mirrorOf>
        <name>Nexus aliyun</name>
        <url>http://maven.aliyun.com/nexus/content/groups/public</url>
    </mirror> 


As shown below



Configured local repository

Modify the maven configuration file settings.xml, modify the path in <localRepository></localRepository>, as follows


Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=325732161&siteId=291194637