222 lines
9.4 KiB
RPMSpec
Executable File
222 lines
9.4 KiB
RPMSpec
Executable File
%define name smeserver-git
|
|
%define version 1.2.0
|
|
%define release 14
|
|
Summary: Centralised Git repositories with setup and configuration through SME Server admin panels.
|
|
Name: %{name}
|
|
Version: %{version}
|
|
Release: %{release}%{?dist}
|
|
Distribution: SME Server
|
|
License: GNU GPL version 2
|
|
URL: https://wiki.koozali.org/Git
|
|
Group: SMEserver/addon
|
|
Source: smeserver-git-%{version}.tar.xz
|
|
Packager: Marco Hess <marco.hess@through-ip.com>
|
|
BuildArchitectures: noarch
|
|
BuildRoot: /var/tmp/%{name}-%{version}
|
|
BuildRequires: smeserver-devtools
|
|
Requires: smeserver-release >= 10.0
|
|
Requires: smeserver-apache >= 2.6.0-19
|
|
Requires: git
|
|
AutoReqProv: no
|
|
|
|
%description
|
|
smeserver-git enables centralised git repositories on an SME server and enables
|
|
access to these repositories through HTTP/HTTPS. Repositories are created and
|
|
managed through a server-manager panel that also configures the access permissions
|
|
to the repositories based on the existing SME users and groups. The package
|
|
installs and enables the git server on the current host like in
|
|
host.com/git. Repositories are then available as https://host.com/git/gitrepo.git.
|
|
Originally brought by Marco Hess http://www.through-ip.com
|
|
|
|
%changelog
|
|
* Sun Sep 08 2024 fix-e-smith-pkg.sh by Trevor Batley <trevor@batley.id.au> 1.2.0-14.sme
|
|
- Fix e-smith references in smeserver-git [SME: 12732]
|
|
|
|
* Sat Sep 07 2024 cvs2git.sh aka Brian Read <brianr@koozali.org> 1.2.0-13.sme
|
|
- Roll up patches and move to git repo [SME: 12338]
|
|
|
|
* Sat Sep 07 2024 BogusDateBot
|
|
- Eliminated rpmbuild "bogus date" warnings due to inconsistent weekday,
|
|
by assuming the date is correct and changing the weekday.
|
|
|
|
* Thu Sep 05 2024 Terry Fage <terry@fage.id.au> 1.2.0-12.sme
|
|
- apply locale 2024-09-05.patch
|
|
|
|
* Fri Mar 24 2023 Jean-Philippe Pialasse <tests@pialasse.com> 1.2.0-11.sme
|
|
- fix system and domaine name not taken into account in manager [SME: 9629]
|
|
|
|
* Fri Mar 24 2023 Jean-Philippe Pialasse <tests@pialasse.com> 1.2.0-10.sme
|
|
- fix not allowing dot in repo name [SME: 12163]
|
|
|
|
* Fri Mar 24 2023 Jean-Philippe Pialasse <tests@pialasse.com> 1.2.0-9.sme
|
|
- fix debug loglevel [SME: 11665]
|
|
|
|
* Fri Jul 22 2022 Jean-Philippe Pialasse <tests@pialasse.com> 1.2.0-8.sme
|
|
- update to httpd 2.4 syntax [SME: 12048]
|
|
fix Argument for 'Require all' must be 'granted' or 'denied'
|
|
|
|
* Sun Aug 22 2021 Terry Fage <terry.fage@gmail.com> 1.2.0-5.sme
|
|
- apply locale 2021-08-22.patch
|
|
|
|
* Fri Mar 26 2021 Brian Read <brianr@bjsystems.co.uk> 1.2.0-4.sme
|
|
- Add Update event to createlinks [SME: 11286 ]
|
|
|
|
* Sun Dec 20 2020 BogusDateBot
|
|
- Eliminated rpmbuild "bogus date" warnings due to inconsistent weekday,
|
|
- by assuming the date is correct and changing the weekday.
|
|
- Sun May 21 2013 --> Sun May 19 2013 or Tue May 21 2013 or Sun May 26 2013 or ....
|
|
|
|
* Sun Dec 20 2020 Brian Read <brianr@bjsystems.co.uk> 1.2.0-3.sme
|
|
- Initial import to SME10 tree [SME: 11286]
|
|
- Set-debugging-disabled
|
|
|
|
* Tue Nov 28 2017 Jean-Philipe Pialasse <tests@pialasse.com> 1.2.0-2.sme
|
|
- Add Update event to createlinks smeserver-git prevents httpd.conf template expansion [SME: 10464]
|
|
- now if gitweb is enabled but smeserver-gitweb is not installed a warning is issued
|
|
instead of an error and template consider it disabled. Same thing if gitweb_theme is enabled
|
|
but smeserver-gitweb-theme is missing.
|
|
|
|
* Tue Nov 28 2017 Jean-Philipe Pialasse <tests@pialasse.com> 1.2.0-0.sme
|
|
- new sources with unix formated line returns
|
|
|
|
* Wed Feb 01 2017 Jean-Philipe Pialasse <tests@pialasse.com> 1.1.0-9.sme
|
|
- apply locale 2017-02-02.patch
|
|
|
|
* Fri Jun 24 2016 Jean-Philipe Pialasse <tests@pialasse.com> 1.1.0-8.sme
|
|
- reverting git db to 644 as default-initialize_database will chown it root:admin
|
|
|
|
* Fri Jun 24 2016 Jean-Philipe Pialasse <tests@pialasse.com> 1.1.0-7.sme
|
|
- removing fragment migrate as it should not be used for that [SME: 9619]
|
|
|
|
* Wed Jun 22 2016 Jean-Philipe Pialasse <tests@pialasse.com> 1.1.0-6.sme
|
|
- Add Update event to createlinks missing ; in migrate fragment 80git to revert db permissions [SME: 9619]
|
|
|
|
* Wed Jun 22 2016 Jean-Philipe Pialasse <tests@pialasse.com> 1.1.0-5.sme
|
|
- Add Update event to createlinks too permissive permissions on db accounts networks and git [SME: 9615] [SME: 9616]
|
|
|
|
* Sat Jun 11 2016 Jean-Philipe Pialasse <tests@pialasse.com> 1.1.0-4.sme
|
|
- commented out back the rewrite rule on HEAD etc to allow CLI git
|
|
- Add Update event to createlinks auth not asked with Location after RewriteRule [SME: 9202]
|
|
- add trailing slash to root git url if omited
|
|
- only using git/repo.git or git/gitweb.cgi/repo.git will ask for auth
|
|
|
|
* Fri Jun 10 2016 Jean-Philipe Pialasse <tests@pialasse.com> 1.1.0-3.sme
|
|
- Add Update event to createlinks allow to see .git short url with gitweb [SME: 9202]
|
|
|
|
* Wed Mar 09 2016 JP Pialasse <tests@pialasse.com> 1.1.0-2.sme
|
|
- apply locale 2016-03-09 patch
|
|
|
|
* Wed Feb 17 2016 Marco Hess <marco.hess@through-ip.com> 1.1.0-3
|
|
- Fixed erronous error message when updating a group due to
|
|
missing check for 'group-modify' in git user access list handling [SME: 9133]
|
|
|
|
* Fri Jan 30 2015 Marco Hess <marco.hess@through-ip.com> 1.1.0-0
|
|
- Require >= SME9.
|
|
- Moved /usr/lib/perl5/site_perl to /usr/share/perl5/vendor_perl.
|
|
- Fixed pwauth setup.
|
|
- Added AuthBasicProvider external in authentication setup.
|
|
- Fixed GitWebRoot variable scope.
|
|
- Allow adjustment of gitweb static path for git 1.7 vs. git 1.8
|
|
|
|
* Fri May 30 2014 Marco Hess <marco.hess@through-ip.com> 1.0.0-37
|
|
- Fixed the HTTPS redirection loop. HTTPS redirection is now only done on the HTTP part of of
|
|
the web server configuration and the full Git configuration part is only done in the HTTPS
|
|
section.
|
|
|
|
* Tue May 27 2014 Marco Hess <marco.hess@through-ip.com> 1.0.0-36
|
|
- Changed how git update-server-info is run as the location of the executable changed in git 1.8.
|
|
|
|
* Fri Jan 24 2014 Marco Hess <marco.hess@through-ip.com> 1.0.0-35
|
|
- Systax error in 29GitRepositories that I though I fixed.
|
|
|
|
* Fri Jan 24 2014 Marco Hess <marco.hess@through-ip.com> 1.0.0-34
|
|
- git version 1.8 has shifted the location of some executables. Modified the scripts
|
|
to test on these locations so we generate the right paths.
|
|
|
|
* Tue May 21 2013 Marco Hess <marco.hess@through-ip.com> 1.0.0-33
|
|
Sun May 21 2013 --> Sun May 19 2013 or Tue May 21 2013 or Sun May 26 2013 or ....
|
|
- Set permissions on git repository databaase for GitWeb access also on upgrade install.
|
|
|
|
* Tue May 21 2013 Marco Hess <marco.hess@through-ip.com> 1.0.0-32
|
|
Sun May 21 2013 --> Sun May 19 2013 or Tue May 21 2013 or Sun May 26 2013 or ....
|
|
- Fixed a problem in the repository delete script where File::Path is needed
|
|
to reference rmtree.
|
|
- Also cleanup the entry from the database so that repositories of the same
|
|
name can be created again.
|
|
|
|
* Tue May 21 2013 Marco Hess <marco.hess@through-ip.com> 1.0.0-31
|
|
Sun May 21 2013 --> Sun May 19 2013 or Tue May 21 2013 or Sun May 26 2013 or ....
|
|
- Changed the repository-delete script to ensure the SME Git database
|
|
permissions are Ok for use by GitWeb after a delete.
|
|
- Ensure that on 64-bit systems we use /usr/lib64/httpd/modules/pwauth
|
|
|
|
* Sat Jul 21 2012 Marco Hess <marco.hess@through-ip.com> 1.0.0-3
|
|
- Ensure git database is present in /home/e-smith/db
|
|
- Create default config database entries for 'git'
|
|
- Moved retrieving maxNameLength for panel validations from config 'git'
|
|
- In the user and group list boxes, added support to the special group admin
|
|
and shared to allow either the admin or everybody to be included in the access lists.
|
|
- Updated the HTTP config db error messages to be more clear as to which property needs
|
|
to be configured.
|
|
|
|
* Sun Jun 17 2012 Jonathan Martens <smeserver-contribs@snetram.nl> 1.0.0-2
|
|
- Rip out gitweb and create tar.xz file
|
|
|
|
* Sun Apr 29 2012 Marco Hess <marco.hess@through-ip.com> 1.0.0-1
|
|
- initial release
|
|
|
|
%prep
|
|
%setup
|
|
|
|
mkdir -p root/home/e-smith/files/git/
|
|
%build
|
|
perl createlinks
|
|
|
|
%install
|
|
rm -rf $RPM_BUILD_ROOT
|
|
(cd root ; find . -depth -print | cpio -dump $RPM_BUILD_ROOT)
|
|
rm -f %{name}-%{version}-filelist
|
|
/sbin/e-smith/genfilelist $RPM_BUILD_ROOT > %{name}-%{version}-filelist
|
|
|
|
%clean
|
|
rm -rf $RPM_BUILD_ROOT
|
|
|
|
%post
|
|
echo "---------------------------------------------------------"
|
|
if [ $1 -eq 1 ] ; then
|
|
echo "Initial installation:"
|
|
echo " - Ensuring git repositories configuration database exist ..."
|
|
touch /home/e-smith/db/git
|
|
echo " - Ensuring git repositories root directory exist with the right permissions ..."
|
|
mkdir -p /home/e-smith/files/git
|
|
chmod 770 /home/e-smith/files/git
|
|
chmod g+s /home/e-smith/files/git
|
|
echo " - Rebuilding server-manager ..."
|
|
/sbin/e-smith/expand-template /etc/httpd/conf/httpd.conf
|
|
/etc/e-smith/events/actions/navigation-conf
|
|
fi
|
|
chown admin:www /home/e-smith/files/git
|
|
#/etc/rc7.d/S86httpd-e-smith sighup
|
|
|
|
# fixing needed permissions
|
|
# fixing previous mess
|
|
chmod 644 /home/e-smith/db/git
|
|
chmod 640 /home/e-smith/db/accounts
|
|
chmod 640 /home/e-smith/db/networks
|
|
|
|
%postun
|
|
if [ $1 -eq 0 ] ; then
|
|
echo "---------------------------------------------------------"
|
|
echo " - Rebuilding server-manager ..."
|
|
/sbin/e-smith/expand-template /etc/httpd/conf/httpd.conf
|
|
/etc/e-smith/events/actions/navigation-conf
|
|
echo " - Final Uninstall:"
|
|
echo " smeserver-git has been removed but the git repositories and the git config database are left in place ..."
|
|
echo " To manually remove the git repositories, use: 'rm -rf /home/e-smith/files/git'"
|
|
echo " To manually remove the git config database, use: 'rm -rf /home/e-smith/db/git'"
|
|
echo "---------------------------------------------------------"
|
|
fi
|
|
|
|
%files -f %{name}-%{version}-filelist
|
|
%defattr(-,root,root)
|