forked from linagora/james-jenkins
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild-pr-from-github
31 lines (30 loc) · 1.05 KB
/
build-pr-from-github
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
def GITHUB_BASE_URL= '/~https://github.com/linagora/'
def REPOSITORIES = ['james-project']
REPOSITORIES.each {
def repository = it
def url = GITHUB_BASE_URL + repository
job('build pull-requests') {
concurrentBuild()
githubProjectUrl(url)
triggers {
pullRequest {
cron('* * * * *')
useGitHubHooks(false)
allowMembersOfWhitelistedOrgsAsAdmin(true)
triggerPhrase('test this please')
orgWhitelist('linagora')
permitAll()
}
}
steps {
downstreamParameterized {
trigger('workflow', 'ALWAYS', false,
[buildStepFailure: 'FAILURE',
failure : 'FAILURE',
unstable : 'UNSTABLE']) {
predefinedProps([repoURL: '${ghprbAuthorRepoGitUrl}', branch: '${ghprbSourceBranch}', sha1: '${ghprbActualCommit}', originalBranch: '${ghprbTargetBranch}'])
}
}
}
}
}