1 |
%define name smeserver-git |
2 |
%define version 1.0.0 |
3 |
%define release 41 |
4 |
Summary: Centralised Git repositories with setup and configuration through SME Server admin panels. |
5 |
Name: %{name} |
6 |
Version: %{version} |
7 |
Release: %{release}%{?dist} |
8 |
Distribution: SME Server |
9 |
License: GNU GPL version 2 |
10 |
URL: http://www.through-ip.com |
11 |
Group: SMEserver/addon |
12 |
Source: smeserver-git-%{version}.tar.gz |
13 |
Packager: Marco Hess <marco.hess@through-ip.com> |
14 |
BuildArchitectures: noarch |
15 |
BuildRoot: /var/tmp/%{name}-%{version} |
16 |
BuildRequires: e-smith-devtools |
17 |
Requires: e-smith-release >= 8.0 |
18 |
Requires: git |
19 |
AutoReqProv: no |
20 |
|
21 |
%description |
22 |
smeserver-git enables centralised git repositories on an SME server and enables |
23 |
access to these repositories through HTTP/HTTPS. Repositories are created and |
24 |
managed through a server-manager panel that also configures the access permissions |
25 |
to the repositories based on the existing SME users and groups. The package |
26 |
installs and enables the git server on the current host like in |
27 |
host.com/git. Repositories are then available as https://host.com/git/gitrepo.git. |
28 |
|
29 |
%changelog |
30 |
* Wed Mar 09 2016 JP Pialasse <tests@pialasse.com> 1.0.0-41.sme |
31 |
- apply locale 2016-03-09 patch |
32 |
|
33 |
* Tue Feb 2 2015 Marco Hess <marco.hess@through-ip.com> 1.0.0-40 |
34 |
- Fixups of 1.1 incompatibilities with older apache. |
35 |
- Allow adjustment of gitweb static path for git 1.7 vs. git 1.8 |
36 |
|
37 |
* Tue Feb 2 2015 Marco Hess <marco.hess@through-ip.com> 1.0.0-40 |
38 |
- Fixup of GitWeb CSS/JS files under 'static' in this version. |
39 |
|
40 |
* Tue Feb 2 2015 Marco Hess <marco.hess@through-ip.com> 1.0.0-38 |
41 |
- Backport changes from 1.1. |
42 |
|
43 |
* Fri May 30 2014 Marco Hess <marco.hess@through-ip.com> 1.0.0-37 |
44 |
- Fixed the HTTPS redirection loop. HTTPS redirection is now only done on the HTTP part of of |
45 |
the web server configuration and the full Git configuration part is only done in the HTTPS |
46 |
section. |
47 |
|
48 |
* Tue May 27 2014 Marco Hess <marco.hess@through-ip.com> 1.0.0-36 |
49 |
- Changed how git update-server-info is run as the location of the executable changed in git 1.8. |
50 |
|
51 |
* Fri Jan 24 2014 Marco Hess <marco.hess@through-ip.com> 1.0.0-35 |
52 |
- Systax error in 29GitRepositories that I though I fixed. |
53 |
|
54 |
* Fri Jan 24 2014 Marco Hess <marco.hess@through-ip.com> 1.0.0-34 |
55 |
- git version 1.8 has shifted the location of some executables. Modified the scripts |
56 |
to test on these locations so we generate the right paths. |
57 |
|
58 |
* Sun May 21 2013 Marco Hess <marco.hess@through-ip.com> 1.0.0-33 |
59 |
- Set permissions on git repository databaase for GitWeb access also on upgrade install. |
60 |
|
61 |
* Sun May 21 2013 Marco Hess <marco.hess@through-ip.com> 1.0.0-32 |
62 |
- Fixed a problem in the repository delete script where File::Path is needed |
63 |
to reference rmtree. |
64 |
- Also cleanup the entry from the database so that repositories of the same |
65 |
name can be created again. |
66 |
|
67 |
* Sun May 21 2013 Marco Hess <marco.hess@through-ip.com> 1.0.0-31 |
68 |
- Changed the repository-delete script to ensure the SME Git database |
69 |
permissions are Ok for use by GitWeb after a delete. |
70 |
- Ensure that on 64-bit systems we use /usr/lib64/httpd/modules/pwauth |
71 |
|
72 |
* Sat Jul 21 2012 Marco Hess <marco.hess@through-ip.com> 1.0.0-3 |
73 |
- Ensure git database is present in /home/e-smith/db |
74 |
- Create default config database entries for 'git' |
75 |
- Moved retrieving maxNameLength for panel validations from config 'git' |
76 |
- In the user and group list boxes, added support to the special group admin |
77 |
and shared to allow either the admin or everybody to be included in the access lists. |
78 |
- Updated the HTTP config db error messages to be more clear as to which property needs |
79 |
to be configured. |
80 |
|
81 |
* Sun Jun 17 2012 Jonathan Martens <smeserver-contribs@snetram.nl> 1.0.0-2 |
82 |
- Rip out gitweb and create tgz file |
83 |
|
84 |
* Sun Apr 29 2012 Marco Hess <marco.hess@through-ip.com> 1.0.0-1 |
85 |
- initial release |
86 |
|
87 |
%prep |
88 |
%setup |
89 |
mkdir -p root/home/e-smith/files/git/ |
90 |
|
91 |
%build |
92 |
perl createlinks |
93 |
|
94 |
%install |
95 |
rm -rf $RPM_BUILD_ROOT |
96 |
(cd root ; find . -depth -print | cpio -dump $RPM_BUILD_ROOT) |
97 |
rm -f %{name}-%{version}-filelist |
98 |
/sbin/e-smith/genfilelist $RPM_BUILD_ROOT > %{name}-%{version}-filelist |
99 |
|
100 |
%clean |
101 |
rm -rf $RPM_BUILD_ROOT |
102 |
|
103 |
%post |
104 |
echo "---------------------------------------------------------" |
105 |
if [ $1 -eq 1 ] ; then |
106 |
echo "Initial installation:" |
107 |
echo " - Ensuring git repositories configuration database exist ..." |
108 |
touch /home/e-smith/db/git |
109 |
echo " - Ensuring git repositories root directory exist with the right permissions ..." |
110 |
mkdir -p /home/e-smith/files/git |
111 |
chmod 770 /home/e-smith/files/git |
112 |
chmod g+s /home/e-smith/files/git |
113 |
echo " - Rebuilding server-manager ..." |
114 |
/sbin/e-smith/expand-template /etc/httpd/conf/httpd.conf |
115 |
/etc/e-smith/events/actions/navigation-conf |
116 |
fi |
117 |
echo " - Ensuring git repositories configuration database has the right permissions ..." |
118 |
chmod 664 /home/e-smith/db/git |
119 |
chown admin:www /home/e-smith/files/git |
120 |
/etc/rc7.d/S86httpd-e-smith sighup |
121 |
echo "---------------------------------------------------------" |
122 |
|
123 |
%postun |
124 |
if [ $1 -eq 0 ] ; then |
125 |
echo "---------------------------------------------------------" |
126 |
echo " - Rebuilding server-manager ..." |
127 |
/sbin/e-smith/expand-template /etc/httpd/conf/httpd.conf |
128 |
/etc/e-smith/events/actions/navigation-conf |
129 |
echo " - Final Uninstall:" |
130 |
echo " smeserver-git has been removed but the git repositories and the git config database are left in place ..." |
131 |
echo " To manually remove the git repositories, use: 'rm -rf /home/e-smith/files/git'" |
132 |
echo " To manually remove the git config database, use: 'rm -rf /home/e-smith/db/git'" |
133 |
echo "---------------------------------------------------------" |
134 |
fi |
135 |
|
136 |
%files -f %{name}-%{version}-filelist |
137 |
%defattr(-,root,root) |