summaryrefslogtreecommitdiff
path: root/swat/nbt_server
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2005-07-19 09:34:11 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 13:29:42 -0500
commit342d11e3544ec4836cf718f23ea65bee3592fc08 (patch)
treee014a00594b7ca5dbf14e67684f210eb36068884 /swat/nbt_server
parent82f1a9474d85f75291d0af0e51d55fa904d42055 (diff)
downloadsamba-342d11e3544ec4836cf718f23ea65bee3592fc08.tar.gz
samba-342d11e3544ec4836cf718f23ea65bee3592fc08.tar.bz2
samba-342d11e3544ec4836cf718f23ea65bee3592fc08.zip
r8591: - added a simple 2 level menu structure to swat. Deryck, I know this
isn't very pretty, and please feel free to do this much more nicely :-) - added a top level menu listing our main servers - added placeholder pages for the main servers - added NBT server statistics (This used to be commit 1aa658b756903e7cb598302eddd18b7734937c83)
Diffstat (limited to 'swat/nbt_server')
-rw-r--r--swat/nbt_server/index.esp24
-rw-r--r--swat/nbt_server/menu.js4
2 files changed, 28 insertions, 0 deletions
diff --git a/swat/nbt_server/index.esp b/swat/nbt_server/index.esp
new file mode 100644
index 0000000000..133615c52c
--- /dev/null
+++ b/swat/nbt_server/index.esp
@@ -0,0 +1,24 @@
+<% page_header("columns", "NBT Server", "/nbt_server/menu.js");
+
+ libinclude("base.js");
+ libinclude("management.js");
+%>
+
+<h1>NBT Server</h1>
+
+<%
+writefln("The NBT server is: %s\n", server_status("nbt"));
+%>
+
+<h2>Packet statistics</h2>
+<%
+
+var stats = nbtd_statistics();
+if (stats == undefined) {
+ writefln("nbt server not running");
+} else {
+ simple_table(stats);
+}
+%>
+
+<% page_footer(); %>
diff --git a/swat/nbt_server/menu.js b/swat/nbt_server/menu.js
new file mode 100644
index 0000000000..fd445bf861
--- /dev/null
+++ b/swat/nbt_server/menu.js
@@ -0,0 +1,4 @@
+/* show a menu for the esp test pages */
+simple_menu(
+ "NBT Server",
+ "Statistics", session_uri("/nbt_server/index.esp"));