-
Notifications
You must be signed in to change notification settings - Fork 0
38 lines (32 loc) · 1008 Bytes
/
CD.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
name: afterschool-CD-with-xquare-deployment-action
on:
push:
branches: [ main ]
jobs:
build:
permissions:
id-token: write
contents: read
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: NodeJS Installation ${{ matrix.node-version }}
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}
- name: build
run: npm run build
working-directory: ./src
- name: Cache node modules
uses: actions/cache@v2
with:
path: node_modules
key: ${{ runner.os }}-node-modules-${{ hashFiles('**/package-lock.json') }}
restore-keys: |
${{ runner.os }}-node-modules-
- name: Deploy to xquare
uses: team-xquare/xquare-deployment-action@master
with:
environment: YOUR_ENVIRONMENT
access_key: ${{ secrets.ACCESS_KEY }}
github_token: ${{ secrets.PERSONAL_ACCESS_TOKEN }}