Deploy convex-duckdb-mirror
Deploy and host convex-duckdb-mirror on Railway
convex-duckdb-mirror
Just deployed
/data
Deploy and Host Convex DuckDB Mirror Proxy on Railway
Convex DuckDB Mirror gives your AI agents (and you) a fast, local, read-only DuckDB copy of your Convex data to run real analytical SQL against: the aggregate- and join-heavy queries Convex doesn't natively support. This template deploys the proxy, the single service half of the project. It holds your Convex deploy key, continuously buffers document deltas, and passes snapshots through so a local mirror can stay fresh.
Deploying the proxy is the first step. Once it's running, you point the convex-duckdb CLI at it from your project to sync and query the mirror locally. Full installation instructions live in the GitHub repo.
About Hosting Convex DuckDB Mirror Proxy
The proxy is a small Node service that talks to Convex's streaming-export API and buffers deltas in SQLite on a mounted volume, so your Convex deploy key never leaves the server and the CLI only ever talks to the proxy. It buffers only deltas (snapshots pass through unstored), so the volume stays small: for a Convex database of roughly 5–20 GB, the 5 GB volume on Railway's Hobby plan is plenty.
Common Use Cases
- Fast ad-hoc analytics over your Convex data with plain SQL
- Debugging production data problems with joins and aggregates
- Giving AI coding agents real, queryable data to reason over
Dependencies for Convex DuckDB Mirror Proxy Hosting
- A Convex deployment URL and a production deploy key
- A mounted volume for the delta buffer (5 GB is enough for most apps; see above)
The template auto-generates the access token the CLI uses, so you don't need to create one.
Deployment Dependencies
- Convex: https://www.convex.dev/
- Convex streaming export, currently beta so endpoints and formats may change: https://docs.convex.dev/production/integrations/streaming-import-export
Implementation Details
A simple Node service that proxies the Convex streaming-export API: it buffers document_deltas in SQLite for fast incremental sync, and passes list_snapshot and json_schemas through unchanged. It also exposes /health and /status for ops.
Why Deploy Convex DuckDB Mirror Proxy on Railway?
Railway's single-click deployments with their Template feature makes it an obvious choice for this tiny utility tool to pick Railway as the destination.
Template Content
convex-duckdb-mirror
maksymilian-majer/convex-duckdb-mirrorCONVEX_URL
CONVEX_DEPLOY_KEY
