This project is designed to help you understand the main usage of Redis, a popular platform for dealing with caching. By following the steps outlined below, you will be able to set up and run this project on your local machine.
Before you begin, make sure you have the following installed on your machine:
- Python 3.x
- Git
First, you need to clone the project repository from GitHub. Open your terminal and run the following command:
git clone https://github.com/Harish-2003/django-and-redis.git
Navigate to the project directory and create a virtual environment. You can use venv
for this purpose. Run the following commands:
cd django-and-redis
python -m venv env
.\env\Scripts\activate
source env/bin/activate
Install the required dependencies using pip:
pip install -r requirements.txt
You need to install Redis on your machine. For Windows users, download the Redis installer from the following link:
Follow the instructions provided in the installer to complete the setup.
Depending on your platform and the port you are using, you might need to update the settings.py
file in your Django project. Ensure that the Redis configurations match your local setup.
After setting up everything, you can run the Django development server. Use the following command:
python manage.py runserver
Open your web browser and navigate to http://127.0.0.1:8000