Added the shortener

This commit is contained in:
2022-07-19 21:20:23 +02:00
parent 0233a2866b
commit 2e16cfa2cb
8 changed files with 3911 additions and 0 deletions

View File

@ -0,0 +1,17 @@
name: Deploy to SSH
on:
push:
branches: [ master ]
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- name: Deploy NodeJS app
uses: garygrossgarten/github-action-ssh@release
with:
host: ${{ secrets.REMOTE_HOST }}
username: ${{ secrets.REMOTE_USER }}
privateKey: ${{ secrets.REMOTE_SSH_KEY }}
command: "cd /var/www/shortener/ && ssh-agent bash -c 'ssh-add ~/.ssh/shortener_rsa; git reset --hard && git pull origin master && git pull origin master' && npm i && cd /var/www/ && pm2 restart shortener"