Skip to main content
Railway and Render are platform-as-a-service providers that deploy containers directly from a GitHub repository. Both offer managed Postgres add-ons, automatic TLS, and dashboard-driven configuration — making them the simplest cloud deployment option for MergeWatch.

Overview

This guide covers deploying MergeWatch on either Railway or Render. Both platforms follow the same pattern: connect your GitHub repo, configure environment variables, add a Postgres database, and point your GitHub App webhook at the provided URL.

Prerequisites

1

Create an account

Sign up for a free account on Railway or Render.
2

Gather your GitHub App credentials

VariableDescription
GITHUB_APP_IDNumeric App ID from the GitHub App settings page
GITHUB_PRIVATE_KEYPEM-formatted private key generated for the App
GITHUB_WEBHOOK_SECRETSecret used to validate incoming webhook payloads
3

Choose an LLM provider

Set LLM_PROVIDER to your preferred provider. For the default Anthropic provider, you also need ANTHROPIC_API_KEY.

Deploy on Railway

1

Create a new project

  1. Go to railway.app/new
  2. Select Deploy from Docker Image
  3. Enter the image: ghcr.io/santthosh/mergewatch:latest
2

Add a PostgreSQL plugin

  1. In your project, click + New and select Database > PostgreSQL
  2. Railway provisions a Postgres instance and exposes the DATABASE_URL variable automatically
Railway injects DATABASE_URL into your service environment automatically when you link the PostgreSQL plugin. No manual configuration needed.
3

Set environment variables

Go to your service’s Variables tab and add:
VariableValue
GITHUB_APP_IDYour App ID
GITHUB_PRIVATE_KEYYour PEM private key
GITHUB_WEBHOOK_SECRETYour webhook secret
LLM_PROVIDERanthropic
ANTHROPIC_API_KEYYour Anthropic API key
PORT3000
Railway sets DATABASE_URL automatically from the PostgreSQL plugin. Do not set it manually unless you are using an external database.
4

Deploy and get the URL

Railway deploys automatically when variables are saved. Find your public URL under Settings > Networking > Public Networking. Generate a domain if one is not assigned.
https://mergewatch-production-abc1.up.railway.app

Deploy on Render

1

Create a new Web Service

  1. Go to dashboard.render.com
  2. Click New > Web Service
  3. Select Deploy an existing image from a registry
  4. Enter: ghcr.io/santthosh/mergewatch:latest
2

Add a PostgreSQL service

  1. Click New > PostgreSQL
  2. Choose a name and plan (the free tier works for evaluation)
  3. Copy the Internal Database URL from the PostgreSQL service dashboard
3

Set environment variables

In the Web Service settings, go to Environment and add:
VariableValue
GITHUB_APP_IDYour App ID
GITHUB_PRIVATE_KEYYour PEM private key
GITHUB_WEBHOOK_SECRETYour webhook secret
LLM_PROVIDERanthropic
ANTHROPIC_API_KEYYour Anthropic API key
DATABASE_URLThe Internal Database URL from the PostgreSQL service
PORT3000
4

Deploy and get the URL

Render deploys automatically. Your service URL is shown at the top of the dashboard:
https://mergewatch.onrender.com
On Render’s free tier, services spin down after 15 minutes of inactivity. The first webhook after a spin-down may time out. Use a paid plan for production workloads.

Set up Postgres

Both platforms provide managed PostgreSQL as a first-party add-on.
PlatformPostgres optionHow DATABASE_URL is set
RailwayPostgreSQL pluginInjected automatically when linked
RenderPostgreSQL serviceCopy the Internal Database URL manually
Both platforms handle backups, connection pooling, and TLS for their managed Postgres offerings. No additional database configuration is needed for MergeWatch.

Configure the webhook URL

Set the webhook URL on your GitHub App to your platform URL followed by /webhook:
https://mergewatch-production-abc1.up.railway.app/webhook

Next steps