“Gunicorn” Code-Antworten

Gunicorn installieren

pip install gunicorn
Random boi

Gunicorn

$ pip install gunicorn
$ cat myapp.py
def app(environ, start_response):
  data = b"Hello, World!\n"
  start_response("200 OK", [
    ("Content-Type", "text/plain"),
    ("Content-Length", str(len(data)))
  ])
  return iter([data])
$ gunicorn -w 4 myapp:app
[2014-09-10 10:22:28 +0000] [30869] [INFO] Listening at: http://127.0.0.1:8000 (30869)
[2014-09-10 10:22:28 +0000] [30869] [INFO] Using worker: sync
[2014-09-10 10:22:28 +0000] [30874] [INFO] Booting worker with pid: 30874
[2014-09-10 10:22:28 +0000] [30875] [INFO] Booting worker with pid: 30875
[2014-09-10 10:22:28 +0000] [30876] [INFO] Booting worker with pid: 30876
[2014-09-10 10:22:28 +0000] [30877] [INFO] Booting worker with pid: 30877
Talhah Patelia

So überprüfen Sie die Gunicorn -Version

how to check gunicorn version
Colorful Cottonmouth

Ähnliche Antworten wie “Gunicorn”

Durchsuchen Sie beliebte Code-Antworten nach Sprache

Durchsuchen Sie andere Codesprachen