Skip to content

MartinPit/Python-API

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Post API

A simple REST API for managing posts.

Running the app

It's probably best to run the app from a virtual python environment, so we need to create, activate it and set the location of the flask app:

Linux (Bash):

virtualenv -p python3 venv
source venv/bin/activate
export FLASK_APP=app/app

Windows (CMD):

pip install virtualenv
virtualenv -p python3 venv
.\venv\Scripts\activate
set FLASK_APP=app/app

After that, we need to install all the dependencies necessary for the app to run:

pip install -r requirements.txt

Next, we initialize the database:

python -m flask initdb

Finally, we run the app:

python -m flask run

MartinPit's GitHub stats

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages