-
Notifications
You must be signed in to change notification settings - Fork 22
Running Conseil
Conseil can either be run in a Docker container or as a JAR file using a Java runtime environment.
If you don't want to run your own Conseil instance and prefer an easy hosted solution, check out Nautilus Cloud.
Please visit the releases page and use a git tag corresponding to a release of your choice. It is advisable to always use the latest release as blockchain protocols keep changing.
Conseil needs access to a Postgres database that is set up with the right schema. To view a SQL file with the right schema, see the file sql/conseil.sql
in the git branch or tag you are using.
Conseil also needs access to a Tezos node to collect blockchain data. See instructions for Running Tezos for Lorre.
Synchronizing Lorre from scratch, i.e. downloading all the blockchain data into the database, can take a very long time. We therefore recommend using the database dumps we provide on the releases page. These dumps can be applied to your Postgres database using the pg_restore tool.
Working docker-compose.yml
file for running Conseil and Lorre from DockerHub can be found here:
https://github.com/Cryptonomic/Conseil/blob/2020-june-release-23/docker/docker-compose.yml
Conseil is available from dockerhub. This is the recommended option if you want to use an official release.
You can pull the latest docker image with:
docker pull cryptonomictech/conseil:latest
You can find available tags on our dockerhub page.
The container can be configured using the following environment variables:
Database Config:
- DB_Host - default: db
- DB_User - default: user
- DB_Password - default: password
- DB_Database: default: conseil
Tezos Node Config:
- XTZ_Scheme - http or https, default : http
- XTZ_Host - default: node
- XTZ_Prefix - prefix for api calls, default: ""
- XTZ_Port - default 8732
- XTZ_Network - default mainnet
- XTZ_Platform - default tezos
Conseil Config:
- API_PORT - Conseil API port, default: 80
- API_KEY - Conseil API key, default: conseil
Or, you can use your own config file, in which case specify the environment variable CONFIG
with the path to your file. See Configuring Conseil for details on building a config file.
To start the Lorre indexer run:
docker run cryptonomictech/conseil:latest lorre
To start the Conseil API run:
docker run cryptonomictech/conseil:latest conseil
To run container with environment variables stated before you can use -e
parameter, for example:
docker run -e XTZ_Host=tezos.example.node.com -e XTZ_Port=443 cryptonomictech/conseil:latest conseil
Depending on the flags you pass in, you may want to start the container with the --network="host"
flag in order to make sure Conseil can access Postgres, and the Tezos node.
Alternatively, to build your own image, clone the Conseil git repo, switch to your desired tag or branch and run this command:
docker build -t conseil .
The container can be configured using the following environment variables:
Database Config:
- DB_Host - default: db
- DB_User - default: user
- DB_Password - default: password
- DB_Database: default: conseil
Tezos Node Config:
- XTZ_Scheme - http or https, default : http
- XTZ_Host - default: node
- XTZ_Prefix - prefix for api calls, default: ""
- XTZ_Port - default 8732
- XTZ_Network - default mainnet
- XTZ_Platform - default tezos
Conseil Config:
- API_PORT - Conseil API port, default: 80
- API_KEY - Conseil API key, default: conseil
Or, you can use your own config file, in which case specify the environment variable CONFIG
with the path to your file. See Configuring Conseil for details on building a config file.
To start the Lorre indexer run:
docker run conseil conseil-lorre
To start the Conseil API run:
docker run conseil conseil-api
To run container with environment variables stated before you can use -e
parameter, for example:
docker run -e XTZ_Host=tezos.example.node.com -e XTZ_Port=443 conseil conseil-lorre
This is the recommended option if you simply want to run the latest release. Each release listed on GitHub has a JAR file attached which you can simply download.
Alternatively, you can build your JAR file by following the instructions on Building Conseil.
You will need to create a configuration file. See Configuring Conseil for details.
To start the Lorre indexer:
java -Dconfig.file=conseil.conf -jar conseil-lorre.jar <platform> <network>
To start the Conseil API:
java -Dconfig.file=conseil.conf -jar conseil-api.jar