diff --git a/docs/gunicorn_ext.py b/docs/gunicorn_ext.py index 3fee43c8..666afe21 100755 --- a/docs/gunicorn_ext.py +++ b/docs/gunicorn_ext.py @@ -3,6 +3,8 @@ import inspect import gunicorn.config as guncfg HEAD = """ +.. _settings: + Settings ======== diff --git a/docs/source/configure.rst b/docs/source/configure.rst index 00c904d1..fa95f415 100644 --- a/docs/source/configure.rst +++ b/docs/source/configure.rst @@ -31,31 +31,20 @@ Once again, in order of least to most authoritative: It also allows you to know if your application can be launched. -Framework Settings -================== +Command Line +============ -Currently, only Paster applications have access to framework specific -settings. If you have ideas for providing settings to WSGI applications or -pulling information from Django's settings.py feel free to open an issue_ to -let us know. +If an option is specified on the command line, it overrides all other values +that may have been specified in the app specific settings, or in the optional +configuration file. Not all Gunicorn settings are available to be set from the +command line. To see the full list of command line settings you can do the +usual:: -.. _issue: http://github.com/benoitc/gunicorn/issues + $ gunicorn -h -Paster Applications -------------------- +There is also a ``--version`` flag available to the command line scripts that +isn't mentioned in the list of :ref:`settings `. -In your INI file, you can specify to use Gunicorn as the server like such:: - - [server:main] - use = egg:gunicorn#main - host = 192.168.0.1 - port = 80 - workers = 2 - proc_name = brim - -Any parameters that Gunicorn knows about will automatically be inserted into -the base configuration. Remember that these will be overridden by the config -file and/or the command line. Configuration File ================== @@ -85,18 +74,31 @@ number of processors:: raise RuntimeError("No sysconf detected.") return os.sysconf("SC_NPROCESSORS_ONLN") -Command Line -============ +All the settings are mentionned in the :ref:`settings ` list. -If an option is specified on the command line, it overrides all other values -that may have been specified in the app specific settings, or in the optional -configuration file. Not all Gunicorn settings are available to be set from the -command line. To see the full list of command line settings you can do the -usual:: - $ gunicorn -h +Framework Settings +================== -There is also a ``--version`` flag available to the command line scripts that -isn't mentioned in the list of settings. +Currently, only Paster applications have access to framework specific +settings. If you have ideas for providing settings to WSGI applications or +pulling information from Django's settings.py feel free to open an issue_ to +let us know. -.. include:: settings.rst +.. _issue: http://github.com/benoitc/gunicorn/issues + +Paster Applications +------------------- + +In your INI file, you can specify to use Gunicorn as the server like such:: + + [server:main] + use = egg:gunicorn#main + host = 192.168.0.1 + port = 80 + workers = 2 + proc_name = brim + +Any parameters that Gunicorn knows about will automatically be inserted into +the base configuration. Remember that these will be overridden by the config +file and/or the command line. diff --git a/docs/source/design.rst b/docs/source/design.rst index 0fe65ef6..fd895d2e 100644 --- a/docs/source/design.rst +++ b/docs/source/design.rst @@ -1,3 +1,4 @@ + .. _design: ====== diff --git a/docs/source/index.rst b/docs/source/index.rst index 29d0de4b..51f19959 100644 --- a/docs/source/index.rst +++ b/docs/source/index.rst @@ -22,7 +22,7 @@ Features .. note:: - main Gunicorn website on http://gunicorn.org + main Gunicorn website on http://gunicorn.org .. note:: @@ -34,11 +34,12 @@ Contents -------- .. toctree:: - :titlesonly: + :maxdepth: 2 install run configure + settings deploy design signals diff --git a/docs/source/settings.rst b/docs/source/settings.rst index 719022e9..162730e8 100644 --- a/docs/source/settings.rst +++ b/docs/source/settings.rst @@ -1,4 +1,6 @@ +.. _settings: + Settings ======== @@ -417,20 +419,20 @@ By default: %(h)s %(l)s %(u)s %(t)s "%(r)s" %(s)s %(b)s "%(f)s" "%(a)s" -h: remote address -l: '-' -u: currently '-', may be user name in future releases -t: date of the request -r: status line (ex: GET / HTTP/1.1) -s: status -b: response length or '-' -f: referer -a: user agent -T: request time in seconds -D: request time in microseconds, -p: process ID -{Header}i: request header -{Header}o: response header +| h: remote address +| l: '-' +| u: currently '-', may be user name in future releases +| t: date of the request +| r: status line (ex: GET / HTTP/1.1) +| s: status +| b: response length or '-' +| f: referer +| a: user agent +| T: request time in seconds +| D: request time in microseconds, +| p: process ID +| {Header}i: request header +| {Header}o: response header errorlog ~~~~~~~~ @@ -771,12 +773,12 @@ PROXY protocol: http://haproxy.1wt.eu/download/1.5/doc/proxy-protocol.txt Example for stunnel config:: -[https] -protocol = proxy -accept = 443 -connect = 80 -cert = /etc/ssl/certs/stunnel.pem -key = /etc/ssl/certs/stunnel.key + [https] + protocol = proxy + accept = 443 + connect = 80 + cert = /etc/ssl/certs/stunnel.pem + key = /etc/ssl/certs/stunnel.key proxy_allow_ips ~~~~~~~~~~~~~~~