Updating workflow

This commit is contained in:
Skylar Grant 2021-10-19 18:57:45 -04:00
parent d8e5e56514
commit ba80d11628

View File

@ -1,6 +1,9 @@
name: Node.js CI/CD
on: [push] # tells github to run this on any push to the repository
on:
push: # tells github to run this on any push to the repository
branches:
- main
jobs:
deploy:
@ -15,8 +18,8 @@ jobs:
key: ${{ secrets.KEY }}
port: ${{ secrets.PORT }}
script: |
cd infrabot # we move into our app's folder
cd nodbot # we move into our app's folder
git pull # we pull any changes from git
npm prune # we remove any unused dependencies
npm install # we install any missing dependencies
pm2 reload all # we reload the app via PM2
pm2 reload nodbot # we reload the app via PM2