mirror of
https://github.com/projectdiscovery/nuclei.git
synced 2026-01-31 15:53:10 +08:00
41 lines
1.3 KiB
YAML
41 lines
1.3 KiB
YAML
name: 🔨 Performance Regression
|
|
|
|
on:
|
|
workflow_call: {}
|
|
workflow_dispatch: {}
|
|
|
|
jobs:
|
|
perf-regression:
|
|
runs-on: ubuntu-latest
|
|
if: github.repository == 'projectdiscovery/nuclei'
|
|
env:
|
|
BENCH_OUT: "/tmp/bench.out"
|
|
steps:
|
|
- uses: actions/checkout@v6
|
|
- uses: projectdiscovery/actions/setup/go@v1
|
|
- uses: projectdiscovery/actions/cache/go-rod-browser@v1
|
|
- uses: projectdiscovery/actions/cache/nuclei@v1
|
|
- run: make build-test
|
|
- run: ./bin/nuclei.test -test.run - -test.bench=. -test.benchmem ./cmd/nuclei/ | tee $BENCH_OUT
|
|
env:
|
|
DISABLE_STDOUT: "1"
|
|
- uses: actions/cache/restore@v5
|
|
with:
|
|
path: ./cache
|
|
key: ${{ runner.os }}-benchmark
|
|
- uses: benchmark-action/github-action-benchmark@v1
|
|
with:
|
|
name: 'RunEnumeration Benchmark'
|
|
tool: 'go'
|
|
output-file-path: ${{ env.BENCH_OUT }}
|
|
external-data-json-path: ./cache/benchmark-data.json
|
|
fail-on-alert: false
|
|
github-token: ${{ secrets.GITHUB_TOKEN }}
|
|
comment-on-alert: true
|
|
summary-always: true
|
|
- uses: actions/cache/save@v5
|
|
if: github.event_name == 'push'
|
|
with:
|
|
path: ./cache
|
|
key: ${{ runner.os }}-benchmark
|