33source /home/joinmarket/joinin.conf
44
55# Basic Options
6- OPTIONS=(LINUX " Running Linux" \
7- MAC " Running MacOS" \
8- WINDOWS " Running Windows" \
6+ OPTIONS=(LINUX " Running Linux"
7+ MAC " Running MacOS"
8+ WINDOWS " Running Windows"
9+ localhost " Linux on the same desktop"
910 )
1011
11- CHOICE=$( dialog --clear --title " Choose a desktop OS" --menu " " 9 45 3 " ${OPTIONS[@]} " 2>&1 > /dev/tty)
12+ CHOICE=$( dialog --clear --title " Choose a desktop OS" --menu " " 10 45 4 " ${OPTIONS[@]} " 2>&1 > /dev/tty)
1213
1314clear
1415case $CHOICE in
1516 LINUX) echo " Showing intructions for Linux" ;;
1617 MAC) echo " Showing intructions for MacOS" ;;
1718 WINDOWS) echo " Showing intructions for Windows" ;;
19+ localhost) echo " Showing intructions for Linux on the same desktop" ;;
1820 * ) exit 1;;
1921esac
2022
@@ -27,6 +29,12 @@ if grep -Eq "^joinmarketSSH=off" /home/joinmarket/joinin.conf; then
2729 joinmarketSSHchanged=1
2830fi
2931
32+ if [ " $RPCoverTor " = " on" ]; then
33+ tor=" torsocks "
34+ else
35+ tor=" "
36+ fi
37+
3038echo "
3139************************************************************************************
3240Instructions to open the JoinMarket-QT GUI on the desktop
@@ -37,19 +45,23 @@ if [ "${CHOICE}" = "LINUX" ]; then
3745 echo "
3846Use the following line in a new desktop terminal to connect:
3947
40- ssh -X joinmarket@$localip joinmarket-clientserver/jmvenv/bin/python joinmarket-clientserver/scripts/joinmarket-qt.py
48+ ssh -X joinmarket@${localip}${tor} joinmarket-clientserver/jmvenv/bin/python joinmarket-clientserver/scripts/joinmarket-qt.py
49+
50+ Use the PASSWORD_B (rpcpassword in the bitcoin.conf) to open the JoinMarket-QT GUI
51+ "
4152
42- Use the PASSWORD_B (rpcpassword in the bitcoin.conf) to open the JoinMarket-QT GUI"
4353
4454elif [ " ${CHOICE} " = " MAC" ]; then
4555 echo "
4656Install the XQuartz application from https://www.xquartz.org/
4757
4858Use the following line in a new desktop terminal to connect:
4959
50- ssh -X joinmarket@$localip joinmarket-clientserver/jmvenv/bin/python joinmarket-clientserver/scripts/joinmarket-qt.py
60+ ssh -X joinmarket@${localip}${tor} joinmarket-clientserver/jmvenv/bin/python joinmarket-clientserver/scripts/joinmarket-qt.py
61+
62+ Use the PASSWORD_B (rpcpassword in the bitcoin.conf) to open the JoinMarket-QT GUI
63+ "
5164
52- Use the PASSWORD_B (rpcpassword in the bitcoin.conf) to open the JoinMarket-QT GUI"
5365
5466elif [ " ${CHOICE} " = " WINDOWS" ]; then
5567 echo "
@@ -73,9 +85,36 @@ In the terminal Exit to the Command Line and type:
7385qtgui
7486
7587The QT GUI will appear on the Windows desktop running from your RaspiBlitz.
88+ "
89+
90+ elif [ " ${CHOICE} " = " localhost" ]; then
91+
92+ if ! grep -Eq " ^X11Forwarding no" /etc/ssh/sshd_config; then
93+ echo " X11Forwarding no" | sudo tee -a /etc/ssh/sshd_config
94+ fi
95+ if sudo sed -i " s/^X11Forwarding no/X11Forwarding yes/g" /etc/ssh/sshd_config; then
96+ echo " # Set 'X11Forwarding yes' and restarting sshd"
97+ sudo service sshd restart
98+ fi
7699
100+ echo "
101+ Use the following line in a new desktop terminal to connect:
102+
103+ ssh -X joinmarket@localhost${tor} joinmarket-clientserver/jmvenv/bin/python joinmarket-clientserver/scripts/joinmarket-qt.py
104+
105+ Use your ssh password to open the JoinMarket-QT GUI
106+
107+
108+ Alternatively disable the display access control of the xserver:
109+ * Open a new terminal on the desktop
110+ * type:
111+ xhost +
112+ * use the shortcut in the JoininBox terminal to open the JoinMarket-QT GUI:
113+ qtgui
114+ * re-enable the access control with:
115+ xhost -
77116"
78- fi
117+ fi
79118
80119echo "
81120
@@ -96,6 +135,13 @@ https://twitter.com/zndtoshi/status/1191799199119134720
96135Press ENTER when done with the instructions to exit to the menu
97136"
98137
138+ if grep -Eq " ^X11Forwarding yes" /etc/ssh/sshd_config; then
139+ echo " # Setting 'X11Forwarding no' in the /etc/ssh/sshd_config"
140+ sudo sed -i " s/^X11Forwarding yes/X11Forwarding no/g" /etc/ssh/sshd_config
141+ echo " # Restarting sshd"
142+ sudo service sshd restart
143+ fi
144+
99145sleep 2
100146read key
101147
0 commit comments