Skip to content

Commit

Permalink
refactor(ci): move cloudflare build to separate job
Browse files Browse the repository at this point in the history
  • Loading branch information
wmertens committed Jul 18, 2024
1 parent 71c0c24 commit 517719b
Showing 1 changed file with 26 additions and 2 deletions.
28 changes: 26 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -503,8 +503,32 @@ jobs:
packages/docs/dist
packages/docs/server
- name: Cloudflare Pages Deployment
# not the official version, so be careful when updating
deploy-docs:
name: Cloudflare Pages Deployment
if: always() && needs.changes.outputs.build-docs == 'true'
needs:
- build-docs
- changes
runs-on: ubuntu-latest

steps:
- name: Check docs status
if: needs.build-docs.result != 'success'
run: exit 1

- name: Checkout
uses: actions/checkout@v4

- name: Restore docs cache
uses: actions/cache/restore@v4
with:
key: ${{ needs.changes.outputs.hash-docs }}
path: |
packages/docs/dist
packages/docs/server
# not the official version, so be careful when updating
- name: Deploy to Cloudflare Pages
uses: AdrianGonz97/refined-cf-pages-action@c7b767eef599f127d8ce2388d4ed2270d3b750af
with:
apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }}
Expand Down

0 comments on commit 517719b

Please sign in to comment.