Skip to content

Commit

Permalink
Update: workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
NguyenAnhTuan1912 committed Aug 8, 2024
1 parent d5b26f1 commit 41d4b4f
Showing 1 changed file with 11 additions and 14 deletions.
25 changes: 11 additions & 14 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,35 +18,32 @@ defaults:
shell: bash

jobs:
prepare:
build_website:
runs-on: ubuntu-latest
steps:
# Check out to repository
- uses: actions/checkout@v4
- name: Check to repository
uses: actions/checkout@v4
with:
submodules: recursive

# Install NODEJS
- uses: actions/setup-node@v4
- name: Install NodeJS
uses: actions/setup-node@v4
with:
node-version: 20

# Install dependencies
- run: npm install
- name: Install dependencies
run: npm install

build_website:
needs: prepare
runs-on: ubuntu-latest
steps:
# Build website with webpack
# The directory is build/gui
- run: npm run build
- name: Build website
run: npm run build

upload_to_s3:
needs: build_website
runs-on: ubuntu-latest
steps:
- uses: shallwefootball/s3-upload-action@master
- name: Upload website to Amazon S3
uses: shallwefootball/s3-upload-action@master
with:
aws_key_id: ${{ secrets.AWS_KEY_ID }}
aws_secret_access_key: ${{ secrets.AWS_SECRET_ACCESS_KEY}}
Expand Down

0 comments on commit 41d4b4f

Please sign in to comment.