常用Maven Repository
仓库名称 | 仓库地址 |
---|---|
Maven Central | https://repo.maven.apache.org/maven2/ |
JCenter | https://jcenter.bintray.com/ |
阿里云public | https://maven.aliyun.com/repository/public |
阿里云google | https://maven.aliyun.com/repository/google |
阿里云spring | https://maven.aliyun.com/repository/spring |
阿里云grails-core | https://maven.aliyun.com/repository/grails-core |
阿里云mapr-public | https://maven.aliyun.com/repository/mapr-public |
Oracle | https://maven.oracle.com |
JBoss | https://repository.jboss.org/nexus/content/groups/public/ |
https://repository.jboss.org/nexus/content/repositories/fs-releases | |
RedHat | https://maven.repository.redhat.com/ga/ |
http://maven.repository.redhat.com/techpreview/all/ | |
Pentaho | http://public.nexus.pentaho.org/content/repositories/pentaho-public-release-repos/ |
JasperReports CE Releases | http://jaspersoft.jfrog.io/jaspersoft/jr-ce-releases |
JasperReports thirdparty | http://jaspersoft.jfrog.io/jaspersoft/third-party-ce-artifacts/ |
注:Oracle Repository需要提供账号,POM中依赖配置如下:
<dependency>
<groupId>com.oracle.jdbc</groupId>
<artifactId>ojdbc6</artifactId>
<version>11.2.0.4</version>
<exclusions>
<exclusion>
<groupId>*</groupId>
<artifactId>*</artifactId>
</exclusion>
</exclusions>
</dependency>
Maven settings加密配置
- 在.m2下创建文件settings-security.xml来保存master密码
使用下面的命令生成master密码:
mvn -encrypt-master-password <any_master_password>
或
mvn -emp <any_master_password>
settings-security.xml内容如下:
<settingsSecurity>
<master>{By8wW7YcTxAHof0MF4Z3wPKboywhGJvxHD9m0NvHA2U=}</master>
</settingsSecurity>
- 配置settings.xml
使用下面命令加密用户密码:
mvn -encrypt-password <any_master_password>
或
mvn -ep <any_master_password>
配置用户和repository:
<servers>
<server>
<id>maven.oracle.com</id>
<username>[email protected]</username>
<password>{pnwmhVnzdM8H3UAneUKLmaHGZCoaprbMQ/Ac5UktvsM=}</password>
<configuration>
<basicAuthScope>
<host>ANY</host>
<port>ANY</port>
<realm>OAM 11g</realm>
</basicAuthScope>
<httpConfiguration>
<all>
<params>
<property>
<name>http.protocol.allow-circular-redirects</name>
<value>%b,true</value>
</property>
</params>
</all>
</httpConfiguration>
</configuration>
</server>
</servers>
<profiles>
<profile>
<id>main</id>
<activation>
<activeByDefault>true</activeByDefault>
</activation>
<repositories>
<repository>
<id>maven.oracle.com</id>
<url>https://maven.oracle.com</url>
<layout>default</layout>
<releases>
<enabled>true</enabled>
</releases>
</repository>
</repositories>
</profile>
</profiles>
参考文档
Get Oracle JDBC drivers and UCP from Oracle Maven Repository
Configuring the Oracle Maven Repository
Oracle Database JDBC driver
Maven Password Encryption