All of lore.kernel.org
 help / color / mirror / Atom feed
From: Ralf Baechle <ralf@linux-mips.org>
To: git@vger.kernel.org
Subject: Issue with git clone via http/https and alternates
Date: Thu, 9 Dec 2021 20:59:14 +0100	[thread overview]
Message-ID: <YbJgEnvuKm+GGXkd@linux-mips.org> (raw)

I'm hosting a number of largish repositories which being very similar
are using git's alternates feature to save disk and memory.  Cloning via
git:// or ssh for users with accounts on the server works as expected but
cloning via http or https results fails as follows:

$ git clone http://git.linux-mips.org/pub/scm/linux-mti.git
Cloning into 'linux-mti'...
warning: alternate disabled by http.followRedirects: http://git.linux-mips.org/pub/scm/ralf/linux.git/
error: Unable to find e4add961d4aaeb19f607f6d7bea8d59e1bd39ff0 under http://git.linux-mips.org/pub/scm/linux-mti.git
Fetching objects: 11, done.
Cannot obtain needed object e4add961d4aaeb19f607f6d7bea8d59e1bd39ff0
while processing commit 9e2bf7cf7d9003c0f06736be5218ed79234f254c.
error: fetch failed.

Adding -c http.followRedirects=true will make the clone succeed. Question,
shouldn't the default of http.followRedirects=initial already suffice?

Anyway, what I'm looking for is something I can do serverside so users
cloning the repository are not bothered with this http.followRedirects
business.  Is there anything I can do?

Thanks,

  Ralf

             reply	other threads:[~2021-12-09 19:59 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-12-09 19:59 Ralf Baechle [this message]
2021-12-10  4:08 ` Issue with git clone via http/https and alternates Jeff King

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=YbJgEnvuKm+GGXkd@linux-mips.org \
    --to=ralf@linux-mips.org \
    --cc=git@vger.kernel.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.