{"title":"Jak używać Django z Hypercorn","version":"5.1","locale":"pl","docname":"howto/deployment/asgi/hypercorn","url":"/pl/5.1/howto/deployment/asgi/hypercorn/","canonical":"https://djangodocs.dev/pl/5.1/howto/deployment/asgi/hypercorn/","summary":"Hypercorn is an ASGI server that supports HTTP/1, HTTP/2, and HTTP/3 with an emphasis on protocol support. Instalowanie Hypercorn Link to this heading # You can…","html":"<h1>Jak używać Django z Hypercorn<a class=\"heading-anchor\" href=\"#how-to-use-django-with-hypercorn\"><span class=\"visually-hidden\">Link to this heading</span><span aria-hidden=\"true\">#</span></a></h1>\n<p><a class=\"reference external\" href=\"https://hypercorn.readthedocs.io/\">Hypercorn</a> is an ASGI server that supports HTTP/1, HTTP/2, and HTTP/3\nwith an emphasis on protocol support.</p>\n<section id=\"installing-hypercorn\">\n<h2>Instalowanie Hypercorn<a class=\"heading-anchor\" href=\"#installing-hypercorn\"><span class=\"visually-hidden\">Link to this heading</span><span aria-hidden=\"true\">#</span></a></h2>\n<p>You can install Hypercorn with <code class=\"docutils literal notranslate\"><span class=\"pre\">pip</span></code>:</p>\n<div class=\"code-block\" data-language=\"shell\"><div class=\"code-block-toolbar\"><span class=\"code-block-language\">Shell</span><button type=\"button\" class=\"copy-button\" data-copy hidden><span class=\"copy-button-label\">Copy</span></button></div><pre role=\"group\" tabindex=\"0\" aria-label=\"Shell code\"><code>python<span class=\"w\"> </span>-m<span class=\"w\"> </span>pip<span class=\"w\"> </span>install<span class=\"w\"> </span>hypercorn\n</code></pre></div>\n</section>\n<section id=\"running-django-in-hypercorn\">\n<h2>Uruchamianie Django w Hypercorn<a class=\"heading-anchor\" href=\"#running-django-in-hypercorn\"><span class=\"visually-hidden\">Link to this heading</span><span aria-hidden=\"true\">#</span></a></h2>\n<p>When <a class=\"extlink-pypi reference external\" href=\"https://pypi.org/project/Hypercorn/\">Hypercorn</a> is installed, a <code class=\"docutils literal notranslate\"><span class=\"pre\">hypercorn</span></code> command is available\nwhich runs ASGI applications. Hypercorn needs to be called with the\nlocation of a module containing an ASGI application object, followed\nby what the application is called (separated by a colon).</p>\n<p>For a typical Django project, invoking Hypercorn would look like:</p>\n<div class=\"code-block\" data-language=\"shell\"><div class=\"code-block-toolbar\"><span class=\"code-block-language\">Shell</span><button type=\"button\" class=\"copy-button\" data-copy hidden><span class=\"copy-button-label\">Copy</span></button></div><pre role=\"group\" tabindex=\"0\" aria-label=\"Shell code\"><code>hypercorn<span class=\"w\"> </span>myproject.asgi:application\n</code></pre></div>\n<p>Uruchomi to proces nasłuchujący pod adresem <code class=\"docutils literal notranslate\"><span class=\"pre\">127.0.0.1:8000</span></code>. Konieczne jest, aby Twój projekt znajdował się w ścieżce instalacji Pythona; upewnij się, że uruchamiasz to polecenie z tego samego katalogu, co plik <code class=\"docutils literal notranslate\"><span class=\"pre\">manage.py</span></code>.</p>\n<p>For more advanced usage, please read the <a class=\"reference external\" href=\"https://hypercorn.readthedocs.io/\">Hypercorn documentation</a>.</p>\n</section>","rootId":"how-to-use-django-with-hypercorn","toc":[{"title":"Instalowanie Hypercorn","anchor":"installing-hypercorn","children":[]},{"title":"Uruchamianie Django w Hypercorn","anchor":"running-django-in-hypercorn","children":[]}],"breadcrumbs":[{"docname":"howto/index","title":"How-to guides","url":"/pl/5.1/howto/"},{"docname":"howto/deployment/index","title":"Jak wdrażać Django","url":"/pl/5.1/howto/deployment/"},{"docname":"howto/deployment/asgi/index","title":"Jak wdrażać z ASGI","url":"/pl/5.1/howto/deployment/asgi/"}],"prev":{"docname":"howto/deployment/asgi/daphne","title":"Jak używać Django z Daphne","url":"/pl/5.1/howto/deployment/asgi/daphne/"},"next":{"docname":"howto/deployment/asgi/uvicorn","title":"Jak używać Django z Uvicorn","url":"/pl/5.1/howto/deployment/asgi/uvicorn/"},"formats":{"html":"/pl/5.1/howto/deployment/asgi/hypercorn/","markdown":"/pl/5.1/howto/deployment/asgi/hypercorn.md","json":"/pl/5.1/howto/deployment/asgi/hypercorn.json"},"source":"https://github.com/django/django/blob/stable/5.1.x/docs/howto/deployment/asgi/hypercorn.txt","official":"https://docs.djangoproject.com/pl/5.1/howto/deployment/asgi/hypercorn/","inVersions":["6.1","6.0","5.2","5.1","5.0","4.2","4.1","4.0","3.2","3.1"],"inLocales":["en","zh-hans","fr","ja","id","it","pt-br","ko","es","el","pl"]}