From 1d048cb81c1eaeac61ee151bb9fa2458870024c3 Mon Sep 17 00:00:00 2001 From: Robby Workman Date: Sun, 24 Nov 2013 20:17:01 -0600 Subject: development/cgit: Fixes for httpd-2.4.x and allow custom DOCROOT Signed-off-by: Robby Workman --- development/cgit/config/cgit-httpd.conf | 15 +++++++-------- development/cgit/config/cgit-lighttpd.conf | 6 +++--- development/cgit/config/cgit.conf | 2 +- 3 files changed, 11 insertions(+), 12 deletions(-) (limited to 'development/cgit/config') diff --git a/development/cgit/config/cgit-httpd.conf b/development/cgit/config/cgit-httpd.conf index a579174fd0..4d713503be 100644 --- a/development/cgit/config/cgit-httpd.conf +++ b/development/cgit/config/cgit-httpd.conf @@ -8,18 +8,17 @@ # # AddHandler cgi-script .cgi - + AllowOverride None - Order allow,deny - Allow from all + Require all granted ## Version 1 (default): under /cgi-bin/cgit.cgi address -#ScriptAlias /cgi-bin/cgit.cgi /var/www/cgi-bin/cgit.cgi -#Alias /cgit/ /var/www/cgi-bin/ +#ScriptAlias /cgi-bin/cgit.cgi @DOCROOT@/cgi-bin/cgit.cgi +#Alias /cgit/ @DOCROOT@/cgi-bin/ # # Options FollowSymlinks ExecCGI -# Allow from All +# Require all granted # #RewriteEngine on #RewriteCond %{REQUEST_FILENAME} !-f @@ -32,10 +31,10 @@ SetEnv CGIT_CONFIG /etc/cgitrc Options FollowSymlinks ExecCGI DirectoryIndex cgit.cgi - DocumentRoot /var/www/cgi-bin + DocumentRoot @DOCROOT@/cgi-bin Options ExecCGI - Allow from All + Require all granted RewriteEngine on RewriteCond %{REQUEST_FILENAME} !-f diff --git a/development/cgit/config/cgit-lighttpd.conf b/development/cgit/config/cgit-lighttpd.conf index fc49e5763f..ce7ccced54 100644 --- a/development/cgit/config/cgit-lighttpd.conf +++ b/development/cgit/config/cgit-lighttpd.conf @@ -6,15 +6,15 @@ $HTTP["host"] == "cgit.my.domain" { alias.url = ( - "/static/" => "/var/www/cgi-bin/", - "/cgit.cgi" => "/var/www/cgi-bin/cgit.cgi", + "/static/" => "@DOCROOT@/cgi-bin/", + "/cgit.cgi" => "@DOCROOT@/cgi-bin/cgit.cgi", ) url.rewrite-once = ( "^/static/.*$" => "$0", "^/([^?/]+/[^?]*)?(?:\?(.*))?$" => "/cgit.cgi?url=$1&$2", ) cgi.assign = ( - "/var/www/cgi-bin/cgit.cgi" => "", + "@DOCROOT@/cgi-bin/cgit.cgi" => "", ) } diff --git a/development/cgit/config/cgit.conf b/development/cgit/config/cgit.conf index 615c7efe97..a569414191 100644 --- a/development/cgit/config/cgit.conf +++ b/development/cgit/config/cgit.conf @@ -1,2 +1,2 @@ -CGIT_SCRIPT_PATH = /var/www/cgi-bin +CGIT_SCRIPT_PATH = @DOCROOT@/cgi-bin CACHE_ROOT = /var/cache/cgit -- cgit v1.2.3-65-gdbad