Use the Pagure code for http cloning

Signed-off-by: Patrick Uiterwijk <patrick@puiterwijk.org>
This commit is contained in:
Patrick Uiterwijk 2018-10-05 07:28:28 +02:00
parent aa337313be
commit 02ff6983fa
2 changed files with 8 additions and 6 deletions

View file

@ -26,7 +26,7 @@
- distgit
- name: install the http push configuration
copy: src=httppush.conf dest=/etc/httpd/conf.d/httpush.conf
template: src=httppush.conf dest=/etc/httpd/conf.d/httpush.conf
notify:
- reload httpd
tags:

View file

@ -1,8 +1,3 @@
SetEnv GIT_PROJECT_ROOT /srv/git/repositories
AliasMatch ^/(.*/objects/[0-9a-f]{2}/[0-9a-f]{38})$ /srv/git/repositories/$1
AliasMatch ^/(.*/objects/pack/pack-[0-9a-f]{40}.(pack|idx))$ /srv/git/repositories/$1
<Location />
AuthType oauth20
Require all granted
@ -22,6 +17,12 @@ AliasMatch ^/(.*/objects/pack/pack-[0-9a-f]{40}.(pack|idx))$ /srv/git/repositori
</Else>
</LocationMatch>
{% if env == "production" %}
SetEnv GIT_PROJECT_ROOT /srv/git/repositories
AliasMatch ^/(.*/objects/[0-9a-f]{2}/[0-9a-f]{38})$ /srv/git/repositories/$1
AliasMatch ^/(.*/objects/pack/pack-[0-9a-f]{40}.(pack|idx))$ /srv/git/repositories/$1
SuexecUserGroup pagure packager
ScriptAliasMatch \
@ -30,3 +31,4 @@ ScriptAliasMatch \
objects/info/[^/]+ | \
git-(upload|receive)-pack))$" \
/var/www/bin/gitolite-suexec-wrapper.sh/
{% endif %}