update docs

This commit is contained in:
long2ice
2021-04-28 22:31:51 +08:00
parent 6bd1ed28c1
commit 8c62b68dc8
37 changed files with 568 additions and 53 deletions

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

@@ -0,0 +1,41 @@
name: deploy
on: [push, pull_request]
jobs:
example:
runs-on: ubuntu-latest
steps:
- name: Deploy
uses: appleboy/ssh-action@master
with:
host: ${{ secrets.HOST }}
username: ${{ secrets.USERNAME }}
key: ${{ secrets.KEY }}
port: ${{ secrets.PORT }}
script: |
cd /root/fastapi-admin/
git pull
docker-compose up -d --build
gh-pages:
runs-on: ubuntu-latest
steps:
- name: Install and configure Poetry
uses: snok/install-poetry@v1.1.1
with:
virtualenvs-create: false
- name: Install deps
run: make deps
- name: Build en
run: cd docs/en && mkdocs build
- name: Deploy en
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: docs/en/site
- name: Build zh
run: cd docs/zh && mkdocs build
- name: Deploy zh
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: docs/zh/site
destination_dir: zh

View File

@@ -10,7 +10,7 @@ jobs:
- uses: actions/checkout@v2
- uses: actions/setup-python@v1
with:
python-version: '3.x'
python-version: "3.x"
- name: Install and configure Poetry
uses: snok/install-poetry@v1.1.1
with: