~sircmpwn/sr.ht-docs

534892162f20a615fc385a8cc5e691ef0daa2f98 — Drew DeVault 4 years ago 4eeddf1
Add http(s) clone details for hg.sr.ht install
1 files changed, 18 insertions(+), 0 deletions(-)

M hg.sr.ht/installation.md
M hg.sr.ht/installation.md => hg.sr.ht/installation.md +18 -0
@@ 34,3 34,21 @@ favorite cron daemon. We recommend the following crontab:

    */20 * * * * hgsrht-periodic

## HTTP(s) Cloning

hg.sr.ht does not do this for you - you need to wire it up in nginx. Here's an
example config:

```nginx
location = /authorize {
		proxy_pass http://127.0.0.1:5001;
		proxy_pass_request_body off;
		proxy_set_header Content-Length "";
		proxy_set_header X-Original-URI $request_uri;
}

location ~ ^/[~^][a-z0-9_]+/[a-zA-Z0-9_.-]+/\.hg.*$ {
		auth_request /authorize;
		root /var/lib/mercurial;
}
```