[shinken] new specfile

david hannequin hvad at fedoraproject.org
Mon Jan 7 20:37:17 UTC 2013


commit e8c4f645113a50ffa126a97e2f17fa36aad5a099
Author: hvad <david.hannequin at gmail.com>
Date:   Mon Jan 7 21:37:06 2013 +0100

    new specfile

 .gitignore               |    1 +
 shinken-commands.cfg     |  248 ++++++++++++++++++++++++++++++++++++++++++++++
 shinken-webui-menu.patch |   37 +++++++
 sources                  |    2 +-
 4 files changed, 287 insertions(+), 1 deletions(-)
---
diff --git a/.gitignore b/.gitignore
index 7097f43..6c9f377 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1 +1,2 @@
 /shinken-1.0.1.tar.gz
+/shinken-1.2.2.tar.gz
diff --git a/shinken-commands.cfg b/shinken-commands.cfg
new file mode 100644
index 0000000..f7aad1a
--- /dev/null
+++ b/shinken-commands.cfg
@@ -0,0 +1,248 @@
+# Here are some sample commands for checking classics things like
+# systems and websites
+
+
+# -----------------------------------------------------------------
+#
+#      Classic network calls
+#
+# -----------------------------------------------------------------
+
+# Simple tcp check
+define command {
+       command_name	check_tcp
+       command_line	$PLUGINSDIR$/check_tcp  -H $HOSTADDRESS$ -p $ARG1$
+}
+
+# Simple web check
+define command {
+       command_name	check_http
+       command_line	$PLUGINSDIR$/check_http -H $HOSTADDRESS$
+}
+
+# And with SSL
+define command {
+       command_name     check_https
+       command_line     $PLUGINSDIR$/check_http -H $HOSTADDRESS$ -S
+}
+
+
+# Check a DNS entry
+define command {
+       command_name	check_dig
+       command_line 	$PLUGINSDIR$/check_dig -H $HOSTADDRESS$ -l $ARG1$
+}
+
+# Check a FTP service
+define command {
+       command_name	check_ftp
+       command_line	$PLUGINSDIR$/check_ftp -H $HOSTADDRESS$
+}
+
+
+# Ask a nrpe agent
+define command {
+       command_name	check_nrpe
+       command_line	$PLUGINSDIR$/check_nrpe -H $HOSTADDRESS$ -t 9 -u -c $ARG1$
+}
+
+# Same but with arguments
+define command {
+       command_name	check_nrpe_args
+       command_line	$PLUGINSDIR$/check_nrpe -H $HOSTADDRESS$ -t 9 -u -c $ARG1$ -a $ARG2$ $ARG3$ $ARG4$ $ARG5$
+}
+
+# Simple ping command
+define command {
+       command_name	check_ping
+       command_line	$PLUGINSDIR$/check_ping -H $HOSTADDRESS$ -w 3000,100% -c 5000,100% -p 1
+}
+
+# Look at good ssh launch
+define command {
+       command_name	check_ssh
+       command_line	$PLUGINSDIR$/check_ssh -H $HOSTADDRESS$
+}
+
+# Look for good smtp connection
+define command {
+       command_name	check_smtp
+       command_line	$PLUGINSDIR$/check_smtp -H $HOSTADDRESS$
+}
+
+# And SMTPS too
+define command {
+       command_name	check_smtps
+       command_line	$PLUGINSDIR$/check_smtp -H $HOSTADDRESS$ -S
+}
+
+# Look at a SSL certificate
+define command {
+       command_name	check_https_certificate
+       command_line	$PLUGINSDIR$/check_http -H $HOSTADDRESS$ -C 30
+}
+
+#Look at an HP printer state
+define command{
+       command_name     check_hpjd
+       command_line     $PLUGINSDIR$/check_hpjd -H $HOSTADDRESS$ -C $SNMPCOMMUNITYREAD$
+}
+
+
+# Look at Oracle connection
+define command {
+       command_name	check_oracle_listener
+       command_line	$PLUGINSDIR$/check_oracle --tns $HOSTADDRESS$
+}
+
+# Same but for MSSQL
+# Look at http://labs.consol.de/nagios/check_mssql_health/ to get it
+# Don't forget to change $MSSQLUSER$ and $MSSQLPASSWORD$ in resources.cfg before you use this ;)
+define command {
+       command_name	check_mssql_connection
+       command_line	$PLUGINSDIR$/check_mssql_health --hostname $HOSTADDRESS$ --username "$MSSQLUSER$" --password "$MSSQLPASSWORD$" --mode connection-time
+}
+
+
+# Ldap query
+# Don't forget to update the macros in the resources.cfg file
+define command {
+       command_name	check_ldap
+       command_line	$PLUGINSDIR$/check_ldap -H $HOSTADDRESS$ -b "$LDAPBASE$" -D $DOMAINUSER$ -P "$DOMAINPASSWORD$"
+}
+
+# Now the same, but in LDAPS
+# Don't forget to update the macros in the resources.cfg
+define command {
+       command_name     check_ldaps
+       command_line     $PLUGINSDIR$/check_ldaps -H $HOSTADDRESS$ -b "$LDAPBASE$" -D $DOMAINUSER$ -P "$DOMAINPASSWORD$"
+}
+
+# Distant mysql check
+define command {
+       command_name	check_mysql_connection
+       command_line	$PLUGINSDIR$/check_mysql -H $HOSTADDRESS$ -u $MYSQLUSER$ -p $MYSQLPASSWORD$
+}
+
+
+## Now ESX and VM checks
+##ARG1 and take cpu, io, net or mem
+define command{
+       command_name     check_esx_host
+       command_line     $PLUGINSDIR$/check_esx3.pl -D $VCENTER$ -H $HOSTADDRESS$ -u $VCENTERLOGIN$ -p $VCENTERPASSWORD$ l $ARG1$
+}
+
+define command{
+        command_name    check_esx_vm
+        command_line    $PLUGINSDIR$/check_esx3.pl -D $VCENTER$ -N $HOSTALIAS$ -u $VCENTERLOGIN$ -p $VCENTERPASSWORD$ -l $ARG1$
+}
+
+
+#### Then samples which are not really useful in the real world
+
+#Pollertag is a advanced features for mix architectures. Look at the doc for it.
+define command{
+	command_name	check_linux_host_alive
+	command_line	$PLUGINSDIR$/check_tcp -H $HOSTADDRESS$ -p 22 -t 3
+	#poller_tag	DMZ
+	#module_type	nrpe_poller
+}
+
+#Pollertag is a advanced features for mix architectures. Look at the doc for it.
+define command{
+        command_name    check_host_alive
+        command_line    $PLUGINSDIR$/check_ping -H $HOSTADDRESS$ -w 1,50% -c 2,70% -p 1
+        #poller_tag     DMZ
+	#module_type	nrpe_poller
+}
+
+
+define command{
+        command_name    check_windows_host_alive
+        command_line    $PLUGINSDIR$/check_tcp -H $HOSTADDRESS$ -p 139 -t 3
+        #poller_tag     DMZ
+	#module_type	nrpe_poller
+}
+
+
+define command{
+	command_name	check_local_disk
+	command_line	$PLUGINSDIR$/check_disk -w $ARG1$ -c $ARG2$ -p $ARG3$
+	#poller_tag	DMZ
+	#module_type	nrpe_poller
+}
+
+
+# Dummy check port command
+define command{
+       command_name	check_port
+       command_line	/bin/ping localhost -c 1
+ #$USER1$/check.sh $HOSTADDRESS$ -c $ARG1$
+       #poller_tag	DMZ
+       #module_type	nrpe_poller
+}
+
+# Dummy check for mysql, always CRITICAL
+define command{
+       command_name     check_mysql
+       command_line     $USER1$/check_dummy.sh 2
+}
+
+
+define command{
+        command_name    check_dummy
+        command_line    $USER1$/check_dummy.sh $ARG1$
+	#poller_tag	DMZ
+}
+
+
+define command{
+	command_name	super_event_kill_everyone
+	command_line	$USER1$/check.sh $HOSTADDRESS$ -c $ARG1$ SERVICE $_HOSTDELLSUCK$
+}
+
+
+# We say Http checks are always OK
+define command{
+	command_name	check_http2
+	command_line	$USER1$/check_dummy.sh 1
+	#module_type	nrpe_poller
+}
+
+define command{
+	command_name	check-host-alive
+	command_line	$USER1$/check.sh $HOSTADDRESS$ -c $ARG1$ HOST $_HOSTDELLSUCK$ $SERVICEDESC:srv-1:Service-2$ $SERVICEDESC::Service-30$ $HOSTADDRESS:$  $HOSTGROUPALIAS:linux-servers$
+	#module_type	dummy_poller
+}
+
+
+define command{
+       command_name	check_vm_cpu
+       command_line	$USER1$/check_esx3.pl -H lulu
+}
+
+
+#### Now notification commands
+define command{
+        command_name                    notify-host-by-email
+        command_line                    /usr/bin/printf "%b" "Shinken Notification\n\nType:$NOTIFICATIONTYPE$\nHost: $HOSTNAME$\nState: $HOSTSTATE$\nAddress: $HOSTADDRESS$\nInfo: $HOSTOUTPUT$\nDate/Time: $DATE$" | /bin/mail -s "Host $HOSTSTATE$ alert for $HOSTNAME$!" $CONTACTEMAIL$
+}
+
+
+define command{
+        command_name                    notify-service-by-email
+        command_line                    /usr/bin/printf "%b" "Shinken Notification\n\nNotification Type: $NOTIFICATIONTYPE$\n\nService: $SERVICEDESC$\nHost: $HOSTALIAS$\nAddress: $HOSTADDRESS$\nState: $SERVICESTATE$\n\nDate/Time: $DATE$ Additional Info : $SERVICEOUTPUT$" | /bin/mail -s "** $NOTIFICATIONTYPE$ alert - $HOSTALIAS$/$SERVICEDESC$ is $SERVICESTATE$ **" $CONTACTEMAIL$
+}
+
+
+#### And Discovery commands
+define command{
+        command_name        nmap_discovery
+        command_line        $USER1$/nmap_discovery_runner.py -t $NMAPTARGETS$
+}
+
+define command{
+        command_name        vmware_esx_discovery
+        command_line        $USER1$/vmware_discovery_runner.py -V $VCENTER$ -u $VCENTERLOGIN$ -p $VCENTERPASSWORD$ -r "lower|nofqdn"
+}
+
diff --git a/shinken-webui-menu.patch b/shinken-webui-menu.patch
new file mode 100644
index 0000000..6a8d056
--- /dev/null
+++ b/shinken-webui-menu.patch
@@ -0,0 +1,37 @@
+diff -up shinken-1.2.2/shinken/webui/views/header_element.tpl.orig shinken-1.2.2/shinken/webui/views/header_element.tpl
+--- shinken-1.2.2/shinken/webui/views/header_element.tpl.orig	2012-12-16 15:37:52.136322431 +0100
++++ shinken-1.2.2/shinken/webui/views/header_element.tpl	2012-12-16 16:11:03.107927977 +0100
+@@ -10,26 +10,6 @@
+       </a>
+ 
+       <div class="nav-collapse">
+-       <ul class="nav">
+-         <li class="dropdown">
+-           <a href="#" class="dropdown-toggle brand" data-toggle="dropdown" style="color: #FFFFFF"> Shinken <b class="caret"></b></a>
+-           <ul class="dropdown-menu span4">
+-            <li><a href=":7767">Shinken UI </a></li>
+-            <li><a href=":7766">Skonf UI</a></li>
+-            <!-- We will add also others UIs on the global menu -->
+-            %if app:
+-            %other_uis = app.get_external_ui_link()
+-            <!-- If we add others UIs, we separate them from the inner ones-->
+-            %if len(other_uis) > 0:
+-            <li class="divider"></li>
+-            %end
+-            %for c in other_uis:
+-            <li><a href="{{c['uri']}}">{{c['label']}}</a></li>
+-            %end
+-            %end
+-          </ul>
+-        </li>
+-      </ul>
+ 
+       <ul class="nav">
+         %menu = [ ('/dashboard', 'Dashboard'), ('/impacts','Impacts'), ('/problems','IT problems'), ('/all', 'All'), ('/wall', 'Wall')]
+@@ -115,4 +95,4 @@
+   </div><!--/.nav-collapse -->
+ </div>
+ </div>
+-</div>
+\ Pas de fin de ligne à la fin du fichier
++</div>
diff --git a/sources b/sources
index c655946..0dbf501 100644
--- a/sources
+++ b/sources
@@ -1 +1 @@
-591dc55ac92dd975a222eb779419724b  shinken-1.0.1.tar.gz
+1e46f5886660ff6f3a9571bee6bc53e8  shinken-1.2.2.tar.gz


More information about the scm-commits mailing list