Skip to content

Commit 8f11ae5

Browse files
authored
deploy-dev setup
1 parent a7fa732 commit 8f11ae5

File tree

1 file changed

+31
-0
lines changed

1 file changed

+31
-0
lines changed

.github/workflows/deploy-dev.yml

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
name: deploy-dev
2+
3+
on:
4+
workflow_dispatch:
5+
6+
jobs:
7+
deploy:
8+
name: Deploy
9+
runs-on: ubuntu-latest
10+
steps:
11+
- name: Checkout
12+
uses: actions/checkout@v4
13+
14+
- name: Setup Node
15+
uses: actions/setup-node@v4
16+
with:
17+
node-version: "20.11.1"
18+
19+
- name: Build & Export
20+
run: |
21+
yarn install
22+
yarn build
23+
24+
- name: Deploy to S3 (Prod)
25+
env:
26+
AWS_ACCESS_KEY_ID: ${{ secrets.DEV_AWS_ACCESS_KEY_ID }}
27+
AWS_SECRET_ACCESS_KEY: ${{ secrets.DEV_AWS_SECRET_ACCESS_KEY }}
28+
AWS_REGION: ap-southeast-2
29+
run: |
30+
aws s3 sync ./dist s3://snuxiuserbucket --delete
31+
aws cloudfront create-invalidation --distribution-id E1TF16G2587C0Z --paths "/*"\

0 commit comments

Comments
 (0)