-
Notifications
You must be signed in to change notification settings - Fork 28
36 lines (29 loc) · 1002 Bytes
/
build.js.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
# This workflow will do a clean install of node dependencies, minify the website, and deploy it to S3
# For more information see: https://help.github.com/actions/language-and-framework-guides/using-nodejs-with-github-actions
name: Build and Deploy
on:
push:
branches: [ main ]
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
lfs: true
- name: Checkout LFS Objects
run: git lfs fetch --all
- name: Use Node.js '22.x'
uses: actions/setup-node@v3
with:
node-version: 22
- run: npm ci
- run: npm run build --if-present
- name: Configure AWS Credentials
uses: aws-actions/configure-aws-credentials@v1
with:
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }}
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
aws-region: us-east-2
- name: Deploy static site to S3 bucket
run: aws s3 sync ./build/ s3://www.scca-classifier.com --delete