NextDeploy v1.0·Coming Soon

Self-Host Next.js with Zero Downtime. No Vercel Markup. No Docker Bloat.

NextDeploy is an open-source, compiled Go engine that deploys Next.js applications to a $4 VPS, AWS, or Cloudflare Workers with atomic POSIX cutovers, Caddy edge proxying, and cumulative static chunk pooling.

macOS · install.shbash
$curl -fsSL https://hersi.dev/install.sh | bash
Apple Silicon (M1/M2/M3/M4) & Intel · ~/.local/bin/nextdeploycurl & bash · Single static binary
< 14 MBDaemon Memory FootprintZero container runtime daemon overhead
$4 / moBare-Metal VPS ServerSave thousands on bandwidth seat taxes
0 msAtomic Cutover DowntimePOSIX symlinks preserve client sockets
Live Deployment DemonstrationPOSIX Atomic Inode Switch
nextdeploy ship --releaseprod
$nextdeploy ship --target=vpsworker PID 41920
Analysed Next.js 15 App Router project
+0.12s
Detected standalone output mode & Turbopack bundle manifest
Ingested .nextdeploy/metadata.json & verified git commit
+0.28s
commit 8e41a29 on origin/main [verified GPG signature]
Booted release 1730489201 on port 3001
+0.71s
Spawned isolated Node.js worker under cgroup 'nd-app-prod'
Health check passed (HTTP 200 on /api/health)
+1.14s
Dual-stage TCP 3001 OK • HTTP GET 200 OK [latency 4ms]
Synced static chunks to shared_static/ (Chunk 404s eliminated)
+1.45s
1,248 cumulative chunk assets pooled • zero asset evictions
Atomic symlink cutover -> current
+1.78s
POSIX rename: /var/www/releases/1730489201 -> /var/www/current
Caddy reverse proxy reloaded with automatic Let's Encrypt TLS (0ms downtime)
+1.95s
Zero TCP connection drops • active WebSocket connections kept alive
Live at https://hersi.dev [2.1s]
+2.10s
Production traffic seamlessly routed to release 1730489201
Cutover verified · 0 in-flight requests dropped
Total duration: 2.10s
01 · Core Engineering Principles

Why NextDeploy?

Built specifically to eliminate the three deepest friction points of self-hosting Next.js in production.

0ms Downtime

Atomic Inode Cutovers

Dual-stage TCP + HTTP health probing with atomic POSIX symlink renames. Bad deploys abort cutovers automatically without dropping active client sockets.

Live: release_104port 3000
dual-stage TCP + HTTP probe passed ↓
Cutover: release_1051.2ms swap
Fail-safe:0 dropped sockets
shared_static/

The Chunk 404 Solution

Eliminates the "white screen of death" for active browsing sessions by pooling cumulative JavaScript chunks across releases.

Traditional Docker:Chunk 404 error
NextDeploy Pool:Cached & Served
Client reliability:100% Chunk retention
14MB Idle RAM

Bare-Metal Speed

Skips heavy Docker daemon RAM overhead. Uses Linux kernel cgroup v2 memory sandboxing and offloads all static bytes directly to NVMe disk via Caddy.

Docker daemon:~850 MB idle
NextDeploy Go daemon:~14 MB idle
Hardware footprint:Runs on $4/mo VPS
02 · Multi-Target Runtime

One Engine. Any Cloud.

One single nextdeploy.yml config file. Switch targets anytime with zero code changes.

Target 1: VPS (Bare-Metal + Caddy)
Architecture Highlights
  • Bare-metal Caddy edge reverse proxy with auto Let's Encrypt TLS
  • Lean standalone artifact uploaded via SFTP (zero VPS build strain)
  • Sandboxed systemd service (ProtectSystem=strict, cgroup v2 limits)
  • Dual-stage TCP & HTTP health checks on new port before cutover
  • Cumulative shared_static pool (eliminates Chunk 404s for active users)
  • Atomic POSIX current symlink swap and zero-downtime caddy reload
Execution Commands
nextdeploy prepare && doppler run -- nextdeploy ship
nextdeploy.ymlBlueprint Spec v1.0
version: "1.0"
target_type: vps

app:
  name: my-app             # lowercase slug (e.g. "my-saas")
  environment: production
  domain: app.example.com  # your public domain
  port: 3000

servers:
  - name: production
    host: 192.0.2.123      # VPS IP address
    user: ubuntu           # SSH user
    ssh_key: ~/.ssh/id_ed25519
    port: 22
03 · Knowledge Base • Powered by Notion

Live Docs & Reference

Authored directly inside Notion databases. Synchronized seamlessly to the edge with zero build lag.

01

Draft in Notion

Write architecture RFCs, deployment steps, and guides using native Notion blocks.

02

Webhook Sync

Changes invalidate edge caches instantly via atomic ISR API routes.

Sub-millisecond Edge

Delivered with syntax highlighting, search index, and zero client hydration penalty.

Categories:
Deployment/docs/production-deployment-guides

Production Deployment Blueprints

Complete blueprints for VPS (Bare-Metal + Caddy), Cloudflare Workers (Edge + R2), AWS Serverless, and Doppler secrets.

#VPS#Cloudflare#AWS#Doppler#Production
Quick Executionverified
Target 1: VPSnextdeploy prepare && doppler run -- nextdeploy ship
Target 2: Cloudflare Workersnextdeploy apply && doppler run -- nextdeploy ship
Target 3: AWS Serverlessdoppler run -- nextdeploy ship
Last verified: TodayRead Full Doc
04 · Architectural Comparison

How NextDeploy Compares

The developer experience of managed cloud platforms without the cloud markup or Docker baggage.

Capability
NextDeploy
VercelDocker / Coolify
Zero-Downtime Cutovers
POSIX rename avoids killing in-flight client TCP sockets.
Edge routing cutoverRestart delay (3-8s gap)
Chunk 404 Prevention
Old JavaScript chunks are preserved so users browsing during a deploy don't get white screens.
Retained on CDN blob storeBroken on container rebuild
Memory Footprint
Runs comfortably on $4/mo 1GB RAM droplets with zero thrashing.
N/A (Managed Serverless)~850MB Docker Daemon & containerd
SSL / TLS Edge Certificates
Zero configuration HTTPS with automatic HTTP/2 and HTTP/3 support.
AutomaticManual Traefik / Nginx setup
Hosting Costs
Save thousands per year on high-traffic apps with zero artificial seat licenses.
$20+ / user + bandwidth overages$12+ / mo (requires >= 2GB RAM)
Vendor Lock-in
Switch between VPS, Cloudflare, and AWS with one line in nextdeploy.yml.
Proprietary middleware / ISR logicOpen source
Reclaim control of your Next.js infrastructure.
Read Architecture RFC on GitHub