Repository: allura
Updated Branches:
  refs/heads/db/8128 [created] 3b8a27364


[#8128] update ApacheAccessHandler.py docs for httpd 2.4, remove unneeded proxy 
stuff


Project: http://git-wip-us.apache.org/repos/asf/allura/repo
Commit: http://git-wip-us.apache.org/repos/asf/allura/commit/fd18061b
Tree: http://git-wip-us.apache.org/repos/asf/allura/tree/fd18061b
Diff: http://git-wip-us.apache.org/repos/asf/allura/diff/fd18061b

Branch: refs/heads/db/8128
Commit: fd18061b832671829a3b794b13ceef1be85da8e7
Parents: a941cec
Author: Dave Brondsema <d...@brondsema.net>
Authored: Mon Sep 19 18:27:24 2016 -0400
Committer: Dave Brondsema <d...@brondsema.net>
Committed: Mon Sep 19 18:29:04 2016 -0400

----------------------------------------------------------------------
 Allura/docs/getting_started/scm_host.rst | 14 +++++++++++---
 scripts/ApacheAccessHandler.py           | 24 +++++++++++++-----------
 2 files changed, 24 insertions(+), 14 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/allura/blob/fd18061b/Allura/docs/getting_started/scm_host.rst
----------------------------------------------------------------------
diff --git a/Allura/docs/getting_started/scm_host.rst 
b/Allura/docs/getting_started/scm_host.rst
index 18811b5..7b94f95 100644
--- a/Allura/docs/getting_started/scm_host.rst
+++ b/Allura/docs/getting_started/scm_host.rst
@@ -48,7 +48,7 @@ and subsequent chapters.
 
     sudo chmod 775 /srv/*  # make sure apache can read the repo dirs
     sudo apt-get install apache2
-    sudo a2enmod proxy rewrite
+    sudo a2enmod cgi
     sudo vi /etc/apache2/sites-available/default
 
 And add the following text within the :code:`<VirtualHost>` block:
@@ -57,11 +57,14 @@ And add the following text within the :code:`<VirtualHost>` 
block:
 
     SetEnv GIT_PROJECT_ROOT /srv/git
     SetEnv GIT_HTTP_EXPORT_ALL
-    ProxyPass /git/ !
     ScriptAlias /git/ /usr/lib/git-core/git-http-backend/
 
     # no authentication required at all - for testing purposes
     SetEnv REMOTE_USER=git-allura
+    <Location "/git/">
+        # new for httpd 2.4
+        Require all granted
+    </Location>
 
 Then exit vim (:kbd:`<esc> :wq`) and run:
 
@@ -191,7 +194,7 @@ First, you need to ensure that mod_python is installed:
 
     sudo aptitude install libapache2-mod-python
 
-Then, in the VirtualHost section where you proxy SCM requests to git, SVN, or 
Hg, add the
+Then, in the VirtualHost section where you send SCM requests to git, SVN, or 
Hg, add the
 access handler, e.g.:
 
 .. code-block:: console
@@ -201,12 +204,17 @@ access handler, e.g.:
 .. code-block:: apache
 
     <LocationMatch "^/(git|svn|hg)/">
+        # new for httpd 2.4
+        Require all granted
+
         AddHandler mod_python .py
         # Change this path if needed:
         PythonAccessHandler 
/home/vagrant/src/allura/scripts/ApacheAccessHandler.py
+
         AuthType Basic
         AuthName "SCM Access"
         AuthBasicAuthoritative off
+
         # Change this path if needed:
         PythonOption ALLURA_VIRTUALENV /home/vagrant/env-allura
         # This routes back to the allura webapp

http://git-wip-us.apache.org/repos/asf/allura/blob/fd18061b/scripts/ApacheAccessHandler.py
----------------------------------------------------------------------
diff --git a/scripts/ApacheAccessHandler.py b/scripts/ApacheAccessHandler.py
index 1ee9ebc..89654c5 100644
--- a/scripts/ApacheAccessHandler.py
+++ b/scripts/ApacheAccessHandler.py
@@ -26,20 +26,22 @@ Here is a quick example for your apache settings (assuming 
ProxyPass)
 
     SetEnv GIT_PROJECT_ROOT /opt/allura/scm/git
     SetEnv GIT_HTTP_EXPORT_ALL
-    ProxyPass /git/ !
     ScriptAlias /git/ /usr/lib/git-core/git-http-backend/
 
     <Location "/git/">
-            AddHandler mod_python .py
-            PythonAccessHandler /path/to/ApacheAccessHandler.py
-            PythonDebug On
-
-            AuthType Basic
-            AuthName "Git Access"
-            AuthBasicAuthoritative off
-            PythonOption ALLURA_PERM_URL 
https://127.0.0.1/auth/repo_permissions
-            PythonOption ALLURA_AUTH_URL https://127.0.0.1/auth/do_login
-            PythonOption ALLURA_VIRTUALENV /var/local/env-allura
+        # new for httpd 2.4
+        Require all granted
+
+        AddHandler mod_python .py
+        PythonAccessHandler /path/to/ApacheAccessHandler.py
+        PythonDebug On
+
+        AuthType Basic
+        AuthName "Git Access"
+        AuthBasicAuthoritative off
+        PythonOption ALLURA_PERM_URL https://127.0.0.1/auth/repo_permissions
+        PythonOption ALLURA_AUTH_URL https://127.0.0.1/auth/do_login
+        PythonOption ALLURA_VIRTUALENV /var/local/env-allura
     </Location>
 
 """

Reply via email to