diff --git a/bsx/activate_venv.sh b/bsx/activate_venv.sh index 94f1907..5c67b26 100755 --- a/bsx/activate_venv.sh +++ b/bsx/activate_venv.sh @@ -1,3 +1,3 @@ #!/bin/bash . $SWAP_DATADIR/venv/bin/activate && python -V -./bsx/setup.sh +/usr/local/bin/bsx/setup.sh diff --git a/bsx/setup.sh b/bsx/setup.sh index f69c836..3196986 100755 --- a/bsx/setup.sh +++ b/bsx/setup.sh @@ -7,20 +7,17 @@ unzip -d coincurve-anonswap coincurve-anonswap.zip mv ./coincurve-anonswap/*/{.,}* ./coincurve-anonswap || true cd $SWAP_DATADIR/coincurve-anonswap pip3 install . +## UBUNTU 22.04 FIX upgrade protobuf inside of venv +python3 -m pip install --upgrade "protobuf<=3.20.1" ## Clone basicswap git cd $SWAP_DATADIR git clone https://github.com/tecnovert/basicswap.git cd $SWAP_DATADIR/basicswap - ## Install basicswap protoc -I=basicswap --python_out=basicswap basicswap/messages.proto pip3 install . -# Move scripts to /usr/local/bin -cd $SWAP_DATADIR -sudo mv -f -t /usr/local/bin/ basicswap-bash bsx* - ## Run basicswap-prepare with particl and monero if [[ "$monerod_addr" && "$monerod_port" ]]; then # Use remote Monero node diff --git a/install.sh b/install.sh index 6601463..4def4bd 100755 --- a/install.sh +++ b/install.sh @@ -34,7 +34,11 @@ read -p 'Press any key to continue, or CTRL-C to exit.' ## Update & Install dependencies sudo apt update -sudo apt install -y git wget python3-full python3-pip gnupg unzip protobuf-compiler automake libtool pkg-config curl jq +## python-is-python3 for ubuntu +sudo apt install -y git wget python-is-python3 python3-full python3-pip gnupg unzip protobuf-compiler automake libtool pkg-config curl jq +# Move scripts to /usr/local/bin +sudo rm -r /usr/local/bin/bsx # Remove old +sudo mv -f -t /usr/local/bin/ basicswap-bash bsx* # Add new ## Make venv export SWAP_DATADIR=$HOME/coinswaps @@ -42,6 +46,5 @@ export monerod_addr=$monerod_addr export monerod_port=$monerod_port mkdir -p "$SWAP_DATADIR/venv" python3 -m venv "$SWAP_DATADIR/venv" - ## Activate venv -./bsx/activate_venv.sh +/usr/local/bin/bsx/activate_venv.sh