Skip to content

Instantly share code, notes, and snippets.

@sigwo
Last active April 19, 2016 02:48
Show Gist options
  • Save sigwo/743c0c6b2a462976a34a to your computer and use it in GitHub Desktop.
Save sigwo/743c0c6b2a462976a34a to your computer and use it in GitHub Desktop.
#!/bin/bash
# **************************************************************************
# Jumbucks RPi installer
# Jumbucks-qt + desktop icon
# Maintained by : sigwo
# **************************************************************************
# install dependencies
echo "*** Installing dependencies ***"
echo
sudo apt-get -y update
sudo apt-get -y upgrade
sudo apt-get install -y qt4-qmake libqt4-dev libminiupnpc-dev libdb++-dev libdb-dev libcrypto++-dev libqrencode-dev libboost-all-dev build-essential libboost-system-dev libboost-filesystem-dev libboost-program-options-dev libboost-thread-dev libboost-filesystem-dev libboost-program-options-dev libboost-thread-dev libssl-dev libdb++-dev libssl-dev ufw git
echo
echo "*** Cloning JBS repo ***"
echo
git clone https://github.com/jyap808/jumbucks.git jbs
cd jbs
qmake
make
echo
# create the firewall rules
echo
# uncomment the firewall lines and replace the port with the port required for either P2P or rpc port for local mining
echo "*** Create firewall rules ***"
sudo ufw allow 51717
sudo ufw allow 51716
sudo ufw allow 2210
sudo ufw allow 5950
sudo ufw allow 6050
sudo ufw allow 3000
sudo ufw enable
echo
# create config file and randomize the password
echo "*** Creating configuration file with randomized password ***"
echo
mkdir ~/.jumbucks
rm -f jumbucks.conf
echo "rpcuser=user
rpcpassword=$(cat /dev/urandom | tr -cd '[:alnum:]' | head -c32)
rpcallowip = 127.0.0.1
server = 1
daemon = 1
listen = 1" >> ~/.jumbucks/jumbucks.conf
echo
echo
# create desktop shortcut for JBS
echo "*** Creating desktop icon ***"
echo
rm -f ~/.jumbucks/jumbucks.png
rm -f ~/Desktop/JBS.desktop
wget https://chainz.cryptoid.info/logo/jbs.png -O ~/.jumbucks/jumbucks.png
echo "[Desktop Entry]
Name=Jumbucks
Type=Application
Comment=JBS
Categories=Application
Exec=/home/$USER/jbs/jumbucks-qt
Icon=/home/$USER/.jumbucks/jumbucks.png
Terminal=false
StartupNotify=true" >> ~/Desktop/JBS.desktop
chmod 755 ~/Desktop/JBS.desktop
echo
echo "*** Installation finished - you can now run the wallet by double clicking the icon on the desktop ***"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment