71 lines
2.1 KiB
YAML
71 lines
2.1 KiB
YAML
name: Loadtest
|
|
|
|
on:
|
|
push:
|
|
branches:
|
|
- main
|
|
tags:
|
|
- v*
|
|
pull_request:
|
|
branches:
|
|
- main
|
|
|
|
jobs:
|
|
Loadtest-PR-Nix:
|
|
name: Loadtest PR (Nix)
|
|
if: ${{ github.event_name == 'pull_request' }}
|
|
runs-on: ubuntu-latest
|
|
concurrency:
|
|
group: ${{ github.workflow }}-${{ github.ref }}
|
|
cancel-in-progress: true
|
|
steps:
|
|
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4
|
|
with:
|
|
fetch-depth: 0
|
|
- name: Setup Nix Environment
|
|
uses: ./.github/actions/setup-nix
|
|
with:
|
|
tools: loadtest
|
|
- uses: WyriHaximus/github-action-get-previous-tag@04e8485ecb6487243907e330d522ff60f02283ce # v1.4.0
|
|
id: get-latest-tag
|
|
with:
|
|
prefix: v
|
|
- name: Run loadtest
|
|
run: |
|
|
postgrest-loadtest-against main ${{ steps.get-latest-tag.outputs.tag }}
|
|
postgrest-loadtest-report > loadtest/loadtest.md
|
|
- name: Upload report
|
|
uses: actions/upload-artifact@5d5d22a31266ced268874388b861e4b58bb5c2f3 # v4
|
|
with:
|
|
name: loadtest.md
|
|
path: loadtest/loadtest.md
|
|
if-no-files-found: error
|
|
|
|
Loadtest-Merge-Nix:
|
|
name: Loadtest Merge (Nix)
|
|
if: ${{ github.event_name == 'push' }}
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4
|
|
with:
|
|
fetch-depth: 0
|
|
- uses: WyriHaximus/github-action-get-previous-tag@04e8485ecb6487243907e330d522ff60f02283ce # v1.4.0
|
|
id: get-latest-tag
|
|
with:
|
|
prefix: v
|
|
- name: Setup Nix Environment
|
|
uses: ./.github/actions/setup-nix
|
|
with:
|
|
tools: loadtest
|
|
- name: Run loadtest
|
|
run: |
|
|
postgrest-loadtest-against ${{ steps.get-latest-tag.outputs.tag }}
|
|
postgrest-loadtest-report > loadtest/loadtest.md
|
|
- name: Upload report
|
|
uses: actions/upload-artifact@5d5d22a31266ced268874388b861e4b58bb5c2f3 # v4
|
|
with:
|
|
name: loadtest.md
|
|
path: loadtest/loadtest.md
|
|
if-no-files-found: error
|
|
|