From f104327922eb2a56ebefca3665ad57f2d654e1f7 Mon Sep 17 00:00:00 2001 From: m32 Date: Sun, 10 Nov 2024 00:07:36 -0700 Subject: [PATCH] add workflow to deploy to cloudflare pages --- .github/workflows/pages-deployment.yaml | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 .github/workflows/pages-deployment.yaml diff --git a/.github/workflows/pages-deployment.yaml b/.github/workflows/pages-deployment.yaml new file mode 100644 index 0000000..2d6cf54 --- /dev/null +++ b/.github/workflows/pages-deployment.yaml @@ -0,0 +1,23 @@ +on: [push] +jobs: + deploy: + runs-on: ubuntu-latest + permissions: + contents: read + deployments: write + name: Deploy to Cloudflare Pages + steps: + - name: Checkout + uses: actions/checkout@v3 + - name: Install Nix + uses: cachix/install-nix-action@v30 + - name: Build + run: nix build + - name: Publish + uses: cloudflare/pages-action@v1 + with: + apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }} + accountId: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }} + projectName: m32.io # e.g. 'my-project' + directory: result # e.g. 'dist' + gitHubToken: ${{ secrets.GITHUB_TOKEN }}