This example demonstrates how to prepare, build, containerize, and run a Ranu.js application for production environments.
- Standalone Node Server:
ranu buildcompiles server and static manifests;ranu startlaunches the high-performance HTTP production server - Containerization: Multi-stage
Dockerfilecreating a lightweight, minimal Alpine Linux image - Healthcheck Probe:
/api/healthproviding readiness and liveness telemetry for Docker and Kubernetes
├── .dockerignore
├── Dockerfile # Multi-stage production container build
├── app/
│ ├── api/health/route.ts # Healthcheck endpoint
│ ├── layout.tsx
│ └── page.tsx
├── package.json
├── ranu.config.ts
└── tsconfig.json
pnpm build
pnpm startdocker build -t ranu-app .
docker run -p 3000:3000 ranu-app