mirror of
https://github.com/rootzoll/raspiblitz.git
synced 2025-02-25 07:07:46 +01:00
Merge pull request #1502 from openoms/specter-update
Specter update to v0.7.2
This commit is contained in:
commit
262fcb8f64
2 changed files with 21 additions and 5 deletions
|
@ -19,6 +19,9 @@ fi
|
|||
if [ "${thunderhub}" == "on" ]; then
|
||||
OPTIONS+=(THUB "Update ThunderHub")
|
||||
fi
|
||||
if [ "${specter}" == "on" ]; then
|
||||
OPTIONS+=(SPECTER "Update Cryptoadvance Specter")
|
||||
fi
|
||||
|
||||
CHOICE=$(whiptail --clear --title "Update Options" --menu "" 12 55 5 "${OPTIONS[@]}" 2>&1 >/dev/tty)
|
||||
|
||||
|
@ -278,4 +281,7 @@ case $CHOICE in
|
|||
THUB)
|
||||
/home/admin/config.scripts/bonus.thunderhub.sh update
|
||||
;;
|
||||
SPECTER)
|
||||
/home/admin/config.scripts/bonus.cryptoadvance-specter.sh update
|
||||
;;
|
||||
esac
|
||||
|
|
|
@ -1,8 +1,6 @@
|
|||
#!/bin/bash
|
||||
set -e
|
||||
# https://github.com/cryptoadvance/specter-desktop
|
||||
# ~/.config/btc-rpc-explorer.env
|
||||
# https://github.com/janoside/btc-rpc-explorer/blob/master/.env-sample
|
||||
|
||||
# command info
|
||||
if [ $# -eq 0 ] || [ "$1" = "-h" ] || [ "$1" = "-help" ]; then
|
||||
|
@ -84,6 +82,10 @@ if [ "$1" = "status" ]; then
|
|||
exit 0
|
||||
fi
|
||||
|
||||
# stop services
|
||||
echo "# --> making sure the service is not running"
|
||||
sudo systemctl stop cryptoadvance-specter 2>/dev/null
|
||||
|
||||
# switch on
|
||||
if [ "$1" = "1" ] || [ "$1" = "on" ]; then
|
||||
echo "# --> INSTALL Cryptoadvance Specter ***"
|
||||
|
@ -112,8 +114,7 @@ EOF
|
|||
sudo -u bitcoin virtualenv --python=python3 /home/bitcoin/.specter/.env
|
||||
|
||||
echo "# --> pip-installing specter"
|
||||
sudo -u bitcoin /home/bitcoin/.specter/.env/bin/python3 -m pip install --upgrade cryptoadvance.specter==0.5.5
|
||||
|
||||
sudo -u bitcoin /home/bitcoin/.specter/.env/bin/python3 -m pip install --upgrade cryptoadvance.specter==0.7.2
|
||||
|
||||
# Mandatory as the camera doesn't work without https
|
||||
echo "# --> Creating self-signed certificate"
|
||||
|
@ -261,7 +262,6 @@ if [ "$1" = "0" ] || [ "$1" = "off" ]; then
|
|||
if [ ${isInstalled} -eq 1 ]; then
|
||||
|
||||
echo "# --> REMOVING Cryptoadvance Specter"
|
||||
sudo systemctl stop cryptoadvance-specter
|
||||
sudo systemctl disable cryptoadvance-specter
|
||||
sudo rm /etc/systemd/system/cryptoadvance-specter.service
|
||||
sudo -u bitcoin /home/bitcoin/.specter/.env/bin/python3 -m pip uninstall --yes cryptoadvance.specter
|
||||
|
@ -287,5 +287,15 @@ if [ "$1" = "0" ] || [ "$1" = "off" ]; then
|
|||
exit 0
|
||||
fi
|
||||
|
||||
# update
|
||||
if [ "$1" = "update" ]; then
|
||||
echo "# --> UPDATING Cryptoadvance Specter"
|
||||
sudo -u bitcoin /home/bitcoin/.specter/.env/bin/python3 -m pip install --upgrade cryptoadvance.specter
|
||||
echo "# --> Updated to the latest in https://pypi.org/project/cryptoadvance.specter/#history ***"
|
||||
echo "# --> Starting the cryptoadvance-specter.service"
|
||||
sudo systemctl start cryptoadvance-specter
|
||||
exit 0
|
||||
fi
|
||||
|
||||
echo "error='unknown parameter'"
|
||||
exit 1
|
||||
|
|
Loading…
Add table
Reference in a new issue