1 |
slords |
1.1 |
Summary: PhpMyAdmin for SME server |
2 |
|
|
%define name smeserver-phpmyadmin-multiuser |
3 |
|
|
Name: %{name} |
4 |
|
|
%define version 2.11.3 |
5 |
|
|
%define release 1 |
6 |
|
|
Version: %{version} |
7 |
|
|
Release: %{release}%{?dist} |
8 |
|
|
License: Freely distributable |
9 |
|
|
Group: Apache |
10 |
|
|
Source: %{name}-%{version}.tar.gz |
11 |
|
|
#Patch0: %{name}-%{version}.patch.yyyymmddnn |
12 |
|
|
BuildRoot: /var/tmp/e-smith-buildroot |
13 |
|
|
BuildRequires: e-smith-devtools |
14 |
|
|
BuildArchitectures: noarch |
15 |
|
|
Requires: smeserver-release >= 7 |
16 |
|
|
AutoReqProv: no |
17 |
|
|
|
18 |
|
|
%changelog |
19 |
|
|
* Wed Dec 13 2007 Michel Van hees <michel@vanhees.cc> |
20 |
|
|
- update contrib to phpmyadmin 2.11.3 |
21 |
|
|
|
22 |
|
|
* Fri Nov 23 2007 Michel Van hees <michel@vanhees.cc> |
23 |
|
|
- update contrib to phpmyadmin 2.11.2.2 |
24 |
|
|
|
25 |
|
|
* Tue Nov 13 2007 Michel Van hees <michel@vanhees.cc> |
26 |
|
|
- update contrib to phpmyadmin 2.11.2.1 |
27 |
|
|
|
28 |
|
|
* Mon Oct 29 2007 Michel Van hees <michel@vanhees.cc> |
29 |
|
|
- update contrib to phpmyadmin 2.11.2 |
30 |
|
|
|
31 |
|
|
* Mon Oct 22 2007 Michel Van hees <michel@vanhees.cc> |
32 |
|
|
- update contrib to phmyadmin 2.11.1.2 |
33 |
|
|
|
34 |
|
|
* Sat Sep 22 2007 Michel Van hees <michel@vanhees.cc> |
35 |
|
|
- Update contrib to phpmyadmin 2.11.1 |
36 |
|
|
|
37 |
|
|
* Mon Aug 27 2007 Michel Van hees <michel@vanhees.cc> |
38 |
|
|
- Update contrib to phpmyadmin 2.11.0 |
39 |
|
|
- Add all available themes |
40 |
|
|
|
41 |
|
|
* Wed Jul 25 2007 Michel Van hees <michel@vanhees.cc> |
42 |
|
|
- Update contrib to phpmyadmin 2.10.3 |
43 |
|
|
|
44 |
|
|
* Mon Jun 18 2007 Michel Van hees <michel@vanhees.cc> |
45 |
|
|
- Update contrib to phpmyadmin 2.10.2 |
46 |
|
|
- Adding redirection from http to https |
47 |
|
|
- Securing httpd.conf configuration |
48 |
|
|
- Adding ability to limit access to internal network - That's the default option! |
49 |
|
|
|
50 |
|
|
* Thu May 24 2007 Michel Van hees <michel@vanhees.cc> |
51 |
|
|
- update contrib to phpmyadmin 2.10.1 |
52 |
|
|
|
53 |
|
|
* Sun Mar 04 2007 Michel Van hees <michel@vanhees.cc> |
54 |
|
|
- update contrib to phpmyadmin 2.10.0.2 |
55 |
|
|
|
56 |
|
|
* Thu Jan 18 2007 Michel Van hees <michel@vanhees.cc> |
57 |
|
|
- update contrib to phpmyadmin 2.9.2 |
58 |
|
|
|
59 |
|
|
* Wed Jan 10 2007 Michel Van hees <michel@vanhees.cc> |
60 |
|
|
- Template move |
61 |
|
|
|
62 |
|
|
* Mon Nov 20 2006 Michel Van hees <michel@vanhees.cc> |
63 |
|
|
- update contrib to phpmyadmin 2.9.1.1 |
64 |
|
|
|
65 |
|
|
* Fri Nov 17 2006 Michel Van hees <michel@vanhees.cc> |
66 |
|
|
- update contrib to phpmyadmin 2.9.1 |
67 |
|
|
|
68 |
|
|
* Fri Nov 03 2006 Michel Van hees <michel@vanhees.cc> |
69 |
|
|
- update contrib to phpmyadmin version 2.9.0.3 |
70 |
|
|
|
71 |
|
|
* Sun Oct 29 2006 Michel Van hees <michel@vanhees.cc> |
72 |
|
|
- update contrib to last version of phpmyadmin |
73 |
|
|
|
74 |
|
|
* Sat Jun 06 2006 Michel Van hees <mvanhees@vanhees.homeip.net> |
75 |
|
|
- initial release |
76 |
|
|
|
77 |
|
|
%description |
78 |
|
|
SME server - phpmyadmin multiuser for smeserver |
79 |
|
|
|
80 |
|
|
%prep |
81 |
|
|
%setup |
82 |
|
|
#%patch0 -p1 |
83 |
|
|
#%patch1 -p1 |
84 |
|
|
|
85 |
|
|
%build |
86 |
|
|
perl createlinks |
87 |
|
|
|
88 |
|
|
%install |
89 |
|
|
rm -rf $RPM_BUILD_ROOT |
90 |
|
|
(cd root ; find . -depth -print | cpio -dump $RPM_BUILD_ROOT) |
91 |
|
|
rm -f %{name}-%{version}-filelist |
92 |
|
|
/sbin/e-smith/genfilelist $RPM_BUILD_ROOT > %{name}-%{version}-filelist |
93 |
|
|
echo "%doc COPYING" >> %{name}-%{version}-filelist |
94 |
|
|
|
95 |
|
|
%clean |
96 |
|
|
rm -rf $RPM_BUILD_ROOT |
97 |
|
|
|
98 |
|
|
%pre |
99 |
|
|
/sbin/e-smith/db accounts set phpmyadminmulti reserved |
100 |
|
|
|
101 |
|
|
%preun |
102 |
|
|
|
103 |
|
|
%post |
104 |
|
|
/sbin/e-smith/db configuration set phpmyadminmulti service |
105 |
|
|
/sbin/e-smith/db configuration setprop phpmyadminmulti access private |
106 |
|
|
|
107 |
|
|
/sbin/e-smith/expand-template /etc/httpd/conf/httpd.conf |
108 |
|
|
service httpd-e-smith sigusr1 |
109 |
|
|
|
110 |
|
|
if [ $1 = 1 ] ; then |
111 |
|
|
mysql --execute="grant all privileges on *.* to admin@localhost identified by 'admin' WITH GRANT OPTION" |
112 |
|
|
mysql --execute="flush privileges" |
113 |
|
|
fi |
114 |
|
|
|
115 |
|
|
case "${LANG:0:2}" in |
116 |
|
|
fr) |
117 |
|
|
echo "" |
118 |
|
|
echo "Vous pouvez maintenant acceder à phpmyadmin via un browser web de la maniere suivante https://nom_server/myadmin" |
119 |
|
|
echo "Vous pourrez vous loger sous admin avec comme mot de pass admin. N'oublier pas de le changer!" |
120 |
|
|
echo "Si vous mettez à jour une version 2.1 ou supérieur, le mot de passe admin n'aura pas changer!" |
121 |
|
|
echo "" |
122 |
|
|
echo "Attention !!!!!" |
123 |
|
|
echo "PHPMyadmin est limité en accès au réseau interne, donc pas depuis internet" |
124 |
|
|
echo "Vous pouvez changer cette option avec les commandes :" |
125 |
|
|
echo "db configuration setprop phpmyadminmulti access public" |
126 |
|
|
echo "signal-events console-save" |
127 |
|
|
echo "" |
128 |
|
|
;; |
129 |
|
|
*) |
130 |
|
|
echo "" |
131 |
|
|
echo "Now you can access phpmyadmin though your browser at https://server_name/myadmin" |
132 |
|
|
echo "You can connect using login admin and password admin. Don't forget to change it" |
133 |
|
|
echo "If you update a 2.1 version of this contribs, admin password don't change!" |
134 |
|
|
echo "" |
135 |
|
|
echo "BEWARE !!!" |
136 |
|
|
echo "PHPMyadmin is now limited to internal network, so it couldn't be access from internet" |
137 |
|
|
echo "You can change this with the following command :" |
138 |
|
|
echo "db configuration setprop phpmyadminmulti access public" |
139 |
|
|
echo "signal-events console-save" |
140 |
|
|
echo "" |
141 |
|
|
;; |
142 |
|
|
esac |
143 |
|
|
|
144 |
|
|
%postun |
145 |
|
|
/sbin/e-smith/db configuration delete phpmyadminmulti |
146 |
|
|
/sbin/e-smith/expand-template /etc/httpd/conf/httpd.conf |
147 |
|
|
/sbin/e-smith/db accounts delete phpmyadminmulti |
148 |
|
|
service httpd-e-smith sigusr1 |
149 |
|
|
if [ $1 = 0 ] ; then |
150 |
|
|
mysql --execute="delete from mysql.user where User='admin'" |
151 |
|
|
mysql --execute="flush privileges" |
152 |
|
|
fi |
153 |
|
|
|
154 |
|
|
%files -f %{name}-%{version}-filelist |
155 |
|
|
%defattr(-,root,root) |