Skip to content

Commit

Permalink
Update CI workflow to use CD workflow for triggering
Browse files Browse the repository at this point in the history
  • Loading branch information
vpgits committed Jan 30, 2024
1 parent 93480ee commit 681a0b2
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 9 deletions.
10 changes: 5 additions & 5 deletions .github/workflows/CI-test_handler.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
name: CI | Test Handler

on:
workflow_run:
workflows: ["Initial Workflow"]
workflow_run:
workflows: ["CD | Build-Test-Release"]
types:
- completed

Expand All @@ -18,11 +18,11 @@ jobs:
uses: fjogeleit/http-request-action@v1
id: deploy
with:
url: "https://api.runpod.ai/v2/${{ vars.RUNNER_24GB }}/run"
url: "https://api.runpod.ai/v2/${{ secrets.RUNNER_24GB }}/run"
method: "POST"
customHeaders: '{"Content-Type": "application/json"}'
bearerToken: ${{ secrets.RUNPOD_API_KEY }}
data: '{"input":{"github_pat": "${{ secrets.GH_PAT }}", "github_org":"${{ vars.GH_ORG }}"}}'
data: '{"input":{"github_pat": "${{ secrets.GH_PAT }}", "github_org":"${{ secrets.GH_ORG }}"}}'

- name: Extract Job ID
id: extract_id
Expand Down Expand Up @@ -62,7 +62,7 @@ jobs:
- name: Terminate and Shutdown Worker
uses: fjogeleit/http-request-action@v1
with:
url: "https://api.runpod.ai/v2/${{ vars.RUNNER_24GB }}/cancel/${{ needs.launch_runner_worker.outputs.id }}"
url: "https://api.runpod.ai/v2/${{ secrets.RUNNER_24GB }}/cancel/${{ needs.launch_runner_worker.outputs.id }}"
method: "POST"
customHeaders: '{"Content-Type": "application/json"}'
bearerToken: ${{ secrets.RUNPOD_API_KEY }}
6 changes: 2 additions & 4 deletions .github/workflows/build-test-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,6 @@ jobs:
echo "GH_ORG=${{ github.repository_owner }}"
echo "GH_EMAIL=${{ secrets.GH_EMAIL }}"
echo "HUGGINGFACE_PAT=${{ secrets.HUGGINGFACE_PAT }}"
echo "GH_ORG=${{ env.GH_ORG }}"
echo "GH_ORG=${{ env.production.GH_ORG }}"
- name: Checkout
uses: actions/checkout@v4

Expand All @@ -45,8 +43,8 @@ jobs:
push: true
tags: ghcr.io/${{ github.repository }}:${{ (github.event_name == 'release' && github.event.release.tag_name) || (github.event_name == 'workflow_dispatch' && github.event.inputs.image_tag) || 'dev' }}
build-args: |
GH_ORG=${{env.GH_ORG}}
GH_EMAIL=${{env.GH_EMAIL}}
GH_ORG=${{secrets.GH_ORG}}
GH_EMAIL=${{secrets.GH_EMAIL}}
HUGGINGFACE_PAT=${{secrets.HUGGINGFACE_PAT}}
dev-test:
Expand Down

0 comments on commit 681a0b2

Please sign in to comment.