Skip to content

Commit c8ff364

Browse files
authored
internal: add sanity workflow to trigger jenkins job after PR merge (#167)
1 parent 8a4e362 commit c8ff364

1 file changed

Lines changed: 35 additions & 0 deletions

File tree

.github/workflows/sanity-test.yaml

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
name: Sanity Test Jenkins Trigger
2+
3+
on:
4+
workflow_call:
5+
push:
6+
branches:
7+
- main
8+
9+
concurrency:
10+
group: main-${{ github.ref }}
11+
cancel-in-progress: false
12+
13+
jobs:
14+
sanity-tests:
15+
if: |
16+
(github.event_name == 'pull_request' && github.event.action == 'ready_for_review') ||
17+
(github.event_name == 'pull_request_review' && github.event.review.state == 'approved') ||
18+
(github.event_name == 'push' && github.ref == 'refs/heads/main')
19+
runs-on: tools-runner
20+
21+
steps:
22+
- name: Trigger Onboarding job for this repo
23+
id: trigger-jenkins-job
24+
uses: sysdiglabs/jenkins-job-trigger-action@1.1.0
25+
with:
26+
jenkins_external_base_url: ${{ secrets.JENKINS_EXTERNAL_BASE_URL }}
27+
jenkins_url: ${{ secrets.JENKINS_INTERNAL_URL }}
28+
jenkins_user: ${{ secrets.JENKINS_BOT_API_USER}}
29+
jenkins_token: ${{ secrets.JENKINS_BOT_API_TOKEN}}
30+
job_name: "qa/job/QA-secure/job/onboarding/job/aws-templates-secure-for-cloud-onboarding-tests/"
31+
job_params: |
32+
{
33+
"MODULE_BRANCH": "${{ github.head_ref || github.ref_name }}"
34+
}
35+
job_timeout: "5400"

0 commit comments

Comments
 (0)