Transaction listener and replicator for Ethereum and BigchainDB
config
contains the configurations files for the Ethereum and BigchainDB.contracts
contains the ethereum contracts and is used by truffle to search, compile, and migrate contracts.migrations
contains truffle migration scripts for the contracts.src
contains ethereum event listener and bigchaindb transaction executor.test
contains the script to create a transaction on ethereum usingtruffle-contract
truffle-config.js
&truffle.js
truffle config files for network setup
- Node.js
- BigchainDB
- Truffle Framework (
npm install -g truffle
or on linuxsudo npm install -g truffle
) - Ganache or a running instance of ethereum.
- Docker and Docker Compose (optional)
- Clone the repository and navigate to
poc2
folder. - Install the dependencies with
npm install
. - Update the
network.config.json
with the specific values of the bigchaindb and ethereum hosts. - Deploy the smart contracts by running
truffle migrate
in the root folder. - Copy the address of the
Token
printed after thetruffle migrate
into thetoken.config.json
. - To run the listener execute
npm start
. - The listener is up & running and listening for
Transfer
events on your deployed contract.
- To build the docker image run:
docker-compose build
. - To start the container:
docker-compose up
. - Docker container is up and listening for
Transfer
events on your deployed contract.