allura-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From brond...@apache.org
Subject [3/6] allura git commit: [#8128] update ApacheAccessHandler.py docs for httpd 2.4, remove unneeded proxy stuff
Date Fri, 23 Sep 2016 18:37:15 GMT
[#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/a2a07fb3
Tree: http://git-wip-us.apache.org/repos/asf/allura/tree/a2a07fb3
Diff: http://git-wip-us.apache.org/repos/asf/allura/diff/a2a07fb3

Branch: refs/heads/master
Commit: a2a07fb356e0a46cb2db14eca6d9cd6e6b989d9f
Parents: 7fb4022
Author: Dave Brondsema <dave@brondsema.net>
Authored: Mon Sep 19 18:27:24 2016 -0400
Committer: Dave Brondsema <dave@brondsema.net>
Committed: Fri Sep 23 14:37:00 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/a2a07fb3/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/a2a07fb3/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>
 
 """


Mime
View raw message