From f2d9bf6b775492f376be33f7940dc9e5eb00c2bc Mon Sep 17 00:00:00 2001
From: benoitc
-Optionally, you can provide your own worker by giving gunicorn a python path -to a subclass of gunicorn.workers.base.Worker. This alternative syntax will -load the gevent class: -gunicorn.workers.ggevent.GeventWorker. -Alternatively the syntax can also load the gevent class with -egg:gunicorn#gevent
+Optionally, you can provide your own worker by giving gunicorn a +python path to a subclass of gunicorn.workers.base.Worker. This +alternative syntax will load the gevent class: +gunicorn.workers.ggevent.GeventWorker. Alternatively the syntax +can also load the gevent class with egg:gunicorn#gevent
Switch worker processes to run as this user.
A valid user id (as an integer) or the name of a user that can be @@ -307,7 +305,7 @@ the worker process user.
Switch worker process to run as this group.
A valid group id (as an integer) or the name of a user that can be @@ -340,36 +338,59 @@ temporary directory.
A dictionary containing headers and values that the front-end proxy uses to indicate HTTPS requests. These tell gunicorn to set -wsgi.url_scheme to "https", so your application can tell that the +wsgi.url_scheme to "https", so your application can tell that the request is secure.
-The dictionary should map upper-case header names to exact string values. The value comparisons are case-sensitive, unlike the header names, so make sure they're exactly what your front-end proxy sends when handling HTTPS requests.
-It is important that your front-end proxy configuration ensures that the headers defined here can not be passed directly from the client.
-The Access log file to write to.
+"-" means log to stdout.
+The Access log format .
+By default:
+%(h)s %(l)s %(u)s %(t)s "%(r)s" %(s)s %(b)s "%(f)s" "%(a)s"
+h: remote address +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
+You can also pass any WSGI request header as a parameter. +(ex '%(HTTP_HOST)s').
+The log file to write to.
+The Error log file to write to.
"-" means log to stdout.
The granularity of log outputs.
+The granularity of Error log outputs.
Valid level names are:
The log config file to use.
-Gunicorn uses the standard Python logging module's Configuration -file format.
+The logger you want to use to log events in gunicorn.
+The default class (gunicorn.glogging.Logger) handle most of +normal usages in logging. It provides error and access logging.
+You can provide your own worker by giving gunicorn a +python path to a subclass like gunicorn.glogging.Logger. +Alternatively the syntax can also load the Logger class +with ``egg:gunicorn#simple`
+Called just before the master process is initialized.
The callable needs to accept a single instance variable for the Arbiter.
-def start_server(server): - pass --
Called just after the server is started.
-The callable needs to accept a single instance variable for the Arbiter.
-Called during a reload from a SIGHUP signal. -This callback should create an appropriate number of new workers. -Old workers will be killed automatically by gunicorn, so it is not required to do so here.
+Called to recycle workers during a reload via SIGHUP.
+The callable needs to accept a single instance variable for the Arbiter.
++def start_server(server): + pass ++
Called just after the server is started.
The callable needs to accept a single instance variable for the Arbiter.
-def post_request(worker, req):
+def post_request(worker, req, environ):
pass
Contents