generated from andersonbosa/dothub
-
-
Notifications
You must be signed in to change notification settings - Fork 0
45 lines (36 loc) · 1.11 KB
/
security-goat-demo.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
45
name: "[security] Security Goat in pipeline"
on:
workflow_dispatch: {}
push:
branches:
- main
pull_request:
branches:
- main
permissions:
contents: read
env:
SECURITY_GOAT_IMAGE: ghcr.io/andersonbosa/security-goat:latest
GOAT_GITHUB_TOKEN: ${{ secrets.CI_GITHUB_ACCESS_TOKEN }}
GOAT_GITHUB_OWNER: ${{ github.repository_owner }}
GOAT_GITHUB_REPO: ${{ github.event.repository.name }}
GOAT_SEVERITY_LIMITS_CRITICAL: 0
GOAT_SEVERITY_LIMITS_HIGH: 0
GOAT_SEVERITY_LIMITS_MEDIUM: 0
GOAT_SEVERITY_LIMITS_LOW: 0
jobs:
through-docker:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Pull Docker image from GitHub Container Registry
run: docker pull ${{ env.SECURITY_GOAT_IMAGE }}
- name: Verify Version
run: docker run ${{ env.SECURITY_GOAT_IMAGE }} version
- name: Set up env file
run: |
env | grep 'GOAT' >.env
- name: "[Perform Security Gate] Verify security alerts from DependaBot"
run: |
docker run --env-file=.env ${{ env.SECURITY_GOAT_IMAGE }} --verbose --error 20