GioJSdocs
Get StartedReleasesGitHub ↗

Deployment

GioJS ships as two processes: the giojs-server Rust binary (HTTP, routing, caching) and a Node.js worker (React SSR). Both start automatically.

Before deploying

  1. Run gio build to produce .gio/manifest.json and compiled assets
  2. Ensure Node.js 20+ is installed on the target host
  3. Place the giojs-server binary and your app directory on the host
  4. Set NODE_ENV=production

Choose a deployment method

MethodWhen to use
Linux systemdLinux VPS or bare metal, long-running service
DockerContainerized, single instance or scaling
KubernetesKubernetes, multi-instance with shared Redis cache
Windows NSSMWindows Server host

Linux systemd

Run GioJS as a systemd service on any Linux VPS or bare metal server. Survives reboots, logs to journald, supports nginx as a TLS reverse proxy.

Full guide: docs/deployment/linux-systemd.md in the repository.

Docker

Multi-stage Dockerfile keeps the final image small (~80MB) by building Rust and Node separately. Includes a docker-compose.yml with optional Redis for shared caching.

Full guide: docs/deployment/docker.md in the repository.

Kubernetes

Deployment, Service, Ingress, HPA, and Redis StatefulSet YAMLs. Uses readinessProbe on /_gio/health and scales on CPU utilization.

Full guide: docs/deployment/kubernetes.md in the repository.

Windows NSSM

Run GioJS as a Windows Service using NSSM. Survives reboots, writes to Event Viewer, and can be managed with PowerShell cmdlets.

Full guide: docs/deployment/windows-nssm.md in the repository.

Health check

/_gio/health returns JSON and is always available. Use it for readiness probes, load balancer health checks, and uptime monitors:

{
  "status": "ok",
  "deploymentId": "abc12345",
  "nodeReady": true,
  "cacheSize": "12MB",
  "uptime": 3600
}

Multi-instance caching

When running multiple instances (Kubernetes, multiple VMs), configure Redis so all instances share a single ISR cache:

[cache.redis]
enabled = true
url     = "redis://redis:6379"
prefix  = "gio:prod:"