ci: sync server via ssh

This commit is contained in:
FoxtrotSierra6829 2023-01-29 16:49:36 +02:00
parent a2d6832d12
commit d53438675a

22
.github/master.yml vendored Normal file
View file

@ -0,0 +1,22 @@
name: Sync server via SSH
on:
push:
branches: [master]
jobs:
build:
# Prevent running this on forks
if: github.repository_owner == 'FoxtrotSierra6829'
runs-on: ubuntu-18.04
steps:
- name: executing remote ssh commands using ssh key
uses: appleboy/ssh-action@v0.1.6
with:
host: ${{ secrets.SSH_HOST }}
username: ${{ secrets.SSH_USER }}
key: ${{ secrets.SSH_KEY }}
port: ${{ secrets.SSH_PORT }}
script: |
cd PairDrop
git pull
sudo docker compose up -d