/[smecontribs]/rpms/smeserver-cacti/contribs8/smeserver-cacti.spec
ViewVC logotype

Diff of /rpms/smeserver-cacti/contribs8/smeserver-cacti.spec

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph | View Patch Patch

Revision 1.1 by unnilennium, Tue Feb 12 04:16:59 2013 UTC Revision 1.11 by unnilennium, Thu Nov 21 22:31:24 2013 UTC
# Line 1  Line 1 
1  # $Id: smeserver-cacti.spec,v 1.3 2008/11/25 16:20:19 slords Exp $  # $Id: smeserver-cacti.spec,v 1.10 2013/11/21 17:03:18 unnilennium Exp $
2  # Authority: nocvs  # Authority: nocvs
3  # Name: Michel Van hees  # Name: Michel Van hees
4    
5  Summary: Cacti for smeserver  Summary: Cacti for smeserver
6  %define name smeserver-cacti  %define name smeserver-cacti
7  Name: %{name}  Name: %{name}
8  %define version 0.8.7a  %define version 0.8.8b
9  %define release 1  %define release 12
10  Version: %{version}  Version: %{version}
11  Release: %{release}%{?dist}  Release: %{release}%{?dist}
12  License: Freely distributable  License: Freely distributable
13  Group: Apache  Group: Apache
14  Source: %{name}-%{version}.tar.gz  Source: %{name}-%{version}.tar.gz
15  #Patch0: %{name}-%{version}.patch.yyyymmddnn  Patch0: smeserver-cacti-0.8.8b-patch0.patch
16    Patch1: smeserver-cacti-0.8.8b-patch1.patch
17    Patch2: smeserver-cacti-0.8.8b-patch2.patch
18    Patch3: smeserver-cacti-0.8.8b-patch3.patch
19    Patch4: smeserver-cacti-0.8.8b-patch4.patch
20    Patch5: smeserver-cacti-0.8.8b-patch5.patch
21    Patch6: smeserver-cacti-0.8.8b-patch6.patch
22    Patch7: smeserver-cacti-0.8.8b-patch7.patch
23    Patch8: smeserver-cacti-0.8.8b-poller.patch
24    Patch9: smeserver-cacti-0.8.8b-disenabled.patch
25    #Patch:%{name}-%{version}.patch.yyyymmddnn
26  BuildRoot: /var/tmp/e-smith-buildroot  BuildRoot: /var/tmp/e-smith-buildroot
27  BuildRequires: e-smith-devtools  BuildRequires: e-smith-devtools
28  BuildArchitectures: noarch  BuildArchitectures: noarch
29  Requires: smeserver-release >= 7, rrdtool >= 1  Requires: smeserver-release >= 8 , rrdtool >= 1
30    Requires: cacti = 0.8.8b-2.el5
31  AutoReqProv: no  AutoReqProv: no
32    
33  %changelog  %changelog
34    * Thu Nov 21 2013 Jean-Philippe Pialasse <tests@pialasse.com> 0.8.8b-12.sme
35    - fixed poller not running in cron , added to crontab
36    - fixed wrong ownership for db.php, now cacti:www
37    - added status enabled by default
38    - user cacti to run in cron
39    
40    * Tue Nov 14 2013 Jean-Philippe Pialasse <tests@pialasse.com> 0.8.8b-10.sme
41    - typo fix in last patch (7)
42    
43    * Sun Nov 10 2013 Jean-Philippe Pialasse <tests@pialasse.com> 0.8.8b-9.sme
44    - fix paths in sql dump  [SME: 7419]
45    
46    * Mon Oct 21 2013 Jean-Philippe Pialasse <tests@pialasse.com> 0.8.8b-8.sme
47    - fixing last template path error in createlinks
48    
49    * Fri Oct 18 2013 Jean-Philippe Pialasse <tests@pialasse.com> 0.8.8b-7.sme
50    - fix missing type
51    - fix wrong path in Virtualhost template
52    - fix DB not creating
53    - fix extra file in template
54    - updated db mysql default
55    
56    * Tue Oct 15 2013 Jean-Philippe Pialasse <tests@pialasse.com> 0.8.8b-3.sme
57    - initial release for SME 8
58    - use el5 repo cacti
59    - fix dependencies
60    
61  * Tue Dec  4 2007 Michel Van hees <michel@vanhees.cc>  * Tue Dec  4 2007 Michel Van hees <michel@vanhees.cc>
62  - Update contrib to 0.8.7a version  - Update contrib to 0.8.7a version
63  - Adding access limitation  - Adding access limitation
# Line 35  SME server - Cacti Line 73  SME server - Cacti
73    
74  %prep  %prep
75  %setup  %setup
76  #%patch0 -p1  %patch0 -p1
77  #%patch1 -p1  %patch1 -p1
78    %patch2 -p1
79    %patch3 -p1
80    %patch4 -p1
81    %patch5 -p1
82    %patch6 -p1
83    %patch7 -p1
84    %patch8 -p1
85    %patch9 -p1
86    
87  %build  %build
88  perl createlinks  perl createlinks
# Line 52  echo "%doc COPYING"          >> %{name}- Line 98  echo "%doc COPYING"          >> %{name}-
98  rm -rf $RPM_BUILD_ROOT  rm -rf $RPM_BUILD_ROOT
99    
100  %pre  %pre
101  /sbin/e-smith/db accounts set cacti reserved  #/sbin/e-smith/db accounts set cacti reserved
102    
103  %preun  %preun
104    
105  %post  %post
106  /sbin/e-smith/db configuration set cacti service  #/sbin/e-smith/db configuration set cacti service
107  /sbin/e-smith/db configuration setprop cacti access private  #/sbin/e-smith/db configuration setprop cacti access private
108    
109  /sbin/e-smith/expand-template /etc/httpd/conf/httpd.conf  #/sbin/e-smith/expand-template /etc/httpd/conf/httpd.conf
110  /sbin/e-smith/expand-template /opt/cacti/include/config.php  #/sbin/e-smith/expand-template /opt/cacti/include/config.php
111  service httpd-e-smith sigusr1  #service httpd-e-smith sigusr1
112    
113    
114  cactiVersion=`mysql cacti_sme -N -s -e"select * from version"`  #cactiVersion=`mysql cacti_sme -N -s -e"select * from version"`
115  case "$cactiVersion" in  #case "$cactiVersion" in
116      0.8.6j)  #    0.8.6j)
117          echo ""  #       echo ""
118          echo "Upgrade process !!!!!!"      #        echo "Upgrade process !!!!!!"    
119          mysql cacti_sme < /opt/cacti/cacti_upg086j.sql  #       mysql cacti_sme < /opt/cacti/cacti_upg086j.sql
120          rm -f /opt/cacti/cacti_sme.sql  #       rm -f /opt/cacti/cacti_sme.sql
121          rm -f /opt/cacti/cacti_upg086j.sql  #       rm -f /opt/cacti/cacti_upg086j.sql
122          echo "Upgrade complete ..."  #       echo "Upgrade complete ..."
123          echo ""  #       echo ""
124      ;;  #    ;;
125      0.8.7a)  #    0.8.7a)
126          # Shoul not be here for the moment  #        # Shoul not be here for the moment
127      ;;  #    ;;
128      *)  #    *)
129          # Fresh install  #        # Fresh install
130          echo ""  #       echo ""
131          echo "fresh install..."  #       echo "fresh install..."
132          mysqladmin create cacti_sme  #       mysqladmin create cacti_sme
133          mysql cacti_sme < /opt/cacti/cacti_sme.sql  #       mysql cacti_sme < /opt/cacti/cacti_sme.sql
134          rm -Rf /opt/cacti/install  #       rm -Rf /opt/cacti/install
135          rm -f /opt/cacti/cacti_sme.sql  #       rm -f /opt/cacti/cacti_sme.sql
136          rm -f /opt/cacti/cacti_upg086j.sql  #       rm -f /opt/cacti/cacti_upg086j.sql
137          echo "Install complete ..."  #        echo "Install complete ..."
138          echo ""  #       echo ""
139  esac  #esac
   
 case "${LANG:0:2}" in  
     fr)  
         echo ""  
         echo "Vous pouvez maintenant acceder à cacti via un browser web de la maniere suivante https://nom_server/cacti"  
         echo "Vous pourrez vous loger sous admin avec comme mot de pass admin."  
         echo "Si vous mettez à jour, le mot de passe admin n'aura pas changer!"  
         echo ""  
         echo "Attention !!!!!"  
         echo "Cacti est limité en accès au réseau interne, donc pas depuis internet"  
         echo "Vous pouvez changer cette option avec les commandes :"  
         echo "db configuration setprop cacti access public"  
         echo "signal-events console-save"  
         echo ""  
     ;;  
     *)  
         echo ""  
         echo "Now you can access cacti though your browser at  https://server_name/cacti"  
         echo "You can connect using login admin and password admin."  
         echo "If you update a 2.1 version of this contribs, admin password don't change!"  
         echo ""  
         echo "BEWARE !!!"  
         echo "Cacti is now limited to internal network, so it couldn't be access from internet"  
         echo "You can change this with the following command :"  
         echo "db configuration setprop cacti access public"  
         echo "signal-events console-save"  
         echo ""  
140    
     ;;  
 esac  
141    
142  %postun  %postun
 /sbin/e-smith/db accounts delete cacti  
 /sbin/e-smith/expand-template /etc/httpd/conf/httpd.conf  
 service httpd-e-smith sigusr1  
 if [ $1 = 0 ] ; then  
 # action to been done if remove  
 case "${LANG:0:2}" in  
     fr)  
         echo ""  
         echo "La base de donnée ne sera pas effacé"  
         echo "Si vous voulez supprimer la base de donnée lancé la commande suivante :"  
         echo "mysqladmin drop cacti_sme"  
     ;;  
     *)  
         echo ""  
         echo "Database will not be removed"  
         echo "If you want to remove completly the database launch"  
         echo "mysqladmin drop cacti_sme"  
     ;;  
 esac  
   
 fi  
143    
144  %files -f %{name}-%{version}-filelist  %files -f %{name}-%{version}-filelist
145  %defattr(-,root,root)  %defattr(-,root,root)


Legend:
Removed lines/characters  
Changed lines/characters
  Added lines/characters

admin@koozali.org
ViewVC Help
Powered by ViewVC 1.2.1 RSS 2.0 feed