This repository has been archived by the owner on Dec 20, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 6
54 lines (46 loc) · 1.73 KB
/
whitesource.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
53
54
name: NPM WhiteSource Scan
on:
pull_request:
branches: [ master* ]
jobs:
WhiteSource-Unified-Agent:
runs-on: ubuntu-latest
timeout-minutes: 20
strategy:
fail-fast: false
matrix:
node-version: [14.x]
steps:
- name: Checkout https://github.com/${{ github.repository }}@${{ github.ref }}
uses: actions/checkout@v2
with:
persist-credentials: false
- name: Configure AWS Credentials
uses: aws-actions/configure-aws-credentials@v1
with:
aws-access-key-id: ${{ secrets.AWS_C2FO_GITHUB_ACTIONS_KEY }}
aws-secret-access-key: ${{ secrets.AWS_C2FO_GITHUB_ACTIONS_SECRET }}
aws-region: us-west-2
- name: Set up Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}
- uses: actions/cache@v2
with:
path: ~/.npm
key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }}
restore-keys: |
${{ runner.os }}-node-
- name: Install dependencies
run: npm install --only=prod
- name: WhiteSource Unified Agent Scan
env:
WS_APIKEY: ${{secrets.WHITESOURCE_ORG_API_KEY}}
WS_USERKEY: ${{secrets.WHITESOURCE_PRIORTIZE_USERKEY}}
WS_WSS_URL: https://saas.whitesourcesoftware.com/agent
WS_PRODUCTNAME: GH_${{github.event.repository.name}}
WS_PROJECTNAME: GH_${{github.event.repository.name}}
run: |
aws s3api get-object --bucket secops-approved-libraries --key whitesource/wss-unified-agent.jar ./wss-unified-agent.jar
echo Unified Agent downloaded successfully
java -jar wss-unified-agent.jar