Maven release plugin git credentials

前端 未结 1 1821
猫巷女王i
猫巷女王i 2021-02-18 13:01

We are using Jenkins and just switched from a file based git repo without authentication to using GitBlit with proper authentication over http.

The problem is -

1条回答
  •  感情败类
    2021-02-18 13:30

    Based on the docs you have to use a special property, project.scm.id, to define the id of the appropriate server entry in your settings.xml file.

    
      my-scm-server
    
    

    And the following in your settings.xml file:

      
         
          
             my-scm-server  
             myUser  
             myPassword  
             
       
    
    

    BTW: Check if you are using the most recent version of maven-release-plugin. The project.scm.id enhancement was introduced in version 2.3 as part of ticket MRELEASE-420. For example if you are using Maven 3.0.5 then you are by default only using version 2.0 of the maven-release-plugin. Much too old. Fix by adding something like below to your POM:

    
        
            
                
                    org.apache.maven.plugins
                    maven-release-plugin
                    2.5.3                
                
            
        
    
    

    0 讨论(0)
提交回复
热议问题