Cannot download ZIP distribution from https://repo.maven.apache.org/maven2/org/apache/maven/apache-maven/3.5.4/apache-maven-3.5.4-bin.zip. Please check distributionUrl The Maven wrapper was disabled. The Maven bundled version will be used instead.
由于在构建项目时,我们在setting中已经配置了阿里云镜像,但是下载依赖还是会遵从super pom(所有自定义pom.xml都是继承自super pom),因此,当maven项目需要下载一些metadata、pom、jar的时候,会优先去中央仓库下载,导致内网用户各种报错!
<mirror>
<id>alimavenid>
<mirrorOf>centralmirrorOf>
<name>aliyun mavenname>
<url>http://maven.aliyun.com/nexus/content/repositories/central/url>
mirror>
<mirror>
<id>alimavenid>
<name>aliyun mavenname>
<url>http://maven.aliyun.com/nexus/content/groups/public/url>
<mirrorOf>centralmirrorOf>
mirror>
<mirror>
<id>centralid>
<name>Maven Repository Switchboardname>
<url>http://repo1.maven.org/maven2/url>
<mirrorOf>centralmirrorOf>
mirror>
<mirror>
<id>repo2id>
<mirrorOf>centralmirrorOf>
<name>Human Readable Name for this Mirror.name>
<url>http://repo2.maven.org/maven2/url>
mirror>
<mirror>
<id>ibiblioid>
<mirrorOf>centralmirrorOf>
<name>Human Readable Name for this Mirror.name>
<url>http://mirrors.ibiblio.org/pub/mirrors/maven2/url>
mirror>
<mirror>
<id>jboss-public-repository-groupid>
<mirrorOf>centralmirrorOf>
<name>JBoss Public Repository Groupname>
<url>http://repository.jboss.org/nexus/content/groups/publicurl>
mirror>
<mirror>
<id>google-maven-centralid>
<name>Google Maven Centralname>
<url>https://maven-central.storage.googleapis.com
url>
<mirrorOf>centralmirrorOf>
mirror>
<mirror>
<id>maven.net.cnid>
<name>oneof the central mirrors in chinaname>
<url>http://maven.net.cn/content/groups/public/url>
<mirrorOf>centralmirrorOf>
mirror>
<repositories>
<repository>
<id>nexus-aliyunid>
<name>nexus-aliyunname>
<url>http://maven.aliyun.com/nexus/content/groups/public/url>
<releases>
<enabled>trueenabled>
releases>
<snapshots>
<enabled>falseenabled>
snapshots>
repository>
repositories>