mirror of
https://github.com/raspiblitz/raspiblitz.git
synced 2025-10-04 12:05:04 +02:00
Merge pull request #1502 from openoms/specter-update
Specter update to v0.7.2
This commit is contained in:
@@ -19,6 +19,9 @@ fi
|
|||||||
if [ "${thunderhub}" == "on" ]; then
|
if [ "${thunderhub}" == "on" ]; then
|
||||||
OPTIONS+=(THUB "Update ThunderHub")
|
OPTIONS+=(THUB "Update ThunderHub")
|
||||||
fi
|
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)
|
CHOICE=$(whiptail --clear --title "Update Options" --menu "" 12 55 5 "${OPTIONS[@]}" 2>&1 >/dev/tty)
|
||||||
|
|
||||||
@@ -278,4 +281,7 @@ case $CHOICE in
|
|||||||
THUB)
|
THUB)
|
||||||
/home/admin/config.scripts/bonus.thunderhub.sh update
|
/home/admin/config.scripts/bonus.thunderhub.sh update
|
||||||
;;
|
;;
|
||||||
|
SPECTER)
|
||||||
|
/home/admin/config.scripts/bonus.cryptoadvance-specter.sh update
|
||||||
|
;;
|
||||||
esac
|
esac
|
||||||
|
@@ -1,8 +1,6 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
set -e
|
set -e
|
||||||
# https://github.com/cryptoadvance/specter-desktop
|
# https://github.com/cryptoadvance/specter-desktop
|
||||||
# ~/.config/btc-rpc-explorer.env
|
|
||||||
# https://github.com/janoside/btc-rpc-explorer/blob/master/.env-sample
|
|
||||||
|
|
||||||
# command info
|
# command info
|
||||||
if [ $# -eq 0 ] || [ "$1" = "-h" ] || [ "$1" = "-help" ]; then
|
if [ $# -eq 0 ] || [ "$1" = "-h" ] || [ "$1" = "-help" ]; then
|
||||||
@@ -84,6 +82,10 @@ if [ "$1" = "status" ]; then
|
|||||||
exit 0
|
exit 0
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# stop services
|
||||||
|
echo "# --> making sure the service is not running"
|
||||||
|
sudo systemctl stop cryptoadvance-specter 2>/dev/null
|
||||||
|
|
||||||
# switch on
|
# switch on
|
||||||
if [ "$1" = "1" ] || [ "$1" = "on" ]; then
|
if [ "$1" = "1" ] || [ "$1" = "on" ]; then
|
||||||
echo "# --> INSTALL Cryptoadvance Specter ***"
|
echo "# --> INSTALL Cryptoadvance Specter ***"
|
||||||
@@ -112,8 +114,7 @@ EOF
|
|||||||
sudo -u bitcoin virtualenv --python=python3 /home/bitcoin/.specter/.env
|
sudo -u bitcoin virtualenv --python=python3 /home/bitcoin/.specter/.env
|
||||||
|
|
||||||
echo "# --> pip-installing specter"
|
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
|
# Mandatory as the camera doesn't work without https
|
||||||
echo "# --> Creating self-signed certificate"
|
echo "# --> Creating self-signed certificate"
|
||||||
@@ -261,7 +262,6 @@ if [ "$1" = "0" ] || [ "$1" = "off" ]; then
|
|||||||
if [ ${isInstalled} -eq 1 ]; then
|
if [ ${isInstalled} -eq 1 ]; then
|
||||||
|
|
||||||
echo "# --> REMOVING Cryptoadvance Specter"
|
echo "# --> REMOVING Cryptoadvance Specter"
|
||||||
sudo systemctl stop cryptoadvance-specter
|
|
||||||
sudo systemctl disable cryptoadvance-specter
|
sudo systemctl disable cryptoadvance-specter
|
||||||
sudo rm /etc/systemd/system/cryptoadvance-specter.service
|
sudo rm /etc/systemd/system/cryptoadvance-specter.service
|
||||||
sudo -u bitcoin /home/bitcoin/.specter/.env/bin/python3 -m pip uninstall --yes cryptoadvance.specter
|
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
|
exit 0
|
||||||
fi
|
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'"
|
echo "error='unknown parameter'"
|
||||||
exit 1
|
exit 1
|
||||||
|
Reference in New Issue
Block a user