Add homepage tile for BoS

This commit is contained in:
Taylor Helsper 2021-10-23 20:15:16 -05:00
parent 8e91dfae82
commit 48e08ce724
5 changed files with 84 additions and 1 deletions

View File

@ -247,7 +247,7 @@
"can_uninstall": true,
"can_enable_disable": false,
"show_on_homepage": true,
"homepage_order": 42
"homepage_order": 43
},
{
"name": "Web SSH",

View File

@ -0,0 +1,23 @@
from flask import Blueprint, render_template, redirect, request, flash, send_from_directory
from user_management import check_logged_in
from device_info import read_ui_settings
from systemctl_info import *
import os
import time
import subprocess
import os
mynode_bos = Blueprint('mynode_bos',__name__)
### Page functions
@mynode_bos.route("/bos")
def bos_page():
check_logged_in()
# Load page
templateData = {
"title": "myNode Balance of Satoshis",
"ui_settings": read_ui_settings(),
}
return render_template('bos.html', **templateData)

View File

@ -10,6 +10,7 @@ from joininbox import mynode_joininbox
from caravan import mynode_caravan
from sphinxrelay import mynode_sphinxrelay
from pyblock import mynode_pyblock
from bos import mynode_bos
from manage_apps import mynode_manage_apps
from tor import mynode_tor
from vpn import mynode_vpn
@ -86,6 +87,7 @@ app.register_blueprint(mynode_joininbox)
app.register_blueprint(mynode_caravan)
app.register_blueprint(mynode_sphinxrelay)
app.register_blueprint(mynode_pyblock)
app.register_blueprint(mynode_bos)
app.register_blueprint(mynode_manage_apps)
app.register_blueprint(mynode_tor)
app.register_blueprint(mynode_electrum_server)

View File

@ -0,0 +1,56 @@
<!DOCTYPE html lang="en">
<head>
<title>{{ title }}</title>
{% include 'includes/head.html' %}
</head>
<body>
{% include 'includes/logo_header.html' %}
<div class="mynode_back_div">
<a class="ui-button ui-widget ui-corner-all mynode_back" href="/"><span class="ui-icon ui-icon-home"></span>home&nbsp;</a>
</div>
{% include 'includes/message_display.html' %}
<div class="main_header">Balance of Satoshis</div>
<br/>
<div class="app_tile_row">
<div class="info_tile">
<div class="info_tile_header">Status</div>
<div class="info_tile_contents">Ready</div>
</div>
</div>
<div class="instructions">
<div class="instructions-header">Instructions to run Balance of Satoshis</div>
<ol class="instructions-steps">
<li>Balance of Satoshis (bos) is a tool for viewing and interacting with lnd.</li>
<li>To get started, you need access to the Linux terminal of your myNode device.</li>
<ul>
<li>A guide to access the Linux terminal is available here - <a href="https://mynodebtc.github.io/advanced/linux-terminal.html" target="_blank">guide</a></li>
</ul>
<li>Once you have terminal access, run commands starting with 'bos'. For example:</li>
<ul>
<li><pre>bos peers</pre></li>
<li><pre>bos balance</pre></li>
<li><pre>bos utxos</pre></li>
<li><pre>bos report</pre></li>
<li><pre>bos help</pre></li>
</ul>
<li>Enjoy Balance of Satoshis!</li>
</ol>
<br/><br/>
<!--
<div class="instructions-header">Tips and Notes</div>
<ul style="font-size: 12px;">
<li>Add tips and notes</li>
</ul>
-->
</div>
{% include 'includes/footer.html' %}
</body>
</html>

View File

@ -51,5 +51,7 @@
</ul>
-->
</div>
{% include 'includes/footer.html' %}
</body>
</html>