Skip to content

Commit

Permalink
Download webui logs functionality added!
Browse files Browse the repository at this point in the history
  • Loading branch information
mariyachanniwala committed Jun 14, 2018
1 parent 469d29d commit 4ab24d0
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
7 changes: 6 additions & 1 deletion br-webui/_includes/header.liquid
Original file line number Diff line number Diff line change
Expand Up @@ -42,9 +42,14 @@
<form class="navbar-form navbar-right">
<button onclick="reboot()" class="btn btn-primary btn-sm navbar-btn">Reboot</button>
<button onclick="shutdown()" class="btn btn-error btn-sm navbar-btn">Shutdown</button>
<a href="/webui.log" download>
<button type="button" class="btn btn-primary btn-sm navbar-btn">
Send Error Log
</button>
</a>
</form>
</div><!--/.nav-collapse -->
</div>
</nav>

<div class="container">
<div class="container">
1 change: 1 addition & 0 deletions br-webui/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ var env = process.env
logger.log('ENVIRONMENT', process.env)
logger.log('COMPANION_DIR', process.env.COMPANION_DIR)
app.use(express.static('public'));
app.use('/webui.log', express.static('/home/pi/.webui.log'));
app.use('/js', express.static(__dirname + '/node_modules/bootstrap/dist/js')); // redirect bootstrap JS
app.use('/js', express.static(__dirname + '/node_modules/jquery/dist')); // redirect JS jQuery
app.use('/font-awesome', express.static(__dirname + '/node_modules/font-awesome')); // redirect JS jQuery
Expand Down

0 comments on commit 4ab24d0

Please sign in to comment.