Self-hosting

Cloudflare Pages Setup for kb.costabile.com.au

Step-by-step deployment and authentication checklist for publishing this knowledge base to Cloudflare Pages.

Updated 17/06/2026 CloudflarePagesAccessDNSDeployment

Overview

The recommended deployment is:

GitHub repository -> Cloudflare Pages build -> kb.costabile.com.au -> Cloudflare Access login

This keeps the site static, fast, cheap, and secure.

Cloudflare Pages settings

When creating the Pages project:

SettingValue
Framework presetAstro
Build commandnpm run build
Build output directorydist
Root directory/
Node version22

If Cloudflare does not automatically use Node 22, add an environment variable:

NODE_VERSION=22

Custom domain

In Cloudflare Pages:

  1. Open the Pages project.
  2. Go to Custom domains.
  3. Add kb.costabile.com.au.
  4. If costabile.com.au DNS is already managed by Cloudflare, Cloudflare will create the required DNS record automatically.

Expected DNS shape:

kb.costabile.com.au -> your-pages-project.pages.dev

Cloudflare usually manages this as a proxied CNAME.

Authentication with Cloudflare Access

Use Cloudflare Zero Trust Access to protect the site.

  1. Open Cloudflare dashboard.
  2. Go to Zero Trust.
  3. Go to AccessApplications.
  4. Add an application.
  5. Choose Self-hosted.
  6. Application domain: kb.costabile.com.au.
  7. Add an allow policy.
  8. Include your email address.
  9. Save and test in a private/incognito browser window.

Start simple:

FieldValue
Policy nameAllow John
ActionAllow
IncludeEmails
EmailJohn’s email address

Later you can add family members or a trusted collaborator.

Security notes

Deployment checklist