Skip to content

📌 Update tool-versions for Cloudflare deployment #2

📌 Update tool-versions for Cloudflare deployment

📌 Update tool-versions for Cloudflare deployment #2

on: [push]
jobs:
deploy:
runs-on: ubuntu-latest
permissions:
contents: read
deployments: write
name: Deploy to Cloudflare Pages
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Install Node.js
uses: actions/setup-node@v4
with:
cache: "yarn"
node-version-file: .tool-versions
cache-dependency-path: ./website/yarn.lock
- name: Install dependencies
run: yarn install --frozen-lockfile
working-directory: ./website
- name: Build
run: yarn build
working-directory: ./website
- name: Publish
uses: cloudflare/pages-action@1
with:
apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }}
accountId: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }}
projectName: recipe-recommendation
directory: website/dist
gitHubToken: ${{ secrets.GITHUB_TOKEN }}