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

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

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


Revision 1.7 - (show annotations) (download)
Sun Dec 15 19:24:32 2013 UTC (10 years, 4 months ago) by unnilennium
Branch: MAIN
CVS Tags: smeserver-egroupware-1_8_005-5_el5_sme, HEAD
Changes since 1.6: +7 -3 lines
* Sun Dec 15 2013  JP Pialasse <tests@pialasse.com> 1.8.005-5.sme
- fix hostname [SME: 5127]

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

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