# Django Chat Application
This is a real-time chat application built with Django and WebSockets using Django Channels.
## Features
- User authentication (login/logout/register)
- Real-time messaging using WebSockets
- Chat rooms for group discussions
- Private messaging between users
- Responsive UI with Bootstrap
## Installation & Setup
Follow these steps to set up the project:
### 1. Clone the Repository
```bash
git clone https://github.com/Fotsingboris/chat_app.git
cd django-chat-apppython -m venv venv
# On Windows
venv\Scripts\activate
# On macOS/Linux
source venv/bin/activatepip install -r requirements.txtpython manage.py migratepython manage.py createsuperuserdaphne chat_app.asgi:applicationOpen your browser and go to:
http://127.0.0.1:8000/login
Make sure ASGI_APPLICATION is set correctly in settings.py:
ASGI_APPLICATION = 'myproject.asgi.application'Add daphne in INSTALLED_APPS:
INSTALLED_APPS = [
...
'daphne',
]Configure CHANNEL_LAYERS (example using In-Memory backend):
CHANNEL_LAYERS = {
"default": {
"BACKEND": "channels.layers.InMemoryChannelLayer"
}
}sudo apt install redis
redis-serverCHANNEL_LAYERS = {
"default": {
"BACKEND": "channels_redis.core.RedisChannelLayer",
"CONFIG": {
"hosts": [("127.0.0.1", 6379)],
},
},
}This project is licensed under the MIT License.
Developed by Fotsing Tchoupe Mathieu Boris.