-
Notifications
You must be signed in to change notification settings - Fork 6
39 lines (39 loc) · 1.05 KB
/
on-push-pr.action.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
name: "[Stage, Production] Push/PR action"
on:
# Trigger conditions. This action will be triggered for each condition. Ex.
# making a PR from stage to master, then pushing a change to stage will trigger
# this action, or all jobs, twice.
push:
branches:
- "stage"
- "master"
paths:
- "src/**"
pull_request:
branches:
- "stage"
- "master"
jobs:
vulnerabilities-scan:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
name: Checkout repository
- uses: debricked/actions/scan@v1
name: Run a vulnerability scan
env:
# Token must have API access scope to run scans
DEBRICKED_TOKEN: ${{ secrets.DEBRICKED_TOKEN }}
code-build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
name: Checkout repository
- uses: actions/setup-node@v3
name: Set NodeJS version
with:
node-version: 18
- name: Install packages
run: "npm ci"
- name: Build source
run: "npm run build"