Skip to content

Add option to "Read and Agree" with mentor and mentee guides at the application process #393

Add option to "Read and Agree" with mentor and mentee guides at the application process

Add option to "Read and Agree" with mentor and mentee guides at the application process #393

Workflow file for this run

name: CI/CD
on:
push:
branches:
- main
pull_request:
branches:
- main
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v3
- name: Use Node.js
uses: actions/setup-node@v3
with:
node-version: '20'
- name: Install dependencies
run: npm ci
- name: Unit tests
run: npm run test
- name: ESLint check
run: npm run lint
- name: Build
run: npm run build
deploy:
if: github.event_name == 'push'
runs-on: ubuntu-latest
needs: build
steps:
- name: Deploy to server
env:
SERVER_PASSWORD: ${{ secrets.SERVER_PASSWORD }}
run: |
sudo apt-get update
sudo apt-get install -y sshpass
sshpass -p "$SERVER_PASSWORD" ssh -o StrictHostKeyChecking=no [email protected] << 'EOF'
cd scholarx-frontend
git pull
npm install
npm run build
sudo cp -r dist/* /var/www/scholarx/
sudo systemctl restart nginx
EOF