Last fuzzing PR for a while hopefully (#929)
This commit is contained in:
parent
211a852efc
commit
7b35c6e5eb
16
.github/workflows/fuzz.yml
vendored
16
.github/workflows/fuzz.yml
vendored
@ -1,7 +1,11 @@
|
|||||||
name: Sus Fuzzing
|
name: Sus Fuzzing
|
||||||
|
|
||||||
on:
|
on:
|
||||||
|
pull_request:
|
||||||
|
types: [labeled, synchronize]
|
||||||
push:
|
push:
|
||||||
|
paths:
|
||||||
|
- "**.zig"
|
||||||
branches:
|
branches:
|
||||||
- master
|
- master
|
||||||
schedule:
|
schedule:
|
||||||
@ -15,6 +19,7 @@ on:
|
|||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
fuzz:
|
fuzz:
|
||||||
|
if: github.event_name != 'pull_request' || contains(github.event.pull_request.labels.*.name, 'pr:fuzz')
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
@ -23,6 +28,16 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
swap-size-gb: 10
|
swap-size-gb: 10
|
||||||
|
|
||||||
|
- name: Default fuzzing duration
|
||||||
|
if: github.event_name != 'pull_request'
|
||||||
|
run: |
|
||||||
|
FUZZING_DURATION=${{ github.event.inputs.fuzzing_duration }}
|
||||||
|
|
||||||
|
- name: PR fuzzing duration
|
||||||
|
if: github.event_name == 'pull_request'
|
||||||
|
run: |
|
||||||
|
FUZZING_DURATION=15m
|
||||||
|
|
||||||
- name: Grab zig
|
- name: Grab zig
|
||||||
uses: goto-bus-stop/setup-zig@v1
|
uses: goto-bus-stop/setup-zig@v1
|
||||||
with:
|
with:
|
||||||
@ -69,7 +84,6 @@ jobs:
|
|||||||
continue-on-error: true
|
continue-on-error: true
|
||||||
run: |
|
run: |
|
||||||
cd $GITHUB_WORKSPACE/sus
|
cd $GITHUB_WORKSPACE/sus
|
||||||
FUZZING_DURATION=${{ github.event.inputs.fuzzing_duration }}
|
|
||||||
{ sleep ${FUZZING_DURATION:-1h}; pkill -9 sus; } &
|
{ sleep ${FUZZING_DURATION:-1h}; pkill -9 sus; } &
|
||||||
./zig-out/bin/sus $GITHUB_WORKSPACE/zls/zig-out/bin/zls markov $GITHUB_WORKSPACE/zig/lib/std
|
./zig-out/bin/sus $GITHUB_WORKSPACE/zls/zig-out/bin/zls markov $GITHUB_WORKSPACE/zig/lib/std
|
||||||
|
|
||||||
|
16
.github/workflows/main.yml
vendored
16
.github/workflows/main.yml
vendored
@ -122,19 +122,3 @@ jobs:
|
|||||||
REMOTE_HOST: ${{ secrets.WEBSITE_DEPLOY_HOST }}
|
REMOTE_HOST: ${{ secrets.WEBSITE_DEPLOY_HOST }}
|
||||||
REMOTE_USER: ${{ secrets.WEBSITE_DEPLOY_USER }}
|
REMOTE_USER: ${{ secrets.WEBSITE_DEPLOY_USER }}
|
||||||
TARGET: ${{ secrets.WEBSITE_DEPLOY_FOLDER }}
|
TARGET: ${{ secrets.WEBSITE_DEPLOY_FOLDER }}
|
||||||
|
|
||||||
- name: Instruct fuzzing server to pull latest zls
|
|
||||||
if: ${{ matrix.os == 'ubuntu-latest' && github.ref == 'refs/heads/master' && github.repository_owner == 'zigtools' }}
|
|
||||||
uses: appleboy/ssh-action@v0.1.7
|
|
||||||
with:
|
|
||||||
host: fuzzing.zigtools.org
|
|
||||||
username: ${{ secrets.FUZZING_SSH_USERNAME }}
|
|
||||||
key: ${{ secrets.FUZZING_SSH_PRIVKEY }}
|
|
||||||
script: |
|
|
||||||
systemctl stop fuzzing
|
|
||||||
systemctl stop fuzzing-web
|
|
||||||
cd /root/sus
|
|
||||||
./script/setup.sh
|
|
||||||
systemctl start fuzzing
|
|
||||||
sleep 5s
|
|
||||||
systemctl start fuzzing-web
|
|
||||||
|
Loading…
Reference in New Issue
Block a user