-
Notifications
You must be signed in to change notification settings - Fork 0
38 lines (32 loc) · 1019 Bytes
/
prod_push_to_s3.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: production Build and deploy to S3
on:
push:
branches:
- production
jobs:
build-and-deploy:
runs-on: ubuntu-latest
permissions:
id-token: write
contents: read
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Use Node.js 20.x
uses: actions/setup-node@v4
with:
node-version: '20.x'
- name: npm install, and build
run: |
printf "@fortawesome:registry=https://npm.fontawesome.com/\n//npm.fontawesome.com/:_authToken=${FA_AUTH_TOKEN}" >> ~/.npmrc
npm ci
npm run build
env:
FA_AUTH_TOKEN: ${{ secrets.FA_AUTH_TOKEN }}
- name: Configure AWS Credentials
uses: aws-actions/configure-aws-credentials@v4
with:
role-to-assume: arn:aws:iam::922311303087:role/github-actions@dpd-zoning-summary-generator@production
aws-region: us-east-1
- name: Deploy static site to S3 bucket
run: aws s3 sync dist s3://dpd-zoning-summary-generator-dev --delete