我正在尝试从GitHub企业服务器触发多分支管道作业。我已将Webhook配置为在所有事件上发送通知。 github企业上的事件日志显示对Jenkins的请求已成功,但是在多分支管道上,事件日志为空。
我的多分支管道作业是使用JobDSL创建的,就像这样:
multibranchPipelineJob("build_${repo}") {
branchSources {
branchSource {
source {
git {
id("${org}.${repo}")
remote("git@${githubEntrerpise}:${org}/${repo}")
}
}
}
}
configure {
def traits = it / sources / data / 'jenkins.branch.BranchSource' / source / traits
traits << 'jenkins.plugins.git.traits.BranchDiscoveryTrait' {}
}
triggers {
periodic(1) // Trigger every min.
}
orphanedItemStrategy { discardOldItems { numToKeep(10) } }
}
这里有什么我想念的吗?