🚀 Live Demo on Render: AnonymousChat
AnonymousChat is a web application that allows users to chat anonymously. It generates anonymous usernames for the users if no name is entered and matches one2one chat based on waiting users in the queue. No registration required. This project is based on Django and Channels.
AnonymousChat is a web application that allows users to chat anonymously. It generates anonymous usernames for the users if no name is entered and matches one2one chat based on waiting users in the queue. No registration required. This project is based on Django and Channels.
Python with Django framework, Channels and Daphne Asgi server, JavaScript.
1. Automatic deployment on linux server using setup.sh:
sudo -s
git clone https://github.com/MurtadaAhmed/AnonymousChat.git
cd AnonymousChat
chmod +x setup.sh
./setup.sh
CSRF_TRUSTED_ORIGINS environment variable need to be passed with the website url.
default username: admin
default password: password
The setup will create a file "run.sh". To re-run the server again after stopping it:
./run.sh
2. Automatic deployment using Docker:
Build docker image:
docker build -t anonymous-chat -f Dockerfile .
When running the docker container, when need to pass the environment variable CSRF_TRUSTED_ORIGINS for the website url:
docker run --name anonymous-chat -p 80:80 -e CSRF_TRUSTED_ORIGINS=https://YOUR_WEBSITE_LINK
default username: admin default password: password
3. To run the AnonymousChat application locally, follow these steps:
// These steps suggests that you already have Python installed
- Clone the repo
git clone https://github.com/MurtadaAhmed/AnonymousChat.git- Create a virtual environment and activate it (optional but recommended):
python -m venv venv
source venv/bin/activate # On Windows, use venv\Scripts\activate- Install the required dependencies:
pip install -r requirements.txt
- Makemigrations, migrate and create superuser:
python manage.py makemigrations
python manage.py migrate
python manage.py createsuperuser
- Run the development server:
python manage.py runserver
AnonymousChat should now be accessible at http://localhost:8000/.
4. To deploy the application on Windows server: The included web.config file contains the basic setup for Windows Server IIS server.
Requirements:
- requirements.txt
- IIS web server
- Websocket to be installed from Windows Server 2022 Server Manager
Distributed under the MIT License.
- Murtada Ahmed - Junior Python Web Developer - Murtada Ahmed




