From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on dcvr.yhbt.net X-Spam-Level: X-Spam-ASN: X-Spam-Status: No, score=-3.2 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_PASS,SPF_PASS shortcircuit=no autolearn=ham autolearn_force=no version=3.4.2 Received: from libre-riscv.org (libre-riscv.org [IPv6:2a00:1098:82:f::1]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dcvr.yhbt.net (Postfix) with ESMTPS id BA9661F619 for ; Thu, 19 Mar 2020 09:41:34 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=libre-riscv.org; s=201607131; h=Content-Type:Cc:To:Subject:Message-ID:Date: From:In-Reply-To:References:MIME-Version:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=as4hCiYru/JKPsqXO3Nr+EFg2nOXJPnFnT7ddgIOq2g=; b=SO3vEcMgL3CO0PaPAHAsGhB67 dZcnOXjv6PxHvaMt0M3INQpbbxF6mvnvUs6nH2WuYjq72emgOsV688DUczKx0ZC8xF6ssZseJnbsw EhQUt+TlGLyFl0Aeq/fE+O+JPaF31o5ed4Qvb8NPhQfx5yjGF4dwIhReEDAPvqLLSBbBo=; Received: from mail-lj1-f181.google.com ([209.85.208.181]) by libre-riscv.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.89) (envelope-from ) id 1jErgC-0005ho-3d for meta@public-inbox.org; Thu, 19 Mar 2020 09:41:32 +0000 Received: by mail-lj1-f181.google.com with SMTP id u12so1694665ljo.2 for ; Thu, 19 Mar 2020 02:41:31 -0700 (PDT) X-Gm-Message-State: ANhLgQ1Gxi1pO1l7TKSpxSZEHIxrEEELsZUo9EVx/BIISgHs0Cem7Iti VPVyp2gzIKMsKdoUtQiFdSyRxb8Zk446oiYfhH4= X-Google-Smtp-Source: ADFU+vuMjMO9xAzkHckKD89+fLPy1Yye80qtJiXSbx5B4HWF2kGXhMBjWRQ4c34ZRSoLGT1dijsF5Hj4qy/SMx36M1A= X-Received: by 2002:a2e:81cc:: with SMTP id s12mr1626934ljg.35.1584610891187; Thu, 19 Mar 2020 02:41:31 -0700 (PDT) MIME-Version: 1.0 References: <20200319030634.GA5768@dcvr> In-Reply-To: <20200319030634.GA5768@dcvr> From: lkcl Date: Thu, 19 Mar 2020 09:41:19 +0000 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: up and running, integrated with exim4 mta To: Eric Wong Cc: "meta@public-inbox.org" Content-Type: text/plain; charset="UTF-8" List-Id: On Thu, Mar 19, 2020 at 3:06 AM Eric Wong wrote: > > lkcl wrote: > > hi eric we have things running, hooray, i thought you might appreciate > > it is a little different > > http://inbox.libre-riscv.org/libre-riscv-dev/new.html > > Good to know! Btw, if you have DBD::SQLite (and optionally, > Search::Xapian), you can run `public-inbox-index $INBOX_DIR' > to get message threading and search enabled. ah excellent and that just kicks it in, and mda picks it up (continuously) from there. excellent, that looks better: http://inbox.libre-riscv.org/libre-riscv-dev > > http://bugs.libre-riscv.org/show_bug.cgi?id=181 > > > > here are attachments for *direct* integration into exim4. rather than > > store in Maildir we have a use subscribed to the mailman2 list, where > > in the exim4 configs we specifically look out for that user and > > run a pipe to public-inbox-mda > > Cool, hope that helps other folks using exim4. it would do just as well without mailman2, by just manually naming the "list" as the incoming email in the exim4 configs. we chose that incoming email to be a *subscriber* email of the mailman2 list, so mailman2 gets it first and *then* passes on. actually i think for convenience (and the archives here) i'll cut/paste the relevant section: exim4 - public-inbox setup setup exim4 as usual in Debian 10 use split conf setup mailman as usual in Debian 10 exim4: routers - please note order of routers is important otherwise mail would reach one and not other router 890_local_pi 900_exim4-config_local_user conf.d/router/890_local_pi --- # Router for public-inbox public_inbox: debug_print = "R: public_inbox for $local_part@$domain" driver = accept # require_files = PI_HOME/check.pck domains = test.local check_local_user local_parts = test transport = public_inbox_transport --- conf.d/transport/45_local_pi --- # Public-inbox transport public_inbox_transport: debug_print = "T: publix_inbox for $local_part@$domain" driver = pipe command = /usr/local/bin/public-inbox-mda user = $local_part group = $local_part delivery_date_add envelope_to_add return_path_add umask = 066 --- i set that umask to 066 because (A) the archives are public and (B) if you don't, various other programs can't see the result (gitweb for example). "local_parts=test" is what needs replacing with "the_subscriber_or_list" before the @. "domains = test.local" is what you replace with the list domain. there's a way to get multiple email addresses "listened" to (multiple subscribers), however if using the mailman2 setup, and the same "subscriber" is subscribed to all the lists then all mailman messages would come to the one email address. if however you wanted to do away with mailman2, and use exim4 as *the* front for diverting to public-inbox, and you want multiple separate addresses, they'd go into "local_parts = ...." using exim4 colon-separated lists, i forget exactly how that's done, it's in the bugreport above. > > a section to disable spam and also adding the listid to the config is > > critical otherwise public-inbox-mda fails silently. > > There's also '--no-precheck' on the command-line to disable > spam filtering, but yes, listid is useful. veera couldn't get it working without > > regarding the httpd it was a nuisance to set up as there was no error > > reporting. i tracked down in the exammples how to add 3 lines to do > > logging, this really should be there by default at least commented out. > > Huh? Do you mean AccessLog middleware or something else? yes AccessLog::Timed. it was in the cgi script (commented-out), i was having a hell of a job working out the difference between "is this failing at nginx proxy_pass, is this failing at fcgid, is this failing at public-inbox-httpd, is the url correct on nginx proxy_pass" and because of the complete lack of access log indication that anything was going through, let alone what url was being passed from nginx (when i finally got that running), it was much more challenging than it should have been. > Errors should be logged to stderr. > > AccessLog isn't enabled by default since either folks don't care > and don't want to waste space; that's what logrotate is for :) and, also, i have fail2ban monitoring log files, with a rather draconian "zero tolerance" policy for anyone trying to access anything with ".php" let alone "wordpressadminlogin.php". you run a server, so you know how mental things get. > or they're very picky about what > format their logs are in and any default format wouldn't work for > them. it's better than a kick in the teeth. commented-out - in public-inbox-httpd - would at least give them the hint. ideally it should be command-line-enabled (and the format specifier allowed to be overridden, that's how it works in nginx / apache2). > > also being able to specify the URL for git repos would be handy because > > we already run gitweb and git-daemon, the URL is different ane would > > need source hacking to specify an alternative. > > Huh? Do you mean $INBOX_DIR/cloneurl for the inbox? That's > gitweb-compatible for v1 inboxes, at least. yes the clone url. it... works! however i have one via gitweb as well. > Or do you mean for coderepos? There's `coderepo..cgitUrl' > (see public-inbox-config(5)) right now, but perhaps > `coderepo..gitwebUrl' should also be supported. https://git.libre-riscv.org/?p=libre-riscv-dev.git;a=summary i'd like that URL (or its git clone equivalent for gitweb) to be in the list of mirrors. i looked up those two config options, they don't seem to exist (not exactly by those names). l.