Advertisement
Guest User

Untitled

a guest
Mar 7th, 2019
115
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Groovy 1.12 KB | None | 0 0
  1. repos.each { repo, props ->                                                      
  2.     multibranchPipelineJob('python_' + repo) {                  
  3.         // MF: How outrageously obscure is this?
  4.         configure { node ->
  5.             node / sources / data / 'jenkins.branch.BranchSource' / source / traits {
  6.                 'jenkins.plugins.git.traits.TagDiscoveryTrait'()
  7.             }  
  8.         }  
  9.         branchSources {                                    
  10.             git {
  11.                 remote(props.URL)
  12.                 credentialsId('builduser')
  13.                 // FIXME: switch to dev and master branches
  14.                 includes('python-packaging master dev')
  15.             }  
  16.         }  
  17.         factory {            
  18.             workflowBranchProjectFactory {
  19.                 scriptPath('python/Jenkinsfile')
  20.             }  
  21.         }  
  22.         orphanedItemStrategy {                                    
  23.             discardOldItems {
  24.                 numToKeep(20)
  25.             }  
  26.         }  
  27.        
  28.     }                                                                                
  29. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement