Skip to content

Back-end du projet 1CS E-tourisme avec FastAPI, PostgreSQL, Docker and Heroku

License

Notifications You must be signed in to change notification settings

m0kr4n3/projet1cs_backend

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Projet 1CS backend

Back-end du projet 1CS E-tourisme avec FastAPI, PostgreSQL, Docker and Heroku.

Features

  • Docker with FastAPI and PostgresSQL.
  • Authentication and securing routes with JWT tokens
  • Fastapi which means an interactive API documentation.

Built on Python: 3.8.

File Structure

.
├── app
│   ├── Dockerfile
│   ├── main.py
│   ├── requirements.txt
│   ├── .env
│   └── src
│       ├── api
│           ├── endpoints
│           ├── api.py
│           └── deps.py
│       ├── core
│           ├── config.py
│           └── security.py
│       ├── crud
│           ├── base.py
│       ├── db
│           ├── base_class.py
│           ├── base.py
│           ├── init_db.py
│           └── session.py
│       ├── models
│       └── schemas
└── docker-compose.yml

Installation and usage

  • clone the repository
git clone git@github.com:m0kr4n3/fastapi_projetct_template.git
cd fastapi_projetct_template/app/
  1. Using python
  • use venv virtual environment
pip install venv
python -m venv venv
source $PWD/venv/bin/activate
  • Install dependencies
pip install -r requirements.txt
  • Create env from env template:
cp example.env .env #only once
  • Put there the necessary info
  • Run main.py
python main.py
  1. Using docker Install docker-compose if it's not done already
sudo apt install docker-compose
  • Run docker-compose in the repo root directory :
sudo docker-compose up

Used this template FastAPI Project Template

About

Back-end du projet 1CS E-tourisme avec FastAPI, PostgreSQL, Docker and Heroku

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages