High Contrast Status Map option
Re: High Contrast Status Map option
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
Try adding the desired color to "/usr/local/nagios/share/stylesheets/map-directive.css":
Example:
Example:
Did this help?.node {
font-family: sans-serif;
color: green;
stroke: green;
fill: green;
}
Be sure to check out our Knowledgebase for helpful articles and solutions!
Re: High Contrast Status Map option
Hello lmiltchev - you're amazing - thank you.
Please close this topic.
Please close this topic.
Re: High Contrast Status Map option
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>
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
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";
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";
-
dwhitfield
- Former Nagios Staff
- Posts: 4583
- Joined: Wed Sep 21, 2016 10:29 am
- Location: NoLo, Minneapolis, MN
- Contact:
Re: High Contrast Status Map option
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!discarn8 wrote: Please close this topic.
Re: High Contrast Status Map option
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.