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

Contents of /rpms/smeserver-egroupware/contribs9/smeserver-egroupware.spec

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


Revision 1.2 - (show annotations) (download)
Mon Sep 1 19:56:15 2014 UTC (10 years, 2 months ago) by stephdl
Branch: MAIN
CVS Tags: HEAD
Changes since 1.1: +7 -2 lines
* Mon Sep 01 2014 stephane de Labrusse <stephdl@de-laabrusse.fr> -Added patch PAtch2 forgotten by the script of JP Pialasse

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

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