tonible14012002 / Instagram-Stories

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Instagram Stories Clone

Getting Started

Project Structure

Production

Backend Web
... ...

Local Development

Backend Web
localhost:8080 ---

With Docker

  1. Build system
docker compose -f local.yaml up --build -d --remove-orphans

Or using makefile

make build # Build container
make down # Shutdown the container

Local Installation

  1. create Virtual environment (optional/suggest) Go to project folder, run these commands
virtualenv env
  1. Activate virtual env For deactivate the env later, use deactivate cmd.
source env/bin/activate
  1. Install Dependencies
python -m pip install -r requirements/local.txt
  1. Connect the Database he project use SQLite for default. To connect to custom database, config the DATABASE VARIABLE in config/settings/base.py.

    Follow the Django docs for more details.

  2. Migrate database adn staticfiles

python manage.py migrate --no-input
python manage.py collectstatic --no-input
  1. Run the server through network
python manage.py runserver 0.0.0.0:8000

Development

Seed Data

  • Seed users instance
make seed_users count=20
  • Seed users' relationships
make seed_relationships count=50
  • Seed stories
make seed_stories count=50

For more commands -> Makefile

Contribution

If you have suggestions for improvements or spot any issues with the project, feel free to submit an issue or pull request to this repo

About


Languages

Language:Python 75.6%Language:Shell 10.9%Language:PLpgSQL 8.4%Language:Dockerfile 3.0%Language:Makefile 2.1%