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.

40 lines
1.5 KiB

  1. localnode
  2. =========
  3. It is assumed that you have already `setup docker <https://docs.docker.com/engine/installation/>`__.
  4. Description
  5. -----------
  6. Image for local testnets.
  7. Add the tendermint binary to the image by attaching it in a folder to the `/tendermint` mount point.
  8. It assumes that the configuration was created by the `tendermint testnet` command and it is also attached to the `/tendermint` mount point.
  9. Example:
  10. This example builds a linux tendermint binary under the `build/` folder, creates tendermint configuration for a single-node validator and runs the node:
  11. ```
  12. cd $GOPATH/src/github.com/tendermint/tendermint
  13. #Build binary
  14. make build-linux
  15. #Create configuration
  16. docker run -e LOG="stdout" -v `pwd`/build:/tendermint tendermint/localnode testnet --o . --v 1
  17. #Run the node
  18. docker run -v `pwd`/build:/tendermint tendermint/localnode
  19. ```
  20. Logging
  21. -------
  22. Log is saved under the attached volume, in the `tendermint.log` file. If the `LOG` environment variable is set to `stdout` at start, the log is not saved, but printed on the screen.
  23. Special binaries
  24. ----------------
  25. If you have multiple binaries with different names, you can specify which one to run with the BINARY environment variable. The path of the binary is relative to the attached volume.
  26. docker-compose.yml
  27. ==================
  28. This file creates a 4-node network using the localnode image. The nodes of the network are exposed to the host machine on ports 46656-46657, 46659-46660, 46661-46662, 46663-46664 respectively.