1 |
# $Id: smeserver-mediawiki.spec,v 1.12 2022/07/12 11:29:51 brianr Exp $ |
# $Id: smeserver-mediawiki.spec,v 1.15 2022/07/12 15:37:07 brianr Exp $ |
2 |
# Authority: ber_die |
# Authority: ber_die |
3 |
# Name: Dietmar Berteld |
# Name: Dietmar Berteld |
4 |
|
|
5 |
%define name smeserver-mediawiki |
%define name smeserver-mediawiki |
6 |
%define version 1.38.2 |
%define version 1.38.2 |
7 |
%define release 1 |
%define release 2 |
8 |
|
|
9 |
Summary: Mediawiki Web Application for SME Server 7.x based on Mediawiki 1.38.0 |
Summary: Mediawiki Web Application for SME Server 7.x based on Mediawiki 1.38.0 |
10 |
Name: %{name} |
Name: %{name} |
14 |
Group: /Web/Applications |
Group: /Web/Applications |
15 |
Source: %{name}-%{version}.tar.gz |
Source: %{name}-%{version}.tar.gz |
16 |
|
|
17 |
#Patch0: smeserver-mediawiki-1.38.1-Fix-sql-create.patch |
Patch0: smeserver-mediawiki-1.38.2-bz12133-httpd24.patch |
|
#Patch0: smeserver-mediawiki-1.37.2-Fix-up-password-generation-and-localsettings.patch |
|
|
#Patch1: smeserver-mediawiki-1.6.10-Update-to-SME10.patch |
|
18 |
|
|
19 |
URL: http://mediawiki.org/ |
URL: http://mediawiki.org/ |
20 |
BuildRoot: /var/tmp/%{name}-%{version}-%{release}-buildroot |
BuildRoot: /var/tmp/%{name}-%{version}-%{release}-buildroot |
31 |
http://your_e-smith-server_adress/wiki |
http://your_e-smith-server_adress/wiki |
32 |
|
|
33 |
%changelog |
%changelog |
34 |
|
* Tue Aug 02 2022 Jean-Philippe Pialasse <tests@pialasse.com> 1.38.2-2.sme |
35 |
|
- update to httpd 2.4 access syntax [SME: 12133] |
36 |
|
|
37 |
* Tue Jul 12 2022 Brian Read <brianr@bjsystems.co.uk> 1.38.2-1.sme |
* Tue Jul 12 2022 Brian Read <brianr@bjsystems.co.uk> 1.38.2-1.sme |
38 |
- Update version to Mediawiki-1.38.2 [sme: 11987] |
- Update version to Mediawiki-1.38.2 [sme: 11987] |
39 |
- Fix initial admin user |
- Fix initial admin user password |
40 |
|
|
41 |
* Thu Jun 09 2022 Brian Read <brianr@bjsystems.co.uk> 1.38.1-2.sme |
* Thu Jun 09 2022 Brian Read <brianr@bjsystems.co.uk> 1.38.1-2.sme |
42 |
- fix sql user create [SME: 11987] |
- fix sql user create [SME: 11987] |
109 |
|
|
110 |
%setup |
%setup |
111 |
|
|
112 |
#%patch0 -p1 |
%patch0 -p1 |
113 |
#%patch1 -p1 |
#%patch1 -p1 |
114 |
|
|
115 |
%build |
%build |
151 |
APP=MediaWiki |
APP=MediaWiki |
152 |
URL=wiki |
URL=wiki |
153 |
WORKDIR=/root |
WORKDIR=/root |
154 |
MEDIAWIKIVERSION='1.38.1' |
MEDIAWIKIVERSION='1.38.2' |
155 |
INSTALLDIR=/usr/share/doc/mediawiki-$MEDIAWIKIVERSION/Sources |
INSTALLDIR=/usr/share/doc/mediawiki-$MEDIAWIKIVERSION/Sources |
156 |
HTMLDIR=/opt/mediawiki |
HTMLDIR=/opt/mediawiki |
157 |
MYSQLDB=mediawiki |
MYSQLDB=mediawiki |
213 |
echo "Creating MySQL User and DataBase..." |
echo "Creating MySQL User and DataBase..." |
214 |
mysqladmin -u root create $MYSQLDB |
mysqladmin -u root create $MYSQLDB |
215 |
mysql $MYSQLDB < $INSTALLDIR/$MYSQLDB.sql |
mysql $MYSQLDB < $INSTALLDIR/$MYSQLDB.sql |
216 |
|
mysql $MYSQLDB -e "UPDATE user SET user_password = MD5( CONCAT( user_id, '-', MD5( 'mediawikiadmin' ) ) ) WHERE user_id =1 " |
217 |
mysql -u root -e "SET PASSWORD FOR $MYSQLUSER@localhost = PASSWORD( '$MYSQLPASS' ) " |
mysql -u root -e "SET PASSWORD FOR $MYSQLUSER@localhost = PASSWORD( '$MYSQLPASS' ) " |
218 |
mysqladmin flush-privileges |
mysqladmin flush-privileges |
219 |
;; |
;; |
268 |
echo "-------------------------------------------------------------------------------" |
echo "-------------------------------------------------------------------------------" |
269 |
|
|
270 |
%preun |
%preun |
271 |
MEDIAWIKIVERSION='1.38.1' |
MEDIAWIKIVERSION='1.38.2' |
272 |
INSTALLDIR=/usr/share/doc/mediawiki-$MEDIAWIKIVERSION/Sources |
INSTALLDIR=/usr/share/doc/mediawiki-$MEDIAWIKIVERSION/Sources |
273 |
if [ $1 = 0 ] ; then |
if [ $1 = 0 ] ; then |
274 |
mv $INSTALLDIR/DO_NOT_USE_OR_DELETE/MW-Full-Uninstall.sh /root/ |
mv $INSTALLDIR/DO_NOT_USE_OR_DELETE/MW-Full-Uninstall.sh /root/ |