add: matchmaking

This commit is contained in:
2023-12-12 12:06:13 +01:00
parent ad6cfdf08a
commit ae20be25fb
14 changed files with 152 additions and 3 deletions

View File

@ -10,7 +10,9 @@ https://docs.djangoproject.com/en/4.2/howto/deployment/asgi/
import os
from channels.routing import ProtocolTypeRouter, URLRouter
from channels.auth import AuthMiddlewareStack
import chat.routing
import matchmaking.routing
from django.core.asgi import get_asgi_application
@ -20,7 +22,8 @@ application = ProtocolTypeRouter({
'http':get_asgi_application(),
'websocket':AuthMiddlewareStack(
URLRouter(
chat.routing.websocket_urlpatterns
chat.routing.websocket_urlpatterns +
matchmaking.routing.websocket_urlpatterns
)
)
})

View File

@ -43,6 +43,8 @@ INSTALLED_APPS = [
'channels',
'daphne',
'matchmaking.apps.MatchmakingConfig',
'games.apps.GamesConfig',
'accounts.apps.AccountsConfig',
'profiles.apps.ProfilesConfig',
'frontend.apps.FrontendConfig',