What is Nostr?
cemehbl4
npub1smk…ctp3
2024-01-29 12:33:57

cemehbl4 on Nostr: RoninDojo Install Guide - manual setup on any Debian-based x86-64 system. #First I ...

RoninDojo Install Guide - manual setup on any Debian-based x86-64 system.

#First I have to thank estudiobitcoin (npub1qqq…c6ad) and personally Albercoin (npub1a9a…cwea) and multicripto (npub12aq…dvgy) for they work with RoninDojo installation on x86 https://estudiobitcoin.com/how-to-install-ronindojo-pc-intel-amd-x86_64/

#This is a basic command line guide. Here you don't need to have 2 drives, you can use any hardware setup you have with minimum requirements that you can find in estudiobitcoin (npub1qqq…c6ad) guide. Second advantage in that you can to choose system components before install, f.e. Fulcrum, Mempool explorer. Also you can set up testnet for your experience.

#I successfully tested basic functionality, but you still can find some things not working.

#You can skip steps with Tor bridges configuration if you don't have issues with Tor connection. If you use bridges, I recommend to use also own VPN server and redirect your node traffic to it in your router configuration.

#Here I use fresh Ubuntu server 22.04. Let's go!


##############
### Pre-install ###
##############

sudo useradd -s /bin/bash -d /home/ronindojo -m -G sudo ronindojo
sudo passwd ronindojo
sudo su
echo "ronindojo ALL=(ALL) ALL" >> /etc/sudoers
su - ronindojo
sudo apt update && sudo apt upgrade
sudo apt install bash-completion nano tor obfs4proxy net-tools apt-transport-https gnupg-agent unzip git openjdk-11-jdk fail2ban net-tools htop unzip ufw rsync jq python3-pip gcc dialog bpytop less --no-install-recommends
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add -
sudo add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/ubuntu $(lsb_release -cs) stable"
sudo apt install docker-ce docker-ce-cli containerd.io docker-buildx-plugin docker-compose-plugin --no-install-recommends
sudo curl -L https://github.com/docker/compose/releases/download/v2.21.0/docker-compose-linux-x86_64 -o /usr/bin/docker-compose
sudo chmod +x /usr/bin/docker-compose
curl -fsSL https://deb.nodesource.com/setup_16.x | sudo -E bash
sudo apt install nodejs
sudo usermod -a -G docker ronindojo
exit


##################
### Samourai Dojo ###
#################

su - ronindojo
git clone https://code.samourai.io/ronindojo/samourai-dojo -b master
mkdir -p ~/dojo/docker/
ln -s /home/ronindojo/samourai-dojo/docker/my-dojo /home/ronindojo/dojo/docker/my-dojo
cd ~/samourai-dojo/docker/my-dojo/

#Generate random password
tr -dc 'a-zA-Z0-9' </dev/urandom | head -c'32'

nano conf/docker-bitcoind.conf.tpl
#Add generated password in BITCOIND_RPC_PASSWORD=

################
##For testnet only##

nano conf/docker-common.conf.tpl
#Change mainnet to testnet in COMMON_BTC_NETWORK=testnet
################

nano conf/docker-docker-indexer.conf.tpl
#Here you can change electrs to fulcrum in INDEXER_TYPE=

tr -dc 'a-zA-Z0-9' </dev/urandom | head -c'32'
tr -dc 'a-zA-Z0-9' </dev/urandom | head -c'32'
nano conf/docker-mempool.conf.tpl
#You cat install Mempool explorer with MEMPOOL_INSTALL=on
#Add generated password in MEMPOOL_MYSQL_PASS=
#Add generated password in MEMPOOL_MYSQL_ROOT_PASSWORD=

tr -dc 'a-zA-Z0-9' </dev/urandom | head -c'32'
tr -dc 'a-zA-Z0-9' </dev/urandom | head -c'32'
nano conf/docker-mysql.conf.tpl
#Add generated password in MYSQL_ROOT_PASSWORD=
#Add generated password in MYSQL_PASSWORD=

tr -dc 'a-zA-Z0-9' </dev/urandom | head -c'32'
tr -dc 'a-zA-Z0-9' </dev/urandom | head -c'32'
tr -dc 'a-zA-Z0-9' </dev/urandom | head -c'32'
nano conf/docker-node.conf.tpl
#Add generated password in NODE_API_KEY=
#Add generated password in NODE_ADMIN_KEY=
#Add generated password in NODE_JWT_SECRET=

nano conf/docker-tor.conf.tpl
#Turn on Tor bridges support in TOR_USE_BRIDGES=on
#Add bridge in TOR_BRIDGE_1="obfs4..."
#Add bridge in TOR_BRIDGE_2="obfs4..."
#Add bridge in TOR_BRIDGE_3="obfs4..."

