Skip to content

Commit 4a61f3d

Browse files
Create trigger_jenkins.yaml for CL CBCI onboarding
1 parent a9d53f1 commit 4a61f3d

File tree

1 file changed

+19
-0
lines changed

1 file changed

+19
-0
lines changed
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
name: Trigger Jenkins CI
2+
on:
3+
- push
4+
- pull_request
5+
jobs:
6+
# This workflow contains a single job called "trigger_jenkins"
7+
trigger_jenkins:
8+
# The type of runner that the job will run on
9+
#runs-on: jenkins-trigger
10+
runs-on: self-hosted
11+
env:
12+
REPO_NAME: ${{ github.event.repository.name }}
13+
ORG_NAME: ${{ github.event.organization.login }}
14+
JENKINS_ROOT: ${{ secrets.JENKINS_CONTROLLER_URL }}job/${{ secrets.JENKINS_TRIGGER_ROOT_FOLDER }}/job/${{ secrets.JENKINS_TRIGGER_ORG_FOLDER }}/job/
15+
steps:
16+
- name: trigger single Job
17+
run: >
18+
curl -X POST -u "${{ secrets.JENKINS_TRIGGER_USER }}:${{ secrets.JENKINS_TRIGGER_TOKEN }}"
19+
${{ env.JENKINS_ROOT}}/${{ env.ORG_NAME }}/job/${{ env.REPO_NAME }}/build\?delay=\0

0 commit comments

Comments
 (0)