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

Annotation of /rpms/smeserver-egroupware/contribs8/smeserver-egroupware.spec

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


Revision 1.5 - (hide annotations) (download)
Thu Dec 12 22:38:13 2013 UTC (10 years, 5 months ago) by unnilennium
Branch: MAIN
CVS Tags: smeserver-egroupware-1_8_005-3_el5_sme
Changes since 1.4: +14 -6 lines
* Thu Dec 12 2013 JP Pialasse <tests@pialasse.com> 1.8.005-3.sme
- upgrade to eGroupware 1.8 using opensuse rpm for Centos5
- built for eGroupware-1.8.005.20131007
- see [SME: 8040]
- 2 revert back some configuration in spec
- will need to move to an event
- 3 fix tmp and sess directory
- fix default g2data path

1 unnilennium 1.5 # $Id: smeserver-egroupware.spec,v 1.4 2013/12/12 21:42:30 unnilennium Exp $
2 unnilennium 1.1 # Authority: cool34000
3     # Name: Sylvain Gomez
4    
5     %define name smeserver-egroupware
6 unnilennium 1.3 %define version 1.8.005
7 unnilennium 1.5 %define release 3
8 unnilennium 1.1 %define rpmver 4.0.4
9    
10    
11 unnilennium 1.3 Summary: eGroupware web application for SME >=8
12 unnilennium 1.1 Name: %{name}
13     Version: %{version}
14     Release: %{release}%{?dist}
15     License: GPL
16     Group: Web/Application
17 unnilennium 1.3 Source: %{name}-%{version}.tgz
18 unnilennium 1.5 Patch0: smeserver-egroupware-1.8.005-g2datapath.patch
19 unnilennium 1.1 URL: http://www.egroupware.org
20     BuildRoot: /var/tmp/%{name}-%{version}-%{release}-buildroot
21     BuildArchitectures: noarch
22     BuildRequires: e-smith-devtools
23 unnilennium 1.2 Requires: e-smith-base, e-smith-release >= 8
24 unnilennium 1.3 Requires: eGroupware >= 1.8
25     Requires: eGroupware-gallery >= 1.8
26 unnilennium 1.1
27     %description
28 unnilennium 1.3 This RPM is an unofficial addon for the SME Server 8.x and above.
29 unnilennium 1.1 eGroupWare is a free enterprise ready groupware software for your network.
30     It enables you to manage contacts, appointments, todos and many more for your whole business.
31     eGroupWare is a groupware server. It comes with a native web-interface which allowes to access
32     your data from any platform all over the planet. Moreover you also have the choice to access the
33     eGroupWare server with your favorite groupware client (Kontact, Evolution, Outlook) and also with
34     your mobile or PDA via SyncML.
35     eGroupWare is international. At the time, it supports more than 25 languages including rtl support.
36     eGroupWare is platform independent. The server runs on Linux, Mac, Windows and many more other
37     operating systems. On the client side, all you need is a internetbrowser such as Firefox,
38     Konqueror, Internet Explorer and many more.
39     https://yourdomain.com/egroupware
40    
41    
42     %changelog
43 unnilennium 1.5 * Thu Dec 12 2013 JP Pialasse <tests@pialasse.com> 1.8.005-3.sme
44 unnilennium 1.3 - upgrade to eGroupware 1.8 using opensuse rpm for Centos5
45     - built for eGroupware-1.8.005.20131007
46     - see [SME: 8040]
47 unnilennium 1.5 - 2 revert back some configuration in spec
48 unnilennium 1.4 - will need to move to an event
49 unnilennium 1.5 - 3 fix tmp and sess directory
50     - fix default g2data path
51 unnilennium 1.3
52 unnilennium 1.2 * Tue Jun 04 2013 JP Pialasse <tests@pialasse.com> 1.4.004-2.sme
53     - fix upload dir not defined [SME 7653]
54     - updated e-smith-release >8
55 unnilennium 1.1
56     * Mon May 12 2008 Sylvain Gomez <sylvaingomez@free.fr>
57     - [1.4.004-1] Update to new version 1.4.004
58     Update eGroupWare and Gallery to latest available versions
59     - Apache template modified for FCKeditor (thanks to 'atariblau')
60     - Default database updated
61    
62     * Fri Oct 26 2007 Sylvain Gomez <sylvaingomez@free.fr>
63     - [1.4.002-3] Improving SME integration
64     MySQL init templates added
65     - Events added for DomainName changes
66     - MySQL importation method changed
67     - Security is now improved on header.inc.php after an update
68     - Gallery2 added (but not installed by default)
69     - Type changed from service to url
70     - Fudforum obsolete lines commented in Apache template
71    
72     * Sun Oct 21 2007 Sylvain Gomez <sylvaingomez@free.fr>
73     - [1.4.002-2] Improving upgradability&MySQL DataBase
74     MySQL DataBase rebuilt in utf-8 (new installations only!)
75     - Fixed Spanish lang in login page (new installations only!)
76     - Fixed MySQL rights after when updating from older version
77     - Fixed files not upgrading from v1.4.001 to v1.4.002
78     - Security is now reset when updating
79     - phpSysInfo security improved in Apache template
80     - Generating shorter passwords (new installations only!)
81     - Description text updated
82     - More comments at the install stage
83    
84     * Sat Oct 20 2007 Sylvain Gomez <sylvaingomez@free.fr>
85     - [1.4.002-1] Improving upgradability&RPM structure
86     BETA VERSION
87     - RPM renamed to smeserver-egroupware-1.4.002
88     - Fixed RPM structure
89     - Fixed iCal bug installing old version 1.4.001
90     - Improved Sitemgr (create link instead of moving the folder - new installations only!)
91     - MySQL database rebuilt from scratch
92     - Updating the RPM is now possible
93     - Security improved on header.inc.php (new installations only!)
94     - Some useless items are now deleted
95     - phpSysInfo default configuration review (config.php+SME styled icon)
96    
97     * Wed Oct 17 2007 Dietmar Berteld <dietmar@berteld.com>
98     - [1.4-10] Fixing little bugs and better languages support
99     - Fixed Apache not restarting correctly when uninstalling
100     - Fixed security on Header.inc.php
101    
102     * Mon Oct 15 2007 Dietmar Berteld <dietmar@berteld.com>
103     - [1.4-9] Changing to new version 1.4.002
104     Fixed HTTPS redirection (Thanks to Sylvain Gomez)
105     - Improved Apache template for better security
106     - Improved integration in SME (https option; PublicAccess local/global - global&https is default)
107     - Cron job added
108    
109     * Tue Jul 10 2007 Dietmar Berteld <dietmar@berteld.com>
110     - [1.4-8] Preparing xmlrpc for synctools; integrate php5 as cgi-bin moduls
111    
112     * Fri Jun 29 2007 Dietmar Berteld <dietmar@berteld.com>
113     - [1.4-7] Changing to utf-8
114    
115     * Thu Jun 19 2007 Dietmar Berteld <dietmar@berteld.com>
116     - [1.4-6] Fixing MySQL errors
117    
118     * Thu Jun 17 2007 Dietmar Berteld <dietmar@berteld.com>
119     - [1.4-5] Fixing max_allowed_packet issue
120    
121     * Thu Jun 14 2007 Dietmar Berteld <dietmar@berteld.com>
122     - [1.4-4] New basis eGW 1.4, delete php5-based sync-tool
123    
124     * Wed May 30 2007 Dietmar Berteld <dietmar@berteld.com>
125     - [1.2.106-3] Automatic domain configuration and integrate php5-based sync-tool
126    
127     * Tue May 29 2007 Dietmar Berteld <dietmar@berteld.com>
128     - [1.2.106-2] Change MySQL-creating method to SME and fixing bugs
129    
130     * Thu Jan 23 2007 Dietmar Berteld <dietmar@berteld.com>
131     - [1.2.106-1] Initial version
132    
133    
134     %prep
135    
136    
137     %setup
138 unnilennium 1.5 %patch0 -p1
139 unnilennium 1.1
140     %build
141     # Creating templates2adjust
142     perl createlinks
143    
144 unnilennium 1.3
145     ### now in archive
146 unnilennium 1.1 # Default DB parameters
147 unnilennium 1.3 #DEFAULTS1=root/etc/e-smith/db/configuration/defaults/egroupware
148     #DEFAULTS2=root/etc/e-smith/db/accounts/defaults/egroupware
149     #mkdir -p $DEFAULTS1
150     #mkdir -p $DEFAULTS2
151     #echo "egroupware" > $DEFAULTS1/DbName
152     #echo "egwuser" > $DEFAULTS1/DbUser
153     #echo "on" > $DEFAULTS1/HTTPS
154     #echo "eGroupWare" > $DEFAULTS1/Name
155     #echo "global" > $DEFAULTS1/PublicAccess
156     #echo "url" > $DEFAULTS1/type
157     #echo "reserved" > $DEFAULTS2/type
158 unnilennium 1.1
159    
160     %install
161     rm -rf $RPM_BUILD_ROOT
162     (cd root ; find . -depth -print | cpio -dump $RPM_BUILD_ROOT)
163     rm -f %{name}-%{version}-filelist
164 unnilennium 1.5 /sbin/e-smith/genfilelist $RPM_BUILD_ROOT \
165     |grep -v egroupware_tmp |grep -v egroupware_sess \
166     > %{name}-%{version}-filelist
167    
168     echo "%dir %attr(0755,www,www) /usr/share/egroupware_tmp">> %{name}-%{version}-filelist
169     echo "%dir %attr(0755,www,www) /usr/share/egroupware_sess">> %{name}-%{version}-filelist
170 unnilennium 1.1
171    
172     %clean
173     rm -rf $RPM_BUILD_ROOT
174    
175    
176     %pre
177     # Checking if eGW files are present before updating
178     # If present, installation files + MySQL DB are saved
179     UPDATE=$(ls /opt | grep -c egroupware)
180     case $UPDATE in
181     0)
182     echo "Installing eGroupware... Please wait!"
183     ;;
184     *)
185     echo "Updating eGroupware... Please wait!"
186 unnilennium 1.3 # echo "Backup folder: /opt/eGW_RPM_BACKUP"
187 unnilennium 1.1 mkdir -p /opt/eGW_RPM_BACKUP
188 unnilennium 1.3 # cd /opt
189     # echo "Backing up installation files..."
190     # tar -czf /opt/eGW_RPM_BACKUP/egroupware.tar.gz egroupware
191 unnilennium 1.1 echo "Backing up MySQL database..."
192 unnilennium 1.3 mysqldump egroupware > /opt/eGW_RPM_BACKUP/egroupware$(date +%Y-%m-%d).sql
193 unnilennium 1.1 /sbin/e-smith/db configuration show egroupware > /opt/eGW_RPM_BACKUP/config.txt
194     ;;
195     esac
196    
197    
198     %post
199     # Initializing SME DB
200 unnilennium 1.4 echo "Initializing SME DB"
201     /etc/e-smith/events/actions/initialize-default-databases 2>/dev/null
202     echo " "
203 unnilennium 1.1
204     # Variables
205     DOMAIN=$(/sbin/e-smith/db configuration get DomainName)
206     EGPASS=$(/sbin/e-smith/db configuration getprop egroupware DbPassword)
207 unnilennium 1.4 UPDATE=$(ls /usr/share/ | grep -c egroupware)
208 unnilennium 1.1
209 unnilennium 1.3 #echo "Decompressing files..."
210     #mkdir -p /opt/egroupware/{files/g2data,backup,tmp}
211     #tar xzf /usr/share/doc/eGroupWare-1.4.004/Sources/eGroupWare-1.4.004.tar.gz -C /opt/egroupware
212     #tar xzf /usr/share/doc/eGroupWare-1.4.004/Sources/eGroupWare-egw-pear-1.4.004.tar.gz -C /opt/egroupware
213     #tar xzf /usr/share/doc/eGroupWare-1.4.004/Sources/eGroupWare-gallery-1.4.004.tar.gz -C /opt/egroupware
214 unnilennium 1.4 echo "Preparing phpSysInfo..."
215 unnilennium 1.3 cp -f /usr/share/doc/eGroupWare-1.8.005/Sources/phpSysInfo/config.php /usr/share/egroupware/phpsysinfo/
216     cp -f /usr/share/doc/eGroupWare-1.8.005/Sources/phpSysInfo/Redhat.png /usr/share/egroupware/phpsysinfo/images/
217    
218     #echo "Cleaning Install..."
219     #rm -rf /opt/egroupware/egroupware
220     #rm -rf /opt/egroupware/html/debian
221     #rm -f /opt/egroupware/html/.htaccess
222    
223     #echo "Setting file access rules:"
224     #cd /opt/egroupware
225     #echo " - Changing owner recursivly..."
226     #chown -R root:root /opt/egroupware/html
227     #echo " - Recursive CHMOD 755 on folders..."
228     #find html -type d -exec chmod 755 {} \;
229     #echo " - Recursive CHMOD 644 on files..."
230     #find html -type f -exec chmod 644 {} \;
231     #echo " - Customization of CHMOD for a few folders..."
232     #chmod 770 /opt/egroupware/backup
233     #chmod 770 /opt/egroupware/files
234     #chmod 770 /opt/egroupware/files/g2data
235     #chmod 770 /opt/egroupware/tmp
236     #chown www:www /opt/egroupware/backup
237     #chown www:www /opt/egroupware/files
238     #chown www:www /opt/egroupware/files/g2data
239     #chown www:www /opt/egroupware/tmp
240 unnilennium 1.1
241 unnilennium 1.3 # fixed this one adding .php, not sure if still necessary
242 unnilennium 1.4 #if [ "$UPDATE" = "0" ] ; then
243     # echo "Preparing Site-Mgr..."
244     # cd /usr/share/egroupware
245     # ln -s sitemgr/sitemgr-link.php
246     #fi
247 unnilennium 1.1
248     echo "Preparing header.inc.php..."
249 unnilennium 1.4 # if first install
250     if [ "$1" = "1" ] ; then
251     # 0)
252     sed 's.egwpass.'$EGPASS'.g' /usr/share/doc/eGroupWare-1.8.005/Sources/header.inc.php > /usr/share/egroupware/header.inc.php
253     echo " done!"
254     fi
255 unnilennium 1.3 # *) mv -f /opt/egroupware/html/header.inc.php /opt/egroupware/ 2>/dev/null ;;
256 unnilennium 1.4 #esacc
257 unnilennium 1.3 #chown www:www /opt/egroupware/header.inc.php
258     #chmod 640 /opt/egroupware/header.inc.php
259     #cd /opt/egroupware/html
260     #ln -s ../header.inc.php 2>/dev/null
261 unnilennium 1.4 echo " "
262 unnilennium 1.3
263     # the integration is complete Ithink now.....
264 unnilennium 1.4 echo "Preparing Gallery2..."
265     if [ -f /usr/share/egroupware/gallery/gallery2/config.php ] ; then
266     touch /usr/share/egroupware/gallery/gallery2/config.php
267     else
268     sed 's.egwpass.'$EGPASS'.g' /usr/share/doc/eGroupWare-1.8.005/Sources/Gallery2/config.php > /usr/share/egroupware/gallery/gallery2/config.php
269     fi
270 unnilennium 1.3
271 unnilennium 1.4 chmod 640 /usr/share/egroupware/gallery/gallery2/config.php
272     chown www:www /usr/share/egroupware/gallery/gallery2/config.php
273     echo " "
274 unnilennium 1.3
275     ### this one will be done by event
276 unnilennium 1.4 echo "MySQL installation:"
277 unnilennium 1.3 #if [ "$UPDATE" = "0" ] ; then
278     # cp /usr/share/doc/eGroupWare-1.4.004/Sources/81egw_database.sql /etc/e-smith/sql/init/
279     #fi
280 unnilennium 1.4 /sbin/e-smith/expand-template /etc/e-smith/sql/init/80egw_mysql.sql
281     /sbin/e-smith/expand-template /etc/e-smith/sql/init/81egw_default
282     /sbin/e-smith/expand-template /etc/e-smith/sql/init/81egw_domain.sql
283     /etc/rc.d/init.d/mysql.init start
284     echo " "
285    
286     echo "Applying modifications to services..."
287     /sbin/e-smith/expand-template /etc/httpd/conf/httpd.conf
288     /etc/rc7.d/S86httpd-e-smith sigusr1
289     /etc/rc.d/init.d/crond restart
290     echo " "
291 unnilennium 1.1
292     echo "-------------------------------------------------------------------------------"
293     case $UPDATE in
294     0) echo "eGroupWare Installation completed, you must finish the installation!" ;;
295     *) echo "eGroupWare update completed, you must finish the update!" ;;
296     esac
297     echo "Please go to https://$DOMAIN/egroupware/setup"
298     echo "-------------------------------------------------------------------------------"
299     echo "For more details, see http://wiki.contribs.org/Egroupware"
300     echo " "
301     case $UPDATE in
302     0)
303     echo "Reminder:"
304     echo " - Website open globally"
305     echo " - https mode enabled with automatic redirection"
306     echo " - Header-Admin-Login = header-admin, pw = 'admin'"
307     echo " - Config-Admin-Login = config-admin, pw = 'admin'"
308     echo " - SME users can login with their user and password (mail auth. method)"
309     echo " "
310     echo "Start https://$DOMAIN/egroupware/setup"
311     echo "Login with the Config-Admin (user=config-admin, pw=admin)"
312     echo "ToDo's:"
313     echo " - Create eGroupWare's admin account with an existing SME account/password"
314     echo " - Configure Gallery2 if needed"
315     ;;
316     *)
317     echo "Reminder:"
318     echo " - The old install was backed up and can be found in /opt/eGW_RPM_BACKUP"
319     echo " PLEASE MOVE THIS DIRECTORY TO A SAFE PLACE!!!"
320     echo " - Start https://$DOMAIN/egroupware/setup"
321     echo " - Login with your existing 'Config-Admin' creditentials"
322     echo " - Finish the upgrade if needed"
323     echo " - Configure Gallery2 if needed"
324     ;;
325     esac
326    
327     echo " "
328     echo " "
329     echo "Current configuration:"
330     /sbin/e-smith/config show egroupware
331     echo " "
332     echo "Following DB parameters are allowed:"
333     echo " # config setprop egroupware HTTPS on/off"
334     echo " # config setprop egroupware PublicAccess local/global"
335     echo " "
336     echo "Don't forget to apply modifications with following commands:"
337     echo " # expand-template /etc/httpd/conf/httpd.conf"
338     echo " # service httpd-e-smith restart"
339     echo " "
340     echo "For more details, see http://wiki.contribs.org/Egroupware"
341     echo "-------------------------------------------------------------------------------"
342    
343    
344     %preun
345     if [ $1 = 0 ] ; then
346 unnilennium 1.3 mv /usr/share/doc/eGroupWare-1.8.005/Sources/DO_NOT_USE_OR_DELETE/eGW-Full-Uninstall.sh /root/
347 unnilennium 1.1 fi
348    
349    
350     %postun
351     if [ $1 = 0 ] ; then
352     echo "Restarting services..."
353     /sbin/e-smith/expand-template /etc/httpd/conf/httpd.conf
354     /etc/rc7.d/S86httpd-e-smith sigusr1
355     /etc/rc.d/init.d/crond restart
356     echo " "
357     echo " "
358     echo "Uninstallation finished!"
359     echo " "
360     echo "If you want to completly remove eGroupWare"
361     echo "(installation files and MySQL user+database)"
362     echo "please issue the following command at the prompt:"
363     echo "# sh /root/eGW-Full-Uninstall.sh"
364     fi
365    
366    
367     %files -f %{name}-%{version}-filelist
368    
369    
370     %defattr(-,root,root)

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