mirror of
https://github.com/mynodebtc/mynode.git
synced 2024-11-14 17:39:16 +00:00
Migrate to version + install marker file combo
This commit is contained in:
parent
142421487d
commit
b56dfcf71d
18
rootfs/standard/usr/bin/mynode_migrate_version_files.sh
Executable file
18
rootfs/standard/usr/bin/mynode_migrate_version_files.sh
Executable file
|
@ -0,0 +1,18 @@
|
|||
#!/bin/bash
|
||||
|
||||
# Migrate from version file to version+install combo
|
||||
# Check install for sd storage
|
||||
FILES=$(ls /home/bitcoin/.mynode/*_version)
|
||||
for file in $FILES; do
|
||||
filename=$(basename $file)
|
||||
shortname=${filename::-8}
|
||||
touch /home/bitcoin/.mynode/install_$shortname
|
||||
done
|
||||
# Check install for ssd storage
|
||||
FILES=$(ls /mnt/hdd/mynode/settings/*_version)
|
||||
for file in $FILES; do
|
||||
filename=$(basename $file)
|
||||
shortname=${filename::-8}
|
||||
touch /mnt/hdd/mynode/settings/install_$shortname
|
||||
done
|
||||
sync
|
|
@ -40,6 +40,11 @@ if [ -f /mnt/hdd/mynode/settings/torify_apt_get ]; then
|
|||
TORIFY="torify"
|
||||
fi
|
||||
|
||||
|
||||
# Migrate from version file to version+install combo
|
||||
/usr/bin/mynode_migrate_version_files.sh
|
||||
|
||||
|
||||
# Stop and disable any old services
|
||||
systemctl disable https || true
|
||||
systemctl stop https || true
|
||||
|
|
|
@ -284,6 +284,10 @@ if [ ! -f /mnt/hdd/mynode/settings/.setquicksyncdefault ]; then
|
|||
fi
|
||||
|
||||
|
||||
# Migrate from version file to version+install combo
|
||||
/usr/bin/mynode_migrate_version_files.sh
|
||||
|
||||
|
||||
# BTC Config
|
||||
source /usr/bin/mynode_gen_bitcoin_config.sh
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user