Options (2)
-b, --bindbooleanListen on port 8080 on localhost
Example:
gunicorn {{[-b|--bind]}} {{localhost}}:{{8080}} {{import.path:app_object}}-w, --workersbooleanUse 4 worker processes for handling requests
Example:
gunicorn {{[-w|--workers]}} {{4}} {{import.path:app_object}}Examples (6)
Run Python web app
gunicorn import.path:app_objectListen on port 8080 on localhost
gunicorn [-b|--bind] localhost:8080 import.path:app_objectTurn on live reload
gunicorn --reload import.path:app_objectUse 4 worker processes for handling requests
gunicorn [-w|--workers] 4 import.path:app_objectUse 4 worker threads for handling requests
gunicorn --threads 4 import.path:app_objectRun app over HTTPS
gunicorn --certfile cert.pem --keyfile key.pem import.path:app_objectmade by @shridhargupta | data from tldr-pages