social-media-api

January 28, 2022 · View on GitHub

Python API development course

  • Project file structure
.
└── src
    ├── __init__.py
    ├── config.py
    ├── database.py
    ├── main.py
    ├── oauth2.py
    ├── routers
    │   ├── __init__.py
    │   ├── auth.py
    │   ├── posts.py
    │   ├── users.py
    │   └── vote.py
    ├── schemas.py
    └── utils.py

Setup using Docker

The API instance runs on https://localhost:8000 using default values of Dockerfile.

  • Building a new image
> docker build -t <tag-name> .
> docker-compose up -d
  • Pulling the existing image
> docker pull devansh3712/social-media-api