Blockchain explorer for Ethereum based network and a tool for inspecting and analyzing EVM based blockchains.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
blockscout/docker-compose
Viktor Baranov 1d6da1b305 Set integration with Blockscout eth bytecode DB endpoint by default, replace old UI with new one in docker-compose configs, set default value for port: 4000 1 year ago
..
envs Set integration with Blockscout eth bytecode DB endpoint by default, replace old UI with new one in docker-compose configs, set default value for port: 4000 1 year ago
proxy Add routing proxies starting with favicon to FRONT_PROXY_PASS 1 year ago
services Fixing visualizer CORS issue in docker-compose 1 year ago
README.md Set integration with Blockscout eth bytecode DB endpoint by default, replace old UI with new one in docker-compose configs, set default value for port: 4000 1 year ago
docker-compose-no-build-erigon.yml Set integration with Blockscout eth bytecode DB endpoint by default, replace old UI with new one in docker-compose configs, set default value for port: 4000 1 year ago
docker-compose-no-build-external-backend.yml Set integration with Blockscout eth bytecode DB endpoint by default, replace old UI with new one in docker-compose configs, set default value for port: 4000 1 year ago
docker-compose-no-build-external-frontend.yml Set integration with Blockscout eth bytecode DB endpoint by default, replace old UI with new one in docker-compose configs, set default value for port: 4000 1 year ago
docker-compose-no-build-ganache.yml Set integration with Blockscout eth bytecode DB endpoint by default, replace old UI with new one in docker-compose configs, set default value for port: 4000 1 year ago
docker-compose-no-build-geth-clique-consensus.yml Set integration with Blockscout eth bytecode DB endpoint by default, replace old UI with new one in docker-compose configs, set default value for port: 4000 1 year ago
docker-compose-no-build-geth.yml Set integration with Blockscout eth bytecode DB endpoint by default, replace old UI with new one in docker-compose configs, set default value for port: 4000 1 year ago
docker-compose-no-build-hardhat-network.yml Set integration with Blockscout eth bytecode DB endpoint by default, replace old UI with new one in docker-compose configs, set default value for port: 4000 1 year ago
docker-compose-no-build-nethermind.yml Set integration with Blockscout eth bytecode DB endpoint by default, replace old UI with new one in docker-compose configs, set default value for port: 4000 1 year ago
docker-compose-no-build-no-db-container.yml Set integration with Blockscout eth bytecode DB endpoint by default, replace old UI with new one in docker-compose configs, set default value for port: 4000 1 year ago
docker-compose.yml Set integration with Blockscout eth bytecode DB endpoint by default, replace old UI with new one in docker-compose configs, set default value for port: 4000 1 year ago

README.md

Docker-compose configuration

Runs Blockscout locally in Docker containers with docker-compose.

Prerequisites

  • Docker v20.10+
  • Docker-compose 2.x.x+
  • Running Ethereum JSON RPC client

Building Docker containers from source

docker-compose up --build

This command uses by-default docker-compose.yml, which builds the explorer into the Docker image and runs 5 Docker containers:

  • Postgres 14.x database, which will be available at port 7432 on localhost.
  • Redis database of latest version, which will be available at port 6379 on localhost.
  • Blockscout explorer at http://localhost:4000.

and 2 microservices (written in Rust):

  • Sig-provider service, which will be available at port 8151 on the host machine.
  • Sol2UML visualizer service, which will be available at port 8152 on the host machine.

Note for Linux users: Linux users need to run the local node on http://0.0.0.0/ rather than http://127.0.0.1/

Configs for different Ethereum clients

The repo contains built-in configs for different JSON RPC clients without need to build the image.

  • Erigon: docker-compose -f docker-compose-no-build-erigon.yml up -d
  • Geth: docker-compose -f docker-compose-no-build-geth.yml up -d
  • Nethermind, OpenEthereum: docker-compose -f docker-compose-no-build-nethermind up -d
  • Ganache: docker-compose -f docker-compose-no-build-ganache.yml up -d
  • HardHat network: docker-compose -f docker-compose-no-build-hardhat-network.yml up -d
  • Running only explorer without DB: docker-compose -f docker-compose-no-build-no-db-container.yml up -d. In this case, one container is created - for the explorer itself. And it assumes that the DB credentials are provided through DATABASE_URL environment variable.

All of the configs assume the Ethereum JSON RPC is running at http://localhost:8545.

Explorer UI will be available at http://localhost.

In order to stop launched containers, run docker-compose -d -f config_file.yml down, replacing config_file.yml with the file name of the config which was previously launched.

You can adjust BlockScout environment variables from ./envs/common-blockscout.env. Descriptions of the ENVs are available in the docs.