mirror of
https://github.com/django/django.git
synced 2025-01-03 06:55:47 +00:00
Refs #35591 -- Emphasized that runserver is not suitable for production.
This commit is contained in:
parent
49815f70e4
commit
cec62fb99e
@ -36,6 +36,14 @@ Some of the checks described below can be automated using the :option:`check
|
|||||||
--deploy` option. Be sure to run it against your production settings file as
|
--deploy` option. Be sure to run it against your production settings file as
|
||||||
described in the option's documentation.
|
described in the option's documentation.
|
||||||
|
|
||||||
|
Switch away from ``manage.py runserver``
|
||||||
|
========================================
|
||||||
|
|
||||||
|
The :djadmin:`runserver` command is not designed for a production setting. Be
|
||||||
|
sure to switch to a production-ready WSGI or ASGI server. For a few common
|
||||||
|
options, see :doc:`WSGI servers </howto/deployment/wsgi/index>` or
|
||||||
|
:doc:`ASGI servers </howto/deployment/asgi/index>`.
|
||||||
|
|
||||||
Critical settings
|
Critical settings
|
||||||
=================
|
=================
|
||||||
|
|
||||||
|
@ -12,7 +12,8 @@ the scope of what Django can give you as guidance.
|
|||||||
|
|
||||||
Django, being a web framework, needs a web server in order to operate. And
|
Django, being a web framework, needs a web server in order to operate. And
|
||||||
since most web servers don't natively speak Python, we need an interface to
|
since most web servers don't natively speak Python, we need an interface to
|
||||||
make that communication happen.
|
make that communication happen. The :djadmin:`runserver` command starts a
|
||||||
|
lightweight development server, which is not suitable for production.
|
||||||
|
|
||||||
Django currently supports two interfaces: WSGI and ASGI.
|
Django currently supports two interfaces: WSGI and ASGI.
|
||||||
|
|
||||||
|
@ -870,11 +870,11 @@ are reserved for the superuser (root).
|
|||||||
This server uses the WSGI application object specified by the
|
This server uses the WSGI application object specified by the
|
||||||
:setting:`WSGI_APPLICATION` setting.
|
:setting:`WSGI_APPLICATION` setting.
|
||||||
|
|
||||||
DO NOT USE THIS SERVER IN A PRODUCTION SETTING. It has not gone through
|
.. warning:: DO NOT USE THIS SERVER IN A PRODUCTION SETTING.
|
||||||
security audits or performance tests. (And that's how it's gonna stay. We're in
|
|
||||||
the business of making web frameworks, not web servers, so improving this
|
This lightweight development server has not gone through security audits or
|
||||||
server to be able to handle a production environment is outside the scope of
|
performance tests, hence is unsuitable for production. Making this server
|
||||||
Django.)
|
able to handle a production environment is outside the scope of Django.
|
||||||
|
|
||||||
The development server automatically reloads Python code for each request, as
|
The development server automatically reloads Python code for each request, as
|
||||||
needed. You don't need to restart the server for code changes to take effect.
|
needed. You don't need to restart the server for code changes to take effect.
|
||||||
|
Loading…
Reference in New Issue
Block a user