Load home page
This commit is contained in:
@ -6,11 +6,21 @@ It exposes the ASGI callable as a module-level variable named ``application``.
|
||||
For more information on this file, see
|
||||
https://docs.djangoproject.com/en/3.2/howto/deployment/asgi/
|
||||
"""
|
||||
|
||||
import os
|
||||
|
||||
from django.core.asgi import get_asgi_application
|
||||
|
||||
os.environ.setdefault("DJANGO_SETTINGS_MODULE", "event.settings")
|
||||
import django
|
||||
|
||||
application = get_asgi_application()
|
||||
django.setup()
|
||||
|
||||
from channels.auth import AuthMiddlewareStack
|
||||
from channels.routing import ProtocolTypeRouter, URLRouter
|
||||
from django.core.asgi import get_asgi_application
|
||||
from app.website.routing import websocket_urlpatterns
|
||||
|
||||
|
||||
application = ProtocolTypeRouter(
|
||||
{
|
||||
"websocket": AuthMiddlewareStack(URLRouter(websocket_urlpatterns)),
|
||||
}
|
||||
)
|
||||
|
Reference in New Issue
Block a user