A simple realtime Chat Application in Python using Django
- Python
- JavaScript
- HTML
- CSS
- Django
- Ajax
- Install Pip following this instruction
- Set up virtual environment following this instruction
- Clone this repository to your working directory
- Install dependencies from requirements.txt:
pip install -r requirements.txt
- Create a .env file in realchat folder, generate a random SECRET_KEY and copy paste into the .env file:
from django.core.management.utils import get_random_secret_key
print(get_random_secret_key())
# within the .env file
SECRET_KEY = "{new secret key}"
- To run the server, activate the virtual environment, and running the following command:
# migrate
python manage.py migrate
# create admin and follow the instructions
python manage.py createsuperuser
# run server
python manage.py runserver
- Have replaced the unsecured SECRET_KEY with a new one