################
##For testnet only##

nano nginx/testnet.conf
#Add below strings to section # Site Configuration:

#####################################
# Proxy WebSocket connections first
location /v2/inv {
proxy_pass http://websocket;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection $connection_upgrade;
}
# PushTX server is separate, so proxy first
location /v2/pushtx/ {
proxy_pass http://node:8081/;
}
# Tracker server is separate, so proxy first
location /v2/tracker/ {
proxy_pass http://node:8082/;
}
# Proxy all other v2 requests to the accounts server
location /v2/ {
proxy_pass http://node:8080/;
}
#####################################
################

./dojo.sh install


##############
### RoninOS ###
#############

sudo ln -s /var/lib/docker/ /mnt/usb/docker
git clone https://code.samourai.io/ronindojo/RoninOS
cd RoninOS/
sudo useradd -c "tor" tor
sudo cp overlays/RoninOS/example.tor.service /usr/lib/systemd/system/tor.service
sudo systemctl stop tor@default.service
sudo rm -rf /usr/lib/systemd/system/tor@*
sudo mkdir -p /mnt/usb/tor/
sudo chown -R tor:tor /mnt/usb/tor/

sudo nano /etc/tor/torrc
#Add below strings to end of file and add bridges after "Bridge":

#######################################
ClientTransportPlugin obfs4 exec /usr/bin/obfs4proxy
UseBridges 1
Bridge obfs4...
Bridge obfs4...
Bridge obfs4...
#Hidden Service Ronin UI
User tor
DataDirectory /mnt/usb/tor
HiddenServiceDir /mnt/usb/tor/hidden_service_ronin_backend/
HiddenServiceVersion 3
HiddenServicePort 80 127.0.0.1:8470
#######################################

sudo systemctl daemon-reload
sudo systemctl restart tor

#Wait for Bootstrapped 100% message
sudo journalctl -f -u tor

sudo mkdir /etc/plymouth
sudo cp overlays/RoninOS/etc/plymouth/plymouthd.conf /etc/plymouth/
sudo cp -r overlays/RoninOS/usr/share/plymouth/themes/ronindojo/ /usr/share/plymouth/themes/

sudo nano /etc/default/grub
#Add params to GRUB_CMDLINE_LINUX_DEFAULT="quiet splash"

sudo apt install plymouth-label
sudo update-alternatives --install /usr/share/plymouth/themes/default.plymouth default.plymouth /usr/share/plymouth/themes/ronindojo 120
sudo update-grub
sudo update-initramfs -u


#############
### Ronin-UI ###
#############

mkdir ~/Ronin-UI
cd
mkdir -p ~/.config/RoninDojo/data/
sudo bash -c "cat /mnt/usb/tor/hidden_service_ronin_backend/hostname > /home/ronindojo/.config/RoninDojo/data/ronin-ui-tor-hostname"
git clone https://code.samourai.io/ronindojo/RoninDojo
sudo ln -sf /home/ronindojo/RoninDojo/ronin /usr/local/bin/ronin
sudo mkdir -p /usr/share/nginx/logs/

nano ~/.bashrc
#Add 2 strings to the end of file:

##############################
/home/ronindojo/RoninDojo/Scripts/.logo
ronin
##############################

source ~/.bashrc

#Inside Ronin CLI
Ronin UI > Re-install
#Exit Ronin CLI


###############
### RoninDojo ###
##############

pip3 install pipenv

################
##For testnet only##
ronin
#Inside Ronin CLI
Samourai Toolkit > Boltzmann Calculator
#Exit Ronin CLI

nano ~/RoninDojo/Scripts/Menu/menu-boltzmann.sh

#############################
#Find this string:
if ! pipenv run python ludwig.py --rpc --txids="${txids}"; then
#And replace with:
if ! pipenv run python ludwig.py --testnet --rpc --txids="${txids}"; then
#############################
################

nano ~/RoninDojo/Scripts/Install/install-dojo.sh
#Find this part and comment out with # below strings:

#############################
#if ! findmnt "${install_dir}"; then
# _print_message "Missing drive mount at ${install_dir}! Please contact support for assistance..."
# _print_message "Exiting RoninDojo..."
# [ $# -eq 0 ] && _pause return
# exit 1
#fi
#############################

nano ~/RoninDojo/Scripts/functions.sh
#Find this part and comment out with # below strings:

#############################
#if ! findmnt "${install_dir}" 1>/dev/null; then
# _print_error_message "Missing drive mount at ${install_dir}!"
# _print_error_message "Please contact support for assistance..."
# _pause exit
# exit
#fi
#############################





Author Public Key
npub1smkgazuplxhcr2ggekpsmeglqk08nfdteg8fh98xpae7n97enmcs89ctp3