-
Notifications
You must be signed in to change notification settings - Fork 31
52 lines (50 loc) · 1.75 KB
/
snyk-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
45
46
47
48
49
50
51
52
---
name: snyk vanagon check
on:
push:
branches: '**'
pull_request_target:
types: [opened, reopened, edited, synchronize]
jobs:
snyk_vanagon:
runs-on: ubuntu-latest
steps:
- name: checkout the current PR
uses: actions/checkout@v2
with:
fetch-depth: 0
persist-credentials: false
- name: Run Vanagon Snyk Scan - push
uses: puppetlabs/[email protected]
if: github.event_name == 'push'
with:
snykToken: ${{ secrets.SNYK_PE_TOKEN }}
snykOrg: 'puppet-bolt'
skipProjects: ''
skipPlatforms: ''
urlsToReplace: 'artifactory.delivery.puppetlabs.net,%s/xart,builds.delivery.puppetlabs.net,%s/xbuild'
newHost: 'localhost'
rproxyUser: '${{ secrets.SEC_RPROXY_USER }}'
rproxyKey: '${{ secrets.SEC_RPROXY_KEY }}'
sshKey: '${{ secrets.SECBOT_SSH_KEY }}'
sshKeyName: 'id_ed25519'
branch : ${{ github.ref_name }}
- name: Run Vanagon Snyk Scan - PR
uses: puppetlabs/[email protected]
if: github.event_name != 'push'
with:
snykToken: ${{ secrets.SNYK_PE_TOKEN }}
snykOrg: 'puppet-bolt'
skipProjects: ''
skipPlatforms: ''
urlsToReplace: 'artifactory.delivery.puppetlabs.net,%s/xart,builds.delivery.puppetlabs.net,%s/xbuild'
newHost: 'localhost'
rproxyUser: '${{ secrets.SEC_RPROXY_USER }}'
rproxyKey: '${{ secrets.SEC_RPROXY_KEY }}'
sshKey: '${{ secrets.SECBOT_SSH_KEY }}'
sshKeyName: 'id_ed25519'
branch : ${{ github.ref_name }}
noMonitor: 'true'
- name: Check output
if: steps.scan.outputs.vulns != ''
run: echo "Vulnerabilities detected; ${{ steps.scan.outputs.vulns }}" && exit 1