{"thread":{"id":"5102","subject":"gitweb testing with non-apache web server","startedAt":"2006-08-03T07:54:03Z","lastAt":"2006-08-04T19:48:40Z","messageCount":18,"participants":["Marc Singer","Jakub Narebski","Sam Vilain","Blu Corater","Junio C Hamano","Martin Waitz","Francis Daly"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"24622","messageId":"20060803075403.GA5238@buici.com","threadId":"5102","inReplyTo":null,"subject":"gitweb testing with non-apache web server","fromName":"Marc Singer","fromEmail":"elf@buici.com","sentAt":"2006-08-03T07:54:03Z","receivedAt":"2006-08-03T07:54:03Z","isPatch":false,"sender":{"key":"elf@buici.com","avatar":null},"body":"I would like to use gitweb with the Cherokee web server because the\nhost that I have on hand has very limited RAM, 32MiB.  Neither the\nversion of gitweb available on Debian (v264) nor the latest in the git\nrepo works.\n\nI did some debugging on the latest repo version.  The lines\n\n  our $project = ($cgi->param('p') || $ENV{'PATH_INFO'});\n  if (defined $project) {\n     ...\n\nare being executed even though the url is\n\n  http://server/git\n\nI think that the problem is that Cherokee translates the request URL\ninto\n\n  http://server/git/\n\nwhich means that the $ENV{'PATH_INFO'} is the string \"/\" insted of\nbeing undefined.\n\nThe error I'm seeing is that the request path is forbidden, but I\nsuspect that this is some sort of misunderstanding between the web\nserver and the script.\n\nSo, I wonder if someone who has a working gitweb would be willing to\ntest with Cherokee or some other resource conservative web server.\n\nCheers.\n"},{"id":"24624","messageId":"easbev$act$1@sea.gmane.org","threadId":"5102","inReplyTo":"20060803075403.GA5238@buici.com","subject":"Re: gitweb testing with non-apache web server","fromName":"Jakub Narebski","fromEmail":"jnareb@gmail.com","sentAt":"2006-08-03T08:18:07Z","receivedAt":"2006-08-03T08:18:07Z","isPatch":false,"sender":{"key":"jnareb@gmail.com","avatar":"https://avatars.githubusercontent.com/u/2706?v=4"},"body":"<opublikowany i wysłany>\n\nMarc Singer wrote:\n\n\n> I did some debugging on the latest repo version.  The lines\n> \n>   our $project = ($cgi->param('p') || $ENV{'PATH_INFO'});\n>   if (defined $project) {\n>      ...\n> \n> are being executed even though the url is\n> \n>   http://server/git\n> \n> I think that the problem is that Cherokee translates the request URL\n> into\n> \n>   http://server/git/\n> \n> which means that the $ENV{'PATH_INFO'} is the string \"/\" insted of\n> being undefined.\n\nTry changing\n\nmy $project = ($cgi->param('p') || $ENV{'PATH_INFO'});\nif (defined $project) {\n        $project =~ s|^/||; $project =~ s|/$||;\n\nto\n\nmy $project = ($cgi->param('p') || $ENV{'PATH_INFO'});\n$project =~ s|^/||; $project =~ s|/$||;\nif (defined $project && $project) {     \n\n(and send patch if it works, please).\n\n-- \nJakub Narebski\nWarsaw, Poland\nShadeHawk on #git\n"},{"id":"24631","messageId":"44D1E11D.1090409@vilain.net","threadId":"5102","inReplyTo":"20060803075403.GA5238@buici.com","subject":"Re: gitweb testing with non-apache web server","fromName":"Sam Vilain","fromEmail":"sam@vilain.net","sentAt":"2006-08-03T11:42:21Z","receivedAt":"2006-08-03T11:42:21Z","isPatch":false,"sender":{"key":"sam@vilain.net","avatar":"https://gravatar.com/avatar/8fc840ca854dbf6f7065b4335e3b934951c1dca3b11db688e95e471901f8f4a8?d=mp&s=160"},"body":"Marc Singer wrote:\n> I would like to use gitweb with the Cherokee web server because the\n> host that I have on hand has very limited RAM, 32MiB.  Neither the\n> version of gitweb available on Debian (v264) nor the latest in the git\n> repo works.\n\nMarc,\n\nI use lighttpd on utsl.gen.nz, which is only a wee box, too.  I hacked\nFastCGI support into gitweb.cgi, my changes are available at\ngit://utsl.gen.nz/gitweb (gitweb url at\nhttp://utsl.gen.nz/gitweb/?p=gitweb).\n\nI just set up the /git path to redirect to /git/ in the web server.\n\nSam.\n\n> \n> I did some debugging on the latest repo version.  The lines\n> \n>   our $project = ($cgi->param('p') || $ENV{'PATH_INFO'});\n>   if (defined $project) {\n>      ...\n> \n> are being executed even though the url is\n> \n>   http://server/git\n> \n> I think that the problem is that Cherokee translates the request URL\n> into\n> \n>   http://server/git/\n> \n> which means that the $ENV{'PATH_INFO'} is the string \"/\" insted of\n> being undefined.\n> \n> The error I'm seeing is that the request path is forbidden, but I\n> suspect that this is some sort of misunderstanding between the web\n> server and the script.\n> \n> So, I wonder if someone who has a working gitweb would be willing to\n> test with Cherokee or some other resource conservative web server.\n> \n> Cheers.\n> \n> -\n> To unsubscribe from this list: send the line \"unsubscribe git\" in\n> the body of a message to majordomo@vger.kernel.org\n> More majordomo info at  http://vger.kernel.org/majordomo-info.html\n"},{"id":"24645","messageId":"20060803153403.GA30729@buici.com","threadId":"5102","inReplyTo":"easbev$act$1@sea.gmane.org","subject":"Re: gitweb testing with non-apache web server","fromName":"Marc Singer","fromEmail":"elf@buici.com","sentAt":"2006-08-03T15:34:03Z","receivedAt":"2006-08-03T15:34:03Z","isPatch":false,"sender":{"key":"elf@buici.com","avatar":null},"body":"On Thu, Aug 03, 2006 at 10:18:07AM +0200, Jakub Narebski wrote:\n> <opublikowany i wys?any>\n> \n> Marc Singer wrote:\n> \n> \n> > I did some debugging on the latest repo version.  The lines\n> > \n> >   our $project = ($cgi->param('p') || $ENV{'PATH_INFO'});\n> >   if (defined $project) {\n> >      ...\n> > \n> > are being executed even though the url is\n> > \n> >   http://server/git\n> > \n> > I think that the problem is that Cherokee translates the request URL\n> > into\n> > \n> >   http://server/git/\n> > \n> > which means that the $ENV{'PATH_INFO'} is the string \"/\" insted of\n> > being undefined.\n> \n> Try changing\n> \n> my $project = ($cgi->param('p') || $ENV{'PATH_INFO'});\n> if (defined $project) {\n>         $project =~ s|^/||; $project =~ s|/$||;\n> \n> to\n> \n> my $project = ($cgi->param('p') || $ENV{'PATH_INFO'});\n> $project =~ s|^/||; $project =~ s|/$||;\n> if (defined $project && $project) {     \n> \n> (and send patch if it works, please).\n\nThat isn't enough.  I did something like that when I was exploring the\nscript.  While the change *does* eliminate the 403 error, it doesn't\nmake the rest of the script work properly.  All of the links return to\nthe same page that lists the projects.\n\n\n> \n> -- \n> Jakub Narebski\n> Warsaw, Poland\n> ShadeHawk on #git\n> \n> \n> -\n> To unsubscribe from this list: send the line \"unsubscribe git\" in\n> the body of a message to majordomo@vger.kernel.org\n> More majordomo info at  http://vger.kernel.org/majordomo-info.html\n"},{"id":"24648","messageId":"eat5qp$3sr$1@sea.gmane.org","threadId":"5102","inReplyTo":"20060803153403.GA30729@buici.com","subject":"Re: gitweb testing with non-apache web server","fromName":"Jakub Narebski","fromEmail":"jnareb@gmail.com","sentAt":"2006-08-03T15:48:11Z","receivedAt":"2006-08-03T15:48:11Z","isPatch":false,"sender":{"key":"jnareb@gmail.com","avatar":"https://avatars.githubusercontent.com/u/2706?v=4"},"body":"Marc Singer wrote:\n\n> That isn't enough.  I did something like that when I was exploring the\n> script.  While the change *does* eliminate the 403 error, it doesn't\n> make the rest of the script work properly.  All of the links return to\n> the same page that lists the projects.\n\nStrange... PATH_INFO is used _only_ if 'p' parameter is not set. And all\nlinks use 'p=$project', not PATH_INFO...\n\nAre you sure you did changes mentioned in earlier post?\n\n-- \nJakub Narebski\nWarsaw, Poland\nShadeHawk on #git\n"},{"id":"24649","messageId":"20060803155603.GS7533@daga.cl","threadId":"5102","inReplyTo":"20060803075403.GA5238@buici.com","subject":"Re: gitweb testing with non-apache web server","fromName":"Blu Corater","fromEmail":"blu@daga.cl","sentAt":"2006-08-03T15:56:03Z","receivedAt":"2006-08-03T15:56:03Z","isPatch":false,"sender":{"key":"blu@daga.cl","avatar":null},"body":"On Thu, Aug 03, 2006 at 12:54:03AM -0700, Marc Singer wrote:\n> I would like to use gitweb with the Cherokee web server because the\n> host that I have on hand has very limited RAM, 32MiB.  Neither the\n> version of gitweb available on Debian (v264) nor the latest in the git\n> repo works.\n> \n> I did some debugging on the latest repo version.  The lines\n> \n>   our $project = ($cgi->param('p') || $ENV{'PATH_INFO'});\n>   if (defined $project) {\n>      ...\n> \n> are being executed even though the url is\n> \n>   http://server/git\n> \n> I think that the problem is that Cherokee translates the request URL\n> into\n> \n>   http://server/git/\n> \n> which means that the $ENV{'PATH_INFO'} is the string \"/\" insted of\n> being undefined.\n> \n> The error I'm seeing is that the request path is forbidden, but I\n> suspect that this is some sort of misunderstanding between the web\n> server and the script.\n\nI am using Cherokee+GitWeb and the behaviour observed is that\nhttp://server/git will return the default Cherokee index page, but\nhttp://server/git/, with a slash at the end, works. \n\n-- \nBlu.\n"},{"id":"24650","messageId":"20060803162038.GA1287@buici.com","threadId":"5102","inReplyTo":"eat5qp$3sr$1@sea.gmane.org","subject":"Re: gitweb testing with non-apache web server","fromName":"Marc Singer","fromEmail":"elf@buici.com","sentAt":"2006-08-03T16:20:38Z","receivedAt":"2006-08-03T16:20:38Z","isPatch":false,"sender":{"key":"elf@buici.com","avatar":null},"body":"On Thu, Aug 03, 2006 at 05:48:11PM +0200, Jakub Narebski wrote:\n> Marc Singer wrote:\n> \n> > That isn't enough.  I did something like that when I was exploring the\n> > script.  While the change *does* eliminate the 403 error, it doesn't\n> > make the rest of the script work properly.  All of the links return to\n> > the same page that lists the projects.\n> \n> Strange... PATH_INFO is used _only_ if 'p' parameter is not set. And all\n> links use 'p=$project', not PATH_INFO...\n> \n> Are you sure you did changes mentioned in earlier post?\n\nYes.  I think that there is something else awry as well.  Note that\nwith the change you suggested, the latest script functions at the same\nlevel as the latest from the repo.\n\nTBPH, I've never found a good way to debug CGI scripts.  I just want\nto see what is going on and that's hard considering the fact that the\nserver behavior seems to be a crucial component.  When I run the\nscript stand-alone, I see the results I expect (with some errors about\nthe CGI object missing some parameters).\n\n\n> \n> -- \n> Jakub Narebski\n> Warsaw, Poland\n> ShadeHawk on #git\n> \n> \n> -\n> To unsubscribe from this list: send the line \"unsubscribe git\" in\n> the body of a message to majordomo@vger.kernel.org\n> More majordomo info at  http://vger.kernel.org/majordomo-info.html\n"},{"id":"24651","messageId":"20060803162241.GB1287@buici.com","threadId":"5102","inReplyTo":"20060803155603.GS7533@daga.cl","subject":"Re: gitweb testing with non-apache web server","fromName":"Marc Singer","fromEmail":"elf@buici.com","sentAt":"2006-08-03T16:22:41Z","receivedAt":"2006-08-03T16:22:41Z","isPatch":false,"sender":{"key":"elf@buici.com","avatar":null},"body":"On Thu, Aug 03, 2006 at 11:56:03AM -0400, Blu Corater wrote:\n> On Thu, Aug 03, 2006 at 12:54:03AM -0700, Marc Singer wrote:\n> > I would like to use gitweb with the Cherokee web server because the\n> > host that I have on hand has very limited RAM, 32MiB.  Neither the\n> > version of gitweb available on Debian (v264) nor the latest in the git\n> > repo works.\n> > \n> > I did some debugging on the latest repo version.  The lines\n> > \n> >   our $project = ($cgi->param('p') || $ENV{'PATH_INFO'});\n> >   if (defined $project) {\n> >      ...\n> > \n> > are being executed even though the url is\n> > \n> >   http://server/git\n> > \n> > I think that the problem is that Cherokee translates the request URL\n> > into\n> > \n> >   http://server/git/\n> > \n> > which means that the $ENV{'PATH_INFO'} is the string \"/\" insted of\n> > being undefined.\n> > \n> > The error I'm seeing is that the request path is forbidden, but I\n> > suspect that this is some sort of misunderstanding between the web\n> > server and the script.\n> \n> I am using Cherokee+GitWeb and the behaviour observed is that\n> http://server/git will return the default Cherokee index page, but\n> http://server/git/, with a slash at the end, works. \n\nWill you share your Cherokee configuration script?\n\nThe links look like this:\n\n  http://scarlet/g?p=bsp.git;a=summary\n\neven when I start with \n\n  http://scarlet/g\n\nor\n\n  http://scarlet/g/\n\nSo, I'm not sure I understand what you are saying.\n\n> \n> -- \n> Blu.\n> -\n> To unsubscribe from this list: send the line \"unsubscribe git\" in\n> the body of a message to majordomo@vger.kernel.org\n> More majordomo info at  http://vger.kernel.org/majordomo-info.html\n"},{"id":"24654","messageId":"7vfygdr888.fsf@assigned-by-dhcp.cox.net","threadId":"5102","inReplyTo":"eat5qp$3sr$1@sea.gmane.org","subject":"Re: gitweb testing with non-apache web server","fromName":"Junio C Hamano","fromEmail":"junkio@cox.net","sentAt":"2006-08-03T18:21:11Z","receivedAt":"2006-08-03T18:21:11Z","isPatch":false,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Jakub Narebski <jnareb@gmail.com> writes:\n\n> Marc Singer wrote:\n>\n>> That isn't enough.  I did something like that when I was exploring the\n>> script.  While the change *does* eliminate the 403 error, it doesn't\n>> make the rest of the script work properly.  All of the links return to\n>> the same page that lists the projects.\n>\n> Strange... PATH_INFO is used _only_ if 'p' parameter is not set. And all\n> links use 'p=$project', not PATH_INFO...\n>\n> Are you sure you did changes mentioned in earlier post?\n\nWell, more importantly, why would we do something like this in the first \nplace?\n\nWouldn't it be a lot better to just rip out PATH_INFO stuff,\nespecially since all pages the script generates use ?p=$project \nto pass that information around and never uses PATH_INFO?\n"},{"id":"24657","messageId":"eatfog$8er$1@sea.gmane.org","threadId":"5102","inReplyTo":"7vfygdr888.fsf@assigned-by-dhcp.cox.net","subject":"Re: gitweb testing with non-apache web server","fromName":"Jakub Narebski","fromEmail":"jnareb@gmail.com","sentAt":"2006-08-03T18:37:39Z","receivedAt":"2006-08-03T18:37:39Z","isPatch":false,"sender":{"key":"jnareb@gmail.com","avatar":"https://avatars.githubusercontent.com/u/2706?v=4"},"body":"Junio C Hamano wrote:\n\n> Jakub Narebski <jnareb@gmail.com> writes:\n>\n>>\n>> Strange... PATH_INFO is used _only_ if 'p' parameter is not set. And all\n>> links use 'p=$project', not PATH_INFO...\n>>\n>> Are you sure you did changes mentioned in earlier post?\n> \n> Well, more importantly, why would we do something like this in the first \n> place?\n> \n> Wouldn't it be a lot better to just rip out PATH_INFO stuff,\n> especially since all pages the script generates use ?p=$project \n> to pass that information around and never uses PATH_INFO?\n\nThe PATH_INFO is here because it is easier to edit parameters by hand when\nthe most important one, the project to examine, can be passed as PATH_INFO.\n\n-- \nJakub Narebski\nWarsaw, Poland\nShadeHawk on #git\n"},{"id":"24661","messageId":"20060803192152.GT7533@daga.cl","threadId":"5102","inReplyTo":"20060803162241.GB1287@buici.com","subject":"Re: gitweb testing with non-apache web server","fromName":"Blu Corater","fromEmail":"blu@daga.cl","sentAt":"2006-08-03T19:21:52Z","receivedAt":"2006-08-03T19:21:52Z","isPatch":false,"sender":{"key":"blu@daga.cl","avatar":null},"body":"On Thu, Aug 03, 2006 at 09:22:41AM -0700, Marc Singer wrote:\n> On Thu, Aug 03, 2006 at 11:56:03AM -0400, Blu Corater wrote:\n> > On Thu, Aug 03, 2006 at 12:54:03AM -0700, Marc Singer wrote:\n> > > I would like to use gitweb with the Cherokee web server because the\n> > > host that I have on hand has very limited RAM, 32MiB.  Neither the\n> > > version of gitweb available on Debian (v264) nor the latest in the git\n> > > repo works.\n> > > \n> > > I did some debugging on the latest repo version.  The lines\n> > > \n> > >   our $project = ($cgi->param('p') || $ENV{'PATH_INFO'});\n> > >   if (defined $project) {\n> > >      ...\n> > > \n> > > are being executed even though the url is\n> > > \n> > >   http://server/git\n> > > \n> > > I think that the problem is that Cherokee translates the request URL\n> > > into\n> > > \n> > >   http://server/git/\n> > > \n> > > which means that the $ENV{'PATH_INFO'} is the string \"/\" insted of\n> > > being undefined.\n> > > \n> > > The error I'm seeing is that the request path is forbidden, but I\n> > > suspect that this is some sort of misunderstanding between the web\n> > > server and the script.\n> > \n> > I am using Cherokee+GitWeb and the behaviour observed is that\n> > http://server/git will return the default Cherokee index page, but\n> > http://server/git/, with a slash at the end, works. \n> \n> Will you share your Cherokee configuration script?\n> \n> The links look like this:\n> \n>   http://scarlet/g?p=bsp.git;a=summary\n> \n> even when I start with \n> \n>   http://scarlet/g\n> \n> or\n> \n>   http://scarlet/g/\n> \n> So, I'm not sure I understand what you are saying.\n\nHere is the interesting part of my cherokee.conf\n\n------------------------------------------\nUserDir public_html {\n    Directory / {\n       Handler common\n    }\n\n    Directory /scm/ {\n        Handler cgi {\n                ScriptAlias /home/blu/bin/gitweb.cgi\n        }\n    }\n}\n-----------------------------------------\n\nSo, I have the gitweb.cgi executable in a bin directory on my home and I\nam telling Cherokee that when it sees the url http://server/~blu/scm/, it\nshould execute /home/blu/bin/gitweb.cgi\n\nIf I request http://server/~blu/scm, Cherokee returns Cherokee's default\nindex page. Only if I request http://server/~blu/scm/, Cherokee returns\nthe expected output from gitweb.\n\nNow, if I add \n\n    Directory /test/ {\n\tHandler cgi\n    }\n\nAnd copy gitweb.cgi to ~/public_html/test/, it seems there is no problem.\n\nI can request http://server/~blu/test/gitweb.cgi or\nhttp://server/~blu/test/gitweb.cgi/ and get the expected gitweb output.\n\nIt looks more like a Cherokee problem to me, but I don't have time to\ninvestigate further right now.\n\n-- \nBlu.\n"},{"id":"24664","messageId":"7virl9ppy7.fsf@assigned-by-dhcp.cox.net","threadId":"5102","inReplyTo":"eatfog$8er$1@sea.gmane.org","subject":"Re: gitweb testing with non-apache web server","fromName":"Junio C Hamano","fromEmail":"junkio@cox.net","sentAt":"2006-08-03T19:41:20Z","receivedAt":"2006-08-03T19:41:20Z","isPatch":false,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Jakub Narebski <jnareb@gmail.com> writes:\n\n> Junio C Hamano wrote:\n>\n>> Well, more importantly, why would we do something like this in the first \n>> place?\n>> \n>> Wouldn't it be a lot better to just rip out PATH_INFO stuff,\n>> especially since all pages the script generates use ?p=$project \n>> to pass that information around and never uses PATH_INFO?\n>\n> The PATH_INFO is here because it is easier to edit parameters by hand when\n> the most important one, the project to examine, can be passed as PATH_INFO.\n\nHuh?  I do not get that.\n\nSuppose I am looking at my repository.  I visit there from my\nFirefox and see this in the location bar:\n\n\thttp://www.kernel.org/git/?p=git/git.git;a=summary\n\nNow I would want to check if there are updates to gitk.  So I\nclick on the location bar, and edit it to:\n\n\thttp://www.kernel.org/git/?p=gitk/gitk.git;a=summary\n\n(that's two insertions of 'k').\n\nNow with PATH_INFO, how exactly is this easier?\n"},{"id":"24665","messageId":"20060803201434.GB5476@admingilde.org","threadId":"5102","inReplyTo":"7virl9ppy7.fsf@assigned-by-dhcp.cox.net","subject":"Re: gitweb testing with non-apache web server","fromName":"Martin Waitz","fromEmail":"tali@admingilde.org","sentAt":"2006-08-03T20:14:34Z","receivedAt":"2006-08-03T20:14:34Z","isPatch":false,"sender":{"key":"tali@admingilde.org","avatar":"https://gravatar.com/avatar/3f89b03eee362187effabe257898735b475673a12265c398ea9161259ae91553?d=mp&s=160"},"body":"hoi :)\n\nOn Thu, Aug 03, 2006 at 12:41:20PM -0700, Junio C Hamano wrote:\n> \thttp://www.kernel.org/git/?p=gitk/gitk.git;a=summary\n> \n> (that's two insertions of 'k').\n> \n> Now with PATH_INFO, how exactly is this easier?\n\nwell, editing is not easier, but you can do other nice things.\n\nOn git.admingilde.org I have set up apache to serve the contents\nof my git repositories for all the well-known git repository\nURLs (*.git/objects/*, *.git/refs/*, ...) and to call gitweb for\nall other URLs.\nThat way I get the exact same URLs for both gitweb and http:// clone\n(and even for git://, just change the protocol name).\n\nI really think that it is very handy that you can give out a\nrepository URL and any user can just click on it and get the\nsummary page of this project.\n\nI'm sure that it is possible to transfer the PATH_INFO into a p=\nparameter through URL rewrite rules, but it is much easier\nto set up if gitweb can directly grok appended paths.\n\nI even changed the old gitweb to hand out links which used PATH_INFO\nrather than the p= parameter so that the URLs looked nicer.\nIf there is interest in such a feature then I can do these changes\nagain.\n\n-- \nMartin Waitz\n"},{"id":"24666","messageId":"20060803202703.GA13147@buici.com","threadId":"5102","inReplyTo":"20060803192152.GT7533@daga.cl","subject":"Re: gitweb testing with non-apache web server","fromName":"Marc Singer","fromEmail":"elf@buici.com","sentAt":"2006-08-03T20:27:03Z","receivedAt":"2006-08-03T20:27:03Z","isPatch":false,"sender":{"key":"elf@buici.com","avatar":null},"body":"On Thu, Aug 03, 2006 at 03:21:52PM -0400, Blu Corater wrote:\n> Here is the interesting part of my cherokee.conf\n> \n> ------------------------------------------\n> UserDir public_html {\n>     Directory / {\n>        Handler common\n>     }\n> \n>     Directory /scm/ {\n>         Handler cgi {\n>                 ScriptAlias /home/blu/bin/gitweb.cgi\n>         }\n>     }\n> }\n> -----------------------------------------\n> \n> So, I have the gitweb.cgi executable in a bin directory on my home and I\n> am telling Cherokee that when it sees the url http://server/~blu/scm/, it\n> should execute /home/blu/bin/gitweb.cgi\n> \n> If I request http://server/~blu/scm, Cherokee returns Cherokee's default\n> index page. Only if I request http://server/~blu/scm/, Cherokee returns\n> the expected output from gitweb.\n> \n> Now, if I add \n> \n>     Directory /test/ {\n> \tHandler cgi\n>     }\n> \n> And copy gitweb.cgi to ~/public_html/test/, it seems there is no problem.\n> \n> I can request http://server/~blu/test/gitweb.cgi or\n> http://server/~blu/test/gitweb.cgi/ and get the expected gitweb output.\n> \n> It looks more like a Cherokee problem to me, but I don't have time to\n> investigate further right now.\n\nHmm.  I was hopeful when I saw that your configuration was different\nfrom mine.  However, it seems to be something else.  BTW, I'm running\ncherokee on ARM.\n\n========================================\nDirectory / {\n    Handler common\n}\n\nDirectory /g/ {\n    Handler cgi {\n        Scriptalias /usr/lib/cgi-bin/git.cgi\n    }\n}\nDirectory /git/ {\n    Handler cgi {\n        Scriptalias /usr/lib/cgi-bin/gitweb.cgi\n    }\n}\n========================================\n\ngitweb.cgi is an old version.  git.cgi is the latest release.\n\nI can see the project overview page, but all of the links bring me\nback to the same top-level page, no summary, not logs.  I've verified\nthat the web server's user can read the git repo. \n\nI don't doubt that this is a cherokee issue.\n\nCheers.\n"},{"id":"24672","messageId":"20060803235536.GJ17966@craic.sysops.org","threadId":"5102","inReplyTo":"20060803202703.GA13147@buici.com","subject":"Re: gitweb testing with non-apache web server","fromName":"Francis Daly","fromEmail":"francis@daoine.org","sentAt":"2006-08-03T23:55:36Z","receivedAt":"2006-08-03T23:55:36Z","isPatch":false,"sender":{"key":"francis@daoine.org","avatar":null},"body":"> Marc Singer wrote: \n> On Thu, Aug 03, 2006 at 03:21:52PM -0400, Blu Corater wrote:\n\nHi there,\n\n> > If I request http://server/~blu/scm, Cherokee returns Cherokee's default\n> > index page. Only if I request http://server/~blu/scm/, Cherokee returns\n> > the expected output from gitweb.\n\nThis is due to one apparent bug in Cherokee's Directory handling.\n\n> I can see the project overview page, but all of the links bring me\n> back to the same top-level page, no summary, not logs.  I've verified\n> that the web server's user can read the git repo. \n\nAnd this is due a a different, but arguably related, one.  (The 301\nhandler ignores things it shouldn't.)\n\n> I don't doubt that this is a cherokee issue.\n\nCherokee's handling of both Directory and Request sections with cgi and\nScriptalias seems a bit funky (in different ways).  If you want to use\nCherokee configured this way, you may find it handy to add\n\n$my_uri .= '/';\n\nto your version of gitweb.cgi shortly after it is set -- that should\nbreak most of the generated links in a way that causes them to work with\nthis server.\n\n$my_url is only used in a few places, but it may be worth doing the same\nthing to it too.\n\nOr use a web server which isn't broken in this particular way.\n\nGood luck,\n\n\tf\n-- \nFrancis Daly        francis@daoine.org\n"},{"id":"24690","messageId":"20060804061122.GA15755@buici.com","threadId":"5102","inReplyTo":"20060803235536.GJ17966@craic.sysops.org","subject":"Re: gitweb testing with non-apache web server","fromName":"Marc Singer","fromEmail":"elf@buici.com","sentAt":"2006-08-04T06:11:22Z","receivedAt":"2006-08-04T06:11:22Z","isPatch":false,"sender":{"key":"elf@buici.com","avatar":null},"body":"On Fri, Aug 04, 2006 at 12:55:36AM +0100, Francis Daly wrote:\n> > Marc Singer wrote: \n> > On Thu, Aug 03, 2006 at 03:21:52PM -0400, Blu Corater wrote:\n> \n> Hi there,\n> \n> > > If I request http://server/~blu/scm, Cherokee returns Cherokee's default\n> > > index page. Only if I request http://server/~blu/scm/, Cherokee returns\n> > > the expected output from gitweb.\n> \n> This is due to one apparent bug in Cherokee's Directory handling.\n> \n> > I can see the project overview page, but all of the links bring me\n> > back to the same top-level page, no summary, not logs.  I've verified\n> > that the web server's user can read the git repo. \n> \n> And this is due a a different, but arguably related, one.  (The 301\n> handler ignores things it shouldn't.)\n> \n> > I don't doubt that this is a cherokee issue.\n> \n> Cherokee's handling of both Directory and Request sections with cgi and\n> Scriptalias seems a bit funky (in different ways).  If you want to use\n> Cherokee configured this way, you may find it handy to add\n> \n> $my_uri .= '/';\n> to your version of gitweb.cgi shortly after it is set -- that should\n> break most of the generated links in a way that causes them to work with\n> this server.\n> \n> $my_url is only used in a few places, but it may be worth doing the same\n> thing to it too.\n\nThat does it.  \n\n> \n> Or use a web server which isn't broken in this particular way.\n\n:-) There doesn't seem to be much of the 'small' variety.  Though now\nI'll look into lighttpd as well.\n\n> \n> Good luck,\n\nCheers.\n"},{"id":"24691","messageId":"20060804073039.GA20417@buici.com","threadId":"5102","inReplyTo":"20060803235536.GJ17966@craic.sysops.org","subject":"Re: gitweb testing with non-apache web server","fromName":"Marc Singer","fromEmail":"elf@buici.com","sentAt":"2006-08-04T07:30:39Z","receivedAt":"2006-08-04T07:30:39Z","isPatch":false,"sender":{"key":"elf@buici.com","avatar":null},"body":"I found that lighttpd works well, though the configuration was a\nlittle more complex.\n\nThe recipe that works well is to make the URL\n\n  http://server/git\n\nto the gitweb.cgi script.  I put the script and the CSS file in a\ndirectory, /var/lib/git/, and then put the following into the lighttpd\nconfiguration:\n\n  # Serve GIT\n  url.redirect    = ( \"^/git$\" => \"/git/\" )\n  alias.url       += ( \"/git/\" => \"/var/lib/git/\" )\n  $HTTP[\"url\"]    =~ \"^/git/\" {\n    cgi.assign            = ( \".cgi\" => \"\" )\n    index-file.names      = ( \"gitweb.cgi\" )\n  }\n\nCheers.\n"},{"id":"24741","messageId":"20060804194840.GM17966@craic.sysops.org","threadId":"5102","inReplyTo":"20060804061122.GA15755@buici.com","subject":"Re: gitweb testing with non-apache web server","fromName":"Francis Daly","fromEmail":"francis@daoine.org","sentAt":"2006-08-04T19:48:40Z","receivedAt":"2006-08-04T19:48:40Z","isPatch":false,"sender":{"key":"francis@daoine.org","avatar":null},"body":"On Thu, Aug 03, 2006 at 11:11:22PM -0700, Marc Singer wrote:\n> On Fri, Aug 04, 2006 at 12:55:36AM +0100, Francis Daly wrote:\n\n> > Or use a web server which isn't broken in this particular way.\n> \n> :-) There doesn't seem to be much of the 'small' variety.  Though now\n> I'll look into lighttpd as well.\n\nI've had some success with thttpd, which is broken in a different way\nwhich doesn't appear to affect gitweb.\n\n$ cp gitweb.cgi g\n$ thttpd -p 8080 -d . -c '/g' \n$ $BROWSER http://localhost:8080/g\n\nfor example.  Adjust the config to fit your overall site need, of course.\n\n-h localhost, or -l /dev/null, or -D, may also be useful.  There's a Fine\nManual out there.\n\nGood luck,\n\n\tf\n-- \nFrancis Daly        francis@daoine.org\n"}]}