Merge pull request #62 from nada-deriv/nada/FEQ-2434/local-storage-key #12
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: Build and Deploy Docs to Cloudflare Pages | |
on: | |
push: | |
branches: | |
- master | |
concurrency: | |
group: cloudflare-pages-deploy-docs-${{github.head_ref}} | |
cancel-in-progress: true | |
jobs: | |
build_to_cloudflare_pages: | |
timeout-minutes: 30 | |
runs-on: ubuntu-latest | |
permissions: | |
contents: read | |
deployments: write | |
steps: | |
- name: Checkout to branch | |
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 | |
- name: Setup node | |
uses: actions/setup-node@b39b52d1213e96004bfcb1c61a8a6fa8ab84f3e8 | |
with: | |
node-version: 18.x | |
cache: 'npm' | |
- name: Install npm dependencies | |
run: cd utils-docs && npm ci | |
shell: bash | |
- name: Build docs | |
run: cd utils-docs && npm run build | |
- name: Publish Docs to Cloudflare Pages | |
uses: "deriv-com/shared-actions/.github/actions/publish_to_pages_branch@master" | |
with: | |
CLOUDFLARE_ACCOUNT_ID: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }} | |
CLOUDFLARE_API_TOKEN: ${{ secrets.CLOUDFLARE_API_TOKEN }} | |
project_name: deriv-utils | |
output_dir: ./utils-docs/build | |
branch_name: master | |
cname_url: deriv-utils.pages.dev |