Skip to content

ENSNode Development and Contributions

Prerequisites

Prepare Workspace

Clone this repository:

Terminal window
git clone git@github.com:namehash/ensnode.git
cd ensnode

Install Dependencies

Terminal window
pnpm install

Running ENSNode

1. Running Postgres

Ensure Postgres in the background, providing its connection details to ENSIndexer via DATABASE_URL.

2. Running ENSRainbow

Terminal window
# from monorepo root
pnpm run -F @ensnode/ensrainbow serve
# or from apps/ensrainbow
pnpm run serve

3. Running ENSIndexer

Terminal window
# from monorepo root
pnpm run -F @ensnode/ensindexer dev
# or from apps/ensindexer
pnpm run dev

4. Running ENSAdmin

Terminal window
cd apps/ensadmin
cp .env.local.example .env.local
Terminal window
# from monorepo root
pnpm run -F @ensnode/ensadmin dev
# or from apps/ensadmin
pnpm run dev

Using Docker Compose

You can use Docker Compose to set up the ENSNode suite, along with its dependencies.

Prerequisites

Before you can use Docker Compose, ensure you have the following installed on your machine:

Building the Docker Images

Before running docker compose the images must be build with the latest changes: see the Building Docker Images guide.

If you make changes in the application code and wish to run those updates, you must build the relevant Docker container again.

Running the Applications

Run the built images with:

Terminal window
docker compose up -d

Stopping the Applications

To stop the running applications, you can press Ctrl + C in the terminal where Docker Compose is running. If you want to remove the containers and networks created by Docker Compose, you can run:

Terminal window
docker compose down