Skip to content

Instantly share code, notes, and snippets.

@dragononcrypto
Forked from stiucsib86/deeponion-raspberry-pi.sh
Last active May 23, 2018 13:34
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save dragononcrypto/610bee782ed362e96136fdda224ca4a6 to your computer and use it in GitHub Desktop.
Save dragononcrypto/610bee782ed362e96136fdda224ca4a6 to your computer and use it in GitHub Desktop.
Work in progress
#!/bin/bash
#title :deeponion-linux.sh
#description :This script will install DeepOnion and required dependencies
#author :dragononcrypto
#email :dragonvslinux@riseup.net
#date :N/A
#version :0.1
#usage :sh deeponion-linux.sh
#notes :Intended for Ubuntu, Mint and Debian.
#to do :everything; declare variables, if/when statements for different OS's.
#end goal :integrate raspberry pi and tails scripts
#credits :initially forked from @stiucsib86 raspberry pi script
#requirements :host bitcoin gpg key for deban
#==============================================================================
# CONSTANTS
declare -r HOME=$(readlink -f ~)
declare -r CONFIG="$HOME/.local/.deeponion"
declare -r SOURCE="https://github.com/deeponion/deeponion"
declare -r VERSION='version'
declare -r PACKAGE="to-be-added-later.gz"
declare -r DEEPONION_DIR=$HOME'/deeponion'
# QUESTIONS
declare -i INSTALL_DEEPONION=0
declare -i reinstall=0
# PACKAGE VERSION
CURRENT_VERSION="0.0.1"
PACKAGE_VERSION="0.0.X"
# Updating and upgrading system before installing depenencies
function system_upgrade()
{
info_msg "UPDATING AND UPGRADING OPERATING SYSTEM"
sudo id &> /dev/null
if [[ $? -ne 0 ]]; then
error_msg "Updating and upgrading system requires sudo privileges"
exit 1
fi
sudo apt-get update && upgrade
info_msg "Done updating and upgrading your operating system."
fi
}
# Install or upgrade required dependencies
function install_dependencies()
{
info_msg "INSTALLING DEEPONION DEPENDENCIES"
sudo id &> /dev/null
if [[ $? -ne 0 ]]; then
error_msg "Installing dependencies requires sudo privileges"
exit 1
fi
# Installing core dependencies for all systems
declare -a packages=( build-essential libtool autotools-dev autoconf automake pkg-config libssl-dev libboost-all-dev bsdmainutils \
libqrencode-dev libminiupnpc-dev libevent-dev libcap-dev libseccomp-dev git \
software-properties-common )
# Ubuntu installation Berekely 4.8++
if [[ $( lsb_release -i | awk '{print $3}' ) == 'Ubuntu' ]]; then
sudo add-apt-repository ppa:bitcoin/bitcoin -y && sudo apt-get update
fi
# Mint installation Berekely 4.8++
if [[ $( lsb_release -i | awk '{print $3}' ) == 'LinuxMint' ]]; then
sudo add-apt-repository ppa:bitcoin/bitcoin -y && sudo apt-get update
fi
# Debian installation Berekely 4.8++
if [[ $( lsb_release -i | awk '{print $3}' ) == 'Debian' ]]; then
# Bitcoin repository key requires hosting
wget http://github.com/deeponion/bitcoin.gpg | sudo apt-key add -
sudo add-apt-repository \
"deb [arch=amd64] http://ppa.launchpad.net/bitcoin/bitcoin/ubuntu xenial main"
fi
fi
info_msg "Done installing DeepOnion dependencies"
}
# Clone the latest version Of DeepOnion software
git clone --recursive https://github.com/deeponion/deeponion.git
# Build with autotools:
cd deeponion
./autogen.sh
./configure --with-gui=qt5 (if you want to build daemon, use --without-gui)
make
# Run DeepOnion Daemon
cd ~
./DeepOniond
# Configure the DeepOnion wallet
# mkdir ~/.DeepOnion
# cd ~/.DeepOnion
# touch DeepOnion.conf
# Paste following contents into the configuration textfile DeepOnion.conf with the nano editor by the command:
# nano ~/.DeepOnion/DeepOnion.conf but replace the node addresses with recent ones from
# https://deeponion.org/DeepOnion.conf.php
#
# testnet=0
# listen=1
# server=1
# daemon=1
# maxconnections=90
# rpcuser=yourIrrelevantUsername
# rpcpassword=yourIrrelevantPassword
# rpcport=18580
# rpcconnect=127.0.0.1
# rpcallowip=127.0.0.1
#
# addnode=2zqbi35cuxaa5hdv.onion:17570
# addnode=qwutsfqfiszhzny5.onion:17570
# addnode=l6ntc2e6fzbj3o2i.onion:17570
# addnode=zixupfklnbyoxgnh.onion:17570
#
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment