ref #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: Server Deploy | |
on: | |
push: | |
branches: | |
- master | |
jobs: | |
deploy-job: | |
runs-on: ubuntu-latest | |
steps: | |
- name: ssh connect to server | |
uses: appleboy/ssh-action@master | |
with: | |
host: ${{ secrets.HOST }} | |
port: ${{ secrets.PORT }} | |
username: ${{ secrets.USERNAME }} | |
password: ${{ secrets.PASSWORD }} | |
script: | | |
cd /var/www/finister-radio/server | |
git pull origin master | |
npm i | |
pm2 stop ./src/server-prod.js | |
pm2 start ./src/server-prod.js --name finister-radio | |
exit |