maven配置私有仓库和阿里仓库共存
profiles标签添加
<profile>
<id>test</id>
<repositories>
<repository>
<id>private-nexus</id>
<url>http://192.168.10.2:8081/repository/maven-public/</url>
</repository>
</repositories>
<pluginRepositories>
<pluginRepository>
<id>private-nexus</id>
<url>http://192.168.10.2:8081/repository/maven-public/</url>
<releases>
<enabled>true</enabled>
<updatePolicy>always</updatePolicy>
</releases>
<snapshots>
<enabled>true</enabled>
<updatePolicy>always</updatePolicy>
</snapshots>
</pluginRepository>
</pluginRepositories>
</profile>
<profile>
<id>aliyun</id>
<repositories>
<repository>
<id>aliyun-nexus</id>
<url>http://maven.aliyun.com/nexus/content/groups/public/</url>
</repository>
</repositories>
<pluginRepositories>
<pluginRepository>
<id>aliyun-nexus</id>
<url>http://maven.aliyun.com/nexus/content/groups/public/</url>
<releases>
<enabled>true</enabled>
<updatePolicy>always</updatePolicy>
</releases>
<snapshots>
<enabled>true</enabled>
<updatePolicy>always</updatePolicy>
</snapshots>
</pluginRepository>
</pluginRepositories>
</profile>
activeProfiles标签添加
<activeProfile>test</activeProfile>
<activeProfile>aliyun</activeProfile>