报错:
bash
Non-resolvable import POM: The following artifacts could not be resolved: com.*.boot:txlc-*-dependencies:pom:2026.01-SNAPSHOT (absent): Could not transfer artifact com.*.boot:txlc-*-dependencies:pom:2026.01-SNAPSHOT from/to maven-default-http-blocker (http://0.0.0.0/): Blocked mirror for repositories: [txlcmaven (http://192.168.10.14:8081/repository/maven-public/, default, releases+snapshots)]
解决:在settings.xml中配置如下:
xml
<mirrors>
<mirror>
<!-- 配置私服地址http,注意:默认有一个0.0.0.0的最好删掉 -->
<id>txlcmaven</id>
<mirrorOf>*</mirrorOf>
<url>http://192.168.10.237:8081/repository/maven-public/</url>
<!-- 针对maven3.9.*允许私服http访问的配置 -->
<blocked>false</blocked>
</mirror>
</mirrors>
<profiles>
<!-- 针对maven3.9.*允许私服http访问的配置 -->
<profile>
<id>allow-http</id>
<repositories>
<repository>
<id>txlcmaven</id>
<url>http://192.168.10.237:8081/repository/maven-public/</url>
<releases>
<enabled>true</enabled>
</releases>
<snapshots>
<enabled>true</enabled>
</snapshots>
<allowInsecureProtocol>true</allowInsecureProtocol>
</repository>
</repositories>
</profile>
</profiles>
<!-- 针对maven3.9.*允许私服http访问的配置 -->
<activeProfiles>
<activeProfile>allow-http</activeProfile>
</activeProfiles>
重启工具再次访问即可