Skip to content

Commit

Permalink
Enabling Github Actions CI/CD
Browse files Browse the repository at this point in the history
  • Loading branch information
rohhn authored and rohhn committed Jan 29, 2024
1 parent 6b80c40 commit 3b2ba48
Showing 1 changed file with 42 additions and 0 deletions.
42 changes: 42 additions & 0 deletions .github/workflows/github_deploy.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
name: FER App Deploy

on:
push:
branches:
- main

jobs:
build:

runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2

- name: Check Front-end repo
uses: actions-setup-node@v2
with:
- node-version: 21.x
run:
cd svelte_client
npm install
npm run build

- name: Deploy using SSH
uses: appleboy/ssh-action@master
with:
host: ${{ secrets.HOST }}
username: ${{ secrets.USER }}
PORT: ${{ secrets.PORT }}
key: ${{ secrets.SSHKEY }}
script: |
cd Facial-Emotion-Recognition
git pull origin main
# Build front-end
cd svelte_client
npm install
npm run build
# restart web server
sudo /bin/systemctl restart fer_app.service fer_app.socket nginx

0 comments on commit 3b2ba48

Please sign in to comment.