mirror of
https://github.com/rgrgogu/new_starr.git
synced 2026-09-27 00:12:54 +08:00
22 lines
573 B
YAML
22 lines
573 B
YAML
name: Deploy to droplet
|
|
|
|
on:
|
|
push:
|
|
branches: [main]
|
|
workflow_dispatch: {}
|
|
|
|
jobs:
|
|
deploy:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
# The key below is restricted server-side to only run
|
|
# /opt/new_starr/deploy.sh (see authorized_keys forced-command on the
|
|
# droplet) — it can't run arbitrary commands even if this secret leaks.
|
|
- name: Deploy via SSH
|
|
uses: appleboy/ssh-action@v1
|
|
with:
|
|
host: ${{ secrets.DEPLOY_HOST }}
|
|
username: deploy
|
|
key: ${{ secrets.DEPLOY_SSH_KEY }}
|
|
script: deploy
|