当前位置: 代码迷 >> 综合 >> maven 本地jar 添加到私服
  详细解决方案

maven 本地jar 添加到私服

热度:100   发布时间:2023-09-13 09:03:29.0

利用命令行:

1). 安装到本地库:
mvn install:install-file -DgroupId=org.apache.hadoop -DartifactId=hbase -Dversion=1.0 -Dpackaging=jar -Dfile=[path to file]

2). 安装到私服
mvn deploy:deploy-file -DgroupId=org.apache.hadoop -DartifactId=hbase -Dversion=1.0 -Dpackaging=jar -Dfile=[path to file] -Durl=[url] -DrepositoryId=[id]

2.批量导入jar

直接拷贝文件至/opt/data/nexus/sonatype-work/nexus/storage/pvinsight/org/apache/hadoop/hive/hive-exec/0.5.0

或者

通过脚本执行 mvn deploy:deploy-file