Learn more about these different git repos.
Other Git URLs
5fefc0a
@@ -179,7 +179,7 @@
source:
git:
uri: "${WAIVERDB_GIT_REPO}"
- ref: "${WAIVERDB_MAIN_BRANCH}"
+ ref: "${WAIVERDB_GIT_REF}"
strategy:
type: JenkinsPipeline
jenkinsPipelineStrategy:
Signed-off-by: Lukas Holecek hluk@email.cz
+1 let's try it
Pull-Request has been merged by gnaponie
This does not work, followup is in #318 but seems that I cannot set up OpenShift template so that the Jenkins job is configured to pull PRs before it reads the Jenkinsfile.
This doesn't work because the Git repo and branch name are preconfigured on Jenkins, and there is no way to tell Jenkins to use another branch before a Job run.
The repo and branch name is configured in "openshift/pipelines/templates/waiverdb-build-template.yaml" (JenkinsPipeline; can be changed from OpenShift UI). But the missing part is refspec configuration for Jenkins -- you can find it in Jenkins job configuration but I didn't find a way to set it in the OpenShift template.
JenkinsPipeline
refspec
Workaround to test the new Jenkinsfile is to temporarily change the repo and branch in OpenShift UI to point to your fork and devel branch, or using following command.
Jenkinsfile
oc start-build --from-repo=. --commit=YOUR_BRANCH waiverdb-premerge-jenkins-slave
@lholecek The pre-merge job is started by the polling job (https://jenkins-waiverdb-test.cloud.paas.upshift.redhat.com/job/waiverdb-test/job/waiverdb-test-waiverdb-polling-for-prs/). I realized we can pass the --commit parameter you mentioned there.
--commit
I realized we can pass the --commit parameter you mentioned there.
@rayson You already mentioned it in "openshift/docs/pipeline-deployment.md" (BTW, thanks for the docs). But the --from-repo argument is required if you have your branch in a fork (not in the main repo).
--from-repo
Signed-off-by: Lukas Holecek hluk@email.cz