mirror of
https://github.com/farcasterxyz/hub-monorepo.git
synced 2026-02-11 13:35:05 -05:00
Provide a working end-to-end example of syncing data from hubs to a Postgres database. This should work with no additional dependencies besides what you install with `yarn install` and Docker.
805 B
805 B
Replicate hub data into Postgres
This example shows you how you can quickly start ingesting data from a Farcaster hub into a traditional database like Postgres.
Run on StackBlitz
Run locally
- Clone the repo locally
- Navigate to this folder with
cd packages/hub-nodejs/examples/replicate-data-postgres - Run
yarn installto install dependencies - Run
docker compose up -dto start a Postgres instance (install Docker if you do not yet have it) - Run
yarn start
To wipe your local data, run docker compose down -v from this directory.