mirror of
https://github.com/Retropex/raspiblitz.git
synced 2025-05-12 19:20:48 +02:00
Update LNDg to latest version 1.5.0 (#3597)
* Update bonus.lndg.sh * Update bonus.lndg.sh Fixes permissions on old /mnt/app-data/lndg folder/db if they are messed up prior to install * Update bonus.lndg.sh
This commit is contained in:
parent
8156c90032
commit
06472cb11e
@ -1,7 +1,7 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
|
|
||||||
# https://github.com/cryptosharks131/lndg
|
# https://github.com/cryptosharks131/lndg
|
||||||
VERSION="1.4.0 "
|
VERSION="1.5.0 "
|
||||||
|
|
||||||
# command info
|
# command info
|
||||||
if [ $# -eq 0 ] || [ "$1" = "-h" ] || [ "$1" = "-help" ]; then
|
if [ $# -eq 0 ] || [ "$1" = "-h" ] || [ "$1" = "-help" ]; then
|
||||||
@ -155,7 +155,7 @@ if [ "$1" = "1" ] || [ "$1" = "on" ]; then
|
|||||||
if [ "$2" == "deletedatabase" ]; then
|
if [ "$2" == "deletedatabase" ]; then
|
||||||
|
|
||||||
# deleting old database and moving new database
|
# deleting old database and moving new database
|
||||||
echo "Deleting existing database and creating new one"
|
echo "Deleting existing database and creating new one"
|
||||||
sudo rm -rf /mnt/hdd/app-data/lndg/data
|
sudo rm -rf /mnt/hdd/app-data/lndg/data
|
||||||
sudo cp -p -r /home/lndg/lndg/data /mnt/hdd/app-data/lndg/data
|
sudo cp -p -r /home/lndg/lndg/data /mnt/hdd/app-data/lndg/data
|
||||||
sudo rm /home/lndg/lndg/data/db.sqlite3
|
sudo rm /home/lndg/lndg/data/db.sqlite3
|
||||||
@ -166,8 +166,11 @@ if [ "$1" = "1" ] || [ "$1" = "on" ]; then
|
|||||||
# using existing database, so remove newly created database and link to existing one
|
# using existing database, so remove newly created database and link to existing one
|
||||||
echo "Database already exists, using existing database"
|
echo "Database already exists, using existing database"
|
||||||
sudo rm /home/lndg/lndg/data/db.sqlite3
|
sudo rm /home/lndg/lndg/data/db.sqlite3
|
||||||
|
sudo chown -R lndg:lndg /mnt/hdd/app-data/lndg
|
||||||
|
sudo chmod -R 755 /mnt/hdd/app-data/lndg
|
||||||
|
sudo chmod 644 /mnt/hdd/app-data/lndg/data/db.sqlite3
|
||||||
sudo -u lndg ln -sf /mnt/hdd/app-data/lndg/data/db.sqlite3 /home/lndg/lndg/data/db.sqlite3
|
sudo -u lndg ln -sf /mnt/hdd/app-data/lndg/data/db.sqlite3 /home/lndg/lndg/data/db.sqlite3
|
||||||
sudo -u lndg /home/lndg/lndg/.venv/bin/python manage.py migrate
|
sudo -u lndg /home/lndg/lndg/.venv/bin/python manage.py migrate
|
||||||
fi
|
fi
|
||||||
else
|
else
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user