Static Edge Publisher: Cloudflare Pages, Netlify & Local ZIP
Keep Daypress running privately on localhost or an internal studio VM for editing and AI agent workflows, then publish a pre-rendered static bundle to global edge CDNs with zero public origin server to patch.
What the static compiler generates
When you trigger a build in Publish → Static Edge (/d-admin/publish) or call daypress_publish_site, Daypress crawls every published route and writes a self-contained artifact tree:
static-export/
├── index.html # Pre-rendered front page with DayStudio CSS & Schema.org JSON-LD
├── <slug>/index.html # Every published post, page, CPT item & localized /{lang}/... route
├── category/<slug>/index.html # Paginated category, tag, author & CPT archive directories
├── uploads/... # Referenced originals + AVIF/WebP derivatives
├── og-image/<id>.png # Pre-baked 1200x630 Rust-rendered OpenGraph social cards
├── sitemap.xml & robots.txt # Canonical edge URLs rewritten to your production domain
├── feed/index.xml # RSS 2.0 & Atom syndication feeds
├── search-index.json # Client-side instant search index for Cmd+K modal on static hosts
└── _redirects & 404.html # Edge 301/302 rules compiled from daypress_redirects
Deploy to Cloudflare Pages
- In Cloudflare Dashboard, copy your Account ID and create an API Token with
Cloudflare Pages: Edit(and optionalZone DNS: Editfor 1-click custom domain CNAME binding). - Open
/d-admin/publish, select Cloudflare Pages, and enter your Public Site URL (e.g.https://mysite.com), Account ID, Project Name, and API Token (stored encrypted in SQLite). - Click Publish to Edge. Daypress uploads changed asset hashes directly to Cloudflare's Direct Upload API and records the live deployment URL and manifest in your history table.
Deploy to Netlify or export a portable .zip
Select Netlify and provide a Personal Access Token + Site ID for SHA-1 delta uploads (only modified HTML/media digests are transmitted), or choose Local Directory / ZIP to write to data/static-export/ and download any historical build from GET /wp-json/daypress/v1/publish/deployments/{id}/download—ready for GitHub Pages, S3 + CloudFront, Nginx, or Surge.
{
"name": "daypress_publish_site",
"arguments": {
"target": "cloudflare",
"public_url": "https://mysite.com",
"cf_account_id": "023e105f4ecef8ad9ca31a8372d0c353",
"cf_project_name": "mysite-prod"
}
}Dynamic features vs. static edge builds
_redirects globally with zero server upkeep. If your site requires server-side FormStudio vault submissions, member-gated newsletter unlocks, server-side A/B testing, or live REST/MCP writes on the public domain, run the Dynamic Rust Binary (a $4/mo VPS easily handles thousands of req/s in ~26 MB RAM).