user/dev discussion of public-inbox itself
 help / color / Atom feed
* [PATCH] examples/*.psgi: add examples for -httpd
@ 2020-03-19 23:55 Eric Wong
  0 siblings, 0 replies; only message in thread
From: Eric Wong @ 2020-03-19 23:55 UTC (permalink / raw)
  To: meta

public-inbox-httpd should work with any PSGI files, so make
it more apparent to people reading .psgi examples.
---
 examples/cgit.psgi         | 5 ++++-
 examples/highlight.psgi    | 4 ++++
 examples/newswww.psgi      | 5 ++++-
 examples/public-inbox.psgi | 5 +++++
 4 files changed, 17 insertions(+), 2 deletions(-)

diff --git a/examples/cgit.psgi b/examples/cgit.psgi
index 3aaa4515..e72e832d 100644
--- a/examples/cgit.psgi
+++ b/examples/cgit.psgi
@@ -4,8 +4,11 @@
 #
 # PublicInbox::Cgit may be used independently of WWW.
 #
-# Usage:
+# Usage (development, with auto-reload):
 #	plackup -I lib -o 127.0.0.1 -R lib -r examples/cgit.psgi
+#
+# Usage (production, with public-inbox-httpd(1)):
+#	public-inbox-httpd [OPTIONS] /path/to/examples/cgit.psgi
 use strict;
 use warnings;
 use Plack::Builder;
diff --git a/examples/highlight.psgi b/examples/highlight.psgi
index fd653b18..23ec7861 100644
--- a/examples/highlight.psgi
+++ b/examples/highlight.psgi
@@ -5,6 +5,10 @@
 # Usage: plackup [OPTIONS] /path/to/this/file
 # A startup command for development which monitors changes:
 #	plackup -I lib -o 127.0.0.1 -R lib -r examples/highlight.psgi
+#
+# .psgi paths may also be passed to public-inbox-httpd(1) for
+# production deployments:
+#	public-inbox-httpd [OPTIONS] /path/to/examples/highlight.psgi
 use strict;
 use warnings;
 use PublicInbox::WwwHighlight;
diff --git a/examples/newswww.psgi b/examples/newswww.psgi
index 4753a501..3cce7191 100644
--- a/examples/newswww.psgi
+++ b/examples/newswww.psgi
@@ -8,8 +8,11 @@
 # inbox.  NewsWWW exists because people (or software) can mishandle
 # "nntp://" or "news://" URLs as "http://" (or "https://")
 #
-# Usage:
+# Usage (development, with auto-reload):
 #	plackup -I lib -o 127.0.0.1 -R lib -r examples/newswww.psgi
+#
+# Usage (production, with public-inbox-httpd(1)):
+#	public-inbox-httpd [OPTIONS] /path/to/examples/newsww.psgi
 use strict;
 use warnings;
 use Plack::Builder;
diff --git a/examples/public-inbox.psgi b/examples/public-inbox.psgi
index b9817e83..9891a1f0 100644
--- a/examples/public-inbox.psgi
+++ b/examples/public-inbox.psgi
@@ -3,8 +3,13 @@
 # License: GPL-3.0+ <https://www.gnu.org/licenses/gpl-3.0.txt>
 # Note: this is part of our test suite, update t/plack.t if this changes
 # Usage: plackup [OPTIONS] /path/to/this/file
+#
 # A startup command for development which monitors changes:
 #	plackup -I lib -o 127.0.0.1 -R lib -r examples/public-inbox.psgi
+#
+# .psgi paths may also be passed to public-inbox-httpd(1) for
+# production deployments:
+#	public-inbox-httpd [OPTIONS] /path/to/examples/public-inbox.psgi
 use strict;
 use warnings;
 use PublicInbox::WWW;

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, back to index

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-03-19 23:55 [PATCH] examples/*.psgi: add examples for -httpd Eric Wong

user/dev discussion of public-inbox itself

Archives are clonable:
	git clone --mirror http://public-inbox.org/meta
	git clone --mirror http://czquwvybam4bgbro.onion/meta
	git clone --mirror http://hjrcffqmbrq6wope.onion/meta
	git clone --mirror http://ou63pmih66umazou.onion/meta

Example config snippet for mirrors

Newsgroups are available over NNTP:
	nntp://news.public-inbox.org/inbox.comp.mail.public-inbox.meta
	nntp://ou63pmih66umazou.onion/inbox.comp.mail.public-inbox.meta
	nntp://czquwvybam4bgbro.onion/inbox.comp.mail.public-inbox.meta
	nntp://hjrcffqmbrq6wope.onion/inbox.comp.mail.public-inbox.meta
	nntp://news.gmane.io/gmane.mail.public-inbox.general

 note: .onion URLs require Tor: https://www.torproject.org/

AGPL code for this site: git clone https://public-inbox.org/public-inbox.git