Page 2 of 2
Re: High Contrast Status Map option
Posted: Mon Jul 31, 2017 8:19 pm
by discarn8
Hello... My sincere apologies - I apparently misunderstood the purpose of posting to this forum. I've not found the answer to one of my existing questions (concerning how to change the node colors on the map) but if you need to close the topic, please feel free to and thank you for asking and again for your assistance.
Re: High Contrast Status Map option
Posted: Tue Aug 01, 2017 1:38 pm
by lmiltchev
Try adding the desired color to "/usr/local/nagios/share/stylesheets/map-directive.css":
Example:
.node {
font-family: sans-serif;
color: green;
stroke: green;
fill: green;
}
Did this help?
Re: High Contrast Status Map option
Posted: Sat Aug 05, 2017 12:06 am
by discarn8
Hello lmiltchev - you're amazing - thank you.
Please close this topic.
Re: High Contrast Status Map option
Posted: Sun Aug 06, 2017 1:50 am
by discarn8
Note:
To add a bit of "
visual flair" to your "
down nodes"
...you can make them stand out a bit more by making their red a "
little louder" by making the following change to your
/usr/local/nagios/share/map-directive.html :
Change your [filter id="icon-glow-down"] to
<filter id="icon-glow-down" x="-50%" y="-50%"
width="200%" height="200%">
<feComponentTransfer in="SourceAlpha" result="solid">
<feFuncR type="table" tableValues="1 0 0 0"/>
<feFuncG type="table" tableValues="0 0 0 0"/>
<feFuncB type="table" tableValues="0 0 0 0"/>
</feComponentTransfer>
<feGaussianBlur in="solid" stdDeviation="6" result="blur"/>
<feBlend in="SourceGraphic" in2="
solid"
mode="screen"/>
</filter>
Re: High Contrast Status Map option
Posted: Sun Aug 06, 2017 2:11 am
by discarn8
If you wish to use the black background on your map, as shown previously, but notice that your "status ok" node labels disappear (because they are also black), edit your: /usr/local/nagios/share/js/map-directive.js
Change the var state = "ok" section's "attrs["fill"]=" to your color of choice:
// Placeholder for attributes
var attrs = new Object;
var state = "ok";
var stateCounts = {};
// Variables used for all layouts
var serviceCount = getObjAttr(d, ["serviceCount"], 0);
var iconTextPadding = getIconTextPadding(d);
var fontSize = $scope.fontSize + "px";
if (d.hostInfo.name == $scope.$parent.search.host)
fontSize = ($scope.fontSize * 2) + "px";
attrs["font-size"] = fontSize;
attrs["font-weight"] = "normal";
attrs["text-decoration"] = "none";
attrs["fill"] = "#00ff00";
Re: High Contrast Status Map option
Posted: Mon Aug 07, 2017 3:30 pm
by dwhitfield
discarn8 wrote:
Please close this topic.
I see this, and then two additional posts. Do you still want us to close? I didn't see a new question, just more info, but maybe I am missing something. Thanks for the additional info!
Re: High Contrast Status Map option
Posted: Thu Aug 10, 2017 1:13 am
by discarn8
Please close it. I posted the last couple of replies, just in case anyone else comes looking for the same information that I originally was seeking. Thanks again for the assistance.