Skip to content

Commit 9c42473

Browse files
committed
chore: add Black Duck scan workflow
1 parent bb89c5e commit 9c42473

File tree

1 file changed

+59
-0
lines changed

1 file changed

+59
-0
lines changed

.github/workflows/black-duck.yml

Lines changed: 59 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,59 @@
1+
name: BlackDuck scan
2+
3+
concurrency:
4+
group: ${{ github.workflow }}-${{ github.ref }}
5+
cancel-in-progress: true
6+
7+
on:
8+
pull_request:
9+
branches:
10+
- develop
11+
paths:
12+
- "src/**"
13+
14+
schedule:
15+
- cron: "0 0 * * 1" # Every Monday at midnight UTC
16+
17+
workflow_dispatch:
18+
inputs:
19+
fail-on-scan-error:
20+
description: "Fail the workflow if the scan fails"
21+
required: false
22+
type: boolean
23+
default: false
24+
25+
permissions:
26+
id-token: write # Required by Akeyless
27+
contents: write
28+
packages: read
29+
security-events: write # Required for Black Duck to report security findings
30+
31+
jobs:
32+
scan:
33+
runs-on: ubuntu-24.04
34+
35+
steps:
36+
- name: Checkout code
37+
uses: actions/checkout@v6
38+
with:
39+
fetch-depth: 0 # Fetch all history for all branches and tags
40+
41+
- name: Install modules
42+
run: npm ci --no-audit --no-fund
43+
44+
- name: Scan project
45+
uses: telerik/actions/black-duck-scan@master
46+
with:
47+
ak-vault-token: ${{ secrets.AK_VAULT_TOKEN_BLACK_DUCK }}
48+
additional-parameters: >-
49+
--detect.detector.search.depth=30
50+
--detect.detector.buildless true
51+
--detect.excluded.directories="/.bridge/Blackduck SCA Detect Execution/detect/tools/,/.github/,/.husky/,/.vscode/,/e2e/,/dist/"
52+
--detect.excluded.detector.types=NUGET
53+
--detect.impact.analysis.enabled=true
54+
--detect.npm.dependency.types.excluded=DEV
55+
--aggressiveness-level high
56+
source: ${{ github.workspace }}
57+
skip-checkout: true
58+
fail-on-scan-error: ${{ github.event_name == 'pull_request' || (inputs.fail-on-scan-error && github.event_name != 'schedule') }}
59+
blackduck-project-group: Web

0 commit comments

Comments
 (0)