Merge branch 'staging' of https://github.com/Asadaaaaa/sersow-view in… #50
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Sersow Web CD Staging | |
on: | |
push: | |
branches: [ "staging" ] | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- name: executing remote ssh commands using password | |
uses: appleboy/ssh-action@v0.1.8 | |
with: | |
host: ${{ secrets.HOST }} | |
username: ${{ secrets.USERNAME }} | |
password: ${{ secrets.PASSWORD }} | |
port: ${{ secrets.PORT }} | |
script: | | |
cd app/sersow/web/staging | |
git reset --hard HEAD | |
git pull origin staging | |
npm i | |
npm run build | |
pm2 restart sersow-web-staging |