[Python-checkins] peps: Use Twisted Web as it's a bit simpler to configure and is Python

donald.stufft python-checkins at python.org
Wed May 14 16:38:09 CEST 2014


http://hg.python.org/peps/rev/2e8893ae1431
changeset: 5477:2e8893ae1431
user: Donald Stufft <donald at stufft.io>
date: Wed May 14 10:37:40 2014 -0400
summary:
 Use Twisted Web as it's a bit simpler to configure and is Python
files:
 pep-0470.txt | 26 +++++++-------------------
 1 files changed, 7 insertions(+), 19 deletions(-)
diff --git a/pep-0470.txt b/pep-0470.txt
--- a/pep-0470.txt
+++ b/pep-0470.txt
@@ -60,12 +60,12 @@
 Compared to the complex rules which a project must be aware of to prevent
 themselves from being considered unsafely hosted setting up an index is fairly
 trivial and in the simplest case does not require anything more than a
-filesystem and a standard web server such as Nginx. Even if using simple
-static hosting without autoindexing support, it is still straightforward
-to generate appropriate index pages as static HTML.
+filesystem and a standard web server such as Nginx or Twisted Web. Even if
+using simple static hosting without autoindexing support, it is still
+straightforward to generate appropriate index pages as static HTML.
 
-Example Index with Nginx
-~~~~~~~~~~~~~~~~~~~~~~~~
+Example Index with Twisted Web
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 
 1. Create a root directory for your index, for the purposes of the example
 I'll assume you've chosen ``/var/www/index.example.com/``.
@@ -73,22 +73,10 @@
 as ``mkdir -p /var/www/index.example.com/{foo,bar,other}/``.
 3. Place the package files for each project in their respective folder,
 creating paths like ``/var/www/index.example.com/foo/foo-1.0.tar.gz``.
-4. Configure nginx to serve the root directory, ideally with TLS, with the
- autoindex directive enable (see below for example configuration).
+4. Configure Twisted Web to serve the root directory, ideally with TLS.
 
 ::
-
- server {
- listen 443 ssl;
- server_name index.example.com;
-
- ssl_certificate /etc/pki/tls/certs/index.example.com.crt;
- ssl_certificate_key /etc/pki/tls/certs/index.example.com.key;
-
- root /var/www/index.example.com;
-
- autoindex on;
- }
+ $ twistd -n web --path /var/www/index.example.com/
 
 
 Examples of Additional indexes with pip
-- 
Repository URL: http://hg.python.org/peps


More information about the Python-checkins mailing list

AltStyle によって変換されたページ (->オリジナル) /