Dokploy
Deploy Greenlight as a Compose app in Dokploy .
Steps
-
Create a Compose application pointing at this repository.
-
Set the compose file to
docker-compose.self-host.yml. -
Generate secrets locally with
npm run env:ensure -- --profile self-host, then paste variables from.env.self-host(or start from.env.self-host.exampleand set secrets yourself). -
Confirm strong secrets are set:
POSTGRES_PASSWORDAUTH_SECRETCALLBACK_SIGNING_SECRETWEBHOOK_SECRETGREENLIGHT_API_KEY(bootstraps admin key whenUSE_AUTH=trueandapi_keysis empty)
-
Set
PUBLIC_WEBHOOK_URLto your public HTTPS API host (no trailing slash). -
Route traffic in Dokploy (services use
expose, not host ports):Two subdomains (recommended):
Public URL Service Container port Path https://app.example.comgreenlight-ui3000/https://api.example.comgreenlight8100/AUTH_URL=https://app.example.com PUBLIC_WEBHOOK_URL=https://api.example.comSame host with path prefix (e.g. API under
/wh):Public URL Service Container port Path in Dokploy https://greenlight.example.comgreenlight-ui3000/https://greenlight.example.com/whgreenlight8100/wh(leading slash required)AUTH_URL=https://greenlight.example.com PUBLIC_WEBHOOK_URL=https://greenlight.example.com/whTraefik/Dokploy must strip
/whwhen forwarding to core (core routes are rooted at/webhooks,/v1,/healthz, not/wh/...).Health checks (internal container probes only — not public URLs):
Service Probe URL greenlight-uihttp://127.0.0.1:3000/api/healthgreenlighthttp://127.0.0.1:8100/healthzDo not use
/wh/healthzfor API health —/healthzis not under the/whprefix. -
Deploy, then register channels via API or the Admin UI.
Docs site only (build on server): use compose file docker-compose.docs.build.yml
with .env.docs — see Docker.
Webhook URLs
Each channel uses:
{PUBLIC_WEBHOOK_URL}/webhooks/{organization_id}/{platform}/{channel_id}Configure that URL in Slack Event Subscriptions, Azure Bot messaging endpoint, Discord Interactions, Meta Callback URL, Google Chat App URL, etc.
After deploy
- Open the Admin UI
/setuponce to create the super admin - Register at least one
PROMPTchannel - Send a test prompt from the UI or
POST /v1/prompts/new
See Platforms for per-platform webhook details.