Skip to content

Domains, Proxy, And HTTPS

Main App Domain

Set DNS for your application domain, for example:

democracyroutes.example.org -> your server IP

Set matching environment values:

APP_BASE_URL=https://democracyroutes.example.org
NEXTAUTH_URL=https://democracyroutes.example.org

Docs Domain

For the documentation site:

docs.democracyroutes.example.org -> your server IP

This repository includes an internal docs service that can be routed by the bundled Nginx proxy when the Host header is docs.democracyroutes.com.

HTTPS

The bundled dr-proxy is an internal HTTP reverse proxy. In production, put HTTPS in front of it using one of:

  • Caddy;
  • Traefik;
  • Nginx with certbot;
  • Cloudflare or another CDN/proxy;
  • your hosting provider’s load balancer.

Ensure the proxy forwards:

  • Host
  • X-Forwarded-For
  • X-Forwarded-Proto
  • WebSocket upgrade headers

ActivityPub Paths

If you enable Fediverse publishing, the public domain must route these paths to dr-app:

  • /.well-known/webfinger
  • /ap/actors/*
  • /ap/objects/*
  • /ap/activities/*

The bundled Nginx config already forwards them.