Problem
Static frontends (SvelteKit with adapter-static, Vite builds, etc.)
are currently deployed as Nginx containers on the VPS alongside
backend services. This wastes VPS resources on serving static files
that a CDN handles better for free.
Proposal
Add a Cloudflare Pages deploy target. The workflow would be:
- Build the static site locally (or in CI)
- Deploy the build output to Cloudflare Pages via the Wrangler CLI
// catapulta.toml or equivalent
[[apps]]
name = "scribe-web"
provider = "cloudflare-pages"
project = "scribe-web"
build_dir = "build"
build_cmd = "npm run build"
The deployer would:
- Run the build command
- Call
wrangler pages deploy {build_dir} --project-name {project}
Cloudflare Pages provides:
- Free tier with unlimited bandwidth
- Global CDN
- Automatic HTTPS
- Custom domain support
- Preview deployments per branch
Prerequisites
wrangler CLI installed
- Cloudflare account with API token
Problem
Static frontends (SvelteKit with adapter-static, Vite builds, etc.)
are currently deployed as Nginx containers on the VPS alongside
backend services. This wastes VPS resources on serving static files
that a CDN handles better for free.
Proposal
Add a Cloudflare Pages deploy target. The workflow would be:
The deployer would:
wrangler pages deploy {build_dir} --project-name {project}Cloudflare Pages provides:
Prerequisites
wranglerCLI installed