项目作者: rishank-shah

项目描述 :
Ecommerce Website Using Django
高级语言: HTML
项目地址: git://github.com/rishank-shah/django-ecommerce.git
创建时间: 2021-03-30T03:33:59Z
项目社区:https://github.com/rishank-shah/django-ecommerce

开源协议:

下载


Django Ecommerce


Table of Contents


Requirements for running project


Before running the project make sure that postgresql, elasticsearch and redis servers are running.

Steps for running project:

Clone Repository:
  1. git clone https://github.com/rishank-shah/django-ecommerce.git
  2. cd django-ecommerce
  3. cp .env.example .env
Environment Setup:
  1. pip install virtualenv
  2. virtualenv venv
Create DB
Create a DB in postgresql and enter the same DB name in the .env file
Fill .env file:
Fill the .env file with the correct database, cloudinary, email, sentry credentials, elasticsearch and redis url.
Installation of Dependencies:
  1. source venv/bin/activate
  2. pip install -r requirements.txt
Migrations and SuperUser
  1. source venv/bin/activate
  2. source .env
  3. python manage.py migrate
  4. python manage.py createsuperuser
Running Django Server:
  1. source venv/bin/activate
  2. source .env
  3. python manage.py runserver
Running Celery:
For running celery open another terminal navigate to django-ecommerce folder and execute the following commands
  1. source venv/bin/activate
  2. source .env
  3. celery -A ecommerce_project worker -l info
ElasticSearch:
If you are facing an error while saving products in admin, navigate to django-ecommerce folder and execute the following commands
  1. source venv/bin/activate
  2. source .env
  3. python manage.py search_index --rebuild
Press y and enter

Initial Data

You can load some initial data from fixture load_product_data.json
Please Note Images will not be displayed as your cloudinary account will be different
  1. source venv/bin/activate
  2. source .env
  3. python manage.py loaddata load_product_data.json


If all commands run successfully website will be running on PORT 8000 on localhost http://localhost:8000