From 1805023c170378b1707e1246e812b6f0a530e1cf Mon Sep 17 00:00:00 2001 From: =?utf8?q?Jan=20R=C4=99korajski?= Date: Fri, 17 May 2013 11:44:53 +0200 Subject: [PATCH] - migrated to apache 2.4 --- viewvc-apache.conf | 34 ++++++++++++++++++++++++++++++++++ viewvc-httpd.conf | 6 +++--- viewvc.spec | 12 +++++++----- 3 files changed, 44 insertions(+), 8 deletions(-) create mode 100644 viewvc-apache.conf diff --git a/viewvc-apache.conf b/viewvc-apache.conf new file mode 100644 index 0000000..7e3de1a --- /dev/null +++ b/viewvc-apache.conf @@ -0,0 +1,34 @@ + + AllowOverride None + Options +FollowSymlinks + Allow from all + + +# Version1 (default): under /cgi-bin/viewvc.cgi address +ScriptAlias /cgi-bin/viewvc.cgi /usr/share/viewvc/bin/cgi/viewvc.cgi +ScriptAlias /cgi-bin/viewvc-query.cgi /usr/share/viewvc/bin/cgi/query.cgi + +# if using apache2 mod_python: +# Alias /viewvc /usr/share/viewvc/bin/mod_python +# +# Allow from all +# +# AddHandler mod_python .py +# PythonPath "sys.path+['/usr/share/viewvc/bin/mod_python']" +# PythonHandler handler +# PythonDebug Off +# +# + +# Version 2: viewvc as handler to whole vhost: +# +# ServerName cvs +# +# Alias /viewvc/ /usr/share/viewvc +# DocumentRoot /usr/share/viewvc/bin/cgi/viewvc.cgi +# +# Options ExecCGI +# Allow from all +# +# + diff --git a/viewvc-httpd.conf b/viewvc-httpd.conf index 7e3de1a..c05fbbb 100644 --- a/viewvc-httpd.conf +++ b/viewvc-httpd.conf @@ -1,7 +1,7 @@ AllowOverride None Options +FollowSymlinks - Allow from all + Require all granted # Version1 (default): under /cgi-bin/viewvc.cgi address @@ -11,7 +11,7 @@ ScriptAlias /cgi-bin/viewvc-query.cgi /usr/share/viewvc/bin/cgi/query.cgi # if using apache2 mod_python: # Alias /viewvc /usr/share/viewvc/bin/mod_python # -# Allow from all +# Require all granted # # AddHandler mod_python .py # PythonPath "sys.path+['/usr/share/viewvc/bin/mod_python']" @@ -28,7 +28,7 @@ ScriptAlias /cgi-bin/viewvc-query.cgi /usr/share/viewvc/bin/cgi/query.cgi # DocumentRoot /usr/share/viewvc/bin/cgi/viewvc.cgi # # Options ExecCGI -# Allow from all +# Require all granted # # diff --git a/viewvc.spec b/viewvc.spec index 2f52105..8611c11 100644 --- a/viewvc.spec +++ b/viewvc.spec @@ -5,12 +5,13 @@ Summary: Browser interface for CVS and Subversion version control repositories Summary(pl.UTF-8): Interfejs przeglądarki do repozytoriów systemów kontroli wersji CVS i Subversion Name: viewvc Version: 1.1.9 -Release: 1 +Release: 2 License: BSD Group: Applications/WWW Source0: http://www.viewvc.org/%{name}-%{version}.tar.gz # Source0-md5: 13292307114b0f4bb4fc322597ec8007 -Source1: %{name}-httpd.conf +Source1: %{name}-apache.conf +Source2: %{name}-httpd.conf URL: http://www.viewvc.org/ BuildRequires: python BuildRequires: python-modules @@ -19,6 +20,7 @@ BuildRequires: rpmbuild(macros) >= 1.268 Requires: %{name}-template Requires: webapps Obsoletes: viewcvs +Conflicts: apache-base < 2.4.0-1 BuildArch: noarch BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) @@ -167,7 +169,7 @@ rm -rf $RPM_BUILD_ROOT install -d $RPM_BUILD_ROOT{%{_webapps}/%{_webapp},%{_appdir},%{_sysconfdir}} cp -a %{SOURCE1} $RPM_BUILD_ROOT%{_webapps}/%{_webapp}/apache.conf -cp -a %{SOURCE1} $RPM_BUILD_ROOT%{_webapps}/%{_webapp}/httpd.conf +cp -a %{SOURCE2} $RPM_BUILD_ROOT%{_webapps}/%{_webapp}/httpd.conf #install lighttpd.conf $RPM_BUILD_ROOT%{_webapps}/%{_webapp}/lighttpd.conf ./viewvc-install --destdir=$RPM_BUILD_ROOT --prefix=%{_appdir} @@ -195,10 +197,10 @@ rm -rf $RPM_BUILD_ROOT %triggerun -- apache1 < 1.3.37-3, apache1-base %webapp_unregister apache %{_webapp} -%triggerin -- apache < 2.2.0, apache-base +%triggerin -- apache-base %webapp_register httpd %{_webapp} -%triggerun -- apache < 2.2.0, apache-base +%triggerun -- apache-base %webapp_unregister httpd %{_webapp} %if 0 -- 2.44.0