3 |
# Name: Stephen Noble |
# Name: Stephen Noble |
4 |
|
|
5 |
%define name smeserver-wordpress |
%define name smeserver-wordpress |
6 |
%define version 1.0 |
%define version 1.2 |
7 |
%define release 5 |
%define release 7 |
8 |
Summary: smserver rpm to setup mysql database and web link for wordpress weblog |
Summary: smserver rpm to setup mysql database and web link for wordpress weblog |
9 |
Name: %{name} |
Name: %{name} |
10 |
Version: %{version} |
Version: %{version} |
11 |
Release: %{release}%{?dist} |
Release: %{release}%{?dist} |
12 |
License: GNU GPL version 2 |
License: GNU GPL version 2 |
13 |
URL: http://www.dungog.net/wiki |
URL: http://wiki.contribs.org/Main_Page |
14 |
Group: SMEserver/addon |
Group: SMEserver/addon |
15 |
Source: %{name}-%{version}.tar.gz |
Source: %{name}-%{version}.tar.gz |
|
Patch0: smeserver-wordpress-1.0-rm80opt.patch |
|
|
Patch1: smeserver-wordpress-1.0-tmp_folder.patch |
|
16 |
BuildArchitectures: noarch |
BuildArchitectures: noarch |
17 |
BuildRoot: /var/tmp/%{name}-%{version} |
BuildRoot: /var/tmp/%{name}-%{version} |
18 |
BuildRequires: e-smith-devtools >= 1.13.1-03 |
BuildRequires: e-smith-devtools |
19 |
Requires: e-smith-release >= 8.0 |
Requires: e-smith-release >= 8.0 |
20 |
Requires: wordpress |
Requires: wordpress |
21 |
AutoReqProv: no |
AutoReqProv: no |
24 |
smserver rpm to setup mysql database and web link for wordpress weblog |
smserver rpm to setup mysql database and web link for wordpress weblog |
25 |
|
|
26 |
%changelog |
%changelog |
27 |
|
* Fri Aug 21 2015 stephane de Labrusse <stephdl@de-labrusse.fr> 1.2-7.sme |
28 |
|
- Initial release to contribs8 |
29 |
|
|
30 |
|
* Mon Feb 09 2015 stephane de Labrusse <stephdl@de-labrusse.fr> 1.2-6.sme |
31 |
|
- Add usr/share/wordpress/wp-content in the default server backup |
32 |
|
|
33 |
|
* Thu Dec 25 2014 stephane de Labrusse <stephdl@de-labrusse.fr> 1.2-5.sme |
34 |
|
- Force the 'Salt property' to enabled |
35 |
|
|
36 |
|
* Sun Nov 9 2014 stephane de Labrusse <stephdl@de-labrusse.fr> 1.2-4.sme |
37 |
|
- Corrected a typo in the virtualhost https redirection |
38 |
|
|
39 |
|
* Wed Oct 15 2014 stephane de Labrusse <stephdl@de-labrusse.fr> 1.2-3.sme |
40 |
|
- Thanks to Remi Collet for the help to resolve the 'bug' |
41 |
|
- define('DISALLOW_FILE_MODS', false); :) |
42 |
|
- Added another default value to {wordpress}{Salt} |
43 |
|
|
44 |
|
* Tue Sep 02 2014 stephane de Labrusse <stephdl@de-labrusse.fr> 1.2-2.sme |
45 |
|
- corrected the lack of module MIME::Base64 [SME: 8548] |
46 |
|
- corrected the new ownership of www on /etc/wordpress [SME: 8546] |
47 |
|
- added templates.metadata to root,www 0640 on /etc/wordpress/wp-config.php |
48 |
|
- changed db {wordpress}{phrase} to {wordpress}{Salt} |
49 |
|
|
50 |
|
* Wed Jun 20 2014 stephane de Labrusse <stephdl@de-labrusse.fr> 1.2-1.sme |
51 |
|
- initial release to sme9 |
52 |
|
|
53 |
|
* Tue Nov 5 2013 JP Pialasse <tests@pialasse.com> 1.0-13.sme |
54 |
|
- added chown to allow plugin instalaltion and translation |
55 |
|
|
56 |
|
* Tue Nov 5 2013 JP Pialasse <tests@pialasse.com> 1.0-12.sme |
57 |
|
- error in config file [SME: 7978] |
58 |
|
- also added more configuration option |
59 |
|
- added /usr/share/php/ in phpbasedir [SME: 7977] |
60 |
|
- patch cleanup, createlinks added to spec |
61 |
|
|
62 |
|
* Sun Oct 27 2013 JP Pialasse <tests@pialasse.com> 1.0-10.sme |
63 |
|
- rewritten for epel version of wordpress |
64 |
|
- added createlinks and conf-wordpress event |
65 |
|
- start cleaning spec file |
66 |
|
- modified php base dir |
67 |
|
|
68 |
|
|
69 |
* Wed Sep 04 2013 Stephane de Labrusse <stephdl@de-labrusse.fr> 1.0.5 |
* Wed Sep 04 2013 Stephane de Labrusse <stephdl@de-labrusse.fr> 1.0.5 |
70 |
- add www:www permission on /opt/wordpress folder to allow automatic update by FTP |
- add www:www permission on /opt/wordpress folder to allow automatic update by FTP |
71 |
|
|
72 |
* Wed Jun 05 2013 Stephane de Labrusse <stephdl@de-labrusse.fr> 1.0.4 |
* Wed Jun 05 2013 Stephane de Labrusse <stephdl@de-labrusse.fr> 1.0.4 |
73 |
- add a tmp folder in httpd.conf |
- add a tmp folder in httpd.conf |
74 |
|
|
75 |
* Mon Jun 03 2013 Stephane de Labrusse <stephdl@de-labrusse.fr> 1.0-3 |
* Mon Jun 03 2013 Stephane de Labrusse <stephdl@de-labrusse.fr> 1.0-3 |
76 |
- backup html-folder, mysql-base, and config-file during erase and upgrade process |
- backup html-folder, mysql-base, and config-file during erase and upgrade process |
77 |
|
|
107 |
|
|
108 |
%prep |
%prep |
109 |
%setup |
%setup |
110 |
%patch0 -p1 |
|
|
%patch1 -p1 |
|
111 |
%build |
%build |
112 |
mkdir -p root/etc/e-smith/db/accounts/defaults/wordpress |
perl createlinks |
|
echo "reserved" > root/etc/e-smith/db/accounts/defaults/wordpress/type |
|
113 |
|
|
|
mkdir -p root/etc/e-smith/db/configuration/defaults/wordpress |
|
|
echo "Wordpress weblog" > root/etc/e-smith/db/configuration/defaults/wordpress/Name |
|
|
echo "global" > root/etc/e-smith/db/configuration/defaults/wordpress/PublicAccess |
|
|
echo "enabled" > root/etc/e-smith/db/configuration/defaults/wordpress/status |
|
|
echo "wordpress" > root/etc/e-smith/db/configuration/defaults/wordpress/DbName |
|
|
echo "wordpress" > root/etc/e-smith/db/configuration/defaults/wordpress/DbUser |
|
|
echo "en" > root/etc/e-smith/db/configuration/defaults/wordpress/WpLang |
|
|
|
|
|
mkdir -p root/etc/e-smith/templates.metadata/etc/e-smith/sql/init |
|
|
echo "PERMS=0750" > root/etc/e-smith/templates.metadata/etc/e-smith/sql/init/80wordpress |
|
|
|
|
|
#only needed so it is removed afterwards |
|
|
mkdir -p root/opt/wordpress |
|
|
touch root/opt/wordpress/wp-config.php |
|
114 |
|
|
115 |
%install |
%install |
116 |
rm -rf $RPM_BUILD_ROOT |
rm -rf $RPM_BUILD_ROOT |
121 |
echo "%doc COPYING" >> %{name}-%{version}-filelist |
echo "%doc COPYING" >> %{name}-%{version}-filelist |
122 |
|
|
123 |
%clean |
%clean |
124 |
|
|
125 |
cd .. |
cd .. |
126 |
rm -rf %{name}-%{version} |
rm -rf %{name}-%{version} |
127 |
|
|
129 |
%preun |
%preun |
130 |
|
|
131 |
%post |
%post |
|
/etc/e-smith/events/actions/initialize-default-databases |
|
|
/sbin/e-smith/expand-template /etc/e-smith/sql/init/80wordpress |
|
|
/etc/rc.d/init.d/mysql.init start |
|
|
/sbin/e-smith/expand-template /etc/httpd/conf/httpd.conf |
|
|
/sbin/e-smith/expand-template /opt/wordpress/wp-config.php |
|
|
/usr/bin/sv h /service/httpd-e-smith |
|
|
|
|
|
echo "" |
|
|
echo "see http://wiki.contribs.org/Wordpress" |
|
|
echo "see config show wordpress" |
|
|
/sbin/e-smith/config show wordpress |
|
|
echo " " |
|
|
/bin/chown -R www:www /opt/wordpress/ |
|
132 |
|
|
133 |
%postun |
%postun |
134 |
#uninstall |
|
|
if [ $1 = 0 ] ; then |
|
|
/sbin/e-smith/expand-template /etc/httpd/conf/httpd.conf |
|
|
/usr/bin/sv h /service/httpd-e-smith |
|
|
fi |
|
135 |
|
|
136 |
%files -f %{name}-%{version}-filelist |
%files -f %{name}-%{version}-filelist |
137 |
%defattr(-,root,root) |
%defattr(-,root,root) |