1 |
# $Id$ |
2 |
# Authority: vip-ire |
3 |
# Name: Daniel Berteaud |
4 |
|
5 |
#%define fpbxversion 2.5.0 |
6 |
%define version 0.1 |
7 |
%define release 9 |
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 |
Patch0: smeserver-freepbx-0.1-fop_link.patch |
18 |
Patch1: smeserver-freepbx-0.1-genzaptelconf.patch |
19 |
Patch2: smeserver-freepbx-0.1-logrotate.patch |
20 |
Patch3: smeserver-freepbx-0.1-asterisk_logrotate.patch |
21 |
Patch4: smeserver-freepbx-0.1-userpanels.patch |
22 |
Patch5: smeserver-freepbx-0.1-trunk_alert_mail.patch |
23 |
Patch6: smeserver-freepbx-0.1-trunk_name_in_alert.patch |
24 |
Patch7: smeserver-freepbx-0.1-postupgrade_to_bootstrap.patch |
25 |
BuildRoot: /var/tmp/%{name}-%{version}-%{release}-buildroot |
26 |
URL: http://www.freepbx.org/ |
27 |
|
28 |
BuildRequires: e-smith-devtools |
29 |
BuildRequires: tar |
30 |
|
31 |
Requires: mysql |
32 |
Requires: httpd |
33 |
Requires: php-pear |
34 |
Requires: asterisk |
35 |
Requires: asterisk-addons |
36 |
Requires: zaptel |
37 |
Requires: speex |
38 |
Requires: sox |
39 |
Requires: mod_auth_tkt |
40 |
Requires: e-smith-base |
41 |
Requires: freepbx-src |
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 Dec 08 2008 Daniel B. <daniel@firewall-services.com> [0.1-9] |
53 |
- move expand-templates from post-upgrade event to bootstrap-console-save |
54 |
|
55 |
* Thu Nov 27 2008 Daniel B. <daniel@firewall-services.com> [0.1-8] |
56 |
- Add support for trunk name in mail alerts |
57 |
|
58 |
* Wed Nov 26 2008 Daniel B. <daniel@firewall-services.com> [0.1-7] |
59 |
- Add a simple script to alert admin by mail on trunk errors |
60 |
|
61 |
* Thu Nov 20 2008 Daniel B. <daniel@firewall-services.com> [0.1-6] |
62 |
- Use AdminPanels props so access can be configured using |
63 |
smeserver-userpanels contrib. AdminUsers and FopUsers |
64 |
props aren't used anymore |
65 |
|
66 |
* Wed Nov 19 2008 Daniel B. <daniel@firewall-services.com> [0.1-5] |
67 |
- add logrotate default config file for asterisk's logs |
68 |
- spec cleanup |
69 |
|
70 |
* Thu Nov 13 2008 Daniel B. <daniel@firewall-services.com> [0.1-4] |
71 |
- fix logrotate issue |
72 |
|
73 |
* Wed Nov 05 2008 Daniel B. <daniel@firewall-services.com> [0.1-3] |
74 |
- split freepbx sources in a separate package (freepbx-src) |
75 |
- alternative genzaptelconf |
76 |
|
77 |
* Mon Oct 13 2008 Daniel B. <daniel@firewall-services.com> [0.1-2] |
78 |
- Fix fop not being displayed in admin page |
79 |
|
80 |
* Sat Sep 20 2008 Daniel B. <daniel@firewall-services.com> [0.1-1] |
81 |
- updated to 2.5.0 final |
82 |
- spec cleaning |
83 |
- templates cleaning |
84 |
- templates to update mysql informations |
85 |
|
86 |
* Mon Aug 04 2008 daniel B. <daniel@firewall-services.com> [0.1-0] |
87 |
- initial release |
88 |
|
89 |
%prep |
90 |
|
91 |
%setup -q -n %{name}-%{version} |
92 |
%patch0 -p1 |
93 |
%patch1 -p1 |
94 |
%patch2 -p1 |
95 |
%patch3 -p1 |
96 |
%patch4 -p1 |
97 |
%patch5 -p1 |
98 |
%patch6 -p1 |
99 |
%patch7 -p1 |
100 |
|
101 |
%build |
102 |
# Build symlinks |
103 |
perl createlinks |
104 |
|
105 |
|
106 |
%install |
107 |
rm -rf $RPM_BUILD_ROOT |
108 |
(cd root ; find . -depth -print | cpio -dump $RPM_BUILD_ROOT) |
109 |
/sbin/e-smith/genfilelist $RPM_BUILD_ROOT \ |
110 |
--file /usr/share/freepbx/scripts/uninstall.sh 'attr(0750,root,root)' \ |
111 |
--file /usr/share/freepbx/scripts/restore-astdb.php 'attr(0750,root,root)' \ |
112 |
--dir /var/service/httpd-fpbx 'attr(01755,root,root)' \ |
113 |
--dir /var/service/httpd-fpbx/supervise 'attr(0700,root,root)' \ |
114 |
--dir /var/service/httpd-fpbx/log 'attr(0755,root,root)' \ |
115 |
--file /var/service/httpd-fpbx/log/run 'attr(0755,root,root)' \ |
116 |
--dir /var/service/httpd-fpbx/log/supervise 'attr(0700,root,root)' \ |
117 |
--dir /var/log/httpd-fpbx 'attr(0750,smelog,smelog)' \ |
118 |
--file /var/lib/asterisk/bin/genzaptelconf 'attr(0750,root,root)' \ |
119 |
--file /var/lib/asterisk/agi-bin/trunk_alert_mail.agi 'attr(0750,asterisk,asterisk)' \ |
120 |
--file /etc/logrotate.d/asterisk 'config(noreplace)' \ |
121 |
> %{name}-%{version}-%{release}-filelist |
122 |
|
123 |
%clean |
124 |
rm -rf $RPM_BUILD_ROOT |
125 |
|
126 |
%files -f %{name}-%{version}-%{release}-filelist |
127 |
%defattr(-,root,root) |
128 |
|
129 |
|
130 |
%post |
131 |
|
132 |
%preun |
133 |
if [ $1 = 0 ] ; then |
134 |
/etc/rc.d/init.d/freepbx stop >& /dev/null || : |
135 |
fi |
136 |
|
137 |
true |
138 |
|