Read Node
Repository viewer
Legacy docs parity surface
Back to repository viewer
Repository document

Primary Host Bootstrap

read-node/primary-host-bootstrap.md

Boundary

This route preserves legacy markdown access inside the Next.js surface. The raw repository file remains authoritative.

Open raw file

Primary Host Bootstrap

Purpose

This document reduces the external cutover work to:

  1. bootstrap an Ubuntu VPS
  2. place the production .env
  3. start the primary-host stack
  4. point DNS to that host

The repo now contains the rest.

Files

Ubuntu bootstrap

Run as root or via sudo on the VPS:

curl -fsSL https://raw.githubusercontent.com/X-PACT/PrivateDAO/main/scripts/bootstrap-primary-host-ubuntu.sh -o /tmp/bootstrap-primary-host-ubuntu.sh
sudo TARGET_USER=ubuntu INSTALL_DIR=/opt/privatedao bash /tmp/bootstrap-primary-host-ubuntu.sh

This installs:

  • Docker Engine
  • Docker Compose plugin
  • Node.js 20
  • Git

Install the stack on the VPS

As the target user:

cd /opt/privatedao
git clone https://github.com/X-PACT/PrivateDAO.git .
git checkout main
cp deploy/primary-host/.env.example deploy/primary-host/.env
nano deploy/primary-host/.env
npm run install:primary-host-stack

Or equivalently:

npm run install:primary-host-stack

This runs:

  • npm ci
  • source preflight
  • primary-host stack bring-up
  • local stack verification

Remote verification after DNS

After DNS points to the VPS:

./scripts/verify-remote-primary-host.sh https://privatedao.org
npm run verify:host-topology:strict

Expected result:

  • privatedao.org no longer reports Server: GitHub.com
  • /healthz returns healthy
  • /api/v1/config returns backend-indexer
  • /api/v1/metrics returns counters

Remaining external actions

The repo cannot perform these without infrastructure credentials:

  1. provision the VPS itself
  2. edit the real production .env
  3. attach privatedao.org DNS to the host
  4. manage registrar or DNS provider records