Last active
April 12, 2019 20:08
-
-
Save Stoner19/dd97166096fe5e333dbbecdb7c6909f8 to your computer and use it in GitHub Desktop.
simple bash script to install and/or update https://github.com/mochimodev/mochimo and start a NON-MINING node
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
if [ -d $HOME/mochimo ]; | |
then | |
echo "Mochimo directory already exists, checking for new commits and pulling the latest source"; | |
cd $HOME/mochimo && git pull | |
echo "Starting gomochi in screen"; | |
cd $HOME/mochimo/bin/ && screen -dmS mochimo ./gomochi d -n | |
else | |
echo "Installing dependencies and pulling latest Mochimo source"; | |
echo "sudo password may be required"; | |
sudo apt-get install build-essential pkg-config screen | |
cd ~ | |
git clone https://github.com/mochimodev/mochimo | |
cd $HOME/mochimo/src && ./makeunx bin -DCPU && ./makeunx install | |
cd ../bin && cp maddr.mat maddr.dat | |
echo "Compile complete. Starting gomochi in screen"; | |
screen -dmS mochimo ./gomochi d -n | |
fi |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
** NOTE: This will create a maddr.dat file (which is needed to start a node) that you do NOT control the keys for. This is simply creating a node to validate transactions without mining.