[Pkg-nagios-changes] [SCM] UNNAMED PROJECT branch, debian/master, updated. 810edbdd3feedbfe37f4a65bee50b57b2f60fa2a

David GUENAULT dguenault at monitoring-fr.org
Tue Feb 28 22:22:37 UTC 2012


The following commit has been merged in the debian/master branch:
commit 33c40d68c251b46c06af8ca17bae2cb44151e084
Author: David GUENAULT <dguenault at monitoring-fr.org>
Date:   Sat Feb 25 12:03:09 2012 +0100

    Added support for mongodb from 10gen

diff --git a/install b/install
index 042be32..8ca3872 100755
--- a/install
+++ b/install
@@ -922,6 +922,41 @@ function fixHtpasswdPath(){
 
 # addons installation
 
+# mongodb
+function install_mongodb(){
+    cadre "Install mongodb server" green
+    case $CODE in
+        REDHAT)
+            if [ ! -f "/etc/yum.repos.d/10gen.repo" ]
+            then
+                cp install.d/10gen.repo.in /etc/yum.repos.d/10gen.repo
+                sed -i "s/__ARCH__/"$ARCH"/g" /etc/yum.repos.d/10gen.repo
+                yum clean all >> $TMP/shinken.install.log 2>&1
+                yum -y install mongo-10gen mongo-10gen-server >> $TMP/shinken.install.log 2>&1
+                chkconfig --add mongod >> $TMP/shinken.install.log 2>&1
+                chkconfig mongod on >> $TMP/shinken.install.log 2>&1
+                cecho " > Start mongodb server"
+                /etc/init.d/mongod start >> $TMP/shinken.install.log 2>&1
+            else
+                cecho "Allready installed" red
+                exit 2
+            fi
+            ;;
+        DEBIAN)
+#            apt-key adv --keyserver keyserver.ubuntu.com --recv 7F0CEB10
+#            echo "deb http://downloads-distro.mongodb.org/repo/ubuntu-upstart dist 10gen" > /etc/apt/sources.list.d/10gen.repo
+#            apt-get update
+#            apt-get -y install 
+            cecho " > Unsuported" red
+            exit 2
+            ;;
+        *)
+            cecho " > Unknown distribution : $DIST" red
+            exit 2
+            ;;
+    esac
+}
+
 # nagvis
 
 function install_nagvis(){
@@ -1810,6 +1845,7 @@ echo "Usage : install -k | -i | -w | -d | -u | -b | -r | -l | -c | -h | -a | -z
         pnp4nagios
         multisite
         nagvis
+        mongodb
     -h  Show help"
 }
 
@@ -1895,10 +1931,15 @@ while getopts "kidubcr:lz:hsvp:we:" opt; do
             then
                 install_nagvis
                 exit 0
+            elif [ "$OPTARG" == "mongodb" ]
+            then
+                install_mongodb
+                exit 0
             else
                 cecho " > Unknown plugin $OPTARG" red
             fi
             ;;
+        
         j)
             addpoller "$OPTARG"
             exit 0

-- 
UNNAMED PROJECT



More information about the Pkg-nagios-changes mailing list