forked from mCaptcha/website
CI: auto deploy
This commit is contained in:
parent
7ef879481d
commit
eadcef120e
1 changed files with 32 additions and 27 deletions
9
.github/workflows/main.yml
vendored
9
.github/workflows/main.yml
vendored
|
@ -23,7 +23,7 @@ jobs:
|
|||
- name: Install Hugo
|
||||
uses: peaceiris/actions-hugo@v2
|
||||
with:
|
||||
hugo-version: 'latest'
|
||||
hugo-version: "latest"
|
||||
extended: true
|
||||
|
||||
- name: Check install Hugo
|
||||
|
@ -38,8 +38,13 @@ jobs:
|
|||
- name: Build production website
|
||||
run: npm run build
|
||||
|
||||
- name: Deploy
|
||||
- name: Deploy to gh-pages
|
||||
uses: peaceiris/actions-gh-pages@v3
|
||||
with:
|
||||
github_token: ${{ secrets.GITHUB_TOKEN }}
|
||||
publish_dir: ./public
|
||||
|
||||
- name: deploy
|
||||
if: ${{ github.event_name == 'push' && github.ref == 'refs/heads/master' }}
|
||||
run: >-
|
||||
curl --location --request POST "https://deploy.batsense.net/api/v1/update" --header 'Content-Type: application/json' --data-raw "{ \"secret\": \"${{ secrets.DEPLOY_TOKEN }}\", \"branch\": \"gh-pages\" }"
|
||||
|
|
Loading…
Reference in a new issue