From: Sylvain Rabot <sylvain@abstraction.fr>
To: Junio C Hamano <gitster@pobox.com>
Cc: git <git@vger.kernel.org>, Jakub Narebski <jnareb@gmail.com>
Subject: Re: Make Gitweb behave like Apache mod_userdir
Date: Tue, 17 Nov 2009 21:24:54 +0100 [thread overview]
Message-ID: <7fce93be0911171224r1cfc438ay7b38b81646154a23@mail.gmail.com> (raw)
In-Reply-To: <7vhbssewm7.fsf@alter.siamese.dyndns.org>
On Tue, Nov 17, 2009 at 21:15, Junio C Hamano <gitster@pobox.com> wrote:
> Sylvain Rabot <sylvain@abstraction.fr> writes:
>
>> +If you want gitweb to act a bit like UserDir mod in apache, knowing, http://<host>/~<user>
>> +will list all git repos of <user> located in a special directory in his home (/home/<user>/gitweb/),
>> +do the following steps :
>> +
>> +Add this to the VirtualHost section of your apache configuration file :
>> +
>> + RewriteRule ^/~([^\/]+)/?$ /cgi-bin/gitweb.cgi [QSA,E=GITWEB_PROJECTROOT:/home/$1/gitweb/,L,PT]
>> +
>> +Modify your gitweb.conf file, located at /etc/gitweb.conf in this example, with :
>> +
>> + $projectroot = $ENV{'GITWEB_PROJECTROOT'} || "/path/to/the/defaul/project/root";
>> +
>> +Thus, each user with a gitweb folder in his home will be able to browse it with gitweb.
>> +/!\ The gitweb folder and user's home folder must be readable by the webserver user.
>
> Wouldn't it be a good idea to somehow make this work well together with
> the --user-path feature of git-daemon?
>
> Perhaps the recommended name given in the example shouldn't be ~/gitweb,
> but more like ~/public_git, as this is like ~/public_html but for git
> repositories. Then the end users will browse
As I said, it's configuration :)
>
> http://my.site/~gitster/public_git/git.git
>
would be http://my.site/~gitster/git.git
> and gitweb can be told to show
>
> clone URL: git://my.site/~gitster/public_git/git.git
and git://my.site/~gitster/git.git
if --user-path of git daemon set to public_git
> on the page. If the site administrator runs git-daemon with --user-path
> set to public_git, everything will work seamlessly, no?
>
Yes :)
next prev parent reply other threads:[~2009-11-17 20:25 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-11-15 10:04 Make Gitweb behave like Apache mod_userdir Sylvain Rabot
2009-11-15 21:03 ` Junio C Hamano
2009-11-17 13:58 ` Jakub Narebski
2009-11-17 15:51 ` Sylvain Rabot
2009-11-17 18:12 ` Jakub Narebski
2009-11-17 19:56 ` Sylvain Rabot
2009-11-17 20:15 ` Junio C Hamano
2009-11-17 20:24 ` Sylvain Rabot [this message]
2009-11-17 22:10 ` Junio C Hamano
2009-11-17 22:54 ` Sylvain Rabot
2009-11-17 23:40 ` Junio C Hamano
2009-11-17 23:52 ` J.H.
2009-11-17 22:59 ` J.H.
2009-11-17 23:46 ` Junio C Hamano
2009-11-17 23:59 ` J.H.
2009-11-18 0:14 ` Junio C Hamano
2009-11-18 0:00 ` J.H.
2009-11-18 0:16 ` Sylvain Rabot
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=7fce93be0911171224r1cfc438ay7b38b81646154a23@mail.gmail.com \
--to=sylvain@abstraction.fr \
--cc=git@vger.kernel.org \
--cc=gitster@pobox.com \
--cc=jnareb@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).