59 lines
1.7 KiB
Bash
59 lines
1.7 KiB
Bash
|
#!/bin/sh
|
||
|
# -*- mode: sh; fill-column: 75; tab-width: 8; coding: utf-8-unix -*-
|
||
|
|
||
|
ROLE=toxcore
|
||
|
. /usr/local/bin/usr_local_tput.bash
|
||
|
|
||
|
[ $# -gt 0 ] && ERROR no arguments needed && exit 1
|
||
|
|
||
|
cd /var/local/bin/
|
||
|
network=new
|
||
|
|
||
|
[ -f /etc/tox-bootstrapd.conf ] && \
|
||
|
port=`grep ^port /etc/tox-bootstrapd.conf | sed -e 's/.*[ ]//'`
|
||
|
[ $? -eq 0 -a -n "$port" ] || port=33446
|
||
|
|
||
|
# EC8F7405F79F281569B6C66D9F03490973AB99BC9175C44FBEF4C3428A63B80D
|
||
|
python3.sh bootstrap_node_info.py ipv4 \
|
||
|
127.0.0.1 $port $network
|
||
|
python3.sh bootstrap_node_info.py tcp4 \
|
||
|
127.0.0.1 3389 $network
|
||
|
|
||
|
grep -q "^wlan[1-9][ ]00000000" /proc/net/route || { echo ERROR: not connected ; exit 1 ; }
|
||
|
|
||
|
if [ `id -un` = bin ] ; then
|
||
|
socks5=ipv4
|
||
|
socks=ipv4
|
||
|
else
|
||
|
socks5=socks5
|
||
|
socks=socks
|
||
|
fi
|
||
|
|
||
|
# onion
|
||
|
[ $socks5 = socks5 ] && \
|
||
|
python3.sh bootstrap_node_info.py $socks5 \
|
||
|
pvbgbm6bmn2d5xnmdqivowsi36ywawmixr645lnjuon22lriqj6gufqd.onion \
|
||
|
$port $network
|
||
|
[ $socks5 = socks5 ] && \
|
||
|
python3.sh bootstrap_node_info.py $socks5 \
|
||
|
pvbgbm6bmn2d5xnmdqivowsi36ywawmixr645lnjuon22lriqj6gufqd.onion \
|
||
|
38445 $network
|
||
|
[ $socks = socks ] && \
|
||
|
python3.sh bootstrap_node_info.py $socks \
|
||
|
pvbgbm6bmn2d5xnmdqivowsi36ywawmixr645lnjuon22lriqj6gufqd.onion \
|
||
|
$port $network
|
||
|
[ $socks = socks ] && \
|
||
|
python3.sh bootstrap_node_info.py $socks \
|
||
|
pvbgbm6bmn2d5xnmdqivowsi36ywawmixr645lnjuon22lriqj6gufqd.onion \
|
||
|
38445 $network
|
||
|
[ $socks = socks ] && \
|
||
|
python3.sh bootstrap_node_info.py $socks \
|
||
|
pvbgbm6bmn2d5xnmdqivowsi36ywawmixr645lnjuon22lriqj6gufqd.onion \
|
||
|
80
|
||
|
|
||
|
# $network
|
||
|
python3.sh bootstrap_node_info.py $socks \
|
||
|
172.93.52.70 $port $network
|
||
|
python3.sh bootstrap_node_info.py $socks5 \
|
||
|
172.93.52.70 $port $network
|