This project is a Blog site written with python3.9 and Django3.2 and Django_rest_framework_3.12 which is for using api.
- Authentication with phone number and Otp code.
- Send otp code to user's phone.
- Two-step verification for authentication.
- Use cache to temporarily store otp code.
- Generate tokens using simple-jwt after authentication.
- Production-ready configuration for Static Files, Database Settings, Gunicorn, Ngnix, Docker.
- Easy installation.
- Automatically delete photos after deleting the blog.
- Ability to comment on blogs.
- Use the PostgreSQL database to store data.
- Python 3.9 , Programming Language.
- Django 3.2 , Web Framework.
- Django Rest Framework 3.12 , Web API's.
- Nginx , Web Server.
- Docker , Container Platform.
- PostgreSQL , Database.
- Gunicorn , WSGI HTTP Server.
- Git , VCS(Version Control System).
install Docker
To run this project, you must install Docker and docker-compose.
and also install docker-compose.
Clone the project
git clone https://github.com/amirpsd/drf_blog_api.git && cd drf_blog_api && cp .env-sample .env && cp .env.db-example .env.db && rm .env-sample .env.db-example
Please enter the required information in the .env and .env.db files before running the project.
Run project
create docker network
docker network create nginx_network1
docker network create blog_network
create docker volume
docker volume create db_data
run project
docker-compose up -d
You can see the endpoints.yaml file to see the exact details of the endpoints.
or you can go to http://127.0.0.1:8000/api/schema/swagger-ui/ or http://127.0.0.1:8000/api/schema/redoc/ to see the endpoints after running the project.
see the LICENSE file for details.