unofficial mirror of meta@public-inbox.org
 help / color / mirror / Atom feed
From: "W. Trevor King" <wking@tremily.us>
To: Eric Wong <e@80x24.org>
Cc: notmuch@notmuchmail.org, David Bremner <david@tethera.net>,
	Steven Allen <steven@stebalien.com>,
	Tomi Ollila <tomi.ollila@iki.fi>, Carl Worth <cworth@cworth.org>,
	meta@public-inbox.org
Subject: Re: Mail archives in Git using ssoma (Docker image)
Date: Sun, 21 Aug 2016 10:36:00 -0700	[thread overview]
Message-ID: <20160821173600.GB30347@odin.tremily.us> (raw)
In-Reply-To: <20160821120852.GA12964@dcvr>

[-- Attachment #1: Type: text/plain, Size: 4424 bytes --]

On Sun, Aug 21, 2016 at 12:08:52PM +0000, Eric Wong wrote:
> "W. Trevor King" <wking@tremily.us> wrote:
> > This is the ssoma archive (with the data in it).  I just set up a
> > basic HTTP archive (following [1]) based on a Docker image [2] (Gentoo
> > doesn't package all the Perl dependencies public-inbox needs).
> 
> Ugh, that sucks (sorry, not a fan of Docker).
> 
> What's missing from Gentoo?

Gentoo doesn't package (or I couldn't find the package for)
Encode::MIME::Header or Mail::Thread.  I tried installing things from
CPAN, but ran into a compile-time error from the ‘cpan’ invocationand
gave up ;).  I can try and reproduce the error if you're curious, but
I don't have it handy at the moment.

> >   $ git config -f srv/notmuch.git/config publicinbox.http http://tremily.us
> >   $ git config -f srv/notmuch.git/config publicinbox.email notmuch@notmuchmail.org
> 
> That should probably be:
> 
> 	; based on your [3]
> 	git config -f srv/notmuch.git/config \
> 		publicinbox.notmuch.url http://tremily.us/notmuch
> 
> 	git config -f srv/notmuch.git/config \
> 		publicinbox.notmuch.address notmuch@notmuchmail.org
> 
> 	; this is crucial for all the public-inbox-* tools
> 	git config -f srv/notmuch.git/config \
> 		publicinbox.notmuch.mainrepo /path/to/notmuch.git

I was using these in the Dockerfile's CMD:

  (cd /srv;
   for NAME in *;
   do
     CONF="/srv/${NAME}/config";
     public-inbox-init "${NAME}" "/srv/${NAME}" $(git config -f "${CONF}" publicinbox.http) $(git config -f "${CONF}" publicinbox.email);
   done) && …

Are you saying that I can skip the ~/.public-inbox/config entries
setup by public-inbox-init if I set publicinbox.{name}.* in the ssoma
repository's config?  That would be nice.

I don't see a point to having {name} in ssoma-config settings though,
since you're already in a single bucket by that point (using
publicinbox.{name}.* makes sense in the multi-bucket
~/.public-inbox/config).

> > It's not updating automatically yet, but that will probably look
> > like:
> > 
> > 1. Pull new mbox [4].
> > 2. Import into notmuch-archives [5].
> > 3. Re-run public-inbox-index (this could probably be via ‘docker exec …’.
> > 
> > But I'll have to test that to confirm.  And ideally we'd be using
> > ssoma-mda or similar directly, instead of going through mbox, but I'd
> > rather get the official headers on the stored mail than be efficient
> > ;).
> 
> For mirroring existing lists, I started using public-inbox-watch
> which currently watches Maildirs.

If I had a Maildir locally, I'd just use procmail and push new
messages into ssoma-mda.  I'm using the import script because my local
mail has “how we delivered this to Trevor” headers (which I don't want
to add) but the downloaded mbox has “how we delivered this to
notmuch@notmuchmail.org” (which seems like a better fit for a shared
ssoma repo).

> I recommend public-inbox-watch for mirroring existing lists (such as
> what I did with git@vger) but public-inbox-mda for self-hosted lists
> (such as meta@public-inbox.org).

Why is that?  Procmail + public-inbox-mda (or my Python ssoma-mda fork
[1,2]) seems simpler and equally effective if you want to insert a
message that your mail system is delivering locally.

> > One shift from Gmane's mid.gmane.org/… is that the public-inbox UI
> > Message-ID lookup is per-bucket, and public-inbox seems to be
> > encouraging per-list buckets.
> 
> The public-inbox-nntpd interface supports mid lookups across all
> inboxes in that instance; so it should be doable in the WWW
> interface, too.  Either way, I think it has to be O(n) where (n) is
> the number of Xapian DBs, though.

I'm more concerned about the interface, and less about the
implementation (which can be improved later).  The (n) lookups are
trivially parallelizable, and you can always add a Message-ID →
buckets lookup table if (n) lookups turns out to be too slow.

Cheers,
Trevor

[1]: id:20141107190321.GL23609@odin.tremily.us
[2]: id:af679af8257e250ac606e35a1307ad02907b8426.1413663212.git.wking@tremily.us
     http://public-inbox.org/meta/af679af8257e250ac606e35a1307ad02907b8426.1413663212.git.wking@tremily.us/t/#u

-- 
This email may be signed or encrypted with GnuPG (http://www.gnupg.org).
For more information, see http://en.wikipedia.org/wiki/Pretty_Good_Privacy

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 819 bytes --]

  reply	other threads:[~2016-08-21 17:38 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20141107190321.GL23609@odin.tremily.us>
     [not found] ` <20160821043631.GA2338@odin.tremily.us>
     [not found]   ` <20160821094833.GB2338@odin.tremily.us>
2016-08-21 12:08     ` Mail archives in Git using ssoma (Docker image) Eric Wong
2016-08-21 17:36       ` W. Trevor King [this message]
2016-08-21 18:28         ` Eric Wong
     [not found]   ` <20160821183704.GB11495@dcvr>
2016-08-21 20:28     ` Mail archives in Git using ssoma W. Trevor King
2016-08-21 21:14       ` Eric Wong

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

  List information: https://public-inbox.org/README

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20160821173600.GB30347@odin.tremily.us \
    --to=wking@tremily.us \
    --cc=cworth@cworth.org \
    --cc=david@tethera.net \
    --cc=e@80x24.org \
    --cc=meta@public-inbox.org \
    --cc=notmuch@notmuchmail.org \
    --cc=steven@stebalien.com \
    --cc=tomi.ollila@iki.fi \
    /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 read-only IMAP folder(s) and NNTP newsgroup(s).