Skip to content

Commit

Permalink
Create test
Browse files Browse the repository at this point in the history
Signed-off-by: Avimitin <[email protected]>
  • Loading branch information
Avimitin committed Apr 2, 2024
1 parent 6df032a commit 1a4dc39
Showing 1 changed file with 33 additions and 0 deletions.
33 changes: 33 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
name: PR
on: [pull_request]
env:
USER: runner

# Cancel the current workflow when new commit pushed
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number }}
cancel-in-progress: true

jobs:
always-success:
name: "I will always success"
runs-on: [self-hosted, linux, nixos]
steps:
- name: "Success"
run: echo "FOO BAR BAZ"

get-report:
name: "Getting report"
if: ${{ success() }}
runs-on: [self-hosted, linux, nixos]
needs: [always-success]
steps:
- name: "Fetch report"
run: |
curl -L \
-X POST \
-H "Accept: application/vnd.github+json" \
-H "Authorization: Bearer ${{ secrets.T1_INHOUSE_PAT }}" \
-H "X-GitHub-Api-Version: 2022-11-28" \
"${{ secrets.T1_INHOUSE_URL }}" \
-d '{"event_type":"ci_success","client_payload":{"commit_sha": "${{ github.event.pull_request.head.sha }}","pr_id": "${{ github.event.pull_request.number }}" }}'

0 comments on commit 1a4dc39

Please sign in to comment.