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.

24 lines
654 B

9 years ago
9 years ago
9 years ago
  1. #! /bin/bash
  2. # don't build if you're impatient
  3. if [[ ! $NO_BUILD ]]; then
  4. if [ `basename $(pwd)` = DOCKER ]; then
  5. docker build -t mint -f Dockerfile ..
  6. else
  7. docker build -t mint -f DOCKER/Dockerfile .
  8. fi
  9. fi
  10. # create the data-only container
  11. if [[ ! $VD ]]; then
  12. docker run --name mintdata --entrypoint /bin/echo mint Data-only container for mint
  13. fi
  14. # copy a directory from host to data-only volume
  15. if [[ $VC ]]; then
  16. cd $VC
  17. tar cf - . | docker run -i --volumes-from mintdata mint tar xvf - -C /data/tendermint
  18. fi
  19. # run tendermint
  20. docker run --name mint --volumes-from mintdata -d -p 46656:46656 -p 46657:46657 -e FAST_SYNC=$FAST_SYNC mint