Add gitea workflow dependencies
All checks were successful
Init / execute-tests (push) Successful in 3s

This commit is contained in:
karthik 2023-10-28 11:23:31 +02:00
parent 9d4d60aaa6
commit 99bd6d15ad
3 changed files with 29 additions and 5 deletions

View File

@ -1,11 +1,14 @@
name: Build name: Build
on: [push] on:
workflow_run:
workflows: ["Tests"]
types:
- completed
jobs: jobs:
execute-tests: execute-tests:
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- name: Set running - name: Set running
if: always()
run: | run: |
curl -v -X POST https://barrelsofdata.com/api/v1/git/action/status/publish \ curl -v -X POST https://barrelsofdata.com/api/v1/git/action/status/publish \
-H 'X-API-KEY: ${{ secrets.STATUS_PUBLISH_API_KEY }}' \ -H 'X-API-KEY: ${{ secrets.STATUS_PUBLISH_API_KEY }}' \
@ -20,7 +23,7 @@ jobs:
distribution: 'temurin' distribution: 'temurin'
- name: Build - name: Build
id: build id: build
run: ./gradlew bootJar -x test run: ./gradlew build -x test
- name: Publish status - name: Publish status
if: always() if: always()
run: | run: |

View File

@ -0,0 +1,18 @@
name: Init
on: [push]
jobs:
execute-tests:
runs-on: ubuntu-latest
steps:
- name: Reset test status
run: |
curl -v -X POST https://barrelsofdata.com/api/v1/git/action/status/publish \
-H 'X-API-KEY: ${{ secrets.STATUS_PUBLISH_API_KEY }}' \
-H 'Content-Type: application/json' \
-d '{"action":"${{ gitea.repository }}/action/Tests","status":"starting"}'
- name: Reset build status
run: |
curl -v -X POST https://barrelsofdata.com/api/v1/git/action/status/publish \
-H 'X-API-KEY: ${{ secrets.STATUS_PUBLISH_API_KEY }}' \
-H 'Content-Type: application/json' \
-d '{"action":"${{ gitea.repository }}/action/Build","status":"waiting for test"}'

View File

@ -1,11 +1,14 @@
name: Tests name: Tests
on: [push, pull_request] on:
workflow_run:
workflows: ["Init"]
types:
- completed
jobs: jobs:
execute-tests: execute-tests:
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- name: Set running - name: Set running
if: always()
run: | run: |
curl -v -X POST https://barrelsofdata.com/api/v1/git/action/status/publish \ curl -v -X POST https://barrelsofdata.com/api/v1/git/action/status/publish \
-H 'X-API-KEY: ${{ secrets.STATUS_PUBLISH_API_KEY }}' \ -H 'X-API-KEY: ${{ secrets.STATUS_PUBLISH_API_KEY }}' \