Add workflow_dispatch
trigger
#2
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: Guides API deploy | |
on: | |
push: | |
branches: | |
- main | |
paths-ignore: | |
- README.md | |
- .gitignore | |
workflow_dispatch: | |
jobs: | |
deploy: | |
name: Build | |
runs-on: ubuntu-20.04 | |
steps: | |
- name: deploy | |
uses: appleboy/[email protected] | |
with: | |
host: ${{ secrets.API_SERVER_HOST }} | |
username: ${{ secrets.API_SERVER_USERNAME }} | |
password: ${{ secrets.API_SERVER_PASSWORD }} | |
script: | | |
cd ${{ secrets.API_SERVER_FOLDER }}/manuals | |
git checkout main | |
git fetch | |
git reset --hard origin/main | |
git clean -df | |
git pull | |
docker compose up -d --build |