mirror of
https://github.com/mynodebtc/mynode.git
synced 2024-11-14 01:19:16 +00:00
17 lines
550 B
Bash
Executable File
17 lines
550 B
Bash
Executable File
#!/bin/bash
|
|
|
|
source /usr/share/mynode/mynode_config.sh
|
|
|
|
set -x
|
|
|
|
# Migrate files to HDD
|
|
# Older version used SD card, but data would get lost during SD re-flash
|
|
if [[ -f /opt/mynode/whirlpool/whirlpool-cli-config.properties && ! -f /mnt/hdd/mynode/whirlpool/whirlpool-cli-config.properties ]]; then
|
|
# Copy old files to new location
|
|
cp -f /opt/mynode/whirlpool/whirlpool-cli-config.properties /mnt/hdd/mynode/whirlpool/whirlpool-cli-config.properties
|
|
cp -f /opt/mynode/whirlpool/*.json /mnt/hdd/mynode/whirlpool/
|
|
|
|
# Sync FS
|
|
sync
|
|
fi
|