forked from ErdemOzgen/blackdagger
-
Notifications
You must be signed in to change notification settings - Fork 0
40 lines (34 loc) · 877 Bytes
/
gosec.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
name: Run Gosec and ZAP Scan
on:
workflow_dispatch:
jobs:
tests:
runs-on: ubuntu-latest
env:
GO111MODULE: on
steps:
- name: Checkout Source
id: checkout
uses: actions/checkout@v3
- name: Generate SBOM
id: sbom
uses: anchore/sbom-action@v0
- name: Start Application
id: start-app
run: blackdagger-server
- name: Wait for Application to Start
id: wait-app
run: sleep 10
- name: ZAP Full Scan
id: zap-scan
uses: zaproxy/action-full-scan@v0.10.0
with:
target: http://localhost:8080
- name: Run Gosec Security Scanner
id: gosec
uses: securego/gosec@master
with:
args: ./...
- name: Check Gosec Result
if: steps.gosec.outcome == 'failure'
run: exit 0