Skip to content
This repository was archived by the owner on Nov 24, 2025. It is now read-only.

Commit b9f982d

Browse files
authored
kibana (#114)
1 parent 743e833 commit b9f982d

File tree

2 files changed

+22
-2
lines changed

2 files changed

+22
-2
lines changed

FireMotD

Lines changed: 17 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#!/bin/bash
22
# Script name: FireMotD
3-
# Version: v9.14.180716
3+
# Version: v9.15.180716
44
# Created on: 10/02/2014
55
# Author: Willem D'Haese
66
# Contributors: Thomas Dietrich, Dmitry Romanenko
@@ -588,6 +588,20 @@ ExploreLogstash () {
588588
jq ".Logstash.LastRun = \"$ExportTime\"" $ExportFile | sponge $ExportFile
589589
}
590590

591+
ExploreKibana () {
592+
ExportTime=$(date '+%Y-%m-%d %H:%M:%S,%3N')
593+
if [[ -x "/usr/bin/yum" ]] ; then
594+
KibanaVersion=$(/usr/bin/yum info -v kibana 2>/dev/null | grep -A12 -B5 -w installed | grep Version | awk '{print $3}')
595+
else
596+
KibanaVersion="Unknown"
597+
fi
598+
if [ -z $KibanaVersion ] || [[ $KibanaVersion == *"Error: No matching Packages"* ]] ; then
599+
KibanaVersion="Unknown"
600+
fi
601+
jq ".Kibana.Version = \"$KibanaVersion\"" $ExportFile | sponge $ExportFile
602+
jq ".Kibana.LastRun = \"$ExportTime\"" $ExportFile | sponge $ExportFile
603+
}
604+
591605
ExportData () {
592606
if [[ -s "$ExportFile" ]] ; then
593607
if [[ "$TemplateType" != "default" ]] ; then
@@ -1860,7 +1874,8 @@ CheckAction () {
18601874
ColorTest 0 ;;
18611875
colortest)
18621876
ColorTest ;;
1863-
*) break ;;
1877+
*)
1878+
WriteLog Output Error "Invalid action: \"$Action\"" ; exit 1 ;;
18641879
esac
18651880
return $?
18661881
}

themes/FireMotD-theme-Elastic.json

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -103,6 +103,11 @@
103103
"Char": "o0",
104104
"Value": "Logstash"
105105
},
106+
{
107+
"Type" : "Info",
108+
"Char": "o0",
109+
"Value": "Kibana"
110+
},
106111
{
107112
"Type" : "Line",
108113
"Char": "Y"

0 commit comments

Comments
 (0)