A gunicorn based django runserver command.
Project description
django-serve
A gunicorn based django runserver command.
Install
python3 -m pip install django-serve
and add to INSTALLED_APPS
#!python
INSTALLED_APPS = [
...
"django_serve.apps.ServeConfig",
...
]
Usage
./manage.py serve
options
--addr
The socket address to bind [default=127.0.0.1]--port
The socket port to bind [default=8000]--workers
The number of worker processes for handling requests [default max(1, (cpu + 1) / 2)]--name
A base to use with setproctitle for process naming [default=django]--wsgi
Dotted path to wsgi application [default=settings.WSGI_APPLICATION]--config
The Gunicorn config file [default=None]--log-level
The granularity of Error log outputs (debug, info, warning, error, critical) [default=info]--logformat
The access log format (default='"%(m)s %(U)s%(q)s %(H)s" %(s)s %(B)s' same as default django runserver)--logger-class
The logger you want to use to log events [default=gunicorn_color.Logger if installed else gunicorn default one]--reload-engine
Which reload engine to use between polling or inotify (or not at all) [default=auto]
CHANGES
0.2.0
- use black
- drop Python 3.5 support
- add Django 3.2 support
- add Python 3.9 and 3.10 support
- add django-serve command
- add support for python -m django_serve
- install inotify only on linux platform
- add --reload-engine and DJANGO_DEFAULT_RELOAD_ENGINE option
- update default workers count
0.1.1
- add gunicorn-color as required
0.1.0
- initial implementation
- add support for gunicorn config file
- add custom django reloader
- add log-level option
- add logformat configuration
- add logger-class option
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distributions
No source distribution files available for this release.See tutorial on generating distribution archives.
Built Distribution
django_serve-0.2-py3-none-any.whl
(12.3 kB
view hashes)
Close
Hashes for django_serve-0.2-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | e4bbdd76d5da1fae5bfa500233a627131b95bb4c55cf10cb0d5da32ead4fa199 |
|
MD5 | c4dcf216e42c09f035f6c8685a6a949c |
|
BLAKE2b-256 | 50c67233a7eca71ce89a11ce3ca38982685490934b5773020f7d65c8f388d57b |