Skip to content

smuratk/flask-init-mini

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

flask-init-mini

This project is a boilerplate for future Flask applications.

Below steps can be executed on any unix like system. I will use ubuntu deployed on O'Reilly's sandbox (alternatively you could use Katacoda's playground). Once the sandbox/playground is ready, execute instructions specified in below sections.

Setup SSH key

This step is option and can be omitted.

Create ssh key and add it to GitHub's SSH keys settings.

ssh-keygen
cat ~/.ssh/id_rsa.pub

Installation

# Cloning the source code
git clone https://github.com/ldynia/flask-init-mini.git
cd flask-init-mini

# Building and running docker container
docker build --tag flask-mini --build-arg FLASK_DEBUG=True .
docker run --detach --name flask-app --publish 80:8080 --rm flask-mini
docker ps

API

curl "http://localhost"

Testing

Unit test

docker exec flask-app pytest

Code coverage

docker exec flask-app coverage run -m pytest
docker exec flask-app coverage report

Stop container

docker stop flask-app

About

Boilerplate for Flask projects

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published