Skip to main content

Prerequisites

Shared server baseline

Option A: Node.js + systemd + Nginx

1

Install runtime packages

2

Clone the repository and create .env

3

Build and migrate

4

Create the systemd service and Nginx site

Set the service working directory to /opt/kuest/prediction-market, proxy Nginx to port 3000, then issue TLS with Certbot.

Option B: Docker Compose + Caddy

1

Install Docker Engine and Compose

Install Docker Engine, Compose plugin, and Git on the server.
2

Clone the repository and create .env

Use the same /opt/kuest/prediction-market layout as the Node.js path.
3

Set domain variables

Add:
4

Start production compose

5

Run database migrations

Scheduler on VPS

If you are not using Supabase mode, create Linux cron jobs that follow Scheduled Jobs. Keep that page as the single source of truth for the exact cron expressions.
Keep only one scheduler backend active for /api/sync/*.