Add GitHub Action deploy.

This commit is contained in:
John Espiritu 2021-07-25 22:38:54 +08:00
parent b2ba582cec
commit d119b3bb21
1 changed files with 23 additions and 0 deletions

23
.github/workflows/deploy.yml vendored Normal file
View File

@ -0,0 +1,23 @@
name: Deploy
on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: SCP Files
uses: appleboy/scp-action@master
with:
host: ${{ secrets.DROPLET_IP }}
username: ${{ secrets.DROPLET_USER }}
key: ${{ secrets.DROPLET_KEY }}
source: "dist/*"
target: ${{ secrets.DEPLOY_PATH }}
strip_components: 1
rm: true