Skip to content

oldcorvus/SocialMedia

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

25 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Django Social Media With RestApi using DRF and JWT authentication

Setup

The first thing to do is to clone the repository:

$ git clone https://github.com/oldcorvus/social-media.git

Create a virtual environment to install dependencies in and activate it:

$ virtualenv env
$ source env/bin/activate

Then install the dependencies:

(env)$ pip install -r requirements.txt

Once pip has finished downloading the dependencies:

(env)$ cd app 
(env)$ python manage.py runserver --settings=socialMedia.settings.test

And navigate to http://127.0.0.1:8000/.

Running Locally with Docker

1.build the image:

  $ docker-compose build .

2.Spin up the containers

  $ docker-compose up

then view the site at http://localhost:8000/

Walkthrough

Before you interact with the application, go to settings and set up secret key.

Tests

To run the tests, cd into the directory where manage.py is:

(env)$ python manage.py test --settings=socialMedia.settings.test

API Docs

navigate to http://127.0.0.1:8000/swagger/

Features

rest api using drf, jwt authentications, activity stream, ajax scrolling , and ...