index.txt 1.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142
  1. ====================
  2. How to deploy Django
  3. ====================
  4. Django is full of shortcuts to make web developers' lives easier, but all
  5. those tools are of no use if you can't easily deploy your sites. Since Django's
  6. inception, ease of deployment has been a major goal.
  7. There are many options for deploying your Django application, based on your
  8. architecture or your particular business needs, but that discussion is outside
  9. the scope of what Django can give you as guidance.
  10. Django, being a web framework, needs a web server in order to operate. And
  11. since most web servers don't natively speak Python, we need an interface to
  12. make that communication happen.
  13. Django currently supports two interfaces: WSGI and ASGI.
  14. * `WSGI`_ is the main Python standard for communicating between web servers and
  15. applications, but it only supports synchronous code.
  16. * `ASGI`_ is the new, asynchronous-friendly standard that will allow your
  17. Django site to use asynchronous Python features, and asynchronous Django
  18. features as they are developed.
  19. You should also consider how you will handle :doc:`static files
  20. </howto/static-files/deployment>` for your application, and how to handle
  21. :doc:`error reporting</howto/error-reporting>`.
  22. Finally, before you deploy your application to production, you should run
  23. through our :doc:`deployment checklist<checklist>` to ensure that your
  24. configurations are suitable.
  25. .. _WSGI: https://wsgi.readthedocs.io/en/latest/
  26. .. _ASGI: https://asgi.readthedocs.io/en/latest/
  27. .. toctree::
  28. :maxdepth: 2
  29. wsgi/index
  30. asgi/index
  31. checklist