1 |
# $Id: smeserver-freepbx.spec,v 1.21 2016/10/24 03:31:36 unnilennium Exp $ |
2 |
# Authority: vip-ire |
3 |
# Name: Daniel Berteaud |
4 |
|
5 |
#%define fpbxversion 2.5.0 |
6 |
%define version 13 |
7 |
%define release 5 |
8 |
%define name smeserver-freepbx |
9 |
|
10 |
Summary: Asterisk web GUI |
11 |
Name: %{name} |
12 |
Version: %{version} |
13 |
Release: %{release}%{?dist} |
14 |
License: GPL |
15 |
Group: System/Servers |
16 |
Source: %{name}-%{version}.tar.gz |
17 |
|
18 |
Patch0: smeserver-freepbx-13.bz9702.udpports.patch |
19 |
Patch1: smeserver-freepbx-13.bz9744.patch |
20 |
Patch2: smeserver-freepbx-13.bz9702-2.patch |
21 |
BuildRoot: /var/tmp/%{name}-%{version}-%{release}-buildroot |
22 |
URL: http://www.freepbx.org/ |
23 |
|
24 |
BuildRequires: e-smith-devtools |
25 |
BuildRequires: tar |
26 |
|
27 |
Requires: mysql |
28 |
Requires: httpd |
29 |
Requires: php-pear |
30 |
Requires: /usr/sbin/asterisk |
31 |
Requires: asterisk-addons |
32 |
Requires: dahdi-tools |
33 |
Requires: dahdi-linux |
34 |
Requires: sox |
35 |
Requires: mod_auth_tkt |
36 |
Requires: e-smith-base |
37 |
Requires: freepbx-src |
38 |
Requires: asterisk-sounds-core-en-ulaw |
39 |
Requires: asterisk-sounds-extra-en-ulaw |
40 |
Requires: asterisk-voicemail |
41 |
Requires: asterisk-configs |
42 |
#Buildarch: noarch |
43 |
AutoReqProv: no |
44 |
|
45 |
|
46 |
%description |
47 |
FreePBX is a Standardised Implementation of Asterisk that gives you a GUI to manage your system. If you have looked into Asterisk, you would know that it does not come with any built in programming. You cannot plug a phone into it and make it work without editing configuration files, writing dialplans, and various messing about. FreePBX simplifies this by giving you a pre-written set of dialplans that allow you to have a fully functional PBX pretty much straight away. |
48 |
This package provide the integration of FreePBX on SME Server. |
49 |
|
50 |
|
51 |
%changelog |
52 |
* Mon Oct 24 2016 Jean-Philipe Pialasse <tests@pialasse.com> -5.sme |
53 |
-fix typo in smeserver-freepbx-13.bz9744.patch |
54 |
|
55 |
* Sun Oct 23 2016 Jean-Philipe Pialasse <tests@pialasse.com> 13-4.sme |
56 |
- fix [SME: 9702] |
57 |
- corrected syntax for port range |
58 |
|
59 |
* Sun Oct 23 2016 Jean-Philipe Pialasse <tests@pialasse.com> 13-3.sme |
60 |
- fix [SME: 9744] |
61 |
- fix wrong /tmp folder permission after update |
62 |
- Thank you Hsing-Foo Wang. |
63 |
|
64 |
* Tue Jul 26 2016 Jean-Philipe Pialasse <tests@pialasse.com> 13-2.sme |
65 |
- fix wrong UDP ports change 1000:2000 to 10000:20000 [SME: 9702] |
66 |
|
67 |
* Mon Jun 13 2016 Jean-Philipe Pialasse <tests@pialasse.com> 13-1.sme |
68 |
- bump version to current Freepbx version 13 |
69 |
|
70 |
* Mon Jun 13 2016 Jean-Philipe Pialasse <tests@pialasse.com> -47.sme |
71 |
- add all needed port for Freepbx sip pjsip and RTP [SME: 9495] |
72 |
|
73 |
* Sat Jun 11 2016 Jean-Philipe Pialasse <tests@pialasse.com> -46.sme |
74 |
- fix missing config files (requires asterisk-configs) [SME: 9577] |
75 |
- fix recuring reconfiguration error while installing digium phone module [SME: 9575] |
76 |
- added port 5061 for tls to TCP ports [SME: 9576] |
77 |
|
78 |
* Thu Jun 09 2016 Jean-Philipe Pialasse <tests@pialasse.com> -45.sme |
79 |
- fix wrong logrotate pattern [SME: 9516] |
80 |
- as the contrib is only in smedev, i do not fix existing log files badly rotated |
81 |
|
82 |
* Mon May 16 2016 Jean-Philipe Pialasse <tests@pialasse.com> 0.1-44.sme |
83 |
- remove fop db [SME: 9495] |
84 |
- add some mysql setting for freepbxdb (user, email) |
85 |
- smeserver-freepbx-0.1-Sme9Ast13Fpbx13-7.patch |
86 |
|
87 |
* Sun May 15 2016 Jean-Philipe Pialasse <tests@pialasse.com> 0.1-43.sme |
88 |
- add path to ucp module [SME: 9495] |
89 |
- add 256Mo as default for freepbx php Memory |
90 |
- add AllowOveride All for .htaccess |
91 |
- remove httpd config to old FOP panel |
92 |
- add port 5061 for freepbx |
93 |
- smeserver-freepbx-0.1-Sme9Ast13Fpbx13-5.patch |
94 |
- configuration of amportal.conf and its mysql equivalent |
95 |
- smeserver-freepbx-0.1-Sme9Ast13Fpbx13-6.patch |
96 |
|
97 |
* Sun May 15 2016 Jean-Philipe Pialasse <tests@pialasse.com> 0.1-42.sme |
98 |
- remove FOP patches [SME: 9495] |
99 |
- deleted link to expand amportal.conf |
100 |
- smeserver-freepbx-0.1-Sme9Ast13Fpbx13-4.patch |
101 |
|
102 |
* Sun May 15 2016 Jean-Philipe Pialasse <tests@pialasse.com> 0.1-41.sme |
103 |
- remove heading of /etc/asterisk/asterisk.conf [SME: 9495] |
104 |
- smeserver-freepbx-0.1-Sme9Ast13Fpbx13-3.patch |
105 |
- bump |
106 |
|
107 |
* Sun May 15 2016 Jean-Philipe Pialasse <tests@pialasse.com> 0.1-38.sme |
108 |
- remove expand template amportal.conf [SME: 9495] |
109 |
- chown /var/lib/asterisk |
110 |
- installation configuration options |
111 |
- smeserver-freepbx-0.1-Sme9Ast13Fpbx13-2.patch |
112 |
- Requires: asterisk-sounds-core-en-ulaw asterisk-sounds-extra-en-ulaw asterisk-voicemail |
113 |
|
114 |
* Sun May 15 2016 Jean-Philipe Pialasse <tests@pialasse.com> 0.1-37.sme |
115 |
- new path to sql files [SME: 9495] |
116 |
- smeserver-freepbx-0.1-Sme9Ast13Fpbx13-1.patch |
117 |
|
118 |
* Fri May 06 2016 Jean-Philipe Pialasse <tests@pialasse.com> 0.1-36.sme |
119 |
- adapt script to fpbx13 and asterisk 13 [SME: 9495] |
120 |
- change Requires Requires: %{_libdir}/asterisk/modules/app_addon_sql_mysql.so to |
121 |
- Requires: asterisk-addons as this is the paquet providing it, and it changed name to app_mysql.so |
122 |
|
123 |
* Fri May 06 2016 Jean-Philipe Pialasse <tests@pialasse.com> 0.1-35.sme |
124 |
- adapt script to fpbx13 and asterisk 13 [SME: 9495] |
125 |
- smeserver-freepbx-0.1-Sme9Ast13Fpbx13-0.patch |
126 |
|
127 |
* Fri May 06 2016 Jean-Philipe Pialasse <tests@pialasse.com> 0.1-34.sme |
128 |
- first import to SME9 [SME: 9495] |
129 |
|
130 |
* Sun May 12 2013 JP Pialasse <tests@pialasse.com> 0.1-33.sme |
131 |
- buildarch removed in order to find the correct %{_libdir}/asterisk/modules/app_addon_sql_mysql.so |
132 |
|
133 |
* Thu Oct 20 2011 Daniel B. <daniel@firewall-services.com> 0.1-32.sme |
134 |
- Protect by locations (so other alias can be defined to protect with LL::NG for example) |
135 |
|
136 |
* Mon Oct 17 2011 Daniel B. <daniel@firewall-services.com> 0.1-31.sme |
137 |
- Add misdn.log to logrotate |
138 |
|
139 |
* Thu Oct 13 2011 Daniel B. <daniel@firewall-services.com> 0.1-30.sme |
140 |
- Change session path [SME: 6661] |
141 |
|
142 |
* Wed Jan 05 2011 Daniel B. <daniel@firewall-services.com> 0.1-29.sme |
143 |
- astdatadir is /var/lib/asterisk |
144 |
- templates for /etc/logrotate.d/asterisk |
145 |
|
146 |
* Mon Sep 20 2010 Daniel B. <daniel@firewall-services.com> 0.1-28.sme |
147 |
- Create and populate the mysql databases in mysql.init |
148 |
- Templates for /etc/asterisk/asterisk.conf |
149 |
|
150 |
* Thu Jul 15 2010 Daniel B. <daniel@firewall-services.com> [0.1-27] |
151 |
- Read ARI password from the DB (and initialize a random one) |
152 |
|
153 |
* Mon Feb 22 2010 Daniel B. <daniel@firewall-services.com> [0.1-26] |
154 |
- Remove hard-coded dependencies on asterisk and asterisk-addons14 |
155 |
Depends now on asterisk binary and app_addon_sql_mysql.so files |
156 |
(so it can work with asterisk or asterisk14) |
157 |
|
158 |
* Mon Feb 15 2010 Daniel B. <daniel@firewall-services.com> [0.1-25] |
159 |
- Remove /etc/logrotate.d/asterisk which is now included in asterisk14 |
160 |
|
161 |
* Tue Feb 09 2010 Daniel B. <daniel@firewall-services.com> [0.1-24] |
162 |
- Depends now on asterisk14 and asterisk-addons14 |
163 |
|
164 |
* Wed Jan 06 2010 Daniel B. <daniel@firewall-services.com> [0.1-23] |
165 |
- disable dynamic hints |
166 |
|
167 |
* Tue Oct 06 2009 Daniel B. <daniel@firewall-services.com> [0.1-22] |
168 |
- include /opt/freepbx/admin/functions.inc.php in freepbx-dump-astdb |
169 |
action script for FreePBX 2.6 compatibility |
170 |
|
171 |
* Tue May 19 2009 Daniel B. <daniel@firewall-services.com> [0.1-21] |
172 |
- Add CHECKREFERER=FALSE in amportal.conf to repvent error message in some |
173 |
modules (due to the ProxyPass configuration) |
174 |
|
175 |
* Tue Apr 28 2009 Daniel B. <daniel@firewall-services.com> [0.1-20] |
176 |
- Fix CDR db password in cdr_mysql.conf template |
177 |
- Use a separate service in SME db for FOP |
178 |
|
179 |
* Thu Apr 16 2009 Daniel B. <daniel@firewall-services.com> [0.1-19] |
180 |
- remove scoreboard directive from httpd-fpbx config |
181 |
- remove some modules (mod_ssl, mod_proxy) |
182 |
|
183 |
* Sat Apr 11 2009 Daniel B. <daniel@firewall-services.com> [0.1-18] |
184 |
- templatize cdr_mysql.conf [SME: 5153] |
185 |
- templatize manager.conf |
186 |
- remove freepbx-cron-scheduler.php from root crontab so only |
187 |
asterisk user runs it (prevent email error sent from cron) |
188 |
|
189 |
* Fri Mar 27 2009 Daniel B. <daniel@firewall-services.com> [0.1-17] |
190 |
- Remove obsolete /admin Alias from apache |
191 |
- Run the security script on bootsrape-console-save event |
192 |
|
193 |
* Mon Mar 23 2009 Daniel B. <daniel@firewall-services.com> [0.1-16] |
194 |
- Security Fixe: put a random password for ARI admin (this should be documented) |
195 |
|
196 |
* Thu Mar 19 2009 Daniel B. <daniel@firewall-services.com> [0.1-15] |
197 |
- Check if /opt/freepbx/admin exists (retry the install if a first one failed) |
198 |
- Remove tabs from spec |
199 |
|
200 |
* Wed Mar 18 2009 Daniel B. <daniel@firewall-services.com> [0.1-14] |
201 |
- Remove speex from dependencies |
202 |
|
203 |
* Thu Mar 12 2009 Daniel B. <daniel@firewall-services.com> [0.1-13] |
204 |
- Remove zaptel dependency, replaced with dahdi-tools and dahdi-linux |
205 |
|
206 |
* Mon Feb 23 2009 Daniel B. <daniel@firewall-services.com> [0.1-12] |
207 |
- Fix logrotate issue (send a sigusr1 signal to httpd-fpbx) |
208 |
|
209 |
* Thu Feb 12 2009 Daniel B. <daniel@firewall-services.com> [0.1-11] |
210 |
- Full support for the new DAHDI driver, droping zaptel |
211 |
|
212 |
* Mon Feb 09 2009 Daniel B. <daniel@firewall-services.com> [0.1-10] |
213 |
- add support for DAHDI channel |
214 |
|
215 |
* Mon Dec 08 2008 Daniel B. <daniel@firewall-services.com> [0.1-9] |
216 |
- move expand-templates from post-upgrade event to bootstrap-console-save |
217 |
|
218 |
* Thu Nov 27 2008 Daniel B. <daniel@firewall-services.com> [0.1-8] |
219 |
- Add support for trunk name in mail alerts |
220 |
|
221 |
* Wed Nov 26 2008 Daniel B. <daniel@firewall-services.com> [0.1-7] |
222 |
- Add a simple script to alert admin by mail on trunk errors |
223 |
|
224 |
* Thu Nov 20 2008 Daniel B. <daniel@firewall-services.com> [0.1-6] |
225 |
- Use AdminPanels props so access can be configured using |
226 |
smeserver-userpanels contrib. AdminUsers and FopUsers |
227 |
props aren't used anymore |
228 |
|
229 |
* Wed Nov 19 2008 Daniel B. <daniel@firewall-services.com> [0.1-5] |
230 |
- add logrotate default config file for asterisk's logs |
231 |
- spec cleanup |
232 |
|
233 |
* Thu Nov 13 2008 Daniel B. <daniel@firewall-services.com> [0.1-4] |
234 |
- fix logrotate issue |
235 |
|
236 |
* Wed Nov 05 2008 Daniel B. <daniel@firewall-services.com> [0.1-3] |
237 |
- split freepbx sources in a separate package (freepbx-src) |
238 |
- alternative genzaptelconf |
239 |
|
240 |
* Mon Oct 13 2008 Daniel B. <daniel@firewall-services.com> [0.1-2] |
241 |
- Fix fop not being displayed in admin page |
242 |
|
243 |
* Sat Sep 20 2008 Daniel B. <daniel@firewall-services.com> [0.1-1] |
244 |
- updated to 2.5.0 final |
245 |
- spec cleaning |
246 |
- templates cleaning |
247 |
- templates to update mysql informations |
248 |
|
249 |
* Mon Aug 04 2008 daniel B. <daniel@firewall-services.com> [0.1-0] |
250 |
- initial release |
251 |
|
252 |
%prep |
253 |
|
254 |
%setup -q -n %{name}-%{version} |
255 |
%patch0 -p1 |
256 |
%patch1 -p1 |
257 |
%patch2 -p1 |
258 |
|
259 |
%build |
260 |
# Build symlinks |
261 |
perl createlinks |
262 |
|
263 |
|
264 |
%install |
265 |
rm -rf $RPM_BUILD_ROOT |
266 |
|
267 |
%{__mkdir_p} $RPM_BUILD_ROOT/var/lib/php/fpbx-session |
268 |
|
269 |
(cd root ; find . -depth -print | cpio -dump $RPM_BUILD_ROOT) |
270 |
/sbin/e-smith/genfilelist $RPM_BUILD_ROOT \ |
271 |
--file /usr/share/freepbx/scripts/uninstall.sh 'attr(0750,root,root)' \ |
272 |
--file /usr/share/freepbx/scripts/restore-astdb.php 'attr(0750,root,root)' \ |
273 |
--dir /var/service/httpd-fpbx 'attr(01755,root,root)' \ |
274 |
--dir /var/service/httpd-fpbx/supervise 'attr(0700,root,root)' \ |
275 |
--dir /var/service/httpd-fpbx/log 'attr(0755,root,root)' \ |
276 |
--file /var/service/httpd-fpbx/log/run 'attr(0755,root,root)' \ |
277 |
--dir /var/service/httpd-fpbx/log/supervise 'attr(0700,root,root)' \ |
278 |
--dir /var/log/httpd-fpbx 'attr(0750,smelog,smelog)' \ |
279 |
--file /var/lib/asterisk/bin/genzaptelconf 'attr(0750,root,root)' \ |
280 |
--file /var/lib/asterisk/agi-bin/trunk_alert_mail.agi 'attr(0750,asterisk,asterisk)' \ |
281 |
--file /etc/logrotate.d/asterisk 'config(noreplace)' \ |
282 |
--dir /var/lib/php/fpbx-session 'attr(0770,root,asterisk)' \ |
283 |
> %{name}-%{version}-%{release}-filelist |
284 |
|
285 |
%clean |
286 |
rm -rf $RPM_BUILD_ROOT |
287 |
|
288 |
%files -f %{name}-%{version}-%{release}-filelist |
289 |
%defattr(-,root,root) |
290 |
|
291 |
|
292 |
%post |
293 |
|
294 |
#bug 9744, restore tmp permissions |
295 |
if [ `stat -c %U /tmp` == "asterisk" ]; then |
296 |
chmod o+rwxt /tmp/ |
297 |
chown root:root /tmp/ |
298 |
fi |
299 |
|
300 |
%preun |
301 |
if [ $1 = 0 ] ; then |
302 |
/etc/rc.d/init.d/freepbx stop >& /dev/null || : |
303 |
fi |
304 |
|
305 |
true |
306 |
|