docker-compose but with built-in TLS, global networking, and managed Postgres.
Overview
This guide covers deploying MergeWatch to Fly.io, provisioning a managed Fly Postgres cluster, setting secrets, and configuring the GitHub App webhook.Prerequisites
1
Install the Fly CLI
2
Gather your GitHub App credentials
3
Choose an LLM provider
Set
LLM_PROVIDER to your preferred provider. For the default Anthropic provider, you also need ANTHROPIC_API_KEY.Deploy to Fly.io
1
Launch the app
From a directory containing a This creates a
Dockerfile (or use the MergeWatch image directly), run:fly.toml configuration file. The --no-deploy flag lets you configure secrets before the first deploy.2
Set environment variables and secrets
Use
fly secrets set for sensitive values. Fly encrypts these at rest and injects them as environment variables at runtime.fly secrets set triggers a redeploy by default. Since we used --no-deploy above, the first deploy happens in the next step.3
Configure the internal port
Edit
fly.toml to set the internal port to 3000:4
Deploy
5
Verify the deployment
Set up Postgres
Fly.io offers a managed Postgres service that runs as a Fly app in the same private network as your MergeWatch instance.1
Create a Fly Postgres cluster
2
Attach the database to MergeWatch
DATABASE_URL secret on your MergeWatch app with the correct internal connection string.Configure the webhook URL
Your Fly.io app is available athttps://your-app.fly.dev. Set the webhook URL on your GitHub App to:
mergewatch with whatever name you chose during fly launch.
Next steps
Configure review behavior
Tune sensitivity, ignored paths, and review focus areas.
Environment variables
Full list of supported environment variables.
Troubleshooting
Common issues and how to fix them.
Upgrading
How to update MergeWatch to the latest version.