Skip to content

Merge pull request #32 from sustech-cs304/Mandyyymeng-deployment-patch #1

Merge pull request #32 from sustech-cs304/Mandyyymeng-deployment-patch

Merge pull request #32 from sustech-cs304/Mandyyymeng-deployment-patch #1

Workflow file for this run

name: Deploy to Production
on:
push:
branches:
- main
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Set up Node.js
uses: actions/setup-node@v2
with:
node-version: '14'
- name: Install dependencies
run: npm install
- name: Build project
run: npm run build
- name: Deploy to server
uses: appleboy/[email protected]
with:
host: ${{ secrets.SERVER_HOST }}
username: ${{ secrets.SERVER_USER }}
key: ${{ secrets.SERVER_SSH_KEY }}
source: "dist/*"
target: "/path/to/your/project"