]> arthur.barton.de Git - netdata.git/commitdiff
show hostname on alarm notifications
authorCosta Tsaousis (ktsaou) <costa@tsaousis.gr>
Mon, 5 Sep 2016 20:08:47 +0000 (23:08 +0300)
committerCosta Tsaousis (ktsaou) <costa@tsaousis.gr>
Mon, 5 Sep 2016 20:08:47 +0000 (23:08 +0300)
web/dashboard.html
web/dashboard.js
web/demo.html
web/demo2.html
web/demosites.html
web/index.html
web/registry.html
web/tv.html

index 7fcc73688bc431bc9b567b5a837ec015cb7907e6..25f71851094e651634ab7183814908077b0fb0b1 100644 (file)
@@ -655,4 +655,4 @@ So, to avoid flashing the charts, we destroy and re-create the charts on each up
     <!-- <script> netdataServer = "http://box:19999"; </script> -->
 
     <!-- load the dashboard manager - it will do the rest -->
-    <script type="text/javascript" src="dashboard.js?v44"></script>
+    <script type="text/javascript" src="dashboard.js?v45"></script>
index a659ee74b0ae65c24317548731c64b9b94c4a5c2..22a06d31008be86e63f4f7ea7c58758625706cca 100644 (file)
@@ -15,8 +15,8 @@
 // var netdataNoRegistry = true;        // Don't update the registry for this access
 // var netdataRegistryCallback = null;  // Callback function that will be invoked with one param,
 //                                         the URLs from the registry
-// var netdataShowHelp = true;          // enable/disable help
-// var netdataShowAlarms = true;        // enable/disable help
+// var netdataShowHelp = false;         // enable/disable help (default enabled)
+// var netdataShowAlarms = true;        // enable/disable alarms checks and notifications (default disabled)
 //
 // You can also set the default netdata server, using the following.
 // When this variable is not set, we assume the page is hosted on your
@@ -50,6 +50,8 @@
     // global namespace
     var NETDATA = window.NETDATA || {};
 
+    NETDATA.hostname = 'localhost';
+
     // ----------------------------------------------------------------------------------------------------------------
     // Detect the netdata server
 
                 }
                 else NETDATA.error(406, host + '/api/v1/charts');
 
+                NETDATA.hostname = data.hostname;
+
                 if(typeof callback === 'function')
                     callback(data);
             })
 
             var name = entry.name.replace(/_/g, ' ');
             var title = name + ' = ' + ((entry.value === null)?'NaN':Math.floor(entry.value)).toString() + ' ' + entry.units;
-            var body = entry.info + ' of ' + entry.chart + ' (' + entry.family + ')';
+            var body = NETDATA.hostname + ' - ' + entry.chart + ' (' + entry.family + ') - ' + entry.status.toLowerCase() + ': ' + entry.info;
             var tag = entry.alarm_id;
             var icon = 'images/seo-performance-128.png';
             var interaction = false;
index 8ed63f096ae93f2d35ff63ad054396caf4f1a399..7642cd5a73eea43f143a89f787aa97cf22d62d61 100644 (file)
@@ -20,7 +20,7 @@
     <meta property="og:title" content="netdata - real-time performance monitoring, done right!"/>
     <meta property="og:description" content="Stunning real-time dashboards, blazingly fast and extremely interactive. Zero configuration, zero dependencies, zero maintenance." />
     
-    <script type="text/javascript" src="dashboard.js?v44"></script>
+    <script type="text/javascript" src="dashboard.js?v45"></script>
 </head>
 <body>
 
index 7e0f3058f4a6be551f2194a6db5e2cbfe91ff994..ccf8c0600dd1ca86aaa9ec21ae7c158f25894032 100644 (file)
@@ -21,7 +21,7 @@
     <meta property="og:description" content="Stunning real-time dashboards, blazingly fast and extremely interactive. Zero configuration, zero dependencies, zero maintenance." />
 
     <script>var netdataTheme = 'slate';</script>
-    <script type="text/javascript" src="http://my-netdata.io/dashboard.js?v44"></script>
+    <script type="text/javascript" src="http://my-netdata.io/dashboard.js?v45"></script>
 </head>
 <body>
 
index 9ad5b5326bd766ab5c277179929b187fa3a86cca..1598ac96618a9abe5091c271c6f9ee0bc8010f9b 100644 (file)
@@ -51,7 +51,7 @@
         and that you have chown it to be owned by netdata:netdata
     -->
     <!-- <script type="text/javascript" src="http://my.server:19999/dashboard.js"></script> -->
-    <script type="text/javascript" src="dashboard.js?v44"></script>
+    <script type="text/javascript" src="dashboard.js?v45"></script>
 
     <script>
     // --- OPTIONS FOR THE CHARTS --
index 536b567558414d6112d864cda10fc00b37971123..8721bc7528c31e884277cd4ace9573eca802c1fb 100644 (file)
 
     <!-- check which theme to use -->
     <script type="text/javascript">
-        var netdataShowNotifications = true;
+        // enable alarms checking and notifications
         var netdataShowAlarms = true;
         
         // --------------------------------------------------------------------
     </script>
 
     <!-- load the dashboard manager - it will do the rest -->
-    <script type="text/javascript" src="dashboard.js?v44"></script>
+    <script type="text/javascript" src="dashboard.js?v45"></script>
 </head>
 <body data-spy="scroll" data-target="#sidebar">
     <div id="loadOverlay" class="loadOverlay" style="background-color: #888; color: #888;">
index 8b5dc3870236f4054b4cc74bbea02838c63e50a4..6c7589ec7aed380d8a2f8ff095b84504990298bb 100644 (file)
         and that you have chown it to be owned by netdata:netdata
     -->
     <!-- <script type="text/javascript" src="http://my.server:19999/dashboard.js"></script> -->
-    <script type="text/javascript" src="dashboard.js?v44"></script>
+    <script type="text/javascript" src="dashboard.js?v45"></script>
 
     <script>
     // Set options for TV operation
index f648a41eaff5e3b1d5672af8b32990ad711dc858..7bd2900e1dcb4beaee762fa526fe5b32baa8fe42 100644 (file)
@@ -49,7 +49,7 @@
         and that you have chown it to be owned by netdata:netdata
     -->
     <!-- <script type="text/javascript" src="http://my.server:19999/dashboard.js"></script> -->
-    <script type="text/javascript" src="dashboard.js?v44"></script>
+    <script type="text/javascript" src="dashboard.js?v45"></script>
 
     <script>
     // Set options for TV operation