nexus maven私服搭建

Maven用到的Repositories说明
maven-central:maven中央库,默认从https://repo1.maven.org/maven2/拉取jar
maven-releases:私库发行版jar
maven-snapshots:私库快照(调试版本)jar(只需要在发布的版本号后面加上-SNAPSHOT
maven-public:仓库分组,把上面三个仓库组合在一起对外提供服务,在本地maven基础配置settings.xml中使用。

nexus3中央仓库改为阿里云


image.png

image.png

https://maven.aliyun.com/repository/central

配置文件




  
  

  
 
  

 
  
     
         nexus-releases  
         admin  
         h*yi  
       
       
         nexus-snapshots  
         admin  
         h*yi  
      
      
         central  
         admin  
         h*yi  
        
  

 
  
       
          central  
          *  
          Central Repository  
          http://139.155.180.*:8081/repository/maven-public/  
       
  

  
  
      
      dev
      
        
          Nexus
          http://139.155.180.*:8081/repository/maven-public/
          
            true
          
          
            true
          
        
      
    



    dev


  


发布包

 
        
            nexus-releases
            Nexus Release Repository
            http://你的maven地址/repository/maven-releases/
        
        
            nexus-snapshots
            Nexus Snapshot Repository
            http://你的maven地址/repository/maven-snapshots/
        
    
image.png

如果出现

from/to central (http://139.155.180.170:8081/repository/maven-public/): Not authorized

检查server对应的id和mirror的id是否一致

你可能感兴趣的:(nexus maven私服搭建)