From 468a3f81cb06a323192762616006afa0abd0507e Mon Sep 17 00:00:00 2001 From: hieuntg81 Date: Sun, 2 Aug 2026 08:55:45 +0700 Subject: [PATCH] ci: deploy documentation with Workers --- .github/workflows/docs.yml | 22 ---------------------- .gitignore | 1 + website/wrangler.jsonc | 14 ++++++++++++++ 3 files changed, 15 insertions(+), 22 deletions(-) create mode 100644 website/wrangler.jsonc diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml index f98cc57..75772a4 100644 --- a/.github/workflows/docs.yml +++ b/.github/workflows/docs.yml @@ -23,25 +23,3 @@ jobs: cache-dependency-path: website/package-lock.json - run: npm ci --prefix website - run: npm run build --prefix website - - uses: actions/upload-artifact@v4 - with: - name: website-build - path: website/build - if-no-files-found: error - - deploy: - needs: build - if: github.event_name == 'push' && github.ref == 'refs/heads/main' - runs-on: ubuntu-latest - steps: - - uses: actions/download-artifact@v4 - with: - name: website-build - path: website/build - - uses: cloudflare/wrangler-action@v3 - with: - apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }} - accountId: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }} - command: pages deploy website/build --project-name=linear-cli-docs --branch=main - - name: Smoke test production site - run: curl --fail --retry 5 --retry-delay 5 --retry-connrefused https://linear-cli.enolalab.com/ diff --git a/.gitignore b/.gitignore index 67a0a45..ad11698 100644 --- a/.gitignore +++ b/.gitignore @@ -32,3 +32,4 @@ Thumbs.db # Config (may contain API keys) config.yaml +.wrangler/ diff --git a/website/wrangler.jsonc b/website/wrangler.jsonc new file mode 100644 index 0000000..f5dfd6f --- /dev/null +++ b/website/wrangler.jsonc @@ -0,0 +1,14 @@ +{ + "$schema": "./node_modules/wrangler/config-schema.json", + "name": "linear-cli-docs", + "compatibility_date": "2026-08-02", + "assets": { + "directory": "./build" + }, + "routes": [ + { + "pattern": "linear-cli.enolalab.com", + "custom_domain": true + } + ] +}