mirror of
https://github.com/mynodebtc/mynode.git
synced 2025-01-11 11:29:27 +00:00
Resetting Electrum Server data no longer needs reboot
This commit is contained in:
parent
aafc981965
commit
05c7ec8599
|
@ -870,12 +870,13 @@ def restart_electrs():
|
|||
t.start()
|
||||
|
||||
def delete_electrs_data():
|
||||
os.system("rm -rf /mnt/hdd/mynode/electrs")
|
||||
os.system("rm -rf /mnt/hdd/mynode/electrs/bitcoin")
|
||||
os.system("rm -rf /mnt/hdd/mynode/electrs/testnet")
|
||||
|
||||
def reset_electrs():
|
||||
stop_electrs()
|
||||
delete_electrs_data()
|
||||
reboot_device()
|
||||
restart_electrs()
|
||||
|
||||
|
||||
#==================================
|
||||
|
|
|
@ -530,19 +530,11 @@ def open_clone_tool_page():
|
|||
def reset_electrs_page():
|
||||
check_logged_in()
|
||||
|
||||
check_and_mark_reboot_action("reset_electrs")
|
||||
|
||||
t = Timer(1.0, reset_electrs)
|
||||
t.start()
|
||||
|
||||
# Display wait page
|
||||
templateData = {
|
||||
"title": "myNode",
|
||||
"header_text": "Resetting Electrum Data",
|
||||
"subheader_text": "This will take several minutes...",
|
||||
"ui_settings": read_ui_settings()
|
||||
}
|
||||
return render_template('reboot.html', **templateData)
|
||||
flash("Resetting Electrum Server data...", category="message")
|
||||
return redirect("/settings")
|
||||
|
||||
@mynode_settings.route("/settings/clear-mempool-cache")
|
||||
def clear_mempool_cache_page():
|
||||
|
|
|
@ -835,7 +835,7 @@
|
|||
<div class="settings_block_header">Electrum Server</div>
|
||||
|
||||
<div class="settings_block_subheader">Reset Electrum Server</div>
|
||||
Advanced: This will delete your Electrum Server data and reboot your device.
|
||||
This will delete your Electrum Server data and restart Electrum Server.
|
||||
<br/>
|
||||
<a href="/settings/reset-electrs" class="ui-button ui-widget ui-corner-all settings_button">Reset Data</a>
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user