-
Notifications
You must be signed in to change notification settings - Fork 1
44 lines (35 loc) · 1000 Bytes
/
zap_scan.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
name: zap_scan
on: [push, pull_request]
permissions:
contents: read
issues: write
jobs:
build-and-scan:
runs-on: ubuntu-latest
timeout-minutes: 60
steps:
- name: Checkout Code
uses: actions/checkout@v3
- name: Set up Python
uses: actions/setup-python@v2
- name: Install Dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
- name: Start Application
run: |
nohup python pastebin.py &
sleep 10 # Wait for the app to start
- name: ZAP Scan
uses: zaproxy/[email protected]
with:
target: 'http://localhost:5000'
cmd_options: '-a'
fail_action: true
issue_title: 'ZAP Scan Results'
token: ${{ secrets.GITHUB_TOKEN }}
- name: Upload ZAP Report
uses: actions/upload-artifact@v3
with:
name: zap-report
path: full_scan_report.html