Skip to content

To-n-y/forum-api

Repository files navigation

Forum API

Code checks

This project uses: Python, FastAPI and SQLAlchemy

How to run

Installing application

First you should create env folder using commands:

mkdir project
cd project
python -m venv env
cd env
cd Scripts
activate.bat

To install the application use following commands:

cd..
cd..
python -m pip install --upgrade pip
git clone https://github.com/To-n-y/forum-api.git
cd forum-api
pip install -r requirements.txt

Environment configuration

.env file is already added

Create database

This api uses sqlite database, so create db folder in the root directory

mkdir db

Running the application in dev mode

You can run this application in dev mode:

uvicorn app.main:app --reload

Or

make run

Run tests

You can run tests using:

pytest -s -v

Or

make test

Using Docker to run an App

Go to Docker and then Settings -> Resources -> FileSharing. Add project folder and click Apply & Restart To run an app using Docker, you need to run Docker containers by typing simple command:

docker-compose up

Now you can access the app at http://127.0.0.1:8000

About

Simple blog/forum api written in Python/FastApi

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors