Score:0

Alias custom domain to GitHub repository for git clone

ir flag

What I'm trying to do is setup a custom domain name so that it can be cloned as a git repository using git clone.
For example,

$ git clone https://my-domain-name.tld/ # would be cloned into my-domain-name.tld
# and
$ git clone https://my-domain-name.tld/my-repository # would be cloned into my-repository

I don't actually want to host the repository itself on my server, I just want to configure the DNS (hopefully that's all that's required) so that it will point any requests git clone makes to GitHub, where the repositories in question are actually hosted.

I'm not sure if git clone https://my-domain-name.tld/ without anything after that (so no path in the URL) would work, but since git clone https://github.com/<user>/<repo> works I figured it must at least be possible for git clone https://not-github.com/<repo> to work.

Sergey92zp avatar
in flag
not sure it possible via dns only, theoretically you can achieve that via reverse proxy , but you still need some VPS as middleware. You can configure nginx or any other reverse proxy there.
I sit in a Tesla and translated this thread with Ai:

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.