9fans - fans of the OS Plan 9 from Bell Labs
 help / color / mirror / Atom feed
From: "Frank D. Engel, Jr." <fde101@fjrhome.net>
To: 9fans@9fans.net
Subject: Re: [9fans] 9front, git and mercurial.
Date: Wed, 18 May 2022 14:12:47 -0400	[thread overview]
Message-ID: <1275338a-65f0-61c2-8162-ba7c93fa2493@fjrhome.net> (raw)
In-Reply-To: <89F3ABF218EE52FAE7605F9B07728487@eigenstate.org>

Related question I can't seem to track down an answer to:

I have a 9front cluster which was set up back when Mercurial was used, 
so that is what sysupdate is looking for.

I finally realized that I am no longer seeing updates because 9front 
switched to git.

How does one go about upgrading an existing 9front install to pull 
updates from git instead of hg?

When I try running the manual commands to pull from git it (logically) 
complains that it is not a git repository, but I am not finding any 
clear instructions on how to go about making this switch on an existing 
install?


On 6/14/21 3:13 PM, ori@eigenstate.org wrote:
> Quoth Tony Mendoza <clueelf@tonymendoza.us>:
>> Quick question (or maybe not), but how are these being hosted?   Is this done on a cloud provider vm platform?   Or is this being done in a traditional DC using real hardware?
>>
>> Just curious to know how this is being done because I would like to do something similar.
> Currently, it's hosted on vultr, but there are
> a number of hosts that you can use.
>
> As far as how it's actually done:
>
> Git goes over git/serve in /rc/bin/service:
>
>          cpu% cat /rc/bin/service/tcp9418
>          #!/bin/rc
>          exec git/serve -r/usr/git
>
> the '-r' path is implicitly prepended on to
> any repositories that are cloned, so eg:
>
>          git/clone git://host.com/repo/path
>
> clones
>
>          /usr/git/repo/path
>
> The authenticated protocol, hjgit, is the same
> as the unauthenticated git:// protocol, but with
> 'tlssrv -a' wrapping the connection to handle auth
> and encryption. The '-w' flag on git/serve enables
> writing to the repo.
>
>          cpu% cat /rc/bin/service/tcp17021
>          #!/bin/rc
>          exec tlssrv -a /bin/git/serve -wr/usr/git
>
> Our encrypted 'gits://' extension is the same,
> but with a cert, and its key in factotum:
>
>          cpu% cat /rc/bin/service/tcp9419
>          #!/bin/rc
>          exec tlssrv -c/sys/lib/tls/git/git.cert /bin/git/serve -r/usr/git
>
> That gets you a fully functional git server,
> that hosts its code in /usr/git.
>
> The website is served using tcp80 and execfs:
>
>          cpu% cat /bin/cpurc.local
>          auth/none execfs -s git.execfs /sys/lib/tcp80/gitrules
>
>          cpu% cat /rc/bin/service/tcp80
>          #!/bin/rc
>          # some ns trickery to allow serving static data,
>          # we can probably clean this up.
> bind /usr/web /mnt/static
> mount /srv/git.execfs /usr/web
> bind /mnt/static /usr/web/static
> rfork n
> exec /bin/tcp80
> 
> And the code for the web ui is more or less a modified
> version of this code:
> 
> http://shithub.us/ori/shithub/HEAD/files.html
> 
> There's also a more minimal proof of concept that I
> did before phil9 ran with it and improved it here:
> 
> http://shithub.us/ori/git9/HEAD/extra/gitls/f.html
> 
> It's less complete, but probably easier to read and
> understand.
> 

------------------------------------------
9fans: 9fans
Permalink: https://9fans.topicbox.com/groups/9fans/T7dfa66085e395bcb-M7a7dc8eefad0d619ba65c04a
Delivery options: https://9fans.topicbox.com/groups/9fans/subscription

  reply	other threads:[~2022-05-18 18:13 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-06-14  0:47 ori
2021-06-14 17:48 ` Tony Mendoza
2021-06-14 17:55   ` Kurt H Maier
2021-06-14 19:13   ` ori
2022-05-18 18:12     ` Frank D. Engel, Jr. [this message]
2022-05-18 18:30       ` Kurt H Maier via 9fans
2022-05-18 19:41         ` Frank D. Engel, Jr.

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=1275338a-65f0-61c2-8162-ba7c93fa2493@fjrhome.net \
    --to=fde101@fjrhome.net \
    --cc=9fans@9fans.net \
    /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).