-
Notifications
You must be signed in to change notification settings - Fork 1
34 lines (32 loc) · 897 Bytes
/
ci.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
name: CI
on:
push:
branches: [$default-branch]
pull_request:
branches: ['**']
jobs:
build:
runs-on: ubuntu-latest
container:
image: node:20.16.0
# this is the user that CI uses, which is needed to generate files within the repo directory
options: --user 1001
steps:
- name: Check out code
uses: actions/checkout@v3
- name: Setup Node
uses: actions/setup-node@v3
with:
node-version: 20
cache: 'npm'
registry-url: 'https://registry.npmjs.org'
- name: Install dependencies
run: npm ci
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
- name: Build
run: npm run build
- name: Test
run: npm run test -- --ci --maxWorkers=1 --reporters=default
- name: Check Serverless
run: npx serverless package --verbose --stage dev