git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jeff King <peff@peff.net>
To: Sebastian Schmidt <isibboi@gmail.com>
Cc: Matthieu Moy <Matthieu.Moy@grenoble-inp.fr>, git@vger.kernel.org
Subject: Re: Git over HTTPS with basic authentication
Date: Fri, 19 Apr 2013 11:36:39 -0400	[thread overview]
Message-ID: <20130419153639.GA14263@sigill.intra.peff.net> (raw)
In-Reply-To: <1366361766.3873.4.camel@sibbo-laptop>

On Fri, Apr 19, 2013 at 10:56:06AM +0200, Sebastian Schmidt wrote:

> I tried switching to smart http now, but have the same error, I guess I
> did something wrong. It seems like it is getting 401, but I also noticed
> that info/refs is just an empty file. This is the config of my apache2:
> 
> SetEnv GIT_PROJECT_ROOT /crypt/git
> SetEnv GIT_HTTP_EXPORT_ALL
> ScriptAlias /git/ /usr/lib/git

This should point to /usr/lib/git/git-http-backend, which I think is the
source of your problems.

> <Directory /crypt/git>
> 	Allow from all
> 	Order deny,allow
> 	
> 	AuthType Basic
> 	AuthName "Git global"
> 	AuthUserFile /etc/apache2/auth/passwd
> 	AuthGroupFile /etc/apache2/auth/groups
> 	
> 	Require group git-shared
> </Directory>

I'm not sure this <Directory> match will do what you want, because from
Apache's perspective, it is hitting /usr/lib/git/git-http-backend on the
filesystem, and it is only git that actually touches the filesystem.

I think you want to use

  <Location /git>
     ...
  </Location>

instead. But I am not an Apache expert, so maybe it does work.

-Peff

      parent reply	other threads:[~2013-04-19 15:36 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-04-18 19:47 Git over HTTPS with basic authentication Sebastian Schmidt
2013-04-18 19:54 ` Matthieu Moy
2013-04-18 20:43   ` Jeff King
     [not found]     ` <1366361766.3873.4.camel@sibbo-laptop>
2013-04-19 15:36       ` Jeff King [this message]

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=20130419153639.GA14263@sigill.intra.peff.net \
    --to=peff@peff.net \
    --cc=Matthieu.Moy@grenoble-inp.fr \
    --cc=git@vger.kernel.org \
    --cc=isibboi@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).