From 50c1b933afec4937ebc99e1d372cef2dc6b295c2 Mon Sep 17 00:00:00 2001 From: Eric Wong Date: Fri, 12 Aug 2016 19:52:35 +0000 Subject: www: allow including links to NNTP sites in HTML footer Improve the discoverability of NNTP endpoints for users who still know what NNTP is. ==> ~/.public-inbox/config <== ; aliases for the locally-run nntpd can be specified in ; the "publicinbox" section: [publicinbox] nntpserver = nntp://ou63pmih66umazou.onion/ nntpserver = news.public-inbox.org ; NNTPS is not supported natively, yet, ; but one can use haproxy or similar ; nntpserver = nntps://news.public-inbox.invalid/ ; mirrors for specific inboxes may be specified either as full ; NNTP (or NNTPS) URLs, or with the server name only if the ; newsgroup name is specfied for a local NNTP server [publicinbox "git"] ... newsgroup = inbox.a.b.c nntpmirror = nntp://czquwvybam4bgbro.onion/ nntpmirror = hjrcffqmbrq6wope.onion ; there may be a mirror on a different server with a ; different name: nntpmirror = nntp://news.example.com/differently.named.group ; (And I really need to write manpages for all this...) --- lib/PublicInbox/Config.pm | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'lib/PublicInbox/Config.pm') diff --git a/lib/PublicInbox/Config.pm b/lib/PublicInbox/Config.pm index 5eae1f1d..5adcd0cc 100644 --- a/lib/PublicInbox/Config.pm +++ b/lib/PublicInbox/Config.pm @@ -145,7 +145,10 @@ sub _fill { my $v = $self->{"$pfx.$k"}; $rv->{$k} = $v if defined $v; } - foreach my $k (qw(altid)) { # TODO: more arrays + + # TODO: more arrays, we should support multi-value for + # more things to encourage decentralization + foreach my $k (qw(altid nntpmirror)) { if (defined(my $v = $self->{"$pfx.$k"})) { $rv->{$k} = ref($v) eq 'ARRAY' ? $v : [ $v ]; } -- cgit v1.2.3-24-ge0c7