notes issue #36
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: Deploy App | |
on: | |
push: | |
branches: [master] | |
jobs: | |
build: | |
name: Build | |
runs-on: ubuntu-latest | |
steps: | |
- name: SSH Exec | |
uses: appleboy/ssh-action@v1.0.0 | |
with: | |
host: ${{ secrets.HOST }} | |
username: ${{ secrets.USERNAME }} | |
port: ${{ secrets.PORT }} | |
key: ${{ secrets.KEY }} | |
script: | | |
eval `ssh-agent -s` | |
ssh-add ~/.ssh/git_id_rsa | |
cd ${{ secrets.PATH }} | |
git pull | |
export NVM_DIR=~/.nvm | |
source ~/.nvm/nvm.sh | |
nvm use 20 | |
npm install | |
npm run build | |
${{ secrets.node }}/node ${{ secrets.node }}/pm2 restart thelonelylands --silent